Director 3D > Realtime Physics - Havok

The Havok Xtra

Real-time physics is basically the process of applying real world “rules” such as gravity to a 3D world. Balls bounce correctly, bricks come tumbling and crashing down realistically, etc. Of course, behind the scenes, the outcome of the interactions between all of the objects (or characters) have to be worked out in real-time, with millions of calculations being performed every second. This would be a Lingo nightmare if it wasn’t for…. The Havok Xtra!

Available with Macromedia Director 8.5 onwards, the Havok Xtra is the default physics engine for the Shockwave 3D platform. It is a fully integrated rigid body physics simulation engine providing complete access to physical properties in the simulated world. It enables you to assign properties such as mass and elasticity to physical objects, apply forces, impulses or torques and set velocities and momentum. Here are some examples of what it can do in a 3D environment. You can view it in action here:

The Havok Xtra comes with a library of behaviours to simplify the creation of physics scenes and a series of demos highlighting the many powerful features of the engine.

A Havok cast member contains all information required to turn a static 3D world into a dynamic physical simulated one. Each Havok cast member is linked to a Director 3D cast member. No sprites need to be created directly from a Havok cast member as the dynamic world is seen through a 3D sprite.

There are a number of stages in setting up and updating a Havok controlled 3D world:

  • Initialization including creation of rigid bodies
  • Applying external inputs to the simulation like forces, torques etc.
  • Stepping - perform simulation and advance the world to a new time.
  • Shutdown.

More information and a tutorial can be found here.

< Previous | Next >

July 2003