• 0

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

    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)

    First of all, its <=, not =<, and second of all, this code doesn't work. My code above works fine except the issue with combat.
    Posted in: Unit Frames
  • 0

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

    No, it will show party frames until the raid has more than 5 members

    It shows both party and raid frames if there are less than five members, actually.
    http://i33.tinypic.com/fz92lx.jpg
    Maybe you meant
    if(GetNumRaidMembers() > 1 and GetNumRaidMembers() <= 5) then

    But then it will not show party frame if I leave BG and get invited to a party (Actually that is why I put second else in my code when I encountered such a problem).

    The problem is connected to being in combat, btw. Reproduced it in AB 10 minutes ago.
    Posted in: Unit Frames
  • 0

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

    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(GetNumPartyMembers() > 1 and GetNumPartyMembers() =< 5) then
    			party:Show()
    			for _,i in ipairs(Raid) do
    				i:Hide()
    			end
    		elseif(GetNumRaidMembers() > 5) then
    			party:Hide()
    			for _,i in ipairs(Raid) do
    				i:Show()
    			end
    		end
    	end
    end)



    Wouldn't it show party frame always?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I have a problem. I need my raid frame to hide if there is only my party in the raid and show up if there are more than five people in the raid and my party is full. The code is following (stolen from numerous layouts and modified a bit)
    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() == GetNumPartyMembers() + 1 then
    			party:Show()
    			for _,i in ipairs(Raid) do
    				i:Hide()
    			end
    		elseif GetNumRaidMembers() > 0 then
    			party:Hide()
    			for _,i in ipairs(Raid) do
    				i:Show()
    			end
    		else
    			party:Show()
    		end
    	end
    end)

    Problem is that sometimes not all the raid members are shown. For instance (see group 3):
    http://i36.tinypic.com/2hxrhww.jpg - 2 members in the third group are not visible
    http://i35.tinypic.com/sv1m5g.jpg - here you can see, that they are in raid

    This behavior persists even if I join another raid until I reload UI. I am not sure, but I think it has something to do with me being in combat when new members join the raid. I am not sure though
    Posted in: Unit Frames
  • 0

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

    Remove the following line:
    button.overlay.Hide = function(self) self:SetVertexColor(0.5, 0.5, 0.5) end


    That did the trick, thank you, but there is a small spacing between buffs left
    http://img129.imageshack.us/my.php?image=wowscrnshot082808204136fs2.jpg

    offset code goes like this
    growthx = (icons["growth-x"] == "LEFT" and -1) or 1 -- This is the offset
    growthy = (icons["growth-y"] == "DOWN" and -1) or 1 -- This is the offset

    As far as i can tell, debuffs have no spacing between them. Is it possible to remove spacing between buffs?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I am modifying Lyn's layout for my needs and I have a question.
    His aura code goes like this
    button.icon:SetTexCoord(.07, .93, .07, .93)
    	button.icon:SetPoint("TOPLEFT", button, "TOPLEFT", 1, -1)
    	button.icon:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -1, 1)
    	
    	button.overlay:SetTexture(bufftex)
    	button.overlay:SetTexCoord(0,1,0,1)
    	button.overlay.Hide = function(self) self:SetVertexColor(0.5, 0.5, 0.5) end
    	
    	button.cd:SetReverse()
    	button.cd:SetPoint("TOPLEFT", button, "TOPLEFT", 4, -3) 
    	button.cd:SetPoint("BOTTOMRIGHT", button, "BOTTOMRIGHT", -3, 4)


    How can I set aura border to be textured only on debuffs and strip it on the buffs?
    Posted in: Unit Frames
  • 0

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

    http://pastey.net/93691

    Let me know if it works for you

    I'll let you know through PM, because I don't know when I will start coding my layout again
    Posted in: Unit Frames
  • 0

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

    http://ixo.no/git/oUF_Lily.git/tree/layout.lua

    Look at line 83, as long you have something like that in your updateHealth code the updateName will be refreshed and fix this issue of yours

    Btw, may I look at your updateName function? (www.pastey.net)


    I posted it here somewhere
    Ah, there it is. http://pastey.net/93075

    Unfotunately, I dumped that file long ago. Besides, UnitAffectingCombat didn't work, changing it to InCombatLockdown resulted in above mentioned behaviour. And also UniPlayerControlled was eventually changed to UnitIsPlayer
    Posted in: Unit Frames
  • 0

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

    In WoW it should mostly only be used for functions that are called in a OnUpdate, or get quite a lot of hits.

    Oh, haste, while you are here. I had a problem previously where I couldn't change the color of player's name to red when he enters combat. The name changed its color only on target frame and only if I reopened the frame ingame (like, get in combat, then run, select myself as a target, and the name stays red even after exiting combat until I reopen target frame). Is this behavior caused by oUF name update function? Or do I miss something?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Erm, forgive me for a stupid question, but why does every layout reassign standard Blizz functions to local ones at the beginning of the file? (oUF_Classic, meanwhile, doesn't do this)
    Posted in: Unit Frames
  • 0

    posted a message on Basic Chat Mods??
    I've got a problem. I transferred to russian realms and found out that channel names module doesn't work there because it uses channel names while some addons (mumble, for instance) use some kind of channel id and work perfectly fine. I would like neither to switch to mumble nor to recode your addon, so could you please fix this issue?
    Posted in: General AddOns
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    if i do something like this, text "combat" is displayed correctly, but name color doesn't get updated unless I click on the frame (and even then name is updated only on target frame), and I don't know what to do to make it update every time I enter combat.
    local cmbt = hp:CreateFontString(nil, "OVERLAY")
    cmbt:SetPoint("CENTER", 0, 0)
    cmbt:SetJustifyH("LEFT")
    cmbt:SetFontObject(GameFontNormalSmall)
    cmbt:SetText("combat")
    self.Combat = cmbt
    Posted in: Unit Frames
  • 0

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

    ps. totally just typed that here, no testing nothing. Oh yeah, perhaps you should put that in the updateName function :P (hell, if it's an issue, updateHealth might work too)

    Doesn't work at all. I tried the same code, but changed UnitAffectingCombat to InCombatLockdown and it updated name color, but only when I clicked on the frame, not when I entered combat. I assume I have to create dummy frame for self.Combat.

    UpdateName looks like this http://pastey.net/93075
    I stole it from Tuller's Sage.
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I want to color player name red if he enters combat, but I can't get the frames to update on entering combat. I don't quite understand oUF's status.lua, so I need your help
    Posted in: Unit Frames
  • 0

    posted a message on UI Screenshots - Show us what you use!
    Quote from khangg »

    Combat
    Idle
    Raid | Addons

    Pls, share your oUF layout.
    Posted in: General Chat
  • To post a comment, please or register a new account.