16 #include <vl/hostStructs.h>
95 virtual const char*
type()
const;
106 virtual bool createPSR();
119 virtual void taskedTick(
DtTime & dT);
123 virtual bool intrinsicOverride();
129 double speed,DtWeaponState weapon,
DtString & demeanor);
136 virtual void setCurrentAnimation(
const DtDiGuyAnimation * animation,
bool overridePosture =
false);
140 virtual void sendSetPosture(DtLifeformState post);
143 static void setCharacteristicsCallback(
DtSimMessage * msg,
void * usr);
144 virtual void processSetCharacterCharacteristics(
DtSimMessage* msg);
147 static void setAppearanceCallback(
DtSimMessage * msg,
void * usr);
148 virtual void processSetCharacterAppearance(
DtSimMessage* msg);
151 static void setHandItemCallback(
DtSimMessage * msg,
void * usr);
152 virtual void processSetCharacterHandItem(
DtSimMessage* msg);
155 static void setHeadCallback(
DtSimMessage * msg,
void * usr);
156 virtual void processSetCharacterHead(
DtSimMessage* msg);
158 static void setRestoreCallback(
DtSimMessage * msg,
void * usrData);
162 static void setAdjustDemeanorCallback(
DtSimMessage * msg,
void * usrData);
163 virtual void processSetAdjustDemeanor(
DtSimMessage* msg);
165 static void animationTaskCallback(
DtSimMessage * msg,
void * usrData);
172 virtual void reset();
176 double speed,DtWeaponState weapon,
const DtString & demeanor);
187 bool isAnimationAvailable(
const std::string& animation)
const;
190 bool isAppearanceAvailable(
const std::string& appearance)
const;
193 bool isHandItemAvailable(
const std::string& item)
const;
197 bool isHeadAvailable(
const std::string& head)
const;
200 bool isGestureAvailable(
const std::string& gesture)
const;
221 virtual void registerRadioMessageCallbacks();
224 virtual void registerDiGuyTasks();
228 virtual void determineInitialHandItem();
230 virtual DtVector groundClamp(
double heading,
const DtVector& location)
const;
251 virtual bool createCollisionPort();
252 virtual bool createAimDirectionPort();
253 virtual bool createOrderedAnimationPort();
254 virtual bool createOrderedHandItemPort();
259 virtual void determineDirection();
261 virtual DtString chooseRandomAppearance();
264 virtual void updatePosition(
const DtTime & dT,DtTaitBryan & localOrientation);
268 virtual void initializeAdjustedDemeanorMap();
275 virtual double diGuyHeading()
const;
#define DT_DLL_vrfmodel
This file is used to determine how to build.
Definition: vrfmodelDefines.h:24
Stores data representing all the possible appearances, animations, hand items, heads, etc.
Definition: diGuyCharacterData.h:57
DtStringInputPort * myOrderedAnimationPort
Input Port Name: ordered-animation Input Port Description: Specifies an animation to be used as long ...
Definition: diGuyController.h:330
Definition: diGuyController.h:48
double myCurrentAnimationSpeed
Definition: diGuyController.h:292
Definition: diGuyControllerDescriptor.h:19
DtDiGuyControllerPSR * myProcessState
Container for state data associated with this component.
Definition: diGuyController.h:308
DtVrfObject is used to represent any type of simulated object (entities, aggregate, control objects) in a VR-Forces application.
Definition: vrfObject.h:215
bool myNeedUpdate
Definition: diGuyController.h:359
const DtDiGuyAnimation * myDefaultAnimation
Definition: diGuyController.h:283
DtUpdateRepositoryOutputPortGroup * myUpdateRepositoryOutputPortGroup
Used to update repository with any movement data.
Definition: diGuyController.h:356
const DtDiGuyAnimation * myCurrentAnimation
Definition: diGuyController.h:289
Description: This repository holds all information that is common to all the forms of all objects wit...
Definition: vrfMovingObjectStateRepository.h:26
DtRwNLengthStringVector is a named, readable/writable vector of strings of arbitrary length...
Definition: rwNLengthStringVector.h:28
Instances of DtBooleanOutputPort are output ports through which data producers can send boolean data...
Definition: boolIOPort.h:45
Definition: diGuyController.h:46
DtLifeformStaticPosture myDefaultAnimationPosture
Definition: diGuyController.h:284
virtual void preFirstTickInit()
This function can be overridden to initialize a component before it is ticked for the first time...
This class provides a base class for all controllers that are capable of executing a DtSimTask...
Definition: singleTaskControllerComponent.h:20
virtual void bindLuaFunctions(lua_State *)=0
Override to bind lua functions.
bool myAmRotating
Definition: diGuyController.h:300
A readable, writable type whose name is the name of a component and that has a list of component name...
Definition: componentDescriptor.h:42
const DtDiGuyControllerDescriptor * myDiGuyDescriptor
Definition: diGuyController.h:279
bool myTickWhileDead
Definition: diGuyController.h:358
Definition: readerWriterRegistry.h:39
virtual const char * type() const =0
Returns a string identifies the class type of component.
Definition: bindableLuaComponent.h:53
DtTime myTimeElapsed
Definition: diGuyController.h:299
DtTaitBryan myTaskedOrientation
Definition: diGuyController.h:287
double myTransitionTime
The remaining time for the current posture transition. Gets decremented in tick() ...
Definition: diGuyController.h:347
Definition: diGuyController.h:42
virtual void taskComplete(bool success=true)
If we are currently tasked, this will cause us to notify the entity that we're done and delete the ta...
virtual void clearTask()
If component is currently tasked, calls clearPendingSubtasks(), sets the tasked flag to false...
DtVrfMovingObjectStateRepository * myLocalState
Definition: diGuyController.h:282
virtual void reset()
For those reader/writer items that support it, resets the reader/writer value to original state Defau...
const DtDiGuyAnimation * myTaskedAnimation
Definition: diGuyController.h:286
DtAnalogInputPort * myAimDirectionPort
Input Port Name: aim-direction Input Port Description: Specifies the heading in which the entity shou...
Definition: diGuyController.h:324
Definition: diGuyController.h:45
DtStringInputPort * myOrderedHandItemPort
Input Port Name: ordered-hand-item Input Port Description: Specifies a hand item to be used...
Definition: diGuyController.h:335
Instances of DtAnalogOutputPort are input ports through which data producers can send real numbers...
Definition: analogIOPort.h:45
The DtDiGuyAnimation class is a class that stores the DI-Guy animation information that is used to en...
Definition: diGuyAnimation.h:29
const DtDiGuyCharacterData * myCharacterData
Definition: diGuyController.h:281
bool myTaskInterrupted
Definition: diGuyController.h:285
DtLifeformStaticPosture
DtLifeformStaticPosture enumeration.
Definition: lifeformStaticPostures.h:27
DtDiGuyDirectionType
Definition: diGuyController.h:40
File: simMsg.h.
Definition: simMessage.h:35
virtual void tick()
This gives the thread of control to the component.
virtual bool tickWhileDestroyed() const
If the component returns true here, it will be ticked regardless of the destroyed state of the host e...
double myAnimationDuration
These values are stored in the PSR Do we want this animation to be performed only once...
Definition: diGuyController.h:298
virtual bool createPorts()
Called by init.
Definition: diGuyController.h:44
virtual bool createPortGroups()
Called by init.
The DtSimComponent class is the base class for the entire simulation model component hierarchy...
Definition: simComponent.h:67
DtWeaponState myCurrentAnimationWeaponState
Definition: diGuyController.h:290
int myLastPosition
Definition: diGuyController.h:362
Definition: diGuyController.h:47
const DtTaskControllerComponent & operator=(const DtTaskControllerComponent &orig)
assignment operator
DtDemeanorToRankMap myDemeanorRankMap
Definition: diGuyController.h:364
DT_DLL_DEBUGDRAWRENDERER void init(makVrv::DtDe &de)
Work function for the plugin initialization.
Definition: diGuyControllerPSR.h:33
DtLifeformStaticPosture myCurrentAnimationPosture
Definition: diGuyController.h:291
The simulation engine is controlled by a single,top-level class called the Simulation Manager...
Definition: simManager.h:102
DtBooleanOutputPort * myIsChangingPosturePort
Output Port Name: is-changing-posture Output Port Description: Indicated that the DI Guy character is...
Definition: diGuyController.h:341
std::map< DtString, unsigned int > DtDemeanorToRankMap
Definition: diGuyController.h:51
virtual void bindLuaGlobals(lua_State *)=0
Override to bind lua globals.
double myCurrentHeading
The last heading for the entity. Will be used when setting animation for rotating on the spot...
Definition: diGuyController.h:350
DtUpdateRepositoryOutputPortGroup is a data port group of a data consumer that contains methods and p...
Definition: updateRepositoryOutputPortGroup.h:28
Controls appearances and animations for an entity that is represented by a DI-Guy 3D visual represent...
Definition: diGuyController.h:69
bool myAmTransitioningPosture
Local flag for we know we're changing posture.
Definition: diGuyController.h:344
bool myAmOrdered
Definition: diGuyController.h:360
double myDirectionOfMovement
This is an angle, in radians, relative to the current heading (a value of PI represents "backwards")...
Definition: diGuyController.h:304
Definition: diGuyController.h:43
DtBooleanInputPort * myCollisionPort
Input Port Name: collision Input Port Description: Checks to see if we're avoiding a collision...
Definition: diGuyController.h:316