Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /questszum <text> [<integer>]:
- permission: mod
- trigger:
- arg 1 is "set":
- arg 2 is set:
- block below player is diamond block:
- {questpoke.portal::%location of block below player%} is not set:
- set {questpoke.loc::%arg 2%} to location of block below player
- set {questpoke.portal::%location of block below player%} to arg 2
- send "&aUstawiono portal nr %arg 2% na kordy &e%{questpoke.loc::%arg 2%}%"
- else:
- send "&cNie stoisz na bloku diamentu!"
- else:
- send "&eUzyj /questszum set <numer>"
- arg 1 is "rem" or "remove":
- arg 2 is set:
- {questpoke.loc::%arg 2%} is set:
- delete {questpoke.portal::%{questpoke.loc::%arg 2%}%}
- delete {questpoke.loc::%arg 2%}
- {questpoke.loc::%arg 2+1%} is set:
- set {_a} to size of {questpoke.loc::*}+1
- set {questpoke.portal::%{questpoke.loc::%{_a}%}%} to arg 2
- set {questpoke.loc::%arg 2%} to {questpoke.loc::%{_a}%}
- delete {questpoke.loc::%{_a}%}
- send "&aPomyslnie usunieto portal o numerze %arg 2%"
- else:
- send "&cNie ma portalu nr %arg 2%"
- else:
- send "&eUzyj /questszum rem <numer>"
- arg 1 is "list":
- send "&3Razem jest &c%size of {questpoke.loc::*}% &3portali:"
- loop {questpoke.loc::*}:
- send " &b%loop-index%. &7%loop-value%"
- arg 1 is "clear":
- delete {questpoke.portal::*}
- delete {questpoke.loc::*}
- send "&aPomyslnie usunieto wszystkie portale"
- # arg 1 is "regset":
- # arg 2 is set:
- # set {questpoke.spawn::%arg 2%} to player's location
- # send "&aUstawiono spawn przy wejsciu na region 'pokoj%arg 2%' na kordy &e%player's location%"
- #
- # arg 1 is "regdel":
- # arg 2 is set:
- # {questpoke.spawn::%arg 2%} is set:
- # set {questpoke.spawn::%arg 2%} to player's location
- # send "&aUsunieto spawn przy wejsciu na region 'pokoj%arg 2%'"
- # else:
- # send "&cNie ma takiego spawnu"
- #
- # arg 1 is "reglist":
- # send "&3Razem jest &c%size of {questpoke.spawn::*}% &3spawnow regionow:"
- # loop {questpoke.spawn::*}:
- # send " &b%loop-index%. &7%loop-value%"
- on walk on diamond block:
- {questpoke.portal::%location of event-block%} is set:
- loop regions at player:
- "%loop-region%" contains "pokoj":
- loop all entities:
- "%regions at loop-entity%" contains "%loop-region%":
- "%type of loop-entity%" is "zombie" or "zombie pigman" or "creeper" or "spider" or "wither" or "skeleton":
- send "&cNie ladnie tak uciekac przed walka c:"
- stop
- exit 2 sections
- set {_p} to {questpoke.portal::%location of event-block%}
- set {_nr} to {_p}+{questpoke.rand}+length of name of player
- set {_tp} to false
- while {_tp} is false:
- add 1 to {_nr}
- set {_nr} to mod({_nr}, size of {questpoke.loc::*}) + 1
- set {_l} to location of block above {questpoke.loc::%{_nr}%}
- set {_b} to block at {_l}
- loop blocks from block above {_b} to block at player:
- loop-block is not air:
- set {_tp} to true
- exit 2 sections
- teleport player to {_l}
- on script load:
- set {questpoke.rand} to random integer between 0 and 60
- #on region enter:
- # "%region%" starts with "pokoj":
- # set {_r} to "%region%"
- # replace all "in world %player's world%" in {_r} with ""
- # teleport player to {questpoke.spawn::%{_r}%}
Advertisement
Add Comment
Please, Sign In to add comment