Advertisement
Guest User

Untitled

a guest
Feb 18th, 2020
251
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.62 KB | None | 0 0
  1. #
  2. # Action Bar, Health Finder, Defence Finder & Combat Timer
  3. #
  4. every 1 second:
  5. loop all players:
  6.  
  7. # Max Health & Defence Finder
  8. set {_h::vitality::*} to line 1 of the lore of the loop-player's helmet split at "&a+"
  9. set {_h::vitality::*} to {_h::vitality::2} split at " &7Vitality"
  10. if {_h::vitality::1} is not set:
  11. set {_h::vitality::1} to 0
  12. set {_c::vitality::*} to line 1 of the lore of the loop-player's chestplate split at "&a+"
  13. set {_c::vitality::*} to {_c::vitality::2} split at " &7Vitality"
  14. if {_c::vitality::1} is not set:
  15. set {_c::vitality::1} to 0
  16. set {_l::vitality::*} to line 1 of the lore of the loop-player's leggings split at "&a+"
  17. set {_l::vitality::*} to {_l::vitality::2} split at " &7Vitality"
  18. if {_l::vitality::1} is not set:
  19. set {_l::vitality::1} to 0
  20. set {_b::vitality::*} to line 1 of the lore of the loop-player's boots split at "&a+"
  21. set {_b::vitality::*} to {_b::vitality::2} split at " &7Vitality"
  22. if {_b::vitality::1} is not set:
  23. set {_b::vitality::1} to 0
  24. set {_h::defence::*} to line 2 of the lore of the loop-player's helmet split at "&a+"
  25. set {_h::defence::*} to {_h::defence::2} split at " &7Defence"
  26. if {_h::defence::1} is not set:
  27. set {_h::defence::1} to 0
  28. set {_c::defence::*} to line 2 of the lore of the loop-player's chestplate split at "&a+"
  29. set {_c::defence::*} to {_c::defence::2} split at " &7Defence"
  30. if {_c::defence::1} is not set:
  31. set {_c::defence::1} to 0
  32. set {_l::defence::*} to line 2 of the lore of the loop-player's leggings split at "&a+"
  33. set {_l::defence::*} to {_l::defence::2} split at " &7Defence"
  34. if {_l::defence::1} is not set:
  35. set {_l::defence::1} to 0
  36. set {_b::defence::*} to line 2 of the lore of the loop-player's boots split at "&a+"
  37. set {_b::defence::*} to {_b::defence::2} split at " &7Defence"
  38. if {_b::defence::1} is not set:
  39. set {_b::defence::1} to 0
  40.  
  41. set {_def} to 0
  42. add {_h::defence::1} to {_def}
  43. send "{_def} test%{_def}%test" to loop-player
  44. add {_c::defence::1} to {_def}
  45. add {_l::defence::1} to {_def}
  46. add {_b::defence::1} to {_def}
  47. set {defence::armor::%loop-player%} to {_def}
  48.  
  49. set {vitality::armor::%loop-player%} to ({_h::vitality::1}+{_c::vitality::1}+{_l::vitality::1}+{_b::vitality::1})
  50.  
  51. set {maxHealth::final::%loop-player%} to ({vitality::armor::%loop-player%}+{vitality::skill::%loop-player%}+{health::base::%loop-player%})
  52.  
  53. send "" to loop-player
  54. send "{_def} test%{_def}%test" to loop-player
  55. send "{_h::defence::1} test%{_h::defence::1}%test" to loop-player
  56. send "{_h::vitality::1} test%{_h::vitality::1}%test" to loop-player
  57. send "" to loop-player
  58. send "{defence::armor::%loop-player%} %{defence::armor::%loop-player%}%" to loop-player
  59. send "{vitality::armor::%loop-player%} %{vitality::armor::%loop-player%}%" to loop-player
  60. send "{maxHealth::final::%loop-player%} %{maxHealth::final::%loop-player%}%" to loop-player
  61. send "" to loop-player
  62.  
  63. # Combat Timer
  64. if {combat::timer::%loop-player%} is greater than 0:
  65. subtract 1 from {combat::timer::%loop-player%}
  66. if {combat::timer::%loop-player%} is equal to 0:
  67. set {combat::%loop-player%} to false
  68.  
  69. # Action Bar
  70. send action bar "&c❤ %{health::final::%loop-player%}%&c/%{maxHealth::final::%loop-player%}% &a❖ %{defence::final::%loop-player%}%" to loop-player
  71. if {combat::%loop-player%} is equal to true:
  72. send action bar "&c❤ %{health::final::%loop-player%}%&c/%{maxHealth::final::%loop-player%}% &a❖ %{defence::final::%loop-player%}% &e⚔ %{health::enemy::%loop-player%}%&e/%{maxHealth::enemy::%loop-player%}%" to loop-player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement