45 #ifndef __VEL_COMP_CONST_H__
46 #define __VEL_COMP_CONST_H__
81 void setVelocity(
const Vector2 & velocity );
153 virtual std::string getUIText(
const std::string & indent=
"" )
const;
192 virtual const char *
name()
const {
return "const"; }
202 return "Provides a preferred velocity which is always a constant value (direction and magnitude).";
236 virtual bool setFromXML(
VelComponent * vc, TiXmlElement * node,
const std::string & behaveFldr )
const;
296 void setDirection(
const Vector2 & dir );
340 virtual std::string getUIText(
const std::string & indent=
"" )
const;
379 virtual const char *
name()
const {
return "const_dir"; }
389 return "Provides a preferred velocity which is always in a fixed direction but uses the agent's preferred speed.";
423 virtual bool setFromXML(
VelComponent * vc, TiXmlElement * node,
const std::string & behaveFldr )
const;
496 virtual std::string getUIText(
const std::string & indent=
"" )
const;
515 virtual const char *
name()
const {
return "zero"; }
525 return "Provides a preferred velocity which is always the zero velocity.";
548 #endif // __VEL_COMP_CONST_H__
size_t _xID
The identifier for the "x" float attribute.
Definition: VelCompConst.h:241
The context for the ConstVelDirComponent.
Definition: VelCompConst.h:321
virtual const char * description() const
A description of the velocity component.
Definition: VelCompConst.h:201
virtual const char * description() const
A description of the velocity component.
Definition: VelCompConst.h:388
The core namespace. All elements of Menge are contained in this namespace.
Definition: AgentGenerator.cpp:43
The context for the ZeroVelComponent.
Definition: VelCompConst.h:480
Vector2 _dir
The direction of the constant preferred velocity.
Definition: VelCompConst.h:120
Sets up the proper compiler directives for platform and dll export/import.
A class for parsing the xml description of a velocity component and instantiating particular instance...
Definition: VelComponentFactory.h:60
virtual const char * name() const
The name of the velocity component.
Definition: VelCompConst.h:192
The base, abstract class defining goals.
Definition: Goal.h:110
Factory for the ConstVelComponent.
Definition: VelCompConst.h:177
The base class for computing an agent's preferred velocity.
Definition: VelComponent.h:112
Vector2 _dir
The direction of the constant preferred velocity.
Definition: VelCompConst.h:312
Factory for the ConstVelDirComponent.
Definition: VelCompConst.h:364
VelComponent * instance() const
Create an instance of this class's velocity component.
Definition: VelCompConst.h:539
A velocity component that always returns a constant velocity.
Definition: VelCompConst.h:62
A velocity component that always returns a constant direction but leaves the preferred speed unchange...
Definition: VelCompConst.h:258
A velocity component that always returns the zero velocity.
Definition: VelCompConst.h:441
Vector2 getConstVelocity() const
Returns the constant velocity.
Definition: VelCompConst.h:104
The namespace contains the Behavior Finite State Machine (BFSM) definition.
size_t _yID
The identifier for the "y" float attribute.
Definition: VelCompConst.h:433
Factory for the ZeroVelComponent.
Definition: VelCompConst.h:505
The definition of how preferred velocity is computed in a state.
virtual const char * name() const
The name of the velocity component.
Definition: VelCompConst.h:515
virtual const char * description() const
A description of the velocity component.
Definition: VelCompConst.h:524
The definition of a preferred velocity.
Definition: PrefVelocity.h:68
Defines the basic agent properties and functionality that all simulation agents share.
Definition: BaseAgent.h:123
float _speed
The speed of the constant preferred velocity.
Definition: VelCompConst.h:125
VelComponent * instance() const
Create an instance of this class's velocity component.
Definition: VelCompConst.h:403
The factory for parsing xml data and instantiating velocity components.
VelComponent * instance() const
Create an instance of this class's velocity component.
Definition: VelCompConst.h:216
size_t _xID
The identifier for the "x" float attribute.
Definition: VelCompConst.h:428
ConstVelDirComponent * _vc
The underlying finite state machine velocity component.
Definition: VelCompConst.h:356
ConstVelComponent * _vc
The underlying finite state machine velocity component.
Definition: VelCompConst.h:169
virtual const char * name() const
The name of the velocity component.
Definition: VelCompConst.h:379
The context for the ConstVelComponent.
Definition: VelCompConst.h:134
The definition of a basic UI context for finite state machine velocity components.
Base context for finite state machine velocity components.
Definition: VelCompContext.h:70
size_t _yID
The identifier for the "y" float attribute.
Definition: VelCompConst.h:246