Advertisement
twogz

Untitled

Jul 26th, 2017
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.37 KB | None | 0 0
  1. on first join:
  2. set {xp.%uuid of player%} to 0
  3. set {xpmax.%uuid of player%} to 1000
  4. set {level.%uuid of player%} to 1
  5. set {booster.%player%} to 1
  6.  
  7. command /xp [<text>] [<player>] [<integer>]:
  8. trigger:
  9. if player does not have permission "admin.xp":
  10. message "&cYou must be admin or higher to use this command."
  11. else:
  12. if arg 1 is not set:
  13. message "&c/xp give (player) (amount)"
  14. if arg 1 is "give":
  15. add arg 3 to {xp.%uuid of arg 2%}
  16. if {xp.%uuid of arg 2%} >= {xpmax.%uuid of arg 2%}:
  17. add 1 to {level.%uuid of arg 2%}
  18. set {xp.%uuid of arg 2%} to 0
  19. add 500 to {xpmax.%uuid of arg 2%}
  20. message "&3You are now &blevel %{level.%uuid of arg 2%}%&3. Type &e/stats &3to view your progress." to arg 2
  21.  
  22. command /reset [<player>]:
  23. trigger:
  24. if player does not have permission "admin.reset":
  25. message "&cYou must be admin or higher to use this command."
  26. else:
  27. if arg 1 is not set:
  28. set {xp.%uuid of player%} to 0
  29. set {xpmax.%uuid of player%} to 1000
  30. set {level.%uuid of player%} to 1
  31. set {gold.%uuid of player%} to 0
  32. set {booster.%player%} to 1
  33. message "&3All of your stats have been reset."
  34. else:
  35. set {xp.%uuid of arg 1%} to 0
  36. set {xpmax.%uuid of arg 1%} to 1000
  37. set {level.%uuid of arg 1%} to 1
  38. set {gold.%uuid of arg 1%} to 0
  39. set {booster.%player%} to 1
  40. message "&3The stats of %arg 1% have been reset."
  41.  
  42. command /stats [<player>]:
  43. trigger:
  44. if arg 1 is not set:
  45. message ""
  46. message "&3Player: &b%player%"
  47. message "&eYou are level %{level.%uuid of player%}% and need &b%{xpmax.%uuid of player%} - {xp.%uuid of player%}% &emore experience to level up."
  48. message "&6You currently have &b%{gold.%uuid of player%}% &6gold."
  49. message ""
  50. else:
  51. if arg 1 is not online:
  52. message "&c/stats (online player)"
  53. else:
  54. message ""
  55. message "&3Player: &b%arg 1%"
  56. message "&eThis player is level %{level.%uuid of arg 1%}% and needs &b%{xpmax.%uuid of arg 1%} - {xp.%uuid of arg 1%}% &emore experience to level up."
  57. message "&6%arg 1% currently has &b%{gold.%uuid of arg 1%}% &6gold."
  58. message ""
  59.  
  60. on chat:
  61. cancel event
  62. if {prefix.%uuid of player%} is not set:
  63. broadcast "&7 Lvl. %{level.%uuid of player%}% %player%: %message%"
  64. else:
  65. broadcast "&f Lvl. %{level.%uuid of player%}% %{prefix.%uuid of player%}% %player%&f: %message%"
  66.  
  67. command /prefix [<player>] [<text>]:
  68. trigger:
  69. if player does not have permission "admin.prefix":
  70. message "&cYou must be admin or higher to use this command."
  71.  
  72. else:
  73. if arg 1 is not set:
  74. message "&c/prefix (player) (text)"
  75. else:
  76. set {prefix.%uuid of arg 1%} to "%coloured arg 2%"
  77. message "&3You set the prefix of &e%arg 1% &3to %coloured arg 2%"
  78.  
  79. on break:
  80. if player's gamemode is survival:
  81. cancel event
  82. if event-block is gold ore:
  83. if held item is pickaxe:
  84. add 1 * {booster.%player%} to {gold.%uuid of player%}
  85. message "&6 + %1 * {booster.%player%}% gold has been added to your balance. &7(%{booster.%player%}%x multiplier.)"
  86. execute console command "/xp give %player% 1"
  87. set {_r} to a random integer between 0 and 1
  88. if {_r} = 0:
  89. set event-block to stone
  90. if {_r} = 1:
  91. set event-block to andesite
  92. wait 5 minutes
  93. set event-block to gold ore
  94. else:
  95. message "&cThis block must be mined with a pickaxe."
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement