#Need help with code - show tooltip number relative to maximum HP?

3 messages · Page 1 of 1 (latest)

reef river
#

There's a priest pvp talent called catharsis - stores incoming damage that's released when you toss out a SWP. Damage stored can't exceed 15% of your health.

I'd want to compare its current tooltip number to my maximum health then show it as a percentage number. Anyone can help out?

tall cargo
#

have you checked wago.io for this? seems like something someone would've created already

vocal herald
#
function()
  local tt = aura_env.state.tooltip1 or 0 -- change from 1 as needed
  local mhp = UnitHealthMax("player") or 1
  return tt/mhp*100
end

Using the text %c%% and formatting %c to round as you like.