Advertisement
Guest User

Here

a guest
May 19th, 2019
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.34 KB | None | 0 0
  1. # Leveling script for PvP by Greqtest.
  2.  
  3. on first join:
  4. set {level.%player's uuid%} to 1
  5. set {xp.%player's uuid%} to 1
  6. set {xpNeeded.%player's uuid%} to 5
  7.  
  8. on death of player:
  9. if attacker is a player:
  10. if attacker has permission "xpmult.2":
  11. add 2 to {xp.%attacker's uuid%}
  12. send "&a+2 XP (Kill)" to attacker
  13. else:
  14. add 1 to {xp.%attacker's uuid%}
  15. send "&a+1 XP (Kill)" to attacker
  16.  
  17. on death of player:
  18. if attacker is a player:
  19. if {xp.%attacker's uuid%} = {xpNeeded.%attacker's uuid%}:
  20. add 1 to {level.%attacker's uuid%}
  21. send attacker title "&e&lLEVEL UP" with subtitle &aNew Level: &7%{level.%attacker's uuid%}%" for 5 seconds
  22. stop
  23.  
  24. if {level.%attacker's uuid%} < 5:
  25. set {xpNeeded.%attacker's uuid%} to 5
  26. set {xp.%attacker's uuid%} to 0
  27. stop
  28.  
  29. if {level.%attacker's uuid%} is between 5 and 9:
  30. set {xpNeeded.%attacker's uuid%} to 10
  31. set {xp.%attacker's uuid%} to 0
  32. stop
  33.  
  34. if {level.%attacker's uuid%} is between 10 and 14:
  35. set {xpNeeded.%attacker's uuid%} to 15
  36. set {xp.%attacker's uuid%} to 0
  37. stop
  38.  
  39. if {level.%attacker's uuid%} is between 15 and 19:
  40. set {xpNeeded.%attacker's uuid%} to 20
  41. set {xp.%attacker's uuid%} to 0
  42. stop
  43.  
  44. if {level.%attacker's uuid%} is between 20 and 24:
  45. set {xpNeeded.%attacker's uuid%} to 25
  46. set {xp.%attacker's uuid%} to 0
  47. stop
  48.  
  49. if {level.%attacker's uuid%} is between 20 and 24:
  50. set {xpNeeded.%attacker's uuid%} to 30
  51. set {xp.%attacker's uuid%} to 0
  52. stop
  53.  
  54. if {level.%attacker's uuid%} is between 25 and 29:
  55. set {xpNeeded.%attacker's uuid%} to 35
  56. set {xp.%attacker's uuid%} to 0
  57. stop
  58.  
  59. if {level.%attacker's uuid%} is between 30 and 34:
  60. set {xpNeeded.%attacker's uuid%} to 40
  61. set {xp.%attacker's uuid%} to 0
  62. stop
  63.  
  64. if {level.%attacker's uuid%} is between 35 and 39:
  65. set {xpNeeded.%attacker's uuid%} to 45
  66. set {xp.%attacker's uuid%} to 0
  67. stop
  68.  
  69. if {level.%attacker's uuid%} is between 40 and 44:
  70. set {xpNeeded.%attacker's uuid%} to 50
  71. set {xp.%attacker's uuid%} to 0
  72. stop
  73.  
  74. if {level.%attacker's uuid%} is between 45 and 49:
  75. set {xpNeeded.%attacker's uuid%} to 55
  76. set {xp.%attacker's uuid%} to 0
  77. stop
  78.  
  79. if {level.%attacker's uuid%} > 50:
  80. set {xpNeeded.%attacker's uuid%} to 60
  81. set {xp.%attacker's uuid%} to 0
  82. stop
  83.  
  84. # PRESTIGES BELOW
  85.  
  86. if {level.%attacker's uuid%} = 100:
  87. add 1 to {prestige.%attacker's uuid%}
  88. set {xpNeeded.%attacker's uuid%} to 5
  89. set {xp.%attacker's uuid%} to 0
  90.  
  91. command /level [<offlineplayer=%player%>]:
  92. usage: &c/level <player>
  93. trigger:
  94. if arg-1 is not set:
  95. send "&7&m--------------------" to player
  96. send "&eCurrent Level&7: %{level.%player's uuid%}%" to player
  97. send "&eNext Level&7: %{nextLevel.%player's uuid%}%" to player
  98. send "&eProgress&7: PROGRESS" to player # NEED A WAY To GET A PERCENTAGE OF THE WAY TO NEXT LEVEL
  99. send "&7&m--------------------" to player
  100. else:
  101. send "&7&m--------------------" to player
  102. send "&eCurrent Level&7: %{level.%arg-1's uuid%}%" to player
  103. send "&eNext Level&7: %{nextLevel.%arg-1's uuid%}%" to player
  104. send "&eProgress&7: PROGRESS" to player # NEED A WAY To GET A PERCENTAGE OF THE WAY TO NEXT LEVEL
  105. send "&7&m--------------------" to player
  106.  
  107. command /adminlevel [<offlineplayer=%player%>]:
  108. usage: &c/adminlevel <player>
  109. trigger:
  110. if arg-1 is not set:
  111. send "&7&m--------------------" to player
  112. send "&eLevel&7: %{level.%player's uuid%}%" to player
  113. send "&eXP&7: %{xp.%player's uuid%}%" to player
  114. send "&eXP Needed:&7: %{xpNeeded.%player's uuid%}%" to player # NEED A WAY To GET A PERCENTAGE OF THE WAY TO NEXT LEVEL
  115. send "&7&m--------------------" to player
  116. else:
  117. send "&7&m--------------------" to player
  118. send "&eLevel&7: %{level.%arg-1's uuid%}%" to player
  119. send "&eXP&7: %{xp.%arg-1's uuid%}%" to player
  120. send "&eXP Needed:&7: %{xpNeeded.%arg-1's uuid%}%" to player # NEED A WAY To GET A PERCENTAGE OF THE WAY TO NEXT LEVEL
  121. send "&7&m--------------------" to player
  122.  
  123. command /resetlevel [<offlineplayer=%player%>]:
  124. trigger:
  125. if arg-1 is not set:
  126. set {xp.%player's uuid%} to 1
  127. set {level.%player's uuid%} to 1
  128. set {prestige.%player's uuid%} to 0
  129. else:
  130. set {xp.%arg-1's uuid%} to 1
  131. set {level.%arg-1's uuid%} to 1
  132. set {prestige.%arg-1's uuid%} to 0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement