Panda3D Manual: Physics Engine
  <<prev top next>>  

Panda3D has a very basic physics engine that may apply forces to classes. The physics engine can handle angular or linear forces, as well as viscosity.

A physics object must be created in order to apply physics to it. Additionally, since the Actor class is a subclass of Physical, actors have inherited these properties and functions.

<Physical Object> = Physical.Physical()

From here, a physics object may be added to the physical object.

<Physical Object>.addPhysicsObject(<Physics Object>)

Linear and angular forces may be added to the physical object, which will affect the physics object within it.

<Physical Object>.setLinearForce(<Force>)
<Physical Object>.setAngularForce(<Force>)

Viscosity is added through a floating-point number.

<Physical Object>.addViscosity(<Viscosity>)
  <<prev top next>>