The Attack Manager component is the component that manages the attack behavior for attack entities.
When you’re creating a new map using the RTS Engine menu editor, this component is attached to an object called “AttackManager”.
- Range Types: This array allows you to define different attack range types for units only. Range types basically define the stopping distances when a unit moves towards a target unit/building to attack it, among other things:
- Code: Each range type must have a unique code. A unit with an attack component is assigned to a range type by entering this code in the general settings of its attack component.
- Unit/Building Stopping Distance: When moving towards a target unit/building, this field is the stopping distance for that movement.
- Move On Attack Offset: When a unit is allowed to move and attack at the same time, the value inputted in this field will be added to the attack range of the unit.
- Update Mvt Distance: If the distance between the attack target and the attack target’s initial position when the target was locked gets higher than this value then the unit will adjust its position and move towards the target’s new position.