|Description:||Set the destination for path-planning for an AI unit.|
This is a low-level command, which is overridden by group radio, as well as the unit FSM. It directly defines a wanted destination for an AI unit. In case of discrepancies between the destination defined in doMove and
doMove location is used (the
doMove destination overwrites the
|Syntax:||unit setDestination [position, planningMode, forceReplan]|
- unit: Object - Affected unit.
- position: Array - Format Position-2.
- planningMode: String - Can be:
- "DoNotPlan" - Used when not moving.
- "DoNotPlanFormation" - Used in formation, when simple path testing is used.
- "Leader Planned" - Used for formation leader (full path-finding used).
- "Leader Direct" - Used for DirectGo (such as getin, supply)
- "Formation Planned" - Used for formation subordinates.
- "Vehicle Planned" - Used for the vehicle driver.
- forceReplan: Boolean - Specifies, if re-planning of the path should be forced.
|See also:|| expectedDestination, doMove |