SetUnitFormation¶
SetUnitFormation(units, formationId) · SetUnitFormationTracked(units, formationId)
Inputs: units is one actor or a dense array; use a non-negative signed
32-bit formationId. The tracked form rejects values outside that range; the
ordinary form converts an integer to the native field.
Description: Requests that formation. A representable ID does not guarantee game support.
Output: SetUnitFormation returns true for queue admission, otherwise
false. SetUnitFormationTracked returns accepted, receipt.
Errors: Wrong Lua argument types raise an argument error. The tracked form rejects an ID outside the non-negative signed 32-bit range; actor, layout, and session failures also reject. A valid ID may still be unsupported by the game. A tracked receipt gives the rejection reason when available.