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

Stores data representing all the possible appearances, animations, hand items, heads, etc. More...

Inheritance diagram for DtVrvDiGuyCharacterData:
Inheritance graph
[legend]

Public Member Functions

 DtVrvDiGuyCharacterData ()
 
 DtVrvDiGuyCharacterData (const DtString &name)
 
 DtVrvDiGuyCharacterData (const DtVrvDiGuyCharacterData &orig)
 
virtual ~DtVrvDiGuyCharacterData ()
 
DtVrvDiGuyCharacterDataoperator= (const DtVrvDiGuyCharacterData &orig)
 
virtual DtDiGuyCharacterDataclone () const
 Returns a newly created clone of this class. More...
 
void setDiGuyScenario (makVrv::DtDiGuyScenario *scenario)
 
virtual void readInAnimationDataFromDiGuyScenario ()
 This is rather slow, because it causes creation of many things inside DI-Guy, so calls should be deferred until it's time to actually display an animation. More...
 
- Public Member Functions inherited from DtDiGuyCharacterData
 DtDiGuyCharacterData ()
 
 DtDiGuyCharacterData (const DtString &name)
 
 DtDiGuyCharacterData (const DtDiGuyCharacterData &orig)
 
virtual ~DtDiGuyCharacterData ()
 
DtDiGuyCharacterDataoperator= (const DtDiGuyCharacterData &orig)
 
virtual void init ()
 
virtual void setDeadAnimation (DtDiGuyAnimationSharedPtr deadAnimation)
 
virtual DtDiGuyAnimationdeadAnimation ()
 
virtual const DtDiGuyAnimationlookupTaskAnimationByName (const DtString &name) const
 Look up a particular animation. More...
 
virtual const std::vector
< DtString > & 
appearances () const
 The list of possible appearances for this character. More...
 
virtual void addAppearance (const DtString &app)
 Add a new possible appearance for the character. More...
 
virtual bool containsAppearance (const DtString &app) const
 
virtual void addGesture (const DtString &app)
 Add a new possible gesture for the character. More...
 
virtual bool containsGesture (const DtString &app) const
 
virtual const std::vector
< DtString > & 
gestures () const
 
virtual const std::vector
< DtString > & 
handItems () const
 The list of possible hand items for this character. More...
 
virtual void addHandItem (const DtString &app)
 Add a new possible hand item for the character. More...
 
virtual const std::vector
< DtString > & 
heads (const DtString &bodyAppearance) const
 The list of possible heads for this character and body appearance. More...
 
virtual void addHead (const DtString &bodyAppearance, const DtString &headAppearance)
 Add a new possible head for the character. More...
 
virtual void addTypeMapField (const DtString &appearanceName, const DtString &fieldValue)
 Adds the value to the next type map field that hasn't yet been set. More...
 
virtual const DtStringgetTypeMapFieldName (int index) const
 Gets the name of a type map field (i.e. name of category) More...
 
virtual int getTypeMapFieldIndex (const DtString &name) const
 Get the index of a type map field name. More...
 
virtual const AlternateNamesListanimationNames () const
 Returns string list of all the animations and their user friendly display name. More...
 
void addAnimation (DtDiGuyAnimationSharedPtr animation)
 readInAnimationDataFromDiGuyScenario() will later classify all added animations into taskable or instrinsic. More...
 
virtual const DtDiGuyAnimationlookupIntrinsicAnimationByName (const DtString &name) const
 
void setAnimationTable (DtDiGuyCharacterAnimationsTable *table)
 
DtDiGuyAnimationSharedPtr readInAnimationDataFromTable (const char *actionName, bool isFirstAction)
 Reads in animations from DtDiGuyCharacterAnimationsTable, which was created by reading in character_animations_table.mtl. More...
 
void setPrintInfo (bool set_print)
 If set_print is true, calls to debugPrint() will print info to stdout. More...
 
void debugPrint (const char *fmt,...)
 
virtual const DtDiGuyAnimationlookupTaskAnimationByVariant (const DtString &variant) const
 
virtual const DtDiGuyAnimationlookupIntrinsicAnimationByVariant (const DtString &variant) const
 
virtual void setCharacterTypeName (const DtString &name)
 The name of the character type. More...
 
virtual const DtStringcharacterTypeName () const
 
virtual const TaskAnimationMaptaskableAnimations () const
 The taskable animationsReturns the map of all taskable animations. More...
 
virtual AlternateNamesList taskableAnimationNames () const
 Returns string list of all the taskable animations and their user friendly display name. More...
 
virtual void addTaskAnimation (const DtString &name, DtDiGuyAnimationSharedPtr animation)
 
virtual const
DtDiGuyIntrinsicAnimationMap
intrinsicAnimations () const
 The intrinsic animations. More...
 
virtual void addIntrinsicAnimation (const DtString &name, DtDiGuyAnimationSharedPtr animation)
 

Protected Attributes

makVrv::DtDiGuyScenariomyDiGuyScenario
 This object must be queried for detailed info about animations. More...
 
- Protected Attributes inherited from DtDiGuyCharacterData
DtString myCharacterTypeName
 
std::vector< DtStringmyCharacterAppearances
 
std::map< DtString, DtStringmyCharacterAppearancesMap
 
std::vector< DtStringmyCharacterHandItems
 
std::vector< DtStringmyCharacterGestures
 
std::map< DtString, DtStringmyCharacterGesturesMap
 
HeadAppearanceMap myCharacterHeads
 
AppearanceToTypeFieldsMap myTypeMaps
 
UnprocessedAnimationList myUnprocessedAnimations
 Will hold animation references until they can be classified as taskable or intrinsic. More...
 
TaskAnimationMap myTaskAnimationsMap
 Holds refs to taskable animations. More...
 
DtDiGuyIntrinsicAnimationMapmyIntrinsicAnimationsMap
 Holds refs to intrinsic animations. More...
 
DtFilename myIntrinsicAnimationsFilename
 
AlternateNamesList myAnimationNames
 List of names of all animations available. More...
 
DtDiGuyAnimationSharedPtr myDeadAnimation
 Keep death animation separate 1) don't need to loop thru the lists to match– dead is dead 2) prevents matching death as closest animation to people in prone posture even though they are alive. More...
 
DtDiGuyCharacterAnimationsTablemyAnimationTable
 This will be generated from the data in character_animations_table.mtl Its main importance is holding user-readable names and info about whether an animation is taskable or instrinsic. More...
 
bool myDataReadFromDiGuyScenario
 flag to indicate that animation data has been gathered from DIGuy More...
 
bool myPrintInfo
 

Additional Inherited Members

- Public Types inherited from DtDiGuyCharacterData
typedef std::map< DtString,
DtDiGuyAnimationSharedPtr
TaskAnimationMap
 
typedef TaskAnimationMap::iterator TaskAnimationMapIterator
 
typedef
TaskAnimationMap::const_iterator 
const_TaskAnimationMapIterator
 
typedef std::list
< DtDiGuyAnimationSharedPtr
UnprocessedAnimationList
 
typedef
UnprocessedAnimationList::iterator 
UnprocessedAnimationListIterator
 
typedef
UnprocessedAnimationList::const_iterator 
const_UnprocessedAnimationListIterator
 
- Static Public Member Functions inherited from DtDiGuyCharacterData
static void setCreatorFcn (const DtDiGuyIntrinsicAnimationMapCreatorFcn &fcn)
 By default, this class creates a DtDiGuyIntrinsicAnimationMap data member, used in determining the appropriate animation for a given posture, speed, and demeanor. More...
 
- Protected Member Functions inherited from DtDiGuyCharacterData
void setUpTypeFieldToIntMap ()
 
- Static Protected Attributes inherited from DtDiGuyCharacterData
static std::map< DtString, intmyTypeFieldNameToIntMap
 
static std::vector< DtStringmyTypeFieldNameVect
 
static
DtDiGuyIntrinsicAnimationMapCreatorFcn 
theDiGuyIntrinsicAnimationMapCreatorFcn
 

Detailed Description

Stores data representing all the possible appearances, animations, hand items, heads, etc.

that are available to a particular character type. It is used by the sim engine at runtime. Populated from both DI-Guy instance and character_animations_table.mtl file.

Constructor & Destructor Documentation

DtVrvDiGuyCharacterData::DtVrvDiGuyCharacterData ( )
DtVrvDiGuyCharacterData::DtVrvDiGuyCharacterData ( const DtString name)
DtVrvDiGuyCharacterData::DtVrvDiGuyCharacterData ( const DtVrvDiGuyCharacterData orig)
virtual DtVrvDiGuyCharacterData::~DtVrvDiGuyCharacterData ( )
virtual

Member Function Documentation

DtVrvDiGuyCharacterData& DtVrvDiGuyCharacterData::operator= ( const DtVrvDiGuyCharacterData orig)
virtual DtDiGuyCharacterData* DtVrvDiGuyCharacterData::clone ( ) const
virtual

Returns a newly created clone of this class.

Reimplemented from DtDiGuyCharacterData.

void DtVrvDiGuyCharacterData::setDiGuyScenario ( makVrv::DtDiGuyScenario scenario)
virtual void DtVrvDiGuyCharacterData::readInAnimationDataFromDiGuyScenario ( )
virtual

This is rather slow, because it causes creation of many things inside DI-Guy, so calls should be deferred until it's time to actually display an animation.

Reimplemented from DtDiGuyCharacterData.

Member Data Documentation

makVrv::DtDiGuyScenario* DtVrvDiGuyCharacterData::myDiGuyScenario
protected

This object must be queried for detailed info about animations.


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

Document ID: Generated on Tue Sep 21 17:42:52 EDT 2021 from SVN revision 234861
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)