Battlezone Realm  »  Tips and FAQs  » AI Processes 
Home Tips and FAQs Features Files
Submit Article Profiles

BZ2 MOD Development BZU Forums TimeDisruptor BZ2Maps Forums

BZ2Maps fish DOT xsi Sub-00's Realm

AI Processes
Author :: Zero Angel View Author Info


Todo:
- Add AI Process "personfriend/enemy"
- Add AI Process recommendations - More notes re: Attack/SubAttack tasks

Introduction

This is all of the data that I've collected on different AI processes, so far. I've listed only the processes of combat vehicles, I'll add Assault vehicles when I have time.

This list will be updated if new information becomes available.

Combat Vehicle AIs


Most combat vehicle AIs are evasive, but do not know how to correctly operate turreted vehicles such as assault tanks

ScoutFriend/EnemyAI Type: Normal
Aggressiveness: Low
  • Automatically marks a single enemy target in its radar range
  • Uses idiotic spin maneuver when being attacked
  • Will use special if enemy is close and attacking it.
Used By: ISDF/Scion Scouts
TankFriend/Enemy AI Type: Normal
Aggressiveness: Moderate
  • No special properties
Used by: ISDF/Scion Tanks
SentryProcess AI Type: Normal
Aggressiveness: Low
  • Uses idiotic spin maneuver when being attacked.
  • Will use special if enemy is close and attacking it.
Used by: Scion Sentry
AttachWingman AI Type: Standard
Aggressiveness: Moderate
+ Customize
  • Defaults to Normal AI
  • Supports task entries under [craftClass]
    • Using ArcherAttack and ArcherSubAttack entries will prevent the AI from turning around in battle. See the Lancer ODF (fvarch) if you're not sure of the exact usage.
    • The mortar bike uses MortarBikeAttack and MortarBikeSubAttack entries, though these aren't very good for fighting units (?). More research is needed here.
Used by: ISDF Mortar Bike, Scion Lancer
SAVFriend/EnemyAI Type: SAV (unique)
Aggressiveness: Very High
Morph to Attack
  • Unpredictable AI
  • Sub-attacking pilots has priority over sub-attacking anything else.
  • Emits damage field that kills pilots
  • Will try to position itself over pilots, effectively killing them (ignores height)
  • Requires 'NeedPilot = 1' entry in ODF to be pilotable.
Used by: Scion SAV
TurretTankFriend/EnemyAI Type: Turret (unique)
Aggressiveness: Very Low
Morph to Attack
  • No evasive, but good accuracy (excellent accuracy at Lv.3).
  • Does not move to engage, but will attack targets in its weapons range.
  • Will work with aircraft to a limited extent.
    • If given an attack command, this AI will undeploy to attack targets within its weapons range
    • OR will automatically undeploy to attack targets that are attacking it.
    • Is fully controllable after undeploying.
    • Wanders aimlessly if not given orders
    • Does not understand the concept of 'height'
Used by: ISDF/Scion Turrets
MorphTankFriend/EnemyAI Type: MT/RT
Aggressiveness: Moderate-High
Weaponmask
Morph to Attack
  • Accurate fighter, predictable evasive.
  • Will attempt to morph to assault when attacking any targets, then morph back to combat when clear.
  • Prioritizes constructors and scavengers over other units.
  • Works with Aircraft to a limited extent.
    • If given an attack command, this AI will only undeploy to attack targets within its engage (?) range
    • OR will automatically undeploy to attack targets in its weapons range
    • Likes to stick its nose into the ground when 'attacking' ground targets.
    • Will redeploy when area is clear
  • Recommended for use with 1.2 pilots
  • This AI is supposedly legacy AI left over from early development, replaced by the other AIs because of their HP auto-linking abilities.
Used by: (None)

Compatibility Notes: Useful in 1.2 because of it has better accuracy then other AI types. 1.3 tweaks bring accuracy of all units up to par with this one

Not Recommended for 1.3 pilots when friendly fire on other pilots is an issue.

Known Bugs: SubAttack Bug :: [All Versions]
RocketTankFriend/EnemyAI Type: MT/RT
Aggressiveness: High
Weaponmask
  • Evasive, but lacks accuracy
  • Can use locking weapons properly.
  • Is *not* used by the ISDF (turreted) Rocket Tank, despite its name.
Used by: ISDF Missile Scout

Compatibility Notes:Not Recommended for 1.3 pilots when friendly fire on other pilots is an issue.

Known Bugs: SubAttack Bug :: [All Versions]
Leading Bug :: [All Versions]
SoldierProcessAI Type: MT/RT
Aggressiveness: Moderate
Weaponmask
  • Avoids friendly fire.
  • Moves around terrain if obstructed.
  • Does not sub-attack if it already has a task (ie: go-to)
  • Will only evade if opponent is already evading. Lacks initiative.
Compatibility Notes: This AI type will try to recycle itself in 1.2 if it has no targets once it reaches its destination, but will behave normally in 1.3 if given the proper ODF entries that allow it to be commandable.

Recommended for 1.3 soldiers if friendly fire is a problem.

Used by: APC Soldiers




Assault Vehicle AIs

The following AIs are not evasive, but can operate turreted vehicles. This makes them best for units like Assault Tanks and Walkers.

GechProcessAI Type: Assault Tank
Aggressiveness: High
  • Standalone AI, does not support Task entries
  • Moves forward during subAttack
  • Aggressive AI, attacks pilots if no other targets available to subattack
Used by: ISDF Walker, Scion Mauler

Compatibility Notes Mixture of bugs requires careful testing when porting to/from versions.

Known bugs: Mixed weapon types bug :: [Version 1.2]
Mortar usage bug :: [Version 1.3]
AssaultTankProcessAI Type: Assault Tank
Aggressiveness: Moderate
  • Uses first linked weapons only, for combat and assault targets
  • Defensive AI, does not move to sub-attack
Used by: ISDF Assault Tank, Scion Titan

Compatibility Notes: 1.3 AIs will auto-select combat/assault hardpoints based on target type.

Known bugs: Mortar usage bug :: [Version 1.3]
SupportProcessAI Type: Assault Tank
Aggressiveness: Moderate
+ Customize
  • Supports Task entries under [craftClass]
  • Selects combat/assault hardpoints based on target type.
  • AI units that use the following task entries act as assault tanks, but with anti air capabilities.
    attackTask = "assaultTankAttack"
    subAttackTask = "supportSubAttack" // Dont move forward in a subAttack
    subAttackClass = "ANS" // AA + Normal (no deploy) + Limit to Weapon Range
See below for a better description of task entries.

Used by: ISDF Rocket Tank
AttachOffensive AI Type: (no data)
Aggressiveness: (no data)
+ Customize
  • Supports Task entries under [craftClass]
  • Undeploys to move
  • Scion Artillery uses the following task entries. Special properties are commented.
    attackTask= "artlAttack"
    subAttackTask = "artlSubAttack" // subAttack air units only; w/priority
    subAttackClass = "AD" // AA + Deploy to subAttack
Notes: I'm not very familiar with this AI type, so this is incomplete.

Used by: Scion Artillery


Additional Reference:

Behavior of Standard AIs
Scout, Tank, AttachWingman, and SentryProcess fight the same for the most part.

When given a follow command, they will follow, and engage other enemies (including non combatants such as extractors) along their route, they'll rejoin if they're too far away from their follow target. When fighting, they dont lead (target) properly very often, some trickery is needed in the handling parameters, to make these AI accurate. These AI have a routine where they'll turn around and try to get some distance when being fired upon, this routine is completely detrimental to their fighting skill. AttachWingman AI, coupled with Archer task entries will prevent this.

Morphing and Deploying
Different AIs do different things depending on the classLabel of the ship they're driving, for example, if morphTank AI is driving a morphtank, it will morph before and after attacking, BUT! If this AI is on a pilot, it will use its jetpack instead of morphing, if its on a SAV, it will change height. Usually 'morphing' is whatever is done with the 'c' key in these cases.

Some AIs that understand the concept of 'morphing' or 'deploying' can be used in interesting ways when mixed and matched with other classLabel ships that have this functionality (ie: aircraft, SAVs, APCs, turrets, pilots, etc.).

AIs that are marked Morph to Attack will use these functionalities.
Using Multiple Weapons
RocketTank and MorphTank AIs are interesting, because they are rarely used AIs that are actually better then stock AIs in some cases. These AIs will fight and hold their ground unfazed by enemy fire, unlike scout and tank AIs that sometimes uselessly turn around when being attacked.

The most interesting things about these AIs is that they understand weaponMask, which is an entry above the weapons config. This setting allows the ship to use multiple weapons, depending on the settings. For example: A weaponmask of 00001 will only use the very first HP for combat, a weaponmask of 00110 will use the second and third HPs, whereas a w/m of 11111 will use ALL available HPs (weapons)
Task Entries
BZ2 supposedly allows for a variety of task entry types allowing you to + Customize the AI to suit your needs:

attackTask = "<name of attack task>"
defendTask = "<name of defend task>"
waitTask = "<name of wait task>"
specialTask = "<name of special task>"
subAttackTask = "<name of sub-attack task>"
subAttackClass = "<control parameters>"

Letter 1: N=attack ground only, A=include air targets
Letter 2: N=regular attack, D=deploy to attack
Letter 3: N=use engage range, S=limit to weapon range

In practice, only attackTask, subAttackTask, and subAttackClass are supported by BZ2. The other 'Tasks' seem to hint at an AI customizing feature that was not completed.

The following list is Task Entries that I've found so far:

AttackTasks:
-Standard-
MortarBikeAttack
ArcherAttack
ArtlAttack
AssaultTankAttack

subAttackTasks:
-Standard-
MortarBikeSubAttack
ArcherSubAttack
ArtlSubAttack
SupportSubAttack
-Experimental-
PersonAttack
SoldierAttack
GechAttack
SAVAttackVehicleTask
SAVAttackPersonTask
SitAttack
MorphTankAttack
RocketTankAttack
AimFireAttack
WingmanBlastAttack
GunTowerAttack
TurretAttack
TurretBlastAttack
APCAttack
-Experimental-
TurretDefendTask
DefendArea
* Mixing and matching attack/subattack tasks are generally not a good idea. The AI will usually reject attack orders if this is done.
Non-combat AIs
TugFriend/Process - For use with non-combat vehicles only. Will cause AV when used in combat vehicles.
RigFriend/Enemy - Constructor AI, is completely inert in other vehicles.
CombatFriend/Enemy - A broken AI with unpredictable behavior. AV Prone in combat vehicles.
BomberProcess - Undeploys, moves to target, and creates a daywrecker object above it. Self-destructs if a bomber bay doesnt exist.
APCProcess - Moves to target and deploys. Distibutes troops during an attack run, but does not attack with weapons. Unlike other AIs, this one will not deploy troops if simply given a 'move' command.
LandAnimalProcess - Used in Jak Killers, will engage in melee combat with pilots. Causes an AV if used in combat vehicles.
TorpedoProcess - Used in WASPs and Comets, will cause AV if used in combat vehicles.
MinelayerFriend/Enemy - Broken AI in 1.2. Possibly fixed in ver 1.3
WingmanFriend/Enemy - This entry is in an unused ODF, but results in empty ships that use it.
BoidProcess - A bird process. Used for flying animals.

Known AI Bugs:

SubAttack Bug: Causes AI to lose weaponmask abilities (and use first HP only). This bug happens when an AI is told to attack 'target A' and ends up subattacking another enemy. I can also happen when an AI is told to 'hold' during a subattack.

Mortar Use Bug: AI bug that occurs with turreted AIs while using mortars. If this AI subattacks a unit that is too high to reach (usually a pilot), it will attempt to aim upwards, and will not attack anything else until it's given a new order, or its target is destroyed.

Mixed Weapons Bug: Version 1.2 bug that happens with Gech AIs. Causes unpredictable weapon type usage. This bug need further observation.

Leading Bug: Bug that only seems to happen with RocketTankFriend/Enemy AIs. AI will strafe, but not properly compensate leading, and often end up under-leading its target and not firing on it at all.

Definitions:

Task Entries: Variables under [craftClass] that define how certain AIs will behave in different situations. (ie: attackTask = "AssaultTankAttack", subAttackTask = ...). These are used only by aiNames that support them.

Sub-Attack: The act of attacking a target where an attack order isn't explicitly given.

Turreted: Vehicles or buildings such as Turrets, Assault Tanks and Gun Towers; which can rotate their weapons independently of their main body.

Hardpoint or HP: A location in a model that determines the start point, type, and sometimes the direction that weapons will fire. HPs can be used for other things as well, such as emits and build points. (beyond the scope of this document)

WeaponMask or w/m: A variable that defines which weapons can be used simultaneously by AI, used only by GunTower, MorphTank, and RocketTank AIs. Set up in reverse order (ie: a weaponmask of 00001 will fire only the very first HP, whereas a weaponmask of 00110 will fire only the second and third HPs) This variable ignores BZ2s tendency to auto-link same-type weapons and can allow the AI to fire any number (up to 5) of weapons at the same time. AIs that use w/m will only lead and attack based on the first linked HP.