[ODE] moving platforms in a game

Jon Watte (ODE) hplus-ode at mindcontrol.org
Tue Sep 18 13:41:28 MST 2007


First, make sure the platform has a body, and that you move it by 
applying forces (and possibly torques to stabilize it). This will allow 
the solver to calculate the velocity of the contact point, and match 
that velocity on your player.
Second, make sure you examine all the possible parameters you can set on 
a contact joint, and set them appropriately to make sure the contact 
behaves the way you want to keep the object embedded with the moving 
platform.

Cheers,

          / h+

gary herman wrote:
> I'm trying to implement a moving platform, which my character
> can jump on and move along with the platform.
>
> The platform currently is only a geometry, which is being moved
> using dGeomSetPosition.  Currently the character correctly collides
> with the moving platform but doesn't move with it.
>
> Should I make the moving platform a body attached to the static
> world geometry with a slider joint?  I'm afraid doing this will cause
> the platform to fall when the character's weight lands on it.
>
> Or should I use a dContactMotion1 contact joint, and calculate the
> velocity of the moving platform, and use that as the motion1 variable?
> I've been struggling to get this to work correctly.
>
> If anyone has already solved this problem,  please let me know...
>
> Thanks
>  - gary
>
>  
> gary herman
>  
> technical director
> gaia industries
> gary at gaiaindustries.com
> 212 673 3613
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> ODE mailing list
> ODE at ode.org
> http://ode.org/mailman/listinfo/ode


More information about the ODE mailing list