This is a short example of moving platforms in Unity3D.
Based on this tweet, I spent … 30 minutes? Maybe? putting it together.
This writeup took longer.
The approach uses two behaviour classes to achive the classical effect of moving platforms that follow some path.
- mark some empty GameObject as
- give each
- attach a
Moverinstance to your platform(s)
- uses the concept of
fuelto avoid losing movement when fast moving platforms don’t have far to travel
- provides some
Gizmologic to make looking at it easier
Normal Unity3D Rigidbody instaces will impact with normal cubes - so if your platforms have a collider you’re all set.
If you need-need Rigidbody platforms; you can make them
Kinematic to avoid weirdness.