Advertisement
Guest User

Untitled

a guest
Dec 15th, 2018
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.29 KB | None | 0 0
  1. # Effort
  2.  
  3. Variables:
  4.  
  5. {killstreak::%player%} = 0
  6.  
  7. {kills::%player%} = 0
  8.  
  9. {deaths::%player%} = 0
  10.  
  11. {xpmultiplier} = 1
  12.  
  13. {tokens::%player%} = 0
  14.  
  15. Options:
  16.  
  17.  
  18.  
  19. # Main
  20.  
  21. on join:
  22. clear player's inventory
  23. teleport player to {spawn}
  24.  
  25. command /setspawn:
  26. permission: admin
  27. trigger:
  28. set {spawn} to location of player
  29. wait 1 tick
  30. send "&7You set the spawn point to &b%{spawn}%&7!"
  31.  
  32. command /xpmultiplier [<number>]:
  33. aliases: /xpm
  34. trigger:
  35. if arg-1 is set:
  36. set {xpmultiplier} to arg-1
  37. send "&7You changed the xp multiplier to &b%arg-1%&7!"
  38. else:
  39. send "&7You must include a number!"
  40.  
  41. #PVP
  42.  
  43. on damage:
  44. if attacker is player:
  45. if victim is player:
  46. if victim's health < damage:
  47. heal the victim
  48. add 1 to {tokens::%attacker%}
  49. add 1 to {kills::%attacker%}
  50. add 1 to {deaths::%victim%}
  51. set {_xp-earned} to (10*{xpmultiplier})
  52. wait 1 tick
  53. add {_xp-earned} to {xp::%attacker%}
  54. clear {killstreak::%victim%}
  55. send attacker title "&b&lKILL" with subtitle "&7You killed &b%victim%&7!"
  56. teleport victim to {spawn}
  57. execute console command "/playsound minecraft:entity.enderdragon_fireball.explode master %victim% ~ ~ ~ 1000 2"
  58. set {_health} to attacker's health
  59. broadcast "&b%attacker% &7killed &b%victim% &7with &c%{_health}%&4❤"
  60. add 1 to {killstreak::%attacker%}
  61. wait 1 tick
  62. if {killstreak::%attacker%} is equal to 3:
  63. broadcast "&b%attacker% &7is now on a kill streak of &b&l3&7!"
  64. else if {killstreak::%attacker%} is equal to 5:
  65. broadcast "&b%attacker% &7is now on a kill streak of &b&l5&7!"
  66. else if {killstreak::%attacker%} is equal to 10:
  67. broadcast "&b%attacker% &7is now on a kill streak of &b&l10&7!"
  68. heal the victim
  69. if {xp::%attacker%} is greater than or equal to {xpneeded::%player%}:
  70. add 1 to {level::%player%}
  71. set {xp::%player%} to 0
  72. wait 1 tick
  73. set {xpneeded::%player%} to {xpneeded::%player%}+({xpneeded::%player%}*0.25)
  74. wait 1 tick
  75. set {xpneeded::%player%} to round({xpneeded::%player%})
  76. wait 1 tick
  77. send player title "&3&lLEVEL UP" with subtitle "&7You are now level &b%{level::%player%}%" for 2 seconds
  78. else:
  79. set action bar of attacker to "&7You dealt &c%damage%&4❤ &7to &b%victim%"
  80. execute console command "/playsound minecraft:entity.enderdragon.hurt master %attacker% ~ ~ ~ 1000 2"
  81.  
  82. every 2 seconds:
  83. loop all players:
  84. wipe loop-player's sidebar
  85. set name of sidebar of loop-player to "&b&lEFFORT"
  86. set score "" in sidebar of loop-player to 10
  87. set score " &3Player Stats" in sidebar of loop-player to 9
  88. set score "&r" in sidebar of loop-player to 8
  89. set score "&fTokens: &b%{tokens::%loop-player%}%❂" in sidebar of loop-player to 7
  90. set score "&fKills: &b%{kills::%loop-player%}%" in sidebar of loop-player to 6
  91. set score "&fDeaths: &b%{deaths::%loop-player%}%" in sidebar of loop-player to 5
  92. set score "&fLevel: &b%{level::%loop-player%}%" in sidebar of loop-player to 4
  93. set score "&fXP: &b%{xp::%loop-player%}%&f/&b%{xpneeded::%loop-player%}%" in sidebar of loop-player to 3
  94. set {kdr::%loop-player%} to ({kills::%loop-player%}/{deaths::%loop-player%})
  95. set score "&fKDR: &b%{kdr::%loop-player%}%" in sidebar of loop-player to 2
  96. set score "&r&r" in sidebar of loop-player to 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement