Skip to content

TerritoryGroup

TerritoryData files define territory groups: top-level containers that hold territory areas and AI behaviors. Each hunting zone has its own file using the naming convention TerritoryData_{huntingZoneId}.xml.

VersionStatus
v92Full
v90-
v86-

Entity: territoryGroups Operations: create, update, delete, upsert Key attributes: huntingZoneId, groupId (composite key)


spec:
version: "1.0"
schema: v92
territoryGroups:
create:
- huntingZoneId: 400
groupId: 1
desc: "Field Boss Group"
berserkAi:
working: true
berserkRate: 0.3
combatRatioDiffToBerserk: 0.5
duration: 60
spec:
version: "1.0"
schema: v92
territoryGroups:
update:
- huntingZoneId: 400
groupId: 1
changes:
desc: "Updated Boss Group"
respawnTimeAi:
working: true
combatRateToReduceRespawnTime: 0.8
respawnReduceTime: 10.0
duration: 120
spec:
version: "1.0"
schema: v92
territoryGroups:
delete:
- huntingZoneId: 400
groupId: 1
spec:
version: "1.0"
schema: v92
territoryGroups:
upsert:
- huntingZoneId: 400
groupId: 1
desc: "Upserted Group"

AttributeTypeSinceDescription
huntingZoneIdintv92Hunting zone identifier (used for file partitioning)
groupIdintv92Unique group identifier within the zone
descstringv92Group description
AttributeTypeSinceDescription
berserkAinestedv92Berserk AI behavior configuration. See BerserkAi.
blastRegenAinestedv92Blast regen AI behavior configuration. See BlastRegenAi.
doorAiListnestedv92Door AI behavior configuration. See DoorAiList.
respawnTimeAinestedv92Respawn time AI behavior configuration. See RespawnTimeAi.
spawnNewNpcAinestedv92Spawn new NPC AI behavior configuration. See SpawnNewNpcAi.

Triggers berserk mode when combat conditions are met.

AttributeTypeSinceDescription
workingboolv92Whether the AI behavior is active
berserkRatedecimalv92Berserk activation threshold rate
combatRatioDiffToBerserkdecimalv92Combat ratio difference that triggers berserk
durationintv92Berserk duration in seconds

Controls blast regeneration based on spawn ratios.

AttributeTypeSinceDescription
workingboolv92Whether the AI behavior is active
checkTypestringv92Type of check to perform
intervalToBlastRegenintv92Interval between regeneration checks
spawnedRatioToBlastRegendecimalv92Spawn ratio threshold for regeneration

Manages door opening mechanics based on NPC death conditions.

AttributeTypeSinceDescription
doorAislist[DoorAi]v92List of door AI entries
AttributeTypeSinceDescription
workingboolv92Whether the AI behavior is active
allNpcDiedboolv92Triggers when all NPCs have died
deadNpcInstanceIdintv92Specific NPC instance whose death triggers the door
openDoorIdintv92Door ID to open

Dynamically adjusts respawn timers based on combat activity.

AttributeTypeSinceDescription
workingboolv92Whether the AI behavior is active
combatRateToReduceRespawnTimedecimalv92Combat rate threshold for respawn reduction
respawnReduceTimedecimalv92Amount of time to reduce from respawn
durationintv92Duration of the effect

Spawns additional NPCs when death count thresholds are reached.

AttributeTypeSinceDescription
workingboolv92Whether the AI behavior is active
npcDeadCountintv92NPC death count threshold
durationintv92Duration of the effect

TerritoryData files use a zone-partitioned structure:

TerritoryData_{huntingZoneId}.xml
└── TerritoryData (huntingZoneId)
└── TerritoryGroup (id, desc) [multiple]
├── BerserkAi (optional)
├── BlastRegenAi (optional)
├── DoorAiList (optional)
│ └── DoorAi [multiple]
├── RespawnTimeAi (optional)
├── SpawnNewNpcAi (optional)
└── TerritoryList
└── Territory [multiple] → see TerritoryArea

  • Zone partitioning: Territory groups are stored in zone-specific files. The huntingZoneId determines which file is modified.

  • Composite key: Groups are identified by both huntingZoneId AND groupId.

  • AI element replacement: When updating AI behaviors via changes, the entire nested element is replaced, not merged. Include all fields of the AI element.