Corrupted Castle
Code Snips - Moving with Objects
Code Snips - Moving with Objects
Player Child Mover - This gets the current movement force of the object that the player is standing on so that the player can be moved with it. The Player Movement Machine calls UpdateParent() and RemoveParent(). This was designed to be modular and works for any object that the player is standing on.
Moving Platform - Although this was originally developed to be a linear moving platform of any kind, it was eventually only used for the elevators in the game. This handles how the moving platform should behave, how fast it should travel from point A to B, and whether or not it should only travel one way.
For ease of development, this also draws a wireframe of the platform at points A and B in the editor for easier visualization when setting up the platform for level designers.