Advertisement
Guest User

Should stop now

a guest
Apr 23rd, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.31 KB | None | 0 0
  1. options:
  2. PrestigeCost: 100000
  3. firstRank: Prisoner
  4. lastRank: God
  5.  
  6. pr: &a&lPrestige &8»
  7. error: &c&lError &8»
  8.  
  9. NoPerm: &cYou don't enough permissions to do that.
  10.  
  11.  
  12. PresTitle: &aCongratulations!
  13. PresSubtitle: &7You've Presitged to &a&l%{_pres}%
  14.  
  15. PresMsg: &f&lGG&a! You've Prestiged to &f&l%{_pres}%
  16. PresBroadcast: &a>&b>&c> &f%{_p}% &aPrestiged to &f%{_pres}%
  17.  
  18. Particle: heart
  19. ParticleCount: 50
  20.  
  21. Sound: ENTITY_PLAYER_LEVELUP
  22.  
  23. on join:
  24. {Prestige::playerdata::%uuid of player%} is not set
  25. set {Prestige::playerdata::%uuid of player%} to 0
  26.  
  27. function prestigeUp(p: player):
  28. set {_pU} to uuid of {_p}
  29. if {_p} doesn't have permission "essentials.kits.{@lastRank}":
  30. send "{@pr} &cYou need to be at rank &f{@lastRank} &cto Prestige." to {_p}
  31. set {_cant} to true
  32. {_cant} is not set
  33. set {_price} to {@PrestigeCost} * {Prestige::playerdata::%{_pU}%} if {Prestige::playerdata::%{_pU}%} > 0 else {@PrestigeCost}
  34. if {_p}'s balance >= {_price}:
  35. remove {_price} from {_p}'s balance
  36. add 1 to {Prestige::playerdata::%{_pU}%}
  37. if player's group is not "coal" or "iron" or "gold" or "diamond+" or "emerald" or "legend" or "god" or "jrmod" or "mod" or "admin" or "manager" or "staffmanager" or "dev" or "coowner" or "owner":
  38. console command "pex user %{_p}% group remove {@lastRank}"
  39. console command "pex user %{_p}% group add {@firstRank}"
  40. teleport {_p} to spawn of (world of {_p})
  41. set {_pres} to {Prestige::playerdata::%{_pU}%}
  42. send {_p} title "{@PresTitle}" with subtitle "{@PresSubtitle}" for 3 seconds
  43. send "{@pr} {@PresMsg}" to {_p}
  44. send "{@PresBroadcast}" to all players
  45. loop all players in radius 50 around {_p}:
  46. show {@ParticleCount} "{@Particle}" particles at {_p} for loop-player
  47. play "{@Sound}" to {_p}
  48. else:
  49. send "{@pr} &cYou don't have enough money. &7&o(Cost: &f$%{_price}%&7&o)" to {_p}
  50.  
  51.  
  52.  
  53. command /prestige [<text>] [<offlineplayer>] [<integer>]:
  54. aliases: pres
  55. trigger:
  56. if arg-1 is "help":
  57. if player has permission "prestige.help":
  58. send "{@pr} &a/pres help &8- &7Shows this message."
  59. send "{@pr} &a/pres set <player> <number> &8- &7Change player's prestige."
  60. send "{@pr} &a/pres &8- &7To prestige."
  61. stop
  62. else:
  63. send "{@NoPerm}"
  64. stop
  65.  
  66. if arg-1 is "set":
  67. if player has permission "prestige.set":
  68. if arg-2 is set:
  69. if arg-3 is set:
  70. set {Prestige::playerdata::%uuid of arg-2%} to arg-3
  71. send "{@pr} &aSuccessfully set &f%arg-2%&a's prestige to &f%arg-3%" to player
  72. send "{@pr} &aYour prestige has been manually set to &f%arg-3%&a." to arg-2
  73. stop
  74. else:
  75. send "{@error} &cMissing Prestige number."
  76. stop
  77. else:
  78. send "{@error} &cMissing player name."
  79. stop
  80. else:
  81. send "{@NoPerm}"
  82. stop
  83. else:
  84. prestigeUp(player)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement