[ODE] Naive newbie questions
Roel van Dijk
roelvandijk at home.nl
Thu Aug 21 13:45:02 2003
On Thursday 21 August 2003 20:12, Nolan J. Darilek wrote:
> I won't need some of ODE's features just yet, if ever. I may some day
> want to try making the game semi-graphical, but I can't imagine
> requiring MUD objects for every single type of joint and body
> imaginable. Initially I'm interested in basic collision detection,
> force and gravity. I'll probably create object primitives for
> cylinders, spheres, etc. and MUD objects will be groupings of those
> (I.e. I'll probably just model most humanoids as cylinders.) Is it
> possible to use ODE in this capacity? Could I define objects only as
> shapes, vehicles as boxes, humanoids as cylinders, and simply apply
> forces to them without necessarily, say, modeling the engine of a tank
> or the leg of a troll?
You can search the mailing list for posts about simulating characters in ODE,
ragdoll physics, that kinda stuff. There's quite a lot of discussion about
that. Simulating humanoids as cylinders is a good option. The only problem is
to balans the cylinder but I believe that problem has been solved.
> I'm trying to make the engine as flexible as possible. My current
> notion is that every game will require at least a planet and a
> universe, even if all of the action takes place on the planet. I may
> eliminate even this minimal requirement, but it seems to make sense
> for now. :) ODE uses the concept of a world, with gravity. Does ODE
> model gravitational attraction with sufficiently large objects? Could
> my "world" then be a 0-gravity universe, with the perceptual world
> being a large sphere with a given mass and radius?
The gravity in ODE is linear. It goes only in one direction, so you can't use
it to model the gravity of a planet. But it is easy to do it your self. Just
make a vector from an object that is affected by the gravity to the center of
the planet. Then normalise the vector and multiply it with the mass of the
object and a constant for the gravity. That's the way I use and it works
well. You could even calculate how far an object is from the planet and
adjust the gravity constant accordingly. I don't know if if the size of the
objects matters. In my program I have a planet with a radius of 5000 with a
little buggy on it to drive around. It works well.
> Also, how well does ODE do in potentially large environments? My
> server platform is fairly scalable, and if any users find that they're
> needing to model thousands of objects then they could spring for a
> cluster, but if I'm initially aiming for relatively simplistic
> objects, no joints/wheels, collision detection and force vector
> management, am I going to quickly run up against limits that make
> using ODE in a multi-user environment mpractical?
Hmm, I really don't know if there are any limits to the maximum number of
objects in ODE. I think it all depends on the amound RAM of your server.