WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   OpenRDX: Community Chat (https://www.wowinterface.com/forums/forumdisplay.php?f=107)
-   -   Rested xp on an Xpbar ? (https://www.wowinterface.com/forums/showthread.php?t=22876)

KiwiiDawn 04-25-09 12:13 PM

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?

Dgrimes 04-25-09 02:37 PM

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.

Dgrimes 04-26-09 07:52 AM

Sorry I forgot to say use the trxp as the fraction variable for the status bar fractional variable.

KiwiiDawn 04-26-09 07:58 AM

Thank you very much, Ill try it out when i work on my UI some more today.


All times are GMT -6. The time now is 05:06 AM.

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