• 0

    posted a message on Unofficial oUF - methods used for layouts
    All rightey then, now that i finally have the raid icons working like i want, I need some more tips.

    Acctually.. Now all I want is the code for Zariel's grid thingy, thats exactly what I was about to ask.
    Posted in: Unit Frames
  • 0

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

    self.unit is a string, and the unit ID of that unit's target is going to be that same string with the other string 'target' stuck on the end of it:

    self.unit .. "target"

    Aha! That did it, thanks so much!
    Posted in: Unit Frames
  • 0

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

    Regular raid icons work fine when i switch back to that, but im trying to get the party player frames to show the raidIcon of the unit they are targeting, instead of their own icon. Hince trying self.unit.target instead of self.unit, but its not workin.

    Anyone? please?
    Posted in: Unit Frames
  • 0

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

    check rabbits raid layout who supports raidicons.
    i included it in my post so you can dl it

    Thanks for trying, but thats not quite what i need. Regular raid icons work fine when i switch back to that, but im trying to get the party player frames to show the raidIcon of the unit they are targeting, instead of their own icon. Hince trying self.unit.target instead of self.unit, but its not workin.
    Posted in: Unit Frames
  • 0

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

    All right, ive been fiddling with my raid icon problem for a couple days on and off, but i cant seem to get it to work.

    In my 'func' i have
    if not (unit=="player") then
    	self.RAID_TARGET_UPDATE = targetUpdate
    end
    ,

    and targetUpdate is
    local targetUpdate = function(self, event, unit)
    	if self.unit.target then
    		local index = GetRaidTargetIndex(self.unit.target)
    	else
    		local index = GetRaidTargetIndex(self.unit)
    	end
    	
    	local icon = self.RaidIcon
    
    	if(index) then
    		SetRaidTargetIconTexture(icon, index)
    		icon:Show()
    	else
    		icon:Hide()
    	end
    end


    But its not workin for me. In a party my own frame shows my raid icon, but all other frames wont show any icons, even if they target me, or another unit with an icon set. Any ideas?

    Anyone? I'd like to get this working before raiding this weekend
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    All right, ive been fiddling with my raid icon problem for a couple days on and off, but i cant seem to get it to work.

    In my 'func' i have
    if not (unit=="player") then
    	self.RAID_TARGET_UPDATE = targetUpdate
    end
    ,

    and targetUpdate is
    local targetUpdate = function(self, event, unit)
    	if self.unit.target then
    		local index = GetRaidTargetIndex(self.unit.target)
    	else
    		local index = GetRaidTargetIndex(self.unit)
    	end
    	
    	local icon = self.RaidIcon
    
    	if(index) then
    		SetRaidTargetIconTexture(icon, index)
    		icon:Show()
    	else
    		icon:Hide()
    	end
    end


    But its not workin for me. In a party my own frame shows my raid icon, but all other frames wont show any icons, even if they target me, or another unit with an icon set. Any ideas?
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    All right i figured out the distinction, guess i should have been more clear with what i needed. How do i set an oUF frame's RaidIcon to that of its target? No oUF layouts ive seen do that. It seems to me that oUF handles showing self.RaidIcon on its own, so I might need a hack-around to get the target's icon showing.
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I'm gettin there. Learnin alot about addon programming through customizing P3lim.

    What i want to do next is have party icons show what raid icons the players are targeting. Not the acctual unit, i just need to see the raid icon. Im guessing i would just set self.Icon to something, but im not really sure what, or where, or how to tell the party frames from the Player frame

    sorry for sounding noobish!
    Posted in: Unit Frames
  • 0

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

    may i suggest you download my attached file in this post and see where i added all that code i just pasted, probably easier than trying to locate why it wont spawn for you.


    Lol thanks, downloaded it tthe first time and skimmed through it. Got it working just fine now! I'm guessing for pet target do the same as focus but replace with 'pet'?

    I'm still wondering about oUF docs, i'd like to have a look over them
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Thanks tiana!! Got the pvp flag working great, but the focus target is givin me trouble.. not sure what im doin wrong, but im not gettin any errors and the frames not showin up.

    if unit=="focustarget" then
    		
    		local name = hp:CreateFontString(nil, "OVERLAY")
    		name:SetPoint("LEFT", 2, -1)
    		name:SetPoint("RIGHT", hp, "LEFT")
    		name:SetJustifyH"LEFT"
    		name:SetFontObject(GameFontNormalSmall)
    		name:SetTextColor(1,1,1)
    		hp:SetHeight(12)
    		pp:SetHeight(2.5)
    		ppp:Hide()
    		self.Name = name
    		self.UNIT_NAME_UPDATE = updateName
    	end
    then at the end
    local fot = oUF:Spawn("focustarget", "oUF_Focustarget")
    fot:SetPoint("LEFT", focus, "RIGHT", 0, 30)
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    Im lovin P3lim so far, but ive been trying to add some things to it, like focus target, pet target pvp flag, and a couple other things... This has probably been asked before (couldnt find much from a search), but is there any documentation on oUF? I get the basics, but some official documentation would really help me out.
    Posted in: Unit Frames
  • To post a comment, please or register a new account.