Polarith AI
1.8

◆ ComputePosition()

override Vector3 ComputePosition ( )
virtual

Overwritten method to build up a FormationBox, i.e., placing agents as a box, by computing the AIMFormation.TargetPosition of each agent.

AgentsPerLine are placed equidistantly on lines with Formation.Spacing as distance between them. The last(bottom) layer may be sparse, since there are probably not enough agents. This method computes only the position of a single agent with respect to the whole formation.

Implements Formation.

Imprint