Advertisement
Guest User

Untitled

a guest
May 30th, 2016
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.71 KB | None | 0 0
  1. function greaterHeal()
  2. gh_shouldStop = gh_shouldStop or false
  3. gh_castFinishTime = gh_castFinishTime or 0
  4. gh_nextCastAt = gh_nextCastAt or 0
  5.  
  6. local currentTime = GetTime()
  7. local gh_cooldown = spellCooldown("Greater Heal")
  8.  
  9. if gh_cooldown > 0 then
  10. gh_castFinishTime = currentTime + 2.5 - 1.5 + gh_cooldown
  11. gh_shouldStop = true
  12. end
  13.  
  14. if UnitHealth("Target") > UnitHealthMax("Target")-2000 and currentTime > gh_castFinishTime-0.2 and gh_shouldStop then
  15. stopcast()
  16. gh_nextCastAt = currentTime + 0.2
  17. gh_shouldStop = false
  18. end
  19.  
  20. if gh_cooldown <= 0 and currentTime > gh_nextCastAt then
  21. cast("Greater Heal(rank 2)")
  22. end
  23. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement