[ODE] ODE - Constant speed in different qualities boxes
Megan Fox
shalinor at circustent.us
Wed Mar 17 08:49:12 MST 2004
If I was doing it properly, I would be running my entire game loop at a
fixed rate (so I would update EVERYTHING in the loop, once per loop, then
render at the end), but I'm not :)
I do run the collision system once per loop, but I don't communicate the
position of the geoms to the "real" entities in my systems until the looping
has stopped. I think I might adjust this in the "real" engine such that I
run the entire system at a fixed rate - it would make it easier to retrofit
the engine to allow replays.
-Megan Fox
> I have a quastion about this method:
> Do you repeat collision detection for multiple updates ?
>
> ie:
>
> --- BEGIN CODE ---
> collideWorld();
> while (timeAccumulator > ODE_STEP_SIZE)
> {
> StepFast(ODE_STEP_SIZE);
> timeAccumulator -= ODE_STEP_SIZE;
> }
> updateWorldPositions();
> renderWorld();
> --- END CODE ---
>
> versus
>
> --- BEGIN CODE ---
> while (timeAccumulator > ODE_STEP_SIZE)
> {
> collideWorld();
> StepFast(ODE_STEP_SIZE);
> updateWorldPositions();
>
> timeAccumulator -= ODE_STEP_SIZE;
> }
> renderWorld();
> --- END CODE ---
>
> mucki
>
> _______________________________________________
> ODE mailing list
> ODE at q12.org
> http://q12.org/mailman/listinfo/ode
>
>
More information about the ODE
mailing list