Guest User

Scoucurse

a guest
Mar 11th, 2018
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.68 KB | None | 0 0
  1. options:
  2. czas: 1200 # tu ustaw czas po jakim konkurs ma sie rozpoczac
  3. ilosc: 5 # ilosc itemu po wpisaniu wlasciwego kodu
  4. item: emerald # jaki item ma dostawac osoba bo wpisaniu kodu
  5. gracze: 50 # ile graczy potrzeba do rozpoczencia konkursu
  6. variables:
  7. {konkurs} = 0
  8. every {@czas} seconds:
  9. if {@gracze} is smaller than number of players:
  10. execute console command "konkurs"
  11. command /konkurs [<text>]:
  12. trigger:
  13. if sender has permission "mcgramy.konkurs":
  14. loop 6 times:
  15. set {konkurs.znak%loop-number%} to 0 or 1 or 2 or 3 or 4 or 5 or 6 or 7 or 8 or 9 or "a" or "A" or "b" or "B" or "c" or "C" or "d" or "D" or "e" or "E" or "f" or "F" or "g" or "G" or "h" or "H" or "k" or "K" or "l" or "L" or "m" or "M" or "n" or "N" or "o" or "O" or "p" or "P" or "q" or "Q" or "r" or "R" or "s" or "S" or "t" or "T" or "u" or "U" or "v" or "V" or "w" or "W" or "x" or "X" or "y" or "Y" or "z" or "Z"
  16. set {konkurs.kod} to "%{konkurs.znak1}%%{konkurs.znak2}%%{konkurs.znak3}%%{konkurs.znak4}%%{konkurs.znak5}%%{konkurs.znak6}%"
  17. set {konkurs} to 1
  18. loop all players:
  19. execute console command "playsound mob.villager.yes %loop-player%"
  20. broadcast "&8» &7Magiczny kod to &a%{konkurs.kod}%&7 aby go wprowadzic i wygrac nagrode wpisz kod na chacie."
  21. else:
  22. message "&8» &aNie masz uprawnien do tego!"
  23. on chat:
  24. if {konkurs} is 1:
  25. if message contains "%{konkurs.kod}%":
  26. cancel event
  27. set {konkurs} to 0
  28. broadcast "&8» &c&lPlugin by Starplacek
  29. broadcast "&8» &7Konkurs magiczny kod wygrywa &a%player%&7."
  30. add 1 to {wygrane::%player%}
  31. give {@ilosc} {@item} to player
  32. loop all players:
  33. execute console command "playsound mob.villager.yes %loop-player%"
Advertisement
Add Comment
Please, Sign In to add comment