ModEnc is currently in Maintenance Mode: Changes could occur at any given moment, without advance warning.

QuarryTypes

From ModEnc
Revision as of 15:26, 17 June 2023 by E1 Elite (talk | contribs) (About target selection.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

There are various target types that teams and special weapons can be assigned to attack. These are general target categories since the actual disposition of potential targets cannot be precisely predicted -- thus these serve as guidelines for the computer AI.
Red Alert source

Quarry1 types is a feature first introduced in Red Alert. As explained by the above comment in the game's source code, they are used to specify general target categories for AI teams and special weapons (super weapons in later games).

Usage

Quarry types are used as a parameter in at least three places:

  • Team mission (RA1) or script action (TS to YR) type 0 ("Attack...") to instruct the team to attack specific kind of targets
  • Script action (RA2/ YR only) type 57 ("Chronoshift Task Force to a target type...") to have the team Chronoshifted to a specific kind of target if appropriate Superweapon is ready and charged.
  • Trigger action type 35 for special/super weapon targeting

Available QuarryTypes

Red Alert

Index QuarryType Description
0 QUARRY_NONE None or invalid, cancels attack mission
1 QUARRY_ANYTHING Any enemy building or unit (same as "hunt")
2 QUARRY_BUILDINGS Any enemy building
3 QUARRY_HARVESTERS Any enemy Ore Miner
4 QUARRY_INFANTRY Any enemy infantry
5 QUARRY_VEHICLES Any enemy ground vehicle
6 QUARRY_VESSELS Any enemy ship
7 QUARRY_FACTORIES Any enemy factory
8 QUARRY_DEFENSE Any enemy defense building
9 QUARRY_THREAT Any enemy objects approaching (or already in) its base and which are in an attack mission
10 QUARRY_POWER Any enemy power facility
11 QUARRY_FAKES Any enemy fake building

Tiberian Sun to Yuri's Revenge

Index QuarryType Description
0 QUARRY_NONE None or invalid, cancels attack mission
1 QUARRY_ANYTHING Enemy object (vehicle/aircraft/infantry/building)
2 QUARRY_BUILDINGS Enemy building
3 QUARRY_HARVESTERS Enemy Harvester or Ore Miner
4 QUARRY_INFANTRY Enemy infantry
5 QUARRY_VEHICLES Enemy ground vehicle
6 QUARRY_FACTORIES Enemy factory
7 QUARRY_DEFENSE Enemy defense building
8 QUARRY_THREAT Enemy objects approaching (or already in) its base and which are in an attack mission
9 QUARRY_POWER Enemy power facility
Red Alert 2 additions
10 QUARRY_OCCUPIABLE2 Building that can be occupied
11 QUARRY_TECH2 Tech building

Target selection is based on the scan range defined by TargetDistanceCoefficientDefault or its technotype override of TargetDistanceCoefficient. If targets are available within that range, then closest of those is selected. If no targets are available within that range, then first built by that enemy is selected.

Notes

  • 1 In this context, quarry means prey, not a mine.

  • 2 Presumed internal name.