kodokoto / Eldermyst

A 2.5D wizard-themed platformer, with combo-based spell system
https://kodokoto.github.io/Eldermyst/
4 stars 0 forks source link

Add moving platforms #17

Closed kodokoto closed 11 months ago

kodokoto commented 12 months ago

Moving platforms should be implemented.

I think the most interesting way to do this would be to implement a "rail" (a line) that has a platform, centered within that rail and moves alongside it.

This way the movement and direction of the platform are dictated entirely by the rail (which is placed when building levels), and we don't have to worry about hardcoding specific platforms (i.e. up-down platform, left-right platform).

The platform itself should run through the rail at its centre, where its position follows the rail, and its rotation should always be at a horizontal angle.

kodokoto commented 12 months ago

We could build a very basic "Auto Moving" system (An interface), that references some object, and a path (an array of points). In Start() it will move the object to the first point in path. Then in Update(), it will move the object towards the next point, at a given speed.

Some extra features would be: