SuperTuxKart
Public Member Functions | List of all members
STKDynamicsWorld Class Reference

A thin wrapper around bullet's btDiscreteDynamicsWorld. More...

#include <stk_dynamics_world.hpp>

Inheritance diagram for STKDynamicsWorld:
Inheritance graph
[legend]

Public Member Functions

 STKDynamicsWorld (btDispatcher *dispatcher, btBroadphaseInterface *pairCache, btConstraintSolver *constraintSolver, btCollisionConfiguration *collisionConfiguration)
 The standard constructor which just created a btDiscreteDynamicsWorld. More...
 
void resetLocalTime ()
 Resets m_localTime to 0. More...
 
void setLocalTime (float t)
 Sets the local time to a specified value. More...
 
float getLocalTime () const
 Gets the local time. More...
 

Detailed Description

A thin wrapper around bullet's btDiscreteDynamicsWorld.

Used to be able to query and set the 'left over' time from a previous time step, which is needed for more precise rewind/replays.

Constructor & Destructor Documentation

◆ STKDynamicsWorld()

STKDynamicsWorld::STKDynamicsWorld ( btDispatcher *  dispatcher,
btBroadphaseInterface *  pairCache,
btConstraintSolver *  constraintSolver,
btCollisionConfiguration *  collisionConfiguration 
)
inline

The standard constructor which just created a btDiscreteDynamicsWorld.

Member Function Documentation

◆ getLocalTime()

float STKDynamicsWorld::getLocalTime ( ) const
inline

Gets the local time.

◆ resetLocalTime()

void STKDynamicsWorld::resetLocalTime ( )
inline

Resets m_localTime to 0.

This allows more precise replay of physics, which is important for replaying histories.

◆ setLocalTime()

void STKDynamicsWorld::setLocalTime ( float  t)
inline

Sets the local time to a specified value.

Used in rewinding.


The documentation for this class was generated from the following file: