How do I make it so that the player will go off the screen and come back on the other side like pacman?
So I just put together a quick example here:
The behaviors are a little tricky, but first I created a basic level with a moving player and a block floor. Then I added the following behaviors to the player slime object.
- An Always trigger so that the logic will run every game "tick"
- The always trigger is connected to an Extractor that extracts the players "x" position property
- The player's extracted property is sent through two filters, one checking whether the position is less than 320 (the left side of the game level here), and one checking whether the position is greater than 650 (the right side of the game here)
- If the position is less than 320, the value 650 is sent into the players x position, and vice-versa
The end result, is that if the player crosses over one side of the game level, he is reset to the other.
I checked that out. The behavior looks really simple.