|
| CCmpUnitMotionScripted (ScriptInterface &scriptInterface, JS::HandleValue instance) |
|
virtual void | Init (const CParamNode ¶mNode) |
|
virtual void | Deinit () |
|
virtual void | HandleMessage (const CMessage &msg, bool global) |
|
virtual void | Serialize (ISerializer &serialize) |
|
virtual void | Deserialize (const CParamNode ¶mNode, IDeserializer &deserialize) |
|
virtual JS::Value | GetJSInstance () const |
|
virtual int | GetComponentTypeId () const |
|
virtual bool | MoveToPointRange (entity_pos_t x, entity_pos_t z, entity_pos_t minRange, entity_pos_t maxRange) |
| Attempt to walk into range of a to a given point, or as close as possible. More...
|
|
virtual bool | IsInPointRange (entity_pos_t x, entity_pos_t z, entity_pos_t minRange, entity_pos_t maxRange) const |
| Determine wether the givven point is within the given range, using the same measurement as MoveToPointRange. More...
|
|
virtual bool | IsInTargetRange (entity_id_t target, entity_pos_t minRange, entity_pos_t maxRange) const |
| Determine whether the target is within the given range, using the same measurement as MoveToTargetRange. More...
|
|
virtual bool | MoveToTargetRange (entity_id_t target, entity_pos_t minRange, entity_pos_t maxRange) |
| Attempt to walk into range of a given target entity, or as close as possible. More...
|
|
virtual void | MoveToFormationOffset (entity_id_t target, entity_pos_t x, entity_pos_t z) |
| Join a formation, and move towards a given offset relative to the formation controller entity. More...
|
|
virtual void | FaceTowardsPoint (entity_pos_t x, entity_pos_t z) |
| Turn to look towards the given point. More...
|
|
virtual void | StopMoving () |
| Stop moving immediately. More...
|
|
virtual fixed | GetCurrentSpeed () const |
| Get the current movement speed. More...
|
|
virtual void | SetSpeed (fixed speed) |
| Set the current movement speed. More...
|
|
virtual bool | IsMoving () const |
| Get whether the unit is moving. More...
|
|
virtual fixed | GetWalkSpeed () const |
| Get the default speed that this unit will have when walking, in metres per second. More...
|
|
virtual fixed | GetRunSpeed () const |
| Get the default speed that this unit will have when running, in metres per second. More...
|
|
virtual void | SetFacePointAfterMove (bool facePointAfterMove) |
| Set whether the unit will turn to face the target point after finishing moving. More...
|
|
virtual pass_class_t | GetPassabilityClass () const |
| Get the unit's passability class. More...
|
|
virtual std::string | GetPassabilityClassName () const |
| Get the passability class name (as defined in pathfinder.xml) More...
|
|
virtual entity_pos_t | GetUnitClearance () const |
| Get the unit clearance (used by the Obstruction component) More...
|
|
virtual void | SetDebugOverlay (bool enabled) |
| Toggle the rendering of debug info. More...
|
|
virtual | ~IComponent () |
|
CEntityHandle | GetEntityHandle () const |
|
void | SetEntityHandle (CEntityHandle ent) |
|
entity_id_t | GetEntityId () const |
|
CEntityHandle | GetSystemEntity () const |
|
const CSimContext & | GetSimContext () const |
|
void | SetSimContext (const CSimContext &context) |
|
virtual bool | NewJSObject (ScriptInterface &scriptInterface, JS::MutableHandleObject out) const |
| Returns false by default, indicating that a scripted wrapper of this IComponent is not supported. More...
|
|
Attempt to walk into range of a to a given point, or as close as possible.
The range is measured from the center of the unit. If the unit is already in range, or cannot move anywhere at all, or if there is some other error, then returns false. Otherwise, returns true and sends a MotionChanged message after starting to move, and sends another MotionChanged after finishing moving. If maxRange is negative, then the maximum range is treated as infinity.
Implements ICmpUnitMotion.
Attempt to walk into range of a given target entity, or as close as possible.
The range is measured between approximately the edges of the unit and the target, so that maxRange=0 is not unreachably close to the target. If the unit is already in range, or cannot move anywhere at all, or if there is some other error, then returns false. Otherwise, returns true and sends a MotionChanged message after starting to move, and sends another MotionChanged after finishing moving. If maxRange is negative, then the maximum range is treated as infinity.
Implements ICmpUnitMotion.