This patch is a follow-up to D2549/rP23853. Ideally each template_structure_*.xml file ought to have a corresponding unique class, as is already the case for practically all template_unit_*.xml files. This removes ambiguity for players and helps preventing mistakes when auras, civ bonuses, or technologies are added or altered. That is the aim for this patch.
The complicated thing is currently both template_structure_economic_market.xml and template_structure_military_dock.xml have the Market class. This patch attempts a more systematic approach:
- template_structure_economic_market.xml → Market
- template_structure_military_dock.xml → Dock
- <Market/TradeType> node → Trade
- requirement for bartering: BarterMarket → Barter
The problem is the Petra AI currently uses the Market for trade and BarterMarket class for the {civ}_market.xml. Therefore the following changes are made:
- Where it is used as a marker for trade routes, Market is replaced with Trade.
- Where it is used as an identifier for the {civ}_market.xml, BarterMarket is replaced with Market.
- Where it is used as a prerequisite for bartering resources, BarterMarket is replaced with Barter.
This should make the Petra AI more robust and flexible: if a mod would want to split the market or dock for only one function, that should not cause problems.
Further changes:
- Renamed the Gates class to Gate, LongWall to WallLong (cf. WallTower), and StoneWall to Wall, to match their template file names. Adjusted AI code, technologies, and templates accordingly.
- Entity build restrictions:
- renamed Apadana to Palace;
- replaced UniqueStructure with IshtarGate and TempleOfVesta.
- added Council to the (unbuildable) spart_gerousia.xml, since it's functionally identical to athen_prytaneion.xml.
- Introduced the following classes:
- Council, IshtarGate, Library, TempleOfVesta, and Theater, to match their build restrictions.
- WallMedium and WallShort, to complement the already existing WallLong and WallTower classes.
- Stoa, TempleOfMars, and TriumphalArch, for completeness.
- Made the ArmyCamp, Colony, Gate, Lighthouse, Naval, Palace, Palisade, SiegeWall, and StoneWall classes visible.
- Deleted the now unused Apadana, Kennel, SpecialBuilding classes.
- Removed the Village class from outposts and palisades, because those are not supposed to count towards the phase technology requirements.
- Slightly rephrased the phase technology requirements tooltips.
- Corrected the <GenericName> of the various palisade files.
- Updated Structure tooltips from D2578 that have not already been committed elsewhere.