Thread Tools Display Modes
08-03-09, 03:45 PM   #1
Belszy
An Aku'mai Servant
Join Date: Jun 2008
Posts: 32
Changing Coors - HUD

Question, I have seen people manipulate them but can you chage the color of your health.mana bars or huds? i am interested into changing them into red/blue or anything honestly but i would like to know how to do it.

V/r
Belszy
 
08-03-09, 04:54 PM   #2
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
In order to do that, at present, you will have to edit the colors in the unit source code... for health edit [ Interface > AddOns > nUI > Units > nUI_UnitHealth.lua ] and look near the top of the file for the following...

Code:
nUI_DefaultConfig.BarColors.Health =
{
    ["min"] = { r = 1, g = 0, b = 0, a = 1 },    -- empty bar color
    ["mid"] = { r = 1, g = 1, b = 0, a = 1 },    -- bar color at 50%
    ["max"] = { r = 0, g = 1, b = 0, a = 1 },    -- full bar color
};
For the power bars, you would edit [ Interface > AddOns > nUI > Units > nUI_UnitPower.lua ] and locate the following section...

Code:
nUI_DefaultConfig.BarColors.Power =
{
    ["Mana"] =
    {
        ["min"] = { r = 1, g = 0, b = 1, a = 1 },    -- empty bar color
        ["mid"] = { r = 0, g = 0.5, b = 1, a = 1 },    -- bar color at 50%
        ["max"] = { r = 0, g = 0.5, b = 1, a = 1 },    -- full bar color
    },    
    ["Rage"] =
    {
        ["min"] = { r = 1, g = 0, b = 0, a = 1 },    -- empty bar color
        ["mid"] = { r = 1, g = 0, b = 0, a = 1 },    -- bar color at 50%
        ["max"] = { r = 1, g = 0, b = 0, a = 1 },    -- full bar color
    },    
    ["Energy"] =
    {
        ["min"] = { r = 1, g = 1, b = 0, a = 1 },    -- empty bar color
        ["mid"] = { r = 1, g = 1, b = 0, a = 1 },    -- bar color at 50%
        ["max"] = { r = 1, g = 1, b = 0, a = 1 },    -- full bar color
    },    
    ["Focus"] =
    {
        ["min"] = { r = 1, g = 0.35, b = 0, a = 1 },    -- empty bar color
        ["mid"] = { r = 1, g = 0.35, b = 0, a = 1 },    -- bar color at 50%
        ["max"] = { r = 1, g = 0.35, b = 0, a = 1 },    -- full bar color
    },
    ["Runes"] =
    {
        ["min"] = { r = 0.5, g = 0.5, b = 0.5, a = 1 },    -- empty bar color
        ["mid"] = { r = 0.5, g = 0.5, b = 0.5, a = 1 },    -- bar color at 50%
        ["max"] = { r = 0.5, g = 0.5, b = 0.5, a = 1 },    -- full bar color
    },
    ["RunicPower"] =
    {
        ["min"] = { r = 0, g = 0.82, b = 1, a = 1 },    -- empty bar color
        ["mid"] = { r = 0, g = 0.82, b = 1, a = 1 },    -- bar color at 50%
        ["max"] = { r = 0, g = 0.82, b = 1, a = 1 },    -- full bar color
    },
};
The 'r', 'g' and 'b' values are the red, green and blue where 0 means no color and 1 is full intensity. The 'a' value is the transparency where 0 is fully transparent and 1 is fully opaque.

Each color set has a min, mid and max value... min is the color with the bar is empty, max is the color when the bar is full and mid is the color when the bar is 50% -- so if you look at the colors for the health bar, you'll see the bar is green when it is full, yellow at 50% and red when it's empty... the colors shade inbetween those values.
__________________

What people don't get is that I am, ultimately, an artist at heart.
My brush has two colors, 1 and 0, and my canvas is made of silicon.



Official nUI Web Site: http://www.nUIaddon.com
Official nUI Support Forum: http://forums.nUIaddon.com
My day job: http://www.presidio.com/
 
 

WoWInterface » Featured Projects » nUI, MozzFullWorldMap and PartySpotter » Support » nUI: Technical Support » Changing Coors - HUD


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off