VR-Forces 4.1 Class Documentation
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes
Kaim::DtModifierGroundPlatformDetectAccident Class Reference
Inheritance diagram for Kaim::DtModifierGroundPlatformDetectAccident:
Inheritance graph
[legend]

Public Member Functions

 DtModifierGroundPlatformDetectAccident ()
virtual void ReInit ()
virtual KyBool DetectAccident ()
virtual void Update ()
KyFloat32 AccidentRatio () const
void AccidentRatio (KyFloat32 val)

Protected Member Functions

virtual void OnSetPathFinder ()

Protected Attributes

KyFloat32 m_accidentRatio
Vec3f m_predictedPosition
KyFloat32 m_predictionDate
KyFloat32 m_straightDistToSubgoal
KyFloat32 m_coverDistToSubgoal
Vec3f m_currentNodePosition
Vec3f m_previousPosition
KyFloat32 m_predictedDistance

Detailed Description

This implementation of the IDetectAccident interface detects accidents in the following case. All other accident detection have been removed. If the Bot appears to be moving away from its current target PathNode, DtModifierGroundPlatformDetectAccident will assume that it cannot proceed as expected. At the end of each frame, if the current PathNode maintained by the PathFinder has changed, the Update() method stores the distance to that PathNode. If the Bot travels a total distance that is more than four times greater than that initial distance, an accident is deemed to have occurred.

Constructor & Destructor Documentation

Kaim::DtModifierGroundPlatformDetectAccident::DtModifierGroundPlatformDetectAccident ( )
inline

Member Function Documentation

virtual void Kaim::DtModifierGroundPlatformDetectAccident::ReInit ( )
virtual
virtual KyBool Kaim::DtModifierGroundPlatformDetectAccident::DetectAccident ( )
virtual
virtual void Kaim::DtModifierGroundPlatformDetectAccident::Update ( )
virtual
KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::AccidentRatio ( ) const
inline

Retrieves the value set through a call to AccidentRatio(KyFloat32).

void Kaim::DtModifierGroundPlatformDetectAccident::AccidentRatio ( KyFloat32  val)
inline

Determines how responsive DtModifierGroundPlatformDetectAccident is to mismatches between the actual and expected positions of the Bot. See the class description above for details. any positive value 0.5f

virtual void Kaim::DtModifierGroundPlatformDetectAccident::OnSetPathFinder ( )
protectedvirtual

Member Data Documentation

KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::m_accidentRatio
protected
Vec3f Kaim::DtModifierGroundPlatformDetectAccident::m_predictedPosition
protected
KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::m_predictionDate
protected
KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::m_straightDistToSubgoal
protected
KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::m_coverDistToSubgoal
protected
Vec3f Kaim::DtModifierGroundPlatformDetectAccident::m_currentNodePosition
protected
Vec3f Kaim::DtModifierGroundPlatformDetectAccident::m_previousPosition
protected
KyFloat32 Kaim::DtModifierGroundPlatformDetectAccident::m_predictedDistance
protected

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

Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (www.mak.com)