Now we are ready to define when the player will get teleported. For that we will need an event, on the right, under Player Events, you’ll see When Trigger is Entered by Player. Use your laser pointer to click and pull it to the left side.
We know that this script will run on a trigger, so this event will fire whenever that trigger is entered by a player.
The next code block we need is Respawn Player, this can be found on the second tab from the left, Motion, and if we scroll down to Player Motion, we can grab the Respawn Player codeblock. When you see a white line indented under the event, you can release the codeblock.
Seen above is our current script, in the next part we will add in the variables.