gravvy

scr_minushp

Jun 24th, 2016
145
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1.  
  2. take_hp = argument0;
  3. var calculate_dmg = true;
  4.  
  5. if(calculate_dmg)
  6. {
  7. hp_target = (current_hp - floor(take_hp/2));
  8. calculate_dmg = false;
  9. }
  10.  
  11. if(hp != hp_target && calculate_dmg == false)
  12. {
  13. hp--;
  14. }
  15.  
  16. if(hp == hp_target)
  17. {
  18. damage_amt = 0;
  19. current_hp = hp;
  20. hp_target = hp;
  21. set_dmg = true;
  22. }
Advertisement
Add Comment
Please, Sign In to add comment