Havok for CD only?

Havok for CD only?


I'm developing an arcade space game, and I'm handling entity movement myself.

I'd like to use Havok for collision detection and raycasting only, and leave the dynamics simulation out.

Is this possible?


publicaciones de 2 / 0 nuevos
Último envío
Para obtener más información sobre las optimizaciones del compilador, consulte el aviso sobre la optimización.

Hi, it's possible. The simplest way would be to set the positions of your rigid bodies directly and never step the physics simulation. A better approach is to set the velocities so that the bodies will move where you want them to be in the next frame, and step the physics simulation to update them. So for example, if you have a ship at x=10 that you want to move to x=12 in the next frame, and the timestep is t, then set the x-velocity to (12 - 10) / t. This is more efficient because it allows Havok to batch update all of the broad phase info during the physics step, instead of doing it separately every time you set an body's position.

You can disable collisions in the physics step by using motion type = MOTION_KEYFRAMED for all bodies, and you'll still be able to raycasts and other collision detection queries. There are many demos that show what sort of queries are available, I recommend taking a look at:



Deje un comentario

Por favor inicie sesión para agregar un comentario. ¿No es socio? Únase ya