FrostedWeFall

Spawner shop

Oct 25th, 2017
66
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.87 KB | None | 0 0
  1. command /spawner:
  2. trigger:
  3. open chest with 2 rows named "&b&lSpawner shop" to player
  4. wait 1 tick
  5. format slot 2 of player with 1 of 52 named "&b&lIron Golem Spawner" with lore "&7Price&8: &3&o1.500.000" to close then run [make player execute command "/spawnerbuy ig"]
  6. format slot 3 of player with 1 of 52 named "&b&lBlaze Spawner" with lore "&7Price&8: &3&o450.000" to close then run [make player execute command "/spawnerbuy blaze"]
  7. format slot 4 of player with 1 of 52 named "&b&lZombie Spawner" with lore "&7Price&8: &3&o55.000" to close then run [make player execute command "/spawnerbuy zombie"]
  8. format slot 5 of player with 1 of 52 named "&b&lPig Spawner" with lore "&7Price&8: &3&o20.000" to close then run [make player execute command "/spawnerbuy pig"]
  9. format slot 6 of player with 1 of 52 named "&b&lCow Spawner" with lore "&7Price&8: &3&o60.000" to close then run [make player execute command "/spawnerbuy cow"]
  10. command /spawnerbuy [<number>]:
  11. trigger:
  12. set {_pris} to arg 1
  13. if player's balance is bigger than or equal to {_pris}:
  14. if {_pris} is ig:
  15. execute console command "ss give %player% irongolem 1"
  16. execute console command "eco take %player% 1500000"
  17. if {_pris} is blaze:
  18. execute console command "ss give %player% blaze 1"
  19. execute console command "eco take %player% 450000"
  20. if {_pris} is zombie:
  21. execute console command "ss give %player% zombie 1"
  22. execute console command "eco take %player% 55000"
  23. if {_pris} is pig:
  24. execute console command "ss give %player% pig 1"
  25. execute console command "eco take %player% 20000"
  26. if {_pris} is cow:
  27. execute console command "ss give %player% cow 1"
  28. execute console command "eco take %player% 60000"
  29. remove {_pris} from player's balance
  30. message "&a&oYou buyed a spawner for &2&o%{_pris}%&a&o!"
  31. else:
  32. message "&c&oYou do not have enought money for this!"
Add Comment
Please, Sign In to add comment