• 0

    posted a message on Unofficial oUF - methods used for layouts
    Quote from Moon Witch »

    Well damn... Yeah, that's a whole lot shorter LOL

    edit: damn typo


    darn that would be

    if not unit:match('^party') or unit:match('^partypet') then

    thanky you this gives me a way of testing. since I can't get my raid & normal layout in one lua file. keep getting error in the
    if not (self:GetParent():GetName()=='oUF_Party' or unit:find('partypet%d')) then
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    are there otherways of calling the party & partypets then

    if not (self:GetParent():GetName()=='oUF_Party' or unit:find('partypet%d')) then
    Posted in: Unit Frames
  • 0

    posted a message on minimap & Battlegroud
    for some reason it still aint working

    http://www.pastey.net/96890

    Posted in: Lua Code Discussion
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Okay I found out the problem might be related to haveing the raid settings in its own lua file.

    evertime, I tried to combine the stuff in one layout I keep getting errors with

    if not (self:GetParent():GetName()=='oUF_Party' or unit:find('partypet%d')) then


    how would I call upon the party & partypets with out getting errors?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Quote from p3lim »

    seems you have no table named 'raid'


    spawning raid is done by

    oUF:SetActiveStyle('AI_Raid')
    local raid = {}
    for i = 1, 8 do
    	local raidgroup = oUF:Spawn('header', 'oUF_Raid'..i)
    	raidgroup:SetManyAttributes('groupFilter', tostring(i), 'showRaid', true, 'yOffSet', -8)
    	table.insert(raid, raidgroup)
    	if(i==1) then
    		raidgroup:SetPoint('LEFT', UIParent, 'LEFT', 10, -300)
    	else
    		raidgroup:SetPoint('TOPLEFT', raid[i-1], 'TOPRIGHT', 8, 0)
    	end
    	raidgroup:Show()
    end


    I just don't get it, why does it still error. casesensitve is okay both are raid.
    there is a table called raid

    code at this time is

    local partyToggle = CreateFrame('Frame')
    partyToggle:RegisterEvent('PLAYER_LOGIN')
    partyToggle:RegisterEvent('RAID_ROSTER_UPDATE')
    partyToggle:RegisterEvent('PARTY_LEADER_CHANGED')
    partyToggle:RegisterEvent('PARTY_MEMBER_CHANGED')
    partyToggle:SetScript('OnEvent', function(self)
    	if(InCombatLockdown()) then
    		self:RegisterEvent('PLAYER_REGEN_ENABLED')
    	else
    		self:UnregisterEvent('PLAYER_REGEN_ENABLED')
    		if(GetNumRaidMembers() > 5) then
    			party:Hide()
    --			for _,i in ipairs(raid) do i:Show() end
    			for key, object in ipairs(pets) do
    				UnregisterUnitWatch(object)
    				object:Hide()
    			end
    		else
    			party:Show()
    --			for _,i in ipairs(raid) do i:Hide() end
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    		end
    	end
    end)


    aesyl if that part was for me. I just want to show 5man raid (arena / old instances) as a party
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Interface\AddOns\oUF_AI\oUF_AI.lua:645: bad argument #1 to 'ipairs' (table expected, got nil)
    [C]: ?
    [C]: in function `ipairs'
    Interface\AddOns\oUF_AI\oUF_AI.lua:645: in function <Interface\AddOns\oUF_AI\oUF_AI.lua:631>


    local partyToggle = CreateFrame('Frame')
    partyToggle:RegisterEvent('PLAYER_LOGIN')
    partyToggle:RegisterEvent('RAID_ROSTER_UPDATE')
    partyToggle:RegisterEvent('PARTY_LEADER_CHANGED')
    partyToggle:RegisterEvent('PARTY_MEMBER_CHANGED')
    partyToggle:SetScript('OnEvent', function(self)
    	if(InCombatLockdown()) then
    		self:RegisterEvent('PLAYER_REGEN_ENABLED')
    	else
    		self:UnregisterEvent('PLAYER_REGEN_ENABLED')
    		if(GetNumRaidMembers() > 5) then
    			party:Hide()
    			for _,i in ipairs(raid) do i:Show() end
    			for key, object in ipairs(pets) do
    				UnregisterUnitWatch(object)
    				object:Hide()
    			end
    		else
    			party:Show()
    			for _,i in ipairs(raid) do i:Hide() end -- LINE 645
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    		end
    	end
    end)


    p3lim the code for pets was not working. any other sugestions?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    changed my raid to:

    oUF:SetActiveStyle('AI_Raid')
    local raid = {}
    for i = 1, 8 do
    	local raidgroup = oUF:Spawn('header', 'oUF_Raid'..i)
    	raidgroup:SetManyAttributes('groupFilter', tostring(i), 'showRaid', true, 'yOffSet', -8)
    	table.insert(raid, raidgroup)
    	if(i==1) then
    		raidgroup:SetPoint('LEFT', UIParent, 'LEFT', 10, -300)
    	else
    		raidgroup:SetPoint('TOPLEFT', raid[i-1], 'TOPRIGHT', 8, 0)
    	end
    	raidgroup:Show()
    end


    still no luck with

    	if(InCombatLockdown()) then
    		self:RegisterEvent('PLAYER_REGEN_ENABLED')
    	else
    		self:UnregisterEvent('PLAYER_REGEN_ENABLED')
    		if(GetNumPartyMembers() > 1 and GetNumPartyMembers() <= 5) then
    			party:Show()
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    			for _,i in ipairs(Raid) do
    				i:Hide()
    			end
    		elseif(GetNumRaidMembers() > 5) then
    			party:Hide()
    			for key, object in ipairs(pets) do
    				UnregisterUnitWatch(object)
    				object:Hide()
    			end
    			for _,i in ipairs(Raid) do
    				i:Show()
    			end
    		else
    			party:Show()
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    		end
    	end


    But the both point to raid now if i'm correct
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Quote from Coldfury »


    UnregisterUnitWatch(raid)


    I tought that
    for _,i in ipairs(Raid) do
    				i:Hide()
    			end


    would take care of that
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Could soneone tell me why my raid is still showing when I have 1 till 5 raid members?

    	if(InCombatLockdown()) then
    		self:RegisterEvent('PLAYER_REGEN_ENABLED')
    	else
    		self:UnregisterEvent('PLAYER_REGEN_ENABLED')
    		self:UnregisterEvent("PLAYER_REGEN_ENABLED")
    		if(GetNumPartyMembers() > 1 and GetNumPartyMembers() <= 5) then
    			party:Show()
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    			for _,i in ipairs(Raid) do
    				i:Hide()
    			end
    		elseif(GetNumRaidMembers() > 5) then
    			party:Hide()
    			for key, object in ipairs(pets) do
    				UnregisterUnitWatch(object)
    				object:Hide()
    			end
    			for _,i in ipairs(Raid) do
    				i:Show()
    			end
    		else
    			party:Show()
    			for key, object in ipairs(pets) do
    				RegisterUnitWatch(object)
    			end
    		end
    	end


    raid spwaning
    oUF:SetActiveStyle('AI_Raid')
    local last = {}
    for i = 1, 8 do
    	local raid = oUF:Spawn('header', 'oUF_Raid'..i)
    	raid:SetManyAttributes('groupFilter', tostring(i), 'showRaid', true, 'yOffSet', -8)
    	table.insert(last, raid)
    	if(i==1) then
    		raid:SetPoint('LEFT', UIParent, 'LEFT', 10, -300)
    	else
    		raid:SetPoint('TOPLEFT', last[i-1], 'TOPRIGHT', 8, 0)
    	end
    	raid:Show()
    end
    Posted in: Unit Frames
  • 0

    posted a message on minimap & Battlegroud
    thanks forgot to remove the old not working code 74 - 79
    Posted in: Lua Code Discussion
  • 0

    posted a message on minimap & Battlegroud
    For some reason It is not working.

    this it the whole code
    http://www.pastey.net/96428
    Posted in: Lua Code Discussion
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Quote from Caellian »


    I've got a screenshot i'll edit in a sec



    sorry to go offtopic, but how did you get that tracking icon in the minimap so slick?
    Mine looks strange and I use "MiniMapTrackingBackground:Hide()" to hide the crap
    Posted in: Unit Frames
  • 0

    posted a message on minimap & Battlegroud
    I have 2 problems:

    1. I can't seem to move the Capturebar from the minimap, it stays below the mm.
    with clusterf*ck I can move the frame but It won't show.

    2. please tell my what is wrong with:
    it should auto release & resurect in a BG

    local AI_bgres = CreateFrame("Frame", nil, UIParent)
    
    function AI_bgres:onEvent()
    	if select(2,IsInInstance()) == "pvp" then
    		if (arg1 ~= "Chained Spirit") and (GetCorpseRecoveryDelay() == 0) then
    			HideUIPanel(StaticPopup1)
    			AcceptResurrect()
    		end
    	end
    end
    
    function AI_bgres:new()
    	self:SetScript("OnEvent", self.onEvent)
    	self:RegisterEvent("RESURRECT_REQUEST")
    end
    
    AI_bgres:new()
    Posted in: Lua Code Discussion
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Today in AV with oUF 1.1.1 a error popt up but everything seems to work

    Interface\AddOns\oUF\ouf.lua:87: attempt to call field '?' (a nil value)
    [C]: in function `?'
    Interface\AddOns\oUF\ouf.lua:87: in function <Interface\AddOns\oUF\ouf.lua:85>


    But how is this done
    if(GetNumPartyMembers() > 1 and GetNumPartyMembers() =< 5)


    that gives me an error, And I like the idea because I had a request to show 5man raids as a party (arena)
    Posted in: Unit Frames
  • 0

    posted a message on fraction question
    Sure, I'll let you know.
    Posted in: Lua Code Discussion
  • To post a comment, please or register a new account.