Thread Tools Display Modes
04-25-09, 12:13 PM   #1
KiwiiDawn
A Black Drake
Join Date: Mar 2008
Posts: 83
Rested xp on an Xpbar ?

Hi how do i add rested xp to the xp bar?

I tried to follow this scripts here
http://www.openrdx.com/forums/viewto...ghlight=rested

but can't seem to get it to work. any one out there with a working one?
  Reply With Quote
04-25-09, 02:37 PM   #2
Dgrimes
A Black Drake
 
Dgrimes's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 89
This is the script I used.

Code:
rxp = GetXPExhaustion();
cxp, trxp, lrxp, cmxp = 0, 0, 0, 0;

if rxp == nil then 
 lrxp = 0;
end

if rxp then
 cxp = UnitXP("player");
 cmxp = UnitXPMax("player");
 if (rxp + cxp) > cmxp then 
  lrxp = cmxp;
 elseif (rxp + cxp) < cmxp then
  lrxp = cxp + rxp;
 end

 trxp = format("%.2f", (lrxp/cmxp));
end
That should work for you.
__________________
What was is, what will be was.
  Reply With Quote
04-26-09, 07:52 AM   #3
Dgrimes
A Black Drake
 
Dgrimes's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 89
Sorry I forgot to say use the trxp as the fraction variable for the status bar fractional variable.
__________________
What was is, what will be was.
  Reply With Quote
04-26-09, 07:58 AM   #4
KiwiiDawn
A Black Drake
Join Date: Mar 2008
Posts: 83
Thank you very much, Ill try it out when i work on my UI some more today.
  Reply With Quote

WoWInterface » Featured Projects » OpenRDX » OpenRDX Community » OpenRDX: Community Chat » Rested xp on an Xpbar ?


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