A client can perform various types of physic computations in its game logic. M3D-Engine’s Physics Module offers an integrated way to perform these computations thru it’s Physics API.
This API exposes 2 data types and an interface:
Different objects and vehicles families demand different physics equations. These equations are provided by the engine in the form of physics solvers.
M3D-Engine is currently bundled with 3 solvers:
- Boat solver
- Plane solver
- Land vehicle solver
A game client can implement many other types of solvers using the IPhysicsSolver interface, and run them in the Physics Manager.
You can have different vehicles types of the same family. A fighter plane and an bomber does not have the same mass, maximum speed or thrust-to-weight ratio. These differences can be expressed using different PhysicsSolverParameters objects for the same PhysicsSolver.
A IPhysicsSolverParameters interface can be used to define new configuration attributes to the user-defined objects implementing IPhysicsSolver.
Each dynamic user-defined game entity must maintain a set of physics attributes and be notified of physics updates and completions. Two boats of the same type won’t necessarily have the same speed or the same heading at the same time. These entities must implement the IPhysicsResponder interface to store their own set of physic attributes and receive notifications from the Physics Manager.