Advertisement
twogz

Untitled

Jul 13th, 2017
69
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.99 KB | None | 0 0
  1. on first join:
  2. set {level::%uuid of player%} to 0
  3. set {xp::%uuid of player%} to 0
  4. set {xpmax::%uuid of player%} to 50
  5.  
  6. command /reset:
  7. trigger:
  8. set {level::%uuid of player%} to 0
  9. set {xp::%uuid of player%} to 0
  10. set {xpmax::%uuid of player%} to 50
  11.  
  12. on break:
  13. cancel event
  14.  
  15. if event-block is coal ore:
  16. set event-block to stone
  17. give coal item to player
  18. execute console command "/xp add %player% 5"
  19. wait 10 seconds
  20. set event-block to coal ore
  21.  
  22. if event-block is iron ore:
  23. set event-block to stone
  24. give iron ingot to player
  25. execute console command "/xp add %player% 5"
  26. wait 10 seconds
  27. set event-block to iron ore
  28.  
  29. if event-block is gold ore:
  30. set event-block to stone
  31. give gold ingot to player
  32. execute console command "/xp add %player% 5"
  33. wait 10 seconds
  34. set event-block to gold ore
  35.  
  36. if event-block is diamond ore:
  37. if {level::%uuid of player%} < 20:
  38. message "&c&lYou must be at least Level 20 to mine this!"
  39. else:
  40. set event-block to stone
  41. give diamond to player
  42. execute console command "/xp add %player% 5"
  43. wait 10 seconds
  44. set event-block to diamond ore
  45.  
  46. if event-block is emerald ore:
  47. if {level::%uuid of player%} < 20:
  48. message "&c&lYou must be at least Level 20 to mine this!"
  49. else:
  50. set event-block to stone
  51. give emerald to player
  52. execute console command "/xp add %player% 5"
  53. wait 10 seconds
  54. set event-block to emerald ore
  55.  
  56. on chat:
  57. cancel event
  58. broadcast "&7Lvl %{level::%uuid of player%}% &e%player% &f%message%"
  59.  
  60.  
  61. command /xp [<text>] [<player>] [<integer>]:
  62. executable by: console
  63. trigger:
  64. if arg 1 is "add":
  65. add arg 3 to {xp::%uuid of arg 2%}
  66. message "&a&l + %arg 3% XP" to arg 2
  67. if {xp::%uuid of arg 2%} >= {xpmax::%uuid of arg 2%}:
  68. add 1 to {level::%uuid of arg 2%}
  69. set {xp::%uuid of arg 2%} to 0
  70. message "&e&lYou are now Level %{level::%uuid of arg 2%}%" to arg 2
  71.  
  72. on any movement:
  73. if player's y-level is below 90:
  74. kill player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement