command /setportal : trigger: if arg 1 is "Bedrock": set {bedrock::location} to location of player message "&0Server: Ustawiono" else if arg 1 is "FirstPortal": set {FirstPortal::location} to location of player message "&0Server: Ustawiono" else if arg 1 is "SecondPortal": set {SecondPortal::location} to location of player message "&0Server: Ustawiono" else if arg 1 is "Nether": set {NetherPortal::location} to location of player message "&0Server: Ustawiono" else if arg 1 is not set: message "You need to set a location for the following portals: Bedrock, FirstPortal, SecondPortal, Nether" on portal: if "%region at player%" contains "portal1": cancel event set {portal::%player%} to 1 send "%{portal::%player%}%" if 1 is 1: teleport player to {bedrock::location} message "You're now in nether above the bedrock!" delete {PaymentReceived::%player%} else: teleport player to {NetherPortal::location} message "You're now in the nether, enjoy!" set {lastPortalTeleportation::%player%} to now else if "%region at player%" contains "portal2": cancel event set {portal::%player%} to 2 if 2 is 2: teleport player to {bedrock::location} message "You're now in nether above the bedrock!" else: teleport player to {NetherPortal::location} message "You're now in the nether, enjoy!" else if "%region at player%" contains "nether": cancel event wait 3 ticks if {portal::%player%} is 1: teleport player to {FirstPortal::location} else if {portal::%player%} is 2: teleport player to {SecondPortal::location} else if {portal::%player%} is not set: send "You cannot return home yet" else if "%region at player%" contains "bedrock": cancel event wait 3 ticks if {portal::%player%} is 1: teleport player to {FirstPortal::location} message "You're now back!" else if {portal::%player%} is 2: teleport player to {SecondPortal::location}