2D Platformer: Teleport Character To Last Known Position After Hitting World Bottom

Alright, so here’s my problem: I’ve got a 2D platformer running on the basic X-Z axes with no Y, right? I’ve got a plane called WorldFloor at the bottom of the playable area that has the property “WorldFloor” as a boolean. I’ve also got two invisible cubes on either side of the area that stretch from the play floor to quite a ways above where the player can traverse. When the player comes into contact with these two cubes they’re assigned the boolean properties “PlayerLedgeRight1” or “PlayerLedgeLeft1” to track which side they went off of. When the player hits WorldFloor or the opposing cube either ledge property is set to remove itself accordingly. My problem is I want the player to teleport to these invisible cubes when they hit the WorldFloor object, but I have no idea how. Any suggestions?

You can teleport using the simple motion actuator set to trigger only once - this teleports relative to where the player current is, which is not what you want.
The other solution is to play an animation - because animations can be done in world coordinates. This will allow you to teleport to an exact position.

In blender:

  • Move the player to where you want him to be ‘restored’ to
  • Insert a keyframe

In your game:

  • When the player hits the bottom, play the frame with him at the top.

The action can contain multiple positions, and you play the frame of the one you want him to teleport to.

Ah, right. So disable Local coordinates and set it to Global then? That’s… Deceptively simple.