View Single Post
01-15-11, 11:09 PM   #7
unlimit
Lookin' Good
 
unlimit's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2008
Posts: 484
Yep, it definitely takes a bit from AP, about 19.8%.

Final code here and perfectly accurate! Thanks a lot Crispii for your help and the original code! =D

Code:
function FracHealthWOG()
  local heal = 2133+(0.209*GetSpellBonusHealing()+0.198*UnitAttackPower(uid));
  local holypower
  if UnitAura(uid, GetSpellInfo(76672)) then holypower = UnitPower(uid,9)+3;
  else holypower = UnitPower(uid,9);
  end
  local a = (UnitHealth(uid)+(heal*holypower));
  local b = UnitHealthMax(uid);
  if(b<1) then return 0; end
  a=a/b;
  if a<0 then
    return 0;
  elseif a>1 then
    return 1;
  else
    return a;
  end
end
wog = FracHealthWOG();
__________________


kúdan: im playing pantheon
JRCapablanca: no youre not
** Pantheon has been Banned. **

Last edited by unlimit : 01-17-11 at 03:28 AM.
  Reply With Quote