Elitist Jerks
Register
Blogs
Chat
Forums
New Posts


Go Back   Elitist Jerks > Public Discussion > User Interface and AddOns

Reply
 
LinkBack (16) Thread Tools
Old 03/23/08, 1:43 PM   2 links from elsewhere to this Post. Click to view. #101 (permalink)
Glass Joe
 
Dwarf Rogue
 
Stonemaul (EU)
Hi, i have a problem with rBuff - as you can see on the top part of a picture (http://img80.imageshack.us/img80/9016/rbuffvr4.jpg), buffs have no border, like those on the bottom part.

top part of a picture source: http://zorktdmog.zo.funpic.de/roth_u...708_210414.jpg
bottom part source: Post your Interface

Assuming this part of rbuff.lua:
 if isDebuff == 2 then
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_red")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      elseif isDebuff == 3 then
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_purple")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      else
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_green")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      end
i hope that debuffs will also have colored border, but... the magic isn't happening

Where is the problem and how it can be solved?
 
User is offline.
Reply With Quote
Old 03/23/08, 2:44 PM   #102 (permalink)
Don Flamenco
 
Night Elf Hunter
 
Bronze Dragonflight (EU)
Originally Posted by vadoom View Post
Hi, i have a problem with rBuff - as you can see on the top part of a picture (http://img80.imageshack.us/img80/9016/rbuffvr4.jpg), buffs have no border, like those on the bottom part.

top part of a picture source: http://zorktdmog.zo.funpic.de/roth_u...708_210414.jpg
bottom part source: Post your Interface

Assuming this part of rbuff.lua:
 if isDebuff == 2 then
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_red")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      elseif isDebuff == 3 then
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_purple")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      else
        local t = f:CreateTexture(nil,"ARTWORK")
        t:SetTexture("Interface\\AddOns\\rTextures\\gloss_green")
        t:SetPoint("TOPLEFT", fg, "TOPLEFT", -0, 0)
        t:SetPoint("BOTTOMRIGHT", fg, "BOTTOMRIGHT", 0, -0)
        fg.texture = t
      end
i hope that debuffs will also have colored border, but... the magic isn't happening

Where is the problem and how it can be solved?
I'm wondering the same thing, the textures are present for the buffs/debuffs to have border colours but for some reason they aren't working.
 
User is offline.
Reply With Quote
Old 03/23/08, 4:00 PM   #103 (permalink)
Glass Joe
 
Blood Elf Priest
 
Gul'dan
Originally Posted by Mikari View Post
I'm wondering the same thing, the textures are present for the buffs/debuffs to have border colours but for some reason they aren't working.
By default Zork seems to have left that disabled. He has comments around it to disable it. So remove "--' and '--" just above and below the set of if statements and it will show the colors for buffs/debuffs.


edit; He has done this with many things in his code. On rbars there is one commented out that shows the proper texture/button art for the shapeshift bar and pet bar that are by default commented out.
Most likely because if something is hidden (shapeshift bar, hidden by default)... It doesn't need textures. So if you want to show the shapeshift bar it's also best to show the textures so it all matches with your action bar.
 
User is offline.
Reply With Quote
Old 03/23/08, 5:07 PM   #104 (permalink)
Don Flamenco
 
Night Elf Hunter
 
Bronze Dragonflight (EU)
Originally Posted by ren0 View Post
By default Zork seems to have left that disabled. He has comments around it to disable it. So remove "--' and '--" just above and below the set of if statements and it will show the colors for buffs/debuffs.


edit; He has done this with many things in his code. On rbars there is one commented out that shows the proper texture/button art for the shapeshift bar and pet bar that are by default commented out.
Most likely because if something is hidden (shapeshift bar, hidden by default)... It doesn't need textures. So if you want to show the shapeshift bar it's also best to show the textures so it all matches with your action bar.
That sort of has it working, it only seems to show the red border though, it doesn't show the different borders depending on the Debuff Dispel type, e.g Red for Physical, Blue for Magic, Purple for Curse, Brown for Disease and Green for Posion.

Blizzard has the colours and types listed in their LUA files http://wdnaddons.com/0408089/FrameXML/BuffFrame.lua
 
User is offline.
Reply With Quote
Old 03/24/08, 12:13 AM   #105 (permalink)
Don Flamenco
 
zork's Avatar
 
Dwarf Warrior
 
Eredar (EU)
Originally Posted by Mikari View Post
That sort of has it working, it only seems to show the red border though, it doesn't show the different borders depending on the Debuff Dispel type, e.g Red for Physical, Blue for Magic, Purple for Curse, Brown for Disease and Green for Posion.

Blizzard has the colours and types listed in their LUA files http://wdnaddons.com/0408089/FrameXML/BuffFrame.lua
If you want to colorize the texture for each debufftype there is a good way to do it.

You have quoted the right lua-file already. Do a search for debuff type and you will find:

-- Set color of debuff border based on dispel class.
if ( filter == "HARMFUL" ) then
  debuffType = GetPlayerBuffDispelType(buffIndex);
  debuffSlot = getglobal(buffName.."Border");
  if ( debuffType ) then
    color = DebuffTypeColor[debuffType];
  else
    color = DebuffTypeColor["none"];
  end

  if ( debuffSlot ) then
    debuffSlot:SetVertexColor(color.r, color.g, color.b);
  end

 
  if ( not debuffType ) then
    debuffType = "none";
  end

end
Now copy the whole function into the rBuffs.lua and rename the first line from

function BuffButton_Update(buttonName, index, filter)
to

BuffButton_Update = function(buttonName, index, filter)
Now you can do all the magic.

To make buff-buttons with a colored border you have to use the gloss_grey.tga texture because when you use the "SetVertexColor" on a near black border it will result in a even more black border.

The "debuffSlot" is:
debuffSlot = getglobal(buffName.."Border");
The blizzard UI puts the color onto the Border, but I hide the border.

I create a new frame called Buttonname.."Gloss", so all you have to do is to change the debuffslot to:

debuffSlot = getglobal(buffName.."Gloss");
Hope this helps you out.

 
User is offline.
Reply With Quote
Old 03/24/08, 6:58 AM   #106 (permalink)
Don Flamenco
 
Night Elf Hunter
 
Bronze Dragonflight (EU)
Where in the rBuff would I paste that function? There's some debuff color code in there already, do I delete it? I don't see function BuffButton_Update(buttonName, index, filter) in the part you quoted, and I also can't find gloss_grey.tga in rTextures.

Would you mind posting or PMing me the entire contents of the LUA file that would be required to have properly working debuff colors with rBuff, basically the whole rBuff file?
 
User is offline.
Reply With Quote
Old 03/24/08, 8:17 AM   #107 (permalink)
Don Flamenco
 
zork's Avatar
 
Dwarf Warrior
 
Eredar (EU)
I will not write functions for you. You must try it yourself its not that hard.

You can place the function at the buttom since we rewrite a Blizzard function that is not called in rBuff itself.

 
User is offline.
Reply With Quote
Old 03/28/08, 3:08 AM   #108 (permalink)
Glass Joe
 
Undead Rogue
 
Outland (EU)
Morning all,

Recently I've installed these rmods and I like it very much.
One of the problems I face is with mods like Omen, BigWigs & Ora2, where the texture used for the bars is the original blizzard statusbar. My question is that if I want Omen to have the same texture as the unitframes, i need to change the path in the lua of Omen? If my way of thinking is right, does it work similar to like changing a font? (e.g. ("rtextures\\ statusbar.tga") instead of (blizzardstatusbar).

How I accomplish it now is by opening azcastbar wich seems to unlock the textures for omen and such.
 
User is offline.
Reply With Quote
Old 03/29/08, 1:54 PM   #109 (permalink)
Von Kaiser
 
Murloc Mage
 
Boulderfist (EU)
Originally Posted by Juless View Post
Morning all,

Recently I've installed these rmods and I like it very much.
One of the problems I face is with mods like Omen, BigWigs & Ora2, where the texture used for the bars is the original blizzard statusbar. My question is that if I want Omen to have the same texture as the unitframes, i need to change the path in the lua of Omen? If my way of thinking is right, does it work similar to like changing a font? (e.g. ("rtextures\\ statusbar.tga") instead of (blizzardstatusbar).

How I accomplish it now is by opening azcastbar wich seems to unlock the textures for omen and such.
Easiest way to do it is install shared media and overwrite one of the textures you dont like with the statusbar.tga from rtextures. It's a very anti minimalistic way to do it, but also the easiest way to do it. You don't have to worry about overwriting your lua files everytime you update omen / ora2 / bigwigs.
 
User is offline.
Reply With Quote
Old 03/31/08, 8:52 AM   #110 (permalink)
Glass Joe
 
Orc Shaman
 
Magtheridon
First off, I would like to say thank you to not only Zork (and the original creators) but to this community for providing great ideas that have really expanded on this series of mods.

My question regarding this however is hiding the party frames. Right now, I have it set up to hide the raid frames but I also want to to hide party frames aswell, anyone know why this isn't working?

local temptoggle = CreateFrame"Frame"
  temptoggle:SetScript("OnEvent", function(self, event, ...)
      if GetNumRaidMembers() > 1 then
          raid:Hide()
      elseif GetNumPartyMembers() > 1  then
          party:Hide()
      end
  end)
This is just being added to the Layout.Lua file at the bottom, I am not on my main computer so I don't have the code I am replacing it with, but it was mentioned earlier in the thread here.

Fake Edit: I am just beginning to get into Lua, so right now it is more taking code fragments from others and a little bit of originality as I begin. So in your responses, please tell me what file it should go into and the code it should replace in that file.
 
User is offline.
Reply With Quote
Old 03/31/08, 11:45 AM   #111 (permalink)
Von Kaiser
 
Night Elf Druid
 
Vashj
Originally Posted by Amosh View Post
First off, I would like to say thank you to not only Zork (and the original creators) but to this community for providing great ideas that have really expanded on this series of mods.

My question regarding this however is hiding the party frames. Right now, I have it set up to hide the raid frames but I also want to to hide party frames aswell, anyone know why this isn't working?
You're only hiding the party frames when you're in a party. Try this:

local temptoggle = CreateFrame"Frame"
  temptoggle:SetScript("OnEvent", function(self, event, ...)
      if GetNumRaidMembers() > 1 then
          raid:Hide()
          party:Hide()
      elseif GetNumPartyMembers() > 1  then
          party:Hide()
      end
  end)
 
User is offline.
Reply With Quote
Old 04/02/08, 11:26 PM   #112 (permalink)
Von Kaiser
 
Draenei Priest
 
Feathermoon
I've been trying to make my bags visible on Mouse over, making one button visible at a time is easy but making all the bags visible is proving it's self pretty hard.
I came up with:
  local counter = .5 
  local function bagOnUpdate(_,elapsed)
    counter = counter + elapsed
      if counter > .5 then counter = 0
       if MouseIsOver(MainMenuBarBackpackButton) then
         MainMenuBarBackpackButton:SetAlpha(1)
	 CharacterBag0Slot:SetAlpha(1)
	 CharacterBag1Slot:SetAlpha(1)
	 CharacterBag2Slot:SetAlpha(1)
	 CharacterBag3Slot:SetAlpha(1)
         KeyRingButton:SetAlpha(1)
           else
         MainMenuBarBackpackButton:SetAlpha(0)
       end
      end
     counter = counter + elapsed
       if counter > .5 then counter = 0
         if MouseIsOver(CharacterBag0Slot) then
         MainMenuBarBackpackButton:SetAlpha(1)
	 CharacterBag0Slot:SetAlpha(1)
	 CharacterBag1Slot:SetAlpha(1)
	 CharacterBag2Slot:SetAlpha(1)
	 CharacterBag3Slot:SetAlpha(1)
         KeyRingButton:SetAlpha(1)
            else
          CharacterBag0Slot:SetAlpha(0)
         end
       end
     counter = counter + elapsed
       if counter > .5 then counter = 0
         if MouseIsOver(CharacterBag1Slot) then
          MainMenuBarBackpackButton:SetAlpha(1)
          CharacterBag0Slot:SetAlpha(1)
          CharacterBag1Slot:SetAlpha(1)
          CharacterBag2Slot:SetAlpha(1)
          CharacterBag3Slot:SetAlpha(1)
          KeyRingButton:SetAlpha(1)
            else
          CharacterBag1Slot:SetAlpha(0)
         end
       end
     counter = counter + elapsed
       if counter > .5 then counter = 0
         if MouseIsOver(CharacterBag2Slot) then
          MainMenuBarBackpackButton:SetAlpha(1)
	  CharacterBag0Slot:SetAlpha(1)
	  CharacterBag1Slot:SetAlpha(1)
	  CharacterBag2Slot:SetAlpha(1)
	  CharacterBag3Slot:SetAlpha(1)
          KeyRingButton:SetAlpha(1)
            else
          CharacterBag2Slot:SetAlpha(0)
         end
       end
     counter = counter + elapsed
       if counter > .5 then counter = 0
         if MouseIsOver(CharacterBag3Slot) then
          MainMenuBarBackpackButton:SetAlpha(1)
	  CharacterBag0Slot:SetAlpha(1)
	  CharacterBag1Slot:SetAlpha(1)
	  CharacterBag2Slot:SetAlpha(1)
	  CharacterBag3Slot:SetAlpha(1)
          KeyRingButton:SetAlpha(1)
            else
          CharacterBag3Slot:SetAlpha(0)
         end
       end
     counter = counter + elapsed
       if counter > .5 then counter = 0
         if MouseIsOver(KeyRingButton) then
          MainMenuBarBackpackButton:SetAlpha(1)
	  CharacterBag0Slot:SetAlpha(1)
	  CharacterBag1Slot:SetAlpha(1)
	  CharacterBag2Slot:SetAlpha(1)
	  CharacterBag3Slot:SetAlpha(1)
	  CharacterBag4Slot:SetAlpha(1)
          KeyRingButton:SetAlpha(1)
            else
          KeyRingButton:SetAlpha(0)
         end
       end
     end

   
   addon:SetScript("OnUpdate",bagOnUpdate)
The problem is that the SetAlpha(0) is set individually to each bag. So what I'm getting is flashing bag icons when I mouse over one of the icons. If someone could help me make this more stable I would appreciate it.
Thanks in advance,
Auralin
 
User is offline.
Reply With Quote
Old 04/03/08, 4:43 AM   #113 (permalink)
Don Flamenco
 
zork's Avatar
 
Dwarf Warrior
 
Eredar (EU)
Try to reanchor your bags to a new frame that you created yourself.

I would do it like this:

- Create a new frame

    local f = CreateFrame("Frame","bag_holder",UIParent)
    f:SetFrameStrata("BACKGROUND")
    f:SetWidth(150)
    f:SetHeight(60)
    f:SetBackdrop({
      bgFile = "Interface/Tooltips/UI-Tooltip-Background", 
      edgeFile = "", 
      tile = true, tileSize = 16, edgeSize = 16, 
      insets = { left = 0, right = 0, top = 0, bottom = 0 }
    })
    f:SetBackdropColor(0,0,0,1)
    f:ClearAllPoints()  
    f:SetPoint("CENTER",UIParent,"CENTER",0,0)
    f:Show()
- Anchor the "MainMenuBarBackpackButton" on the Frame and to the right.

    MainMenuBarBackpackButton:ClearAllPoints()  
    MainMenuBarBackpackButton:SetPoint("BOTTOMRIGHT",bag_holder,"TOPRIGHT",0,0)
If I am not mistaken all your other Bags are already anchored to "MainMenuBarBackpackButton", so they should be inside the frame (I hope so).

Now you could try to Show/Hide the Frame and see what happens.

 
User is offline.
Reply With Quote
Old 04/03/08, 4:32 PM   #114 (permalink)
Von Kaiser
 
Draenei Priest
 
Feathermoon
Zork,
Thanks so much.
I got it working, I have my bags and my character bar in the bottom left hand side of the screen and its set to fade on mouse over.
So heres the code if you want the same thing on your UI.
-------------
--bags fade
-------------

    local f = CreateFrame("Frame","bag_holder",UIParent)
    f:SetFrameStrata("BACKGROUND")
    f:SetWidth(300)
    f:SetHeight(30)
    f:SetBackdrop({
      bgFile = "", 
      edgeFile = "", 
      tile = true, tileSize = 16, edgeSize = 16, 
      insets = { left = 0, right = 0, top = 0, bottom = 0 }
    })
    f:SetBackdropColor(0,0,0,1)
    f:ClearAllPoints()  
    f:SetPoint("BOTTOM",UIParent,"BOTTOM",-230,0);
    f:SetPoint("LEFT",-0,0)
    f:Show()
    
    
      MainMenuBarBackpackButton:ClearAllPoints()  
      MainMenuBarBackpackButton:SetParent(f)
      MainMenuBarBackpackButton:SetPoint("BOTTOMRIGHT",bag_holder,"TOPRIGHT",-270,-40)
      
      CharacterMicroButton:ClearAllPoints()
      CharacterMicroButton:SetParent(f)
      CharacterMicroButton:SetPoint("BOTTOMRIGHT",bag_holder,"TOPRIGHT",-185,-36)
      
      CharacterBag0Slot:SetParent(f)
      CharacterBag1Slot:SetParent(f)
      CharacterBag2Slot:SetParent(f)
      CharacterBag3Slot:SetParent(f)
      KeyRingButton:SetParent(f)
      
      TalentMicroButton:SetParent(f)
      SpellbookMicroButton:SetParent(f)
      QuestLogMicroButton:SetParent(f)
      SocialsMicroButton:SetParent(f)
      MainMenuMicroButton:SetParent(f)
      HelpMicroButton:SetParent(f)
      LFGMicroButton:SetParent(f)
      
  local counter = .5 
  local function fOnUpdate(_,elapsed)
    counter = counter + elapsed
      if counter > .5 then counter = 0
       if MouseIsOver(f) then
         f:SetAlpha(1)
           else
         f:SetAlpha(0)
       end
      end
    end

    
  addon:SetScript("OnUpdate",fOnUpdate)
I hope this bit of code will help someone else out. Put this in your rBars file and make sure you have your bags and character buttons set to show or this won't work.
 
User is offline.
Reply With Quote
Old 04/04/08, 11:28 AM   #115 (permalink)
Von Kaiser
 
Blood Elf Paladin
 
Nazgrel
When you go to update rMods or any other minimalist mod like LynStats that you have modified, does it restore the LUA to default? if so, do you guys use a changelog file located somewhere else to show where the changes you have made go?
 
User is offline.
Reply With Quote
Old 04/04/08, 8:04 PM   #116 (permalink)
Von Kaiser
 
Draenei Priest
 
Feathermoon
I don't know what other people do but for me, I just update the TOC file for the addon and make it reflect the newest version of the game. That way the game will tell me its up to date but I don't have to download and rewrite the new version. If you use something like Baud error frames (downloadable from Zork's downloads) then you'll know when something no longer works and why. Then you can easily fix it. If for some reason you can't fix the problem your self you can more than likely download the newest version and look for the area that caused the problem and see what the original author did to correct the problem.
 
User is offline.
Reply With Quote
Old 04/05/08, 8:32 PM   #117 (permalink)
King Hippo
 
Human Paladin
 
Blackrock
Originally Posted by Delita View Post
When you go to update rMods or any other minimalist mod like LynStats that you have modified, does it restore the LUA to default? if so, do you guys use a changelog file located somewhere else to show where the changes you have made go?
If you are using a svn client to pull these changes from googlecode etc you can do a diff or a merge instead of an update.

The universe is run by the complex interweaving of three elements. Energy, matter, and enlightened self-interest.

www.retpaladin.com
 
User is offline.
Reply With Quote
Old 04/08/08, 9:07 AM   #118 (permalink)
Von Kaiser
 
Eliza's Avatar
 
Draenei Shaman
 
Khaz'goroth (EU)
*thread hijack*

Originally Posted by Ragnor View Post
If you are using a svn client to pull these changes from googlecode etc you can do a diff or a merge instead of an update.
I don't use post LynStats on any svn.

Originally Posted by Delita View Post
When you go to update rMods or any other minimalist mod like LynStats that you have modified, does it restore the LUA to default? if so, do you guys use a changelog file located somewhere else to show where the changes you have made go?
For LynStats, I maybe do an extern config.lua maybe. But not yet.

Naeva/ Lyn / Minilyn

I miss the things I’ve never done...
 
User is offline.
Reply With Quote
Old 04/11/08, 5:32 PM   #119 (permalink)
Glass Joe
 
Night Elf Druid
 
Silver Hand
Never mind, figured it out.
Awesome mod!

Last edited by ukator : 04/11/08 at 10:46 PM.
 
User is offline.
Reply With Quote
Old 04/12/08, 12:39 AM   #120 (permalink)
Glass Joe
 
Murloc Priest
 
Frostwolf
Don't know how hard this is, but is there a quick way to have debuffs grow up instead of down after the first row of 8 fills out in rbars?

I got it on my own, just copied

if(i == 1) then
button:SetPoint("BOTTOMLEFT", icons, 3, 0)
elseif(i == 11) then
button:SetPoint("BOTTOMLEFT", icons[1], "TOPLEFT", 0, 2)
elseif(i == 21) then
button:SetPoint("BOTTOMLEFT", icons[11], "TOPLEFT", 0, 2)
elseif(i == 31) then
button:SetPoint("BOTTOMLEFT", icons[21], "TOPLEFT", 0, 2)
else
button:SetPoint("LEFT", icons[i-1], "RIGHT", 3, 0)

From buffs on to debuffs

Last edited by Fugazi : 04/12/08 at 12:13 PM.
 
User is offline.
Reply With Quote
Old 04/12/08, 8:14 AM   #121 (permalink)
Von Kaiser
 
Tauren Druid
 
Demon Soul
I'm trying to get the PVP icon to show on the unit frames, I've come up with the following but it its on all the time whether I'm flagged or not:

local pvp = self:CreateTexture(nil, "OVERLAY")
	pvp:SetHeight(16)
	pvp:SetWidth(16)
	pvp:SetPoint("RIGHT", self, "LEFT")
	pvp:SetTexture"Interface\\PVPFrame\\PVP-Currency-Horde"
	self.PvP = pvp
Is there a separate OnUpdate check I need to have? Any help is appreciated.
 
User is offline.
Reply With Quote