let rigidbody idle around in space

hey! i am working on a low gravity game: Wie die Technologie unser Leben verändert hat Essay - Pixelpizza - Medien and alles drum herum

and what i want to do is, that my rigidbody chracter is “ideling” a little bit around.
so that means that he pushes himself up (addforce) when he is moving down, and back down when he is moving upwards. the same for left and right. in the end he should always try to push himself back to his start position or a specific point.
so that it somehow looks like natural floating around in space. how would you do that?

For this difficult problem, the simplest reasonable solution is,

  1. attach one of Unity’s natty spring solutions
  1. write a script to VERY gently force the object in random directions at (probably) about 2hz

Note that when you see this done in say a PIxar movie, it is very much animated, not simulated. So, literally one of the half-dozen best animators on Earth will sit there for a few days and animate an “idle bobble” for the object in question. For buoancy in water, you can simulate it with math but it’s usually not very good.

I hope the simple solution using Unity’s handy spring, works for you.