Code:
every tick:
loop all players
set {loc} to player's location
if {loc} is 50026 13 50001:
make console execute command "gamemode spectator %player%"
freeze player
teleport player to 50026 27 50001
wait 0.5 second
teleport player to 50026 24 50001
wait 0.5 second
teleport player to 50026 27 50001
wait 0.5 second
teleport player to 50026 24 50001
wait 1 second
teleport player to 50026 13 50001
make console execute command "gamemode survival %player%"
set block to barrier at {loc}
set {start} to true
also i need so while the animation will play there will be a title "&dCorruptor Boss" that would change color to "&bCorruptor Boss" and then again to "&dCorruptor Boss" (by using {start} im going to start the boss fight), help me please.