Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

oxygen::VelocityController Class Reference

BodyController that restricts the maximum velocity a body can attain. More...

#include <velocitycontroller.h>

Inheritance diagram for oxygen::VelocityController:

Inheritance graph
[legend]
Collaboration diagram for oxygen::VelocityController:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 VelocityController ()
virtual ~VelocityController ()
float GetMaxVelocity ()
void SetMaxVelocity (float vel)

Protected Member Functions

virtual void PrePhysicsUpdateInternal (float deltaTime)
 enforces the maximum allowed velocity

Protected Attributes

float mMaxVel
 maximum velocity, the controlled body can attain

Detailed Description

BodyController that restricts the maximum velocity a body can attain.

Definition at line 31 of file velocitycontroller.h.


Constructor & Destructor Documentation

VelocityController::VelocityController  ) 
 

Definition at line 26 of file velocitycontroller.cpp.

VelocityController::~VelocityController  )  [virtual]
 

Definition at line 31 of file velocitycontroller.cpp.


Member Function Documentation

float VelocityController::GetMaxVelocity  ) 
 

Definition at line 35 of file velocitycontroller.cpp.

References mMaxVel.

void VelocityController::PrePhysicsUpdateInternal float  deltaTime  )  [protected, virtual]
 

enforces the maximum allowed velocity

Reimplemented from oxygen::BaseNode.

Definition at line 45 of file velocitycontroller.cpp.

References oxygen::BodyController::mBody, mMaxVel, salt::TVector< DATATYPE, ELEMENTS, TYPE >::Normalize(), and salt::TVector< DATATYPE, ELEMENTS, TYPE >::SquareLength().

Here is the call graph for this function:

void VelocityController::SetMaxVelocity float  vel  ) 
 

Definition at line 40 of file velocitycontroller.cpp.

References mMaxVel.


Member Data Documentation

float oxygen::VelocityController::mMaxVel [protected]
 

maximum velocity, the controlled body can attain

Definition at line 55 of file velocitycontroller.h.

Referenced by GetMaxVelocity(), PrePhysicsUpdateInternal(), and SetMaxVelocity().


The documentation for this class was generated from the following files:
Generated on Thu Apr 6 15:46:48 2006 for rcssserver3d by  doxygen 1.4.4