View Single Post
06-03-09, 06:38 AM   #7
spiel2001
nUI's Author
 
spiel2001's Avatar
AddOn Author - Click to view addons
Join Date: Jun 2008
Posts: 7,724
NO! NO! NO!

This is the *WRONG* way to make changes to nUI's layout... you never modify the executable code, only the layout files.

Do not *EVER* modify the files in [ Interface > AddOns > nUI > Units ]

If you want to display current power instead of percent power, you edit the files in [ Interface > AddOns > nUI > Layouts > Default > HUDLayouts (or UnitPanels) > etc... ] -- In those files you'll find sections for ["Health"] and ["Power"] which control what the display of health and power bars look like. To change the power bars to display current power instead of percent power, you replace the pct_power = section with cur_power = and voila, you display current power instead of percent.

Originally Posted by Xrystal View Post
Okay, took a gander in the files and found this that you could change if you were inclined and confident to do so.

File: nUI_UnitPower.lua in nUI/Units folder
Line: 890 or thereabouts

Code:
if frame.bar.enabled then
   frame.bar.updateBar( unit_info.pct_power, unit_info.power_color );
end
If you change pct_power to cur_power it looks like it will display the current power ( in your case mana ) value. Not in game at present to test it at the moment but the value should exist and thus display unless it gets overridden at a later date.
__________________

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/