WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   AddOn Help/Support (https://www.wowinterface.com/forums/forumdisplay.php?f=3)
-   -   !BeautyCase help (https://www.wowinterface.com/forums/showthread.php?t=34809)

Viridis 09-05-10 10:31 AM

!BeautyCase help
 
I love this little addon and I'm currently starting to add borders with it to various frames, however when adding it to sThreatMeter2 the border remains even when the actual meter is not in use, is there any way to make it disappear with the threat meter?

I was also wondering if there was a way to add the lines such as;
CreateBorder(sThreatMeter, 12, 7, 7, 7, 1, 2, 1, 2, 1, 48, 1, 48)
into their own addon so that I can update addons without having to keep re-editing.

My last question is whether I can use BeautyCase to skin the default buff frames? I tried using the frame "BuffButton1".

Thanks for any help in advance, I'm completely new to any kind of lua editing. :o
(You can download !BeautyCase with Neav's UI)

Xhelius 09-05-10 12:23 PM

Use /framestack to verify that the frame is actually named "sThreatMeter". Once you have actual frame name should clear up the issue you are having.

Viridis 09-05-10 12:53 PM

The sThreatMeter2 border works when the CreateBorder line is in the addons lua file, however not in a standalone addon.

I'm guessing an addon with nothing but the .toc file and that line doesn't work?

( CreateBorder(sThreatMeter, 12, 7, 7, 7, 1, 2, 1, 2, 1, 48, 1, 48) )

Thanks for the reply :)

Porsha 09-07-10 10:37 AM

Quote:

Originally Posted by Viridis (Post 205161)
The sThreatMeter2 border works when the CreateBorder line is in the addons lua file, however not in a standalone addon.

I'm guessing an addon with nothing but the .toc file and that line doesn't work?

( CreateBorder(sThreatMeter, 12, 7, 7, 7, 1, 2, 1, 2, 1, 48, 1, 48) )

Thanks for the reply :)

This is what I have in my sThreatMeter2 file (not the config one) but the main one. I use !Beautycase too :P

anyways, with a text editor thing, open it up and find about line 143 - the local Function UndateThreatBars =

add this (but fix it so it is your border perference):

bar.background = bar:CreateTexture("$parentBackground", "BACKGROUND");
bar.background:SetAllPoints();
bar.background:SetTexture(sThreatMeter_Data.Texture);
--bar.background:SetBackdrop{
--bgFile = "Interface\\ChatFrame\\ChatFrameBackground", tile = true, tileSize = 16,
--insets = {left = -1, right = -1, top = -1, bottom = -1},
--}
--bar.background:SetBackdropColor(0,0,0,1)
--CreateBorder(bar,3,0,0,0,1,1,1,1,1,1,1,1)

I have mine commented out cause I sont want a border :P so make sure you delete all the "--" from that.


Hope that helps!

edit: oh so i should read better....no, it wont work cause you have to have the border create it during the fuction phase of the bar.....hope that makes sense. thats why !BeautyCase is so wonderful...one line and your done

Viridis 09-07-10 10:56 AM

Thanks all! Cleared up a few things. :)

Guardix 09-07-10 11:56 AM

You can create a simple addon yourself to fix the border and make it depend on sThreatMeter2 and !BeautyCase, so that it loads when sThreatMeter2 is loaded (This way you make sure sThreatMeter isn't a nil value).


All times are GMT -6. The time now is 04:21 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI