Floating effect

Hi guys,

First post here, so hi to everybody!

Now, what I'm trying to achieve is a "floating space". Think about it as a space where objects are in some sort of suspension, not completely still but moving slowly and smoothly in a random manner not far from their initial position. I was trying to do this just by myself until someone suggested using a physics engine and here I am.

Sadly I have no previous experience with physics engines (although I remember some of the stuff from school days!) but I've been reading the Wiki, some of the tutorials and samples available and I think it's doable.

At first I thought I could get away with a very low gravity that would randomly change direction but that would move ALL elements in the same direction at the same time and doesn't look good.

So I think what I have to do is apply some sort of random and unique force to each of the elements so the overall look is more random. But before getting there I would to double check I'm going in right direction.

Any ideas, gotchas or indications much appreciated : )

Cheers!

Juan
I would try to turn the x and y gravity very low, or completely to 0, what you already thought about and then play around
with the friction and linear/angular damping of your bodys. Try a low value for friction, so your objects wont completely stop very
fast, but slow down and float a bit until they stop. And also keep the dumping low, for the same reason.
So Zarate, have you learned Box2d at all yet? It kinda doesn't sound like you have, and if that's the case go here! -- http://kerp.net/box2d/ -- This guy made all these video tutorials, and they're great! You should learn a lot of what you need from there. It is definitely possible and probably easier to do what you want to do without using a physics engine from what it sounds like, though. So long as you don't want all the particles colliding with each other or anything, you'd probably be better off not using a physics engine. Box2d is amazing, though, so definitely learn it.. just because. It'll come in handy many, many times in the future.. hope all that helps

Original thread: https://box2d.org/forum/viewtopic.php?t=3221