VR-Forces 4.3 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtCigiCharacterEntity Class Reference

A DtCigiCharacterEntity is a CIGI entity that loads a character model. More...

Inheritance diagram for makVrv::DtCigiCharacterEntity:
Inheritance graph
[legend]

Public Member Functions

 DtCigiCharacterEntity (DtCigiConnection &connection, DtAgentManagerInterface &sceneInterface, int entityId, int entityType)
 Constructor.
virtual ~DtCigiCharacterEntity ()
 Destructor.
virtual void setPosition (const DtGeodeticCoord &pos, bool force=false)
 Set the entity's geodetic position.
virtual void setOrientation (const DtTaitBryan &orientation, bool force=false)
 Set the entity's orientation.
virtual void setCharacterPaused (bool paused)
 Set paused state without specifying an action.
virtual void setCharacterActionSpeed (float speed)
 Change action speed of an existing action.
virtual void setCharacterAction (const std::string &action)
 Set a character action. Will used saved previous paused and speed flags.
virtual void setCharacterAction (const std::string &action, bool paused, double speed)
 When you have all three, set together.
virtual void setCharacterPosture (DtCharacterModel::Posture posture)
 Set a character's posture.
virtual void setWeaponDeployed (bool deployed)
 Set whether the character's weapon is deployed.
virtual bool weaponDeployed () const
 Get whether the character's weapon is deployed.
virtual void setAlive (bool alive)
 Set whether the character is alive.
virtual bool alive () const
 Get whether the character is alive.
virtual void setWaterlineOriginOffset (float offset)
 Set the amount that a bouyant entity's origin is offset from the waterline.
virtual void startEmbarked ()
 Override to prevent amphibious behavior when embarked.
virtual void endEmbarked ()
 Override to restore amphibious behavior when disembarked.
- Public Member Functions inherited from makVrv::DtCigiBaseEntity
 DtCigiBaseEntity (DtCigiConnection &connection, DtAgentManagerInterface &sceneInterface, int entityId, int entityType)
 Constructor takes a DtCigiConnection, scene interface, and the CIGI entity ID/type.
virtual ~DtCigiBaseEntity ()
 Destructor.
virtual DtUniqueID uniqueId () const
 Returns the unique ID of the entity's scene object.
virtual int cigiId () const
 Returns the ID of the CIGI entity.
virtual void setVisible (bool yesNo)
 Set whether the entity is visible.
virtual void setDeadReckoningOn (bool onOff)
 Turns dead-reckoning on/off.
virtual const DtGeodeticCoord & position () const
 Returns the last position set by a CIGI entity control message.
virtual const DtVectorlocalPosition () const
 Returns the last computed local position set.
virtual const DtTaitBryan & orientation () const
 Returns the last orientation set by a CIGI entity control message.
virtual void setLinearRate (const DtVector &rate, bool useWorldCoordinates=true)
 Sets the entity's linear rate.
virtual void setAngularRate (const DtVector &rate, bool useWorldCoordinates=true)
 Set's the entity's angular rate.
virtual void setRelativeTo (DtCigiBaseEntity *parent)
 Attachment control.
virtual void setRelativePosition (const DtVector &pos)
 Sets the entity's relative position (if attached).
virtual void setRelativeOrientation (const DtTaitBryan &orient)
 Sets the entity's relative orientation (relative to the parent's body coordinates) if attached.
virtual void setAlpha (int alpha)
 Sets the entity's alpha value.
virtual int alpha () const
 Returns the entity's alpha value.
virtual void setInheritAlpha (bool inherit)
 Set whether the entity should inherit alpha from its parent.
virtual void slot_alphaChanged (int alpha, DtUniqueID id)
 Slot so we can check if the parent's alpha has changed.
virtual void setGroundClampingOn (DtGroundClampingUpdater::GroundClampingMode clampType)
 Turns ground clamping on/off.

Protected Member Functions

virtual void startDeadReckoning ()
 Override to specify the correct motion model.
virtual void endDeadReckoning ()
 Remove the Dead Reckoning updater.
virtual void startGroundClamping ()
 Override to work with surface clamping updater, because character's are amphibious.
virtual void endGroundClamping ()
 Remove the ground clamping updater.
- Protected Member Functions inherited from makVrv::DtCigiBaseEntity
virtual void buildGroundClampingUpdater ()

Protected Attributes

DtCharacterModelAgent * myCharacterModel
bool myCharacterPaused
float myCharacterActionSpeed
bool myWeaponDeployed
bool myAlive
std::string myCharacterAction
DtCharacterModel::Posture myPosture
DtSurfaceClampingUpdaterAgent * mySurfaceClampingUpdaterAgent
DtWaterClampingUpdaterAgent * myWaterClampingUpdaterAgent
- Protected Attributes inherited from makVrv::DtCigiBaseEntity
DtSceneObjectAgent * mySceneObject
DtModelAgent * myModel
DtDeadReckonUpdaterAgent * myDeadReckonUpdaterAgent
DtGroundClampingUpdaterAgent * myGroundClampingUpdaterAgent
DtEmbarkationUpdaterAgent * myEmbarkationUpdaterAgent
bool myDeadReckoningOn
bool myEmbarked
DtGroundClampingUpdater::GroundClampingMode myGroundClampingType
DtGeodeticCoord myLastPosition
DtVector myLastLocalPosition
DtTaitBryan myLastOrientation
DtTaitBryan myLastGeocentricOrientation
DtCigiConnectionmyConnection
DtAgentManagerInterfacemySceneInterface
int myEntityId
int myEntityType
DtCigiBaseEntitymyParent
DtUniqueID myEmbarkedParentID
bool myInheritAlpha
int myAlpha
bool myVisiblity

Additional Inherited Members

- Public Attributes inherited from makVrv::DtCigiBaseEntity
boost::signal< void(int,
DtUniqueID)> 
signal_alphaChanged
 Emitted when this entity's alpha has changed.

Detailed Description

A DtCigiCharacterEntity is a CIGI entity that loads a character model.

Constructor & Destructor Documentation

makVrv::DtCigiCharacterEntity::DtCigiCharacterEntity ( DtCigiConnection connection,
DtAgentManagerInterface sceneInterface,
int  entityId,
int  entityType 
)

Constructor.

virtual makVrv::DtCigiCharacterEntity::~DtCigiCharacterEntity ( )
virtual

Destructor.

Member Function Documentation

virtual void makVrv::DtCigiCharacterEntity::setPosition ( const DtGeodeticCoord &  pos,
bool  force = false 
)
virtual

Set the entity's geodetic position.

Parameters
[in]posis the position set from the CIGI entity control message.
[in]forceis a flag to force handling even if position has not changed.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::setOrientation ( const DtTaitBryan &  orientation,
bool  force = false 
)
virtual

Set the entity's orientation.

Parameters
[in]orientationis the orientation set from the CIGI entity control message.
[in]forceis a flag to force handling even if orientation has not changed.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::setCharacterPaused ( bool  paused)
virtual

Set paused state without specifying an action.

virtual void makVrv::DtCigiCharacterEntity::setCharacterActionSpeed ( float  speed)
virtual

Change action speed of an existing action.

virtual void makVrv::DtCigiCharacterEntity::setCharacterAction ( const std::string &  action)
virtual

Set a character action. Will used saved previous paused and speed flags.

virtual void makVrv::DtCigiCharacterEntity::setCharacterAction ( const std::string &  action,
bool  paused,
double  speed 
)
virtual

When you have all three, set together.

virtual void makVrv::DtCigiCharacterEntity::setCharacterPosture ( DtCharacterModel::Posture  posture)
virtual

Set a character's posture.

virtual void makVrv::DtCigiCharacterEntity::setWeaponDeployed ( bool  deployed)
virtual

Set whether the character's weapon is deployed.

Note that not all postures or animations will support a deployed weapon

virtual bool makVrv::DtCigiCharacterEntity::weaponDeployed ( ) const
virtual

Get whether the character's weapon is deployed.

virtual void makVrv::DtCigiCharacterEntity::setAlive ( bool  alive)
virtual

Set whether the character is alive.

The transition from alive to not alive will result in an animation; and from not alive to alive the entity will be restored to its last state

virtual bool makVrv::DtCigiCharacterEntity::alive ( ) const
virtual

Get whether the character is alive.

virtual void makVrv::DtCigiCharacterEntity::setWaterlineOriginOffset ( float  offset)
virtual

Set the amount that a bouyant entity's origin is offset from the waterline.

virtual void makVrv::DtCigiCharacterEntity::startEmbarked ( )
virtual

Override to prevent amphibious behavior when embarked.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::endEmbarked ( )
virtual

Override to restore amphibious behavior when disembarked.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::startDeadReckoning ( )
protectedvirtual

Override to specify the correct motion model.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::endDeadReckoning ( )
protectedvirtual

Remove the Dead Reckoning updater.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::startGroundClamping ( )
protectedvirtual

Override to work with surface clamping updater, because character's are amphibious.

Reimplemented from makVrv::DtCigiBaseEntity.

virtual void makVrv::DtCigiCharacterEntity::endGroundClamping ( )
protectedvirtual

Remove the ground clamping updater.

Reimplemented from makVrv::DtCigiBaseEntity.

Member Data Documentation

DtCharacterModelAgent* makVrv::DtCigiCharacterEntity::myCharacterModel
protected
bool makVrv::DtCigiCharacterEntity::myCharacterPaused
protected
float makVrv::DtCigiCharacterEntity::myCharacterActionSpeed
protected
bool makVrv::DtCigiCharacterEntity::myWeaponDeployed
protected
bool makVrv::DtCigiCharacterEntity::myAlive
protected
std::string makVrv::DtCigiCharacterEntity::myCharacterAction
protected
DtCharacterModel::Posture makVrv::DtCigiCharacterEntity::myPosture
protected
DtSurfaceClampingUpdaterAgent* makVrv::DtCigiCharacterEntity::mySurfaceClampingUpdaterAgent
protected
DtWaterClampingUpdaterAgent* makVrv::DtCigiCharacterEntity::myWaterClampingUpdaterAgent
protected

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

Document ID: Generated on Wed Mar 11 21:20:57 EDT 2015 from SVN revision 150940
Copyright © 2005-2014 VT MÄK. All Rights Reserved (www.mak.com)