AdvMapTown function is to define towns on adventure map.
Location[]
The AdvMapTown.xdb is a XML snippet usually part of Heroes V Map.xdb file. The "shared files" which contain the town defaults are found in the "data\MapObjects" folder and have names such as "Heaven.(AdvMapTownShared).xdb"
Tags[]
Tag Name | Description |
---|---|
AdvMapTown | Information on the towns on the adventure map |
Pos | The X, Y, and Z location of the town. |
Rot | The angle the town is facing, measured in radians. |
Floor | 0 - Town is on the top floor.
1 - Town is in the underground |
Name | Maybe the town's custom name? |
CombatScript | Script to be executed when hero attacks the town. |
pointLights | ??? |
Shared href | points to Town visuals - AdvMapTownShared |
PlayerID | Player ID who owns the town (PLAYER_1, PLAYER_2, ETC) |
CaptureTrigger | Function/script to trigger when town is captured by player |
HeroDeployTrigger | Function/script to trigger when hero is being hired in that town |
ShipTile | The tile location where produced ships appear? |
Specialization href | The specilization of the town (eg Millfield) |
buildings | Lists what is the initial and max upgrade of the buildings in the town |
Editable | Links to the town's name and directory |
armySlots | Contains the information on the town's garrison |
spellIDs | Doesn't appear to do anything in town files, normally controlls what spells are available. |
CaptionFileRef href | ??? |
GarrisonHero | Information on the Hero that starts in the town |
Script | Script executed every time town window is opened. WARNING! The global values(ex. functions) are not available in this scope! |
RndSource | Where to get the information on what type of town this should be |
LinkToPlayer | If the RndSource is RND_PLAYER then this is the player number to link the town to |
LinkToTown | Link Town to another town. For example:
<LinkToTown href="Heaven-3.(AdvMapTown).xdb#xpointer(/AdvMapTown)"/> |
CanCaptureOnlyNotVisit | If you don't want the player to be able to enter the town after they capture it. |
AllowQuickCombat | Set to false if you want to force the player to manually fight for the town. |