• 0

    posted a message on Unofficial oUF - methods used for layouts
    talking about oUF castbar is there support for a mirrorbar?
    I realy hate the default one
    Posted in: Unit Frames
  • 0

    posted a message on Framerates?
    sorry fps = limited to 60 (without limed it goes +100), in raid 36-60 depending on the aoe amount
    Posted in: General Chat
  • 0

    posted a message on oUF
    there is a thread for oUF
    http://www.wowace.com/forums/index.php?topic=10696.0

    But look for Self.Buffs / self.Debuffs / self.Auras

    or Buffs / Debuffs / Auras
    Posted in: Unit Frames
  • 0

    posted a message on Framerates?
    Intel Core Duo E6750 @3GHZ
    Abit IP35-Pro
    XFX Geforce 8800GT
    Creative Sound Blaster X-Fi
    4GB ram
    Acer X222W
    Windows Vista 64 Ulitmate
    Posted in: General Chat
  • 0

    posted a message on TimeManagerClockButton
    I'm updating my minimap for wotlk

    everything works except the clock, it won't do anything

    	local clockFrame, clockTime = TimeManagerClockButton:GetRegions()
    	clockFrame:Hide()
    	clockTime:SetFont(clockfont, 16)
    	clockTime:SetTextColor(.46,.59,.68)
    	TimeManagerClockButton:SetPoint("TOPRIGHT", Minimap, "BOTTOMRIGHT", 0, 0)
    	TimeManagerClockButton:SetScript("OnClick", function()
    	if(button == 'RightButton') then
    		ToggleCalendar()
    	else
    		ToggleTimeManager()
    	end
    	if TimeManagerFrame:IsVisible() then
    		TimeManagerFrame:Hide()
    		else
    		TimeManagerFrame:Show()
    		end
       end)


    ps I know the "OnClick" is not needed anymore, but I whant to get the alarm to left & calender to rightclick.
    so that both frames can be accesed for the clock
    Posted in: Lua Code Discussion
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I'm have some problems moving the runframe, did you guys had anyluck?

    my code
    		if(class == 'DEATHKNIGHT') then
    			RuneFrame:SetParent(self.Health)
    			RuneFrame:SetScale(0.8)
    			RuneFrame:SetFrameLevel(2)
    			RuneFrame:SetPoint("CENTER", self.Health, "CENTER",0 , 0)
    		end
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    if(self:GetParent():GetName()=='oUF_Party' or unit:find('partypet%d')) then
    give the same error
    attempt to index local 'unit' (a nil value)


    http://www.pastey.net/95453

    marked the error lines & setting

    any help would be very nice
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    how can I call on party & party pets without getting the error.
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I have a strange thing.

    I'm adding the raid into my layout, I added the spawn of the raid targets, and since then I get a error in this line

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

    attempt to index local 'unit' (a nil value)

    why does this happen?

    complete code =

    	if(self:GetParent():GetName()=='oUF_Party' or unit:find('partypet%d')) then 
    		self.Name = self.Health:CreateFontString(nil, 'OVERLAY')
    		self.Name:SetFont(font, fSize+2, 'OUTLINE')
    	  self.Name:SetPoint('LEFT', 2, 0) 
    	else 
    		self.Level = self.Health:CreateFontString(nil, 'OVERLAY')
    		self.Level:SetFont(font, fSize+3, 'OUTLINE')
    	  self.Level:SetPoint('TOPLEFT', 2, 16) 
    	 
    		self.Name = self.Health:CreateFontString(nil, 'OVERLAY')
    		self.Name:SetFont(font, fSize+3, 'OUTLINE')
    	  self.Name:SetPoint('LEFT', self.Level, 'RIGHT', 1, 0) 
    	 
    	  if (unit == 'target') then 
    			self.Race = self.Health:CreateFontString(nil, 'OVERLAY')
    			self.Race:SetFont(font, fSize+3, 'OUTLINE')
    		  self.Race:SetPoint('LEFT', self.Name, 'RIGHT', 1, 0) 
    	 
    			self.Class = self.Health:CreateFontString(nil, 'OVERLAY')
    			self.Class:SetFont(font, fSize+3, 'OUTLINE')
    		  self.Class:SetPoint('LEFT', self.Race, 'RIGHT', 1, 0) 
    	  end 
    	end 

    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    I tested both codes, and it seem both work.

    but I have to do a /rl to hide te party pets

    ---------------------------------------------------- Spawn Party & Partypets
    local party = oUF:Spawn('header', 'oUF_Party') 
    party:SetPoint('LEFT', UIParent, 'LEFT', 20, -280) 
    party:SetManyAttributes('yOffset', -44, 'showParty', true)
    	 
    local pets = {} 
    pets[1] = oUF:Spawn('partypet1', 'oUF_PartyPet1') 
    pets[1]:SetPoint('TOPRIGHT', party, 'TOPRIGHT', 130, 0) 
    for i =2, 4 do 
      pets[i] = oUF:Spawn('partypet'..i, 'oUF_PartyPet'..i) 
      pets[i]:SetPoint('TOP', pets[i-1], 'BOTTOM', 0, -44) 
    end 
    	 
    ---------------------------------------------------- Party hiding 
    	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() > 0) then
    				party:Hide()
    				for i = 2, 4 do 
    			 		pets[i]:Hide()
    				end
    			else
    				party:Show()
    				for i = 2, 4 do 
    					pets[i]:Show()
    				end
    			end
    		end
    	end)


    This is the complete code, for party en party pet. any sugestions how to fix this?
    Posted in: Unit Frames
  • 0

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

    I have no idea how you spawned party pets, so I cant say for sure


    sorry I spawn them

    local pets = {} 
    pets[1] = oUF:Spawn('partypet1', 'oUF_PartyPet1') 
    pets[1]:SetPoint('TOPRIGHT', party, 'TOPRIGHT', 130, 0) 
    for i =2, 4 do 
      pets[i] = oUF:Spawn('partypet'..i, 'oUF_PartyPet'..i) 
      pets[i]:SetPoint('TOP', pets[i-1], 'BOTTOM', 0, -44) 
    end 


    If it's a dumb way let me know
    Posted in: Unit Frames
  • 0

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

    bar.value:SetFormattedText("%s (|cff%02x%02x%02x%.1f|r%%)", letter(cur), r*255, g*255, b*255, (cur/maxhp)*100)



    Thank you

    one more question

    	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() > 0) then
    				party:Hide()
    			else
    				party:Show()
    			end
    		end
    	end)


    hides the party in raids

    partypets:Hide() doesn't work, is there a way to hide them aswell
    Posted in: Unit Frames
  • 0

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

    Oops should be.
    bar.value:SetFormattedText("|cff%02x%02x%02x%s (%.1f%%)|r", letter(cur),r*255, g*255, b*255, (cur/maxhp)*100)





    I know but in this case the wohle health (100%) is colored.
    all I want to have colored is 100%
    %.1f%%
    <- that part :)
    Posted in: Unit Frames
  • 0

    posted a message on Unofficial oUF - methods used for layouts
    that nearly works

    bar.value:SetFormattedText("%s (|cff%02x%02x%02x%.1f%%|r)",r*255, g*255, b*255, letter(cur), (cur/maxhp)*100)


    the health tekst and () stay white. but the
    |cff%02x%02x%02x%.1f%%|r
    does something weird

    The color & values show strange stuff

    any sugestions

    thanks
    Posted in: Unit Frames
  • 0

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

    du, du hast, du hast mich, du hast mich gefragt, ...

    I didn't really get your example but:
    local r,g,b = self.ColorGradient(cur/maxhp, r1, g1, b1, r2, g2, b2, [, r3, g3, g3, and so on...])
    You can then use those values to generate the hex for the fontstring with string.format('|cff%02x%02x%02x', r*255, g*255, b*255)

    Remember that it's good practice to always close your color strings with |r.


    I have set up the color :) that works for bars fine.
    but how do I get this
    string.format('|cff%02x%02x%02x', r*255, g*255, b*255)

    in that
    bar.value:SetFormattedText("%s (%.1f%%)", letter(cur), (cur/maxhp)*100)


    and It may only change the color of (cur/maxhp)*100).
    Posted in: Unit Frames
  • To post a comment, please or register a new account.