TownCenter, How to add unit to spawn there

Created a new custom unit, Settler. I can get them to spawn via the civ file and on start of a skirmish.
I cannot get them to be spawn able at the town center. Im wondering if my “train” addition to the proto file is the issue. I have added various values in the column with no success.

Here is my protomods

<protomods>

  <unit id="294" name="TownCenter">
	<train mergeMode="add" row="0" page="0" column="7">RusSettler</train>
  </unit>
  
  <unit mergeMode="add" id="2733" name="RusSettler">
    <dbid>1</dbid>
    <displaynameid>220058</displaynameid>
    <editornameid>220059</editornameid>
    <populationcount>1</populationcount>
    <obstructionradiusx>0.4900</obstructionradiusx>
    <obstructionradiusz>0.4900</obstructionradiusz>
    <formationcategory>Protected</formationcategory>
    <maxvelocity>6.0000</maxvelocity>
    <maxrunvelocity>10.0000</maxrunvelocity>
    <movementtype>land</movementtype>
    <turnrate>18.0000</turnrate>
    <animfile>units\villagers\villager.xml</animfile>
    <impacttype>Flesh</impacttype>
    <physicsinfo>dude</physicsinfo>
    <icon>resources\art\units\villagers\villager_icon.png</icon>
    <portraiticon>resources\art\units\villagers\villager_portrait.png</portraiticon>
    <selectionpriority>10</selectionpriority>
    <rollovertextid>22814</rollovertextid>
    <shortrollovertextid>25708</shortrollovertextid>
    <initialhitpoints>550.0000</initialhitpoints>
    <maxhitpoints>550.0000</maxhitpoints>
    <los>14.0000</los>
    <projectileprotounit>InvisibleProjectile</projectileprotounit>
    <unitaitype>Civilian</unitaitype>
    <trainpoints>25.0000</trainpoints>
    <buildlimit>20</buildlimit>
    <bounty>10.0000</bounty>
    <buildbounty>10.0000</buildbounty>
    <cost resourcetype="Food">100.0000</cost>
    <carrycapacity resourcetype="Food">1.0000</carrycapacity>
    <carrycapacity resourcetype="Wood">1.0000</carrycapacity>
    <carrycapacity resourcetype="Gold">1.0000</carrycapacity>
    <carrycapacity resourcetype="Influence">1.0000</carrycapacity>
    <allowedage>0</allowedage>
    <armor type="Hand" value="0.2000">
    </armor>
    <unittype>LogicalTypeMinimapFilterEconomic</unittype>
    <unittype>LogicalTypeEasySelectAvoid</unittype>
    <unittype>LogicalTypeHealed</unittype>
    <unittype>LogicalTypeNeededForVictory</unittype>
    <unittype>LogicalTypeHandUnitsAutoAttack</unittype>
    <unittype>LogicalTypeValidSPCUnitsDeadCondition</unittype>
    <unittype>LogicalTypeGarrisonInShips</unittype>
    <unittype>LogicalTypeAffectedByTownBell</unittype>
    <unittype>LogicalTypeRangedUnitsAutoAttack</unittype>
    <unittype>LogicalTypeVillagersAttack</unittype>
    <unittype>LogicalTypeHandUnitsAttack</unittype>
    <unittype>LogicalTypeRangedUnitsAttack</unittype>
    <unittype>LogicalTypeLandEconomy</unittype>
    <unittype>LogicalTypeSettlerBuildLimit</unittype>
    <unittype>LogicalTypeMalteseCivBonus</unittype>
    <unittype>LogicalTypeMalteseCivBonusHealsWhenIdle</unittype>
    <unittype>Unit</unittype>
    <unittype>UnitClass</unittype>
    <unittype>Economic</unittype>
    <unittype>EconomicUnit</unittype>
    <unittype>AbstractVillager</unittype>
    <unittype>HasBountyValue</unittype>
    <unittype>Ranged</unittype>
    <unittype>CountsTowardEconomicScore</unittype>
    <unittype>ValidIdleVillager</unittype>
    <unittype>ConvertsHerds</unittype>
    <unittype>AffectedByTownBell</unittype>
    <unittype>CannotConvertHill</unittype>
    <train row="0" page="6" column="1">deHouseInca</train>
    <train row="0" page="6" column="12">deKallanka</train>
    <train row="0" page="6" column="0">Manor</train>
    <train row="0" page="6" column="17">Capitol</train>
    <train row="0" page="6" column="17">deStateCapitol</train>
    <train row="0" page="6" column="0">HouseEast</train>
    <train row="0" page="6" column="0">HouseMed</train>
    <train row="0" page="6" column="0">House</train>
    <train row="0" page="6" column="0">deHouseAfrican</train>
    <train row="0" page="6" column="0">deTorp</train>
    <train row="0" page="6" column="18">TownCenter</train>
    <train row="0" page="6" column="19">NativeEmbassy</train>
    <train row="0" page="6" column="16">dePalace</train>
    <train row="0" page="6" column="16">Saloon</train>
    <train row="0" page="6" column="16">deTavern</train>
    <train row="0" page="6" column="0">CommunityPlaza</train>
    <train row="0" page="6" column="1">Teepee</train>
    <train row="0" page="6" column="1">Longhouse</train>
    <train row="0" page="6" column="1">HouseAztec</train>
    <train row="0" page="255" column="1">WallStraight2</train>
    <train row="0" page="255" column="1">WallStraight5</train>
    <train row="0" page="6" column="2">Market</train>
    <train row="0" page="6" column="2">deLivestockMarket</train>
    <train row="0" page="6" column="3">Farm</train>
    <train row="0" page="6" column="3">Mill</train>
    <train row="0" page="6" column="3">deField</train>
    <train row="0" page="6" column="3">deHacienda</train>
    <train row="0" page="6" column="4">LivestockPen</train>
    <train row="0" page="6" column="5">Dock</train>
    <train row="0" page="6" column="5">dePort</train>
    <train row="0" page="6" column="6">Outpost</train>
    <train row="0" page="6" column="6">deTower</train>
    <train row="0" page="6" column="6">Blockhouse</train>
    <train row="0" page="6" column="7">TradingPost</train>
    <train row="0" page="6" column="8">WallConnector</train>
    <train row="0" page="6" column="9">Bank</train>
    <train row="0" page="6" column="9">deLombard</train>
    <train row="0" page="6" column="10">deMountainMonastery</train>
    <train row="0" page="6" column="10">deUniversity</train>
    <train row="0" page="6" column="10">Church</train>
    <train row="0" page="6" column="10">deCathedral</train>
    <train row="0" page="6" column="10">deBasilica</train>
    <train row="0" page="6" column="11">WarHut</train>
    <train row="0" page="6" column="11">Barracks</train>
    <train row="0" page="6" column="11">deHospital</train>
    <train row="0" page="6" column="11">deWarCamp</train>
    <train row="0" page="6" column="12">Stable</train>
    <train row="0" page="6" column="12">deCommandery</train>
    <train row="0" page="6" column="12">Corral</train>
    <train row="0" page="6" column="12">NoblesHut</train>
    <train row="0" page="6" column="13">ArtilleryDepot</train>
    <train row="0" page="6" column="14">Arsenal</train>
    <train row="0" page="6" column="15">Plantation</train>
    <train row="0" page="6" column="15">deGranary</train>
    <train row="0" page="6" column="6">deBlockhouse</train>
    <train row="0" page="255" column="0">ypWJGiantBuddha2</train>
    <train row="0" page="255" column="0">ypWJGiantBuddha3</train>
    <train row="0" page="255" column="0">ypWJGiantBuddha4</train>
    <train row="0" page="255" column="0">ypWJGiantBuddha5</train>
    <train row="0" page="255" column="0">ypWJGoldenPavillion2</train>
    <train row="0" page="255" column="0">ypWJGoldenPavillion3</train>
    <train row="0" page="255" column="0">ypWJGoldenPavillion4</train>
    <train row="0" page="255" column="0">ypWJGoldenPavillion5</train>
    <train row="0" page="255" column="0">ypWJShogunate2</train>
    <train row="0" page="255" column="0">ypWJShogunate3</train>
    <train row="0" page="255" column="0">ypWJShogunate4</train>
    <train row="0" page="255" column="0">ypWJShogunate5</train>
    <train row="0" page="255" column="0">ypWJToriiGates2</train>
    <train row="0" page="255" column="0">ypWJToriiGates3</train>
    <train row="0" page="255" column="0">ypWJToriiGates4</train>
    <train row="0" page="255" column="0">ypWJToriiGates5</train>
    <train row="0" page="255" column="0">ypWJToshoguShrine2</train>
    <train row="0" page="255" column="0">ypWJToshoguShrine3</train>
    <train row="0" page="255" column="0">ypWJToshoguShrine4</train>
    <train row="0" page="255" column="0">ypWJToshoguShrine5</train>
    <train row="0" page="255" column="0">ypWITowerOfVictory5</train>
    <train row="0" page="255" column="0">ypWITowerOfVictory4</train>
    <train row="0" page="255" column="0">ypWITowerOfVictory3</train>
    <train row="0" page="255" column="0">ypWITowerOfVictory2</train>
    <train row="0" page="255" column="0">ypWITajMahal5</train>
    <train row="0" page="255" column="0">ypWITajMahal4</train>
    <train row="0" page="255" column="0">ypWITajMahal3</train>
    <train row="0" page="255" column="0">ypWITajMahal2</train>
    <train row="0" page="255" column="0">ypWIKarniMata5</train>
    <train row="0" page="255" column="0">ypWIKarniMata4</train>
    <train row="0" page="255" column="0">ypWIKarniMata3</train>
    <train row="0" page="255" column="0">ypWIKarniMata2</train>
    <train row="0" page="255" column="0">ypWICharminarGate5</train>
    <train row="0" page="255" column="0">ypWICharminarGate4</train>
    <train row="0" page="255" column="0">ypWICharminarGate3</train>
    <train row="0" page="255" column="0">ypWICharminarGate2</train>
    <train row="0" page="255" column="0">ypWIAgraFort5</train>
    <train row="0" page="255" column="0">ypWIAgraFort4</train>
    <train row="0" page="255" column="0">ypWIAgraFort3</train>
    <train row="0" page="255" column="0">ypWIAgraFort2</train>
    <train row="0" page="255" column="0">ypWCWhitePagoda5</train>
    <train row="0" page="255" column="0">ypWCWhitePagoda4</train>
    <train row="0" page="255" column="0">ypWCWhitePagoda2</train>
    <train row="0" page="255" column="0">ypWCWhitePagoda3</train>
    <train row="0" page="255" column="0">ypWCTempleOfHeaven5</train>
    <train row="0" page="255" column="0">ypWCTempleOfHeaven4</train>
    <train row="0" page="255" column="0">ypWCTempleOfHeaven3</train>
    <train row="0" page="255" column="0">ypWCTempleOfHeaven2</train>
    <train row="0" page="255" column="0">ypWCSummerPalace5</train>
    <train row="0" page="255" column="0">ypWCSummerPalace4</train>
    <train row="0" page="255" column="0">ypWCSummerPalace3</train>
    <train row="0" page="255" column="0">ypWCConfucianAcademy2</train>
    <train row="0" page="255" column="0">ypWCConfucianAcademy3</train>
    <train row="0" page="255" column="0">ypWCConfucianAcademy4</train>
    <train row="0" page="255" column="0">ypWCConfucianAcademy5</train>
    <train row="0" page="255" column="0">ypWCPorcelainTower2</train>
    <train row="0" page="255" column="0">ypWCPorcelainTower3</train>
    <train row="0" page="255" column="0">ypWCPorcelainTower4</train>
    <train row="0" page="255" column="0">ypWCPorcelainTower5</train>
    <train row="0" page="255" column="0">ypWCSummerPalace2</train>
    <train row="0" page="6" column="11">ypWarAcademy</train>
    <train row="0" page="6" column="0">ypVillage</train>
    <train row="0" page="6" column="2">ypTradeMarketAsian</train>
    <train row="0" page="6" column="12">ypStableJapanese</train>
    <train row="0" page="6" column="0">ypShrineJapanese</train>
    <train row="0" page="6" column="4">ypSacredField</train>
    <train row="0" page="6" column="3">ypRicePaddy</train>
    <train row="0" page="6" column="10">ypMonastery</train>
    <train row="0" page="6" column="0">ypHouseIndian</train>
    <train row="0" page="6" column="5">YPDockAsian</train>
    <train row="0" page="6" column="14">ypConsulate</train>
    <train row="0" page="6" column="6">ypCastle</train>
    <train row="0" page="6" column="12">ypCaravanserai</train>
    <train row="0" page="6" column="11">ypBarracksJapanese</train>
    <train row="0" page="6" column="11">YPBarracksIndian</train>
    <train row="0" page="6" column="4">deFurTrade</train>
    <tech row="0" page="1" column="0">YPWonderJapaneseToshoguShrine4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTowerOfVictory3</tech>
    <tech row="0" page="1" column="0">YPWonderIndianKarniMata5</tech>
    <tech row="0" page="1" column="0">YPWonderIndianAgra3</tech>
    <tech row="0" page="1" column="0">YPWonderChineseWhitePagoda3</tech>
    <tech row="0" page="1" column="0">YPWonderChineseWhitePagoda2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseShogunate4</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToriiGates3</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToshoguShrine5</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToriiGates4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTowerOfVictory5</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTajMahal2</tech>
    <tech row="0" page="1" column="0">YPWonderIndianCharminar5</tech>
    <tech row="0" page="1" column="0">YPWonderIndianAgra5</tech>
    <tech row="0" page="1" column="0">YPWonderChinesePorcelainTower4</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGiantBuddha3</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGiantBuddha4</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGoldenPavillion2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGoldenPavillion3</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGoldenPavillion4</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGoldenPavillion5</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseShogunate2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToriiGates2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToshoguShrine3</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToshoguShrine2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseToriiGates5</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTowerOfVictory4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTajMahal4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTajMahal3</tech>
    <tech row="0" page="1" column="0">YPWonderIndianKarniMata2</tech>
    <tech row="0" page="1" column="0">YPWonderIndianCharminar4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianCharminar3</tech>
    <tech row="0" page="1" column="0">YPWonderIndianAgra4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianAgra2</tech>
    <tech row="0" page="1" column="0">YPWonderChineseWhitePagoda5</tech>
    <tech row="0" page="1" column="0">YPWonderChineseWhitePagoda4</tech>
    <tech row="0" page="1" column="0">YPWonderChineseTempleOfHeaven4</tech>
    <tech row="0" page="1" column="0">YPWonderChineseTempleOfHeaven3</tech>
    <tech row="0" page="1" column="0">YPWonderChineseTempleOfHeaven2</tech>
    <tech row="0" page="1" column="0">YPWonderChineseSummerPalace5</tech>
    <tech row="0" page="1" column="0">YPWonderChineseSummerPalace4</tech>
    <tech row="0" page="1" column="0">YPWonderChineseSummerPalace3</tech>
    <tech row="0" page="1" column="0">YPWonderChineseSummerPalace2</tech>
    <tech row="0" page="1" column="0">YPWonderChinesePorcelainTower5</tech>
    <tech row="0" page="1" column="0">YPWonderChinesePorcelainTower3</tech>
    <tech row="0" page="1" column="0">YPWonderChinesePorcelainTower2</tech>
    <tech row="0" page="1" column="0">YPWonderChineseConfucianAcademy5</tech>
    <tech row="0" page="1" column="0">YPWonderChineseConfucianAcademy4</tech>
    <tech row="0" page="1" column="0">YPWonderChineseConfucianAcademy3</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseShogunate3</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTowerOfVictory2</tech>
    <tech row="0" page="1" column="0">YPWonderIndianTajMahal5</tech>
    <tech row="0" page="1" column="0">YPWonderIndianKarniMata4</tech>
    <tech row="0" page="1" column="0">YPWonderIndianKarniMata3</tech>
    <tech row="0" page="1" column="0">YPWonderIndianCharminar2</tech>
    <tech row="0" page="1" column="0">YPWonderChineseTempleOfHeaven5</tech>
    <tech row="0" page="1" column="0">YPWonderChineseConfucianAcademy2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGiantBuddha2</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseGiantBuddha5</tech>
    <tech row="0" page="1" column="0">YPWonderJapaneseShogunate5</tech>
    <flag>CollidesWithProjectiles</flag>
    <flag>ApplyHandicapTraining</flag>
    <flag>CorpseDecays</flag>
    <flag>ShowGarrisonButton</flag>
    <flag>DontRotateObstruction</flag>
    <flag>ObscuredByUnits</flag>
    <flag>DeadReplacementWhenDestroyed</flag>
    <flag>VisibleUnderFogIfGaia</flag>
    <flag>Tracked</flag>
    <flag>SettlerBuildLimit</flag>
    <command page="10" column="0">Garrison</command>
    <command page="10" column="1">Stop</command>
    <command page="10" column="7">Delete</command>
	<command page="11" column="0">Abilities</command>
    <tactics>settler.tactics</tactics>
    <protoaction>
      <name>AutoGatherTrade</name>
      <type>AutoGather</type>
      <rate type="Trade">0.030000</rate>
    </protoaction>
    <protoaction>
      <name>SpearAttack</name>
      <damage>3.000000</damage>
      <damagetype>Ranged</damagetype>
      <minrange>2.000000</minrange>
      <maxrange>12.000000</maxrange>
      <typedminrange type="Huntable">0</typedminrange>
      <typedmaxrange type="Huntable">12</typedmaxrange>
      <rof>3.000000</rof>
      <damagebonus type="Huntable">4.000000</damagebonus>
      <damagebonus type="AbstractPet">2.000000</damagebonus>
      <damagebonus type="AbstractArtillery">2.000000</damagebonus>
      <damagebonus type="AbstractVillager">0.500000</damagebonus>
    </protoaction>
    <protoaction>
      <name>BlunderbussAttack</name>
      <damage>39.000000</damage>
      <damagetype>Ranged</damagetype>
      <minrange>2.000000</minrange>
      <maxrange>12.000000</maxrange>
      <typedminrange type="Huntable">0</typedminrange>
      <typedmaxrange type="Huntable">12</typedmaxrange>
      <rof>3.000000</rof>
      <damagebonus type="Huntable">4.000000</damagebonus>
      <damagebonus type="AbstractPet">2.000000</damagebonus>
      <damagebonus type="AbstractArtillery">2.000000</damagebonus>
      <damagebonus type="AbstractVillager">0.500000</damagebonus>
    </protoaction>
    <protoaction>
      <name>Build</name>
      <rate type="Building">1.000000</rate>
      <rate type="Manor">1.000000</rate>
      <rate type="House">1.000000</rate>
      <rate type="Church">1.000000</rate>
      <rate type="deField">1.000000</rate>
    </protoaction>
    <protoaction>
      <name>BuildingAttack</name>
      <damage>5.000000</damage>
      <damagetype>Siege</damagetype>
      <rof>3.000000</rof>
      <damagebonus type="AbstractResourceEnclosure">3.000000</damagebonus>
    </protoaction>
    <protoaction>
      <name>ChopAttack</name>
      <damage>8.000000</damage>
      <damagetype>Hand</damagetype>
    </protoaction>
    <protoaction>
      <name>CrateGather</name>
      <rate type="AbstractResourceCrate">8.000000</rate>
    </protoaction>
    <protoaction>
      <name>Gather</name>
      <rate type="Tree">0.500000</rate>
      <rate type="AbstractMine">0.600000</rate>
      <rate type="Plantation">0.500000</rate>
      <rate type="Herdable">2.000000</rate>
      <rate type="Huntable">0.840000</rate>
      <rate type="AbstractBerryBush">0.670000</rate>
      <rate type="Farm">0.500000</rate>
      <rate type="Mill">0.670000</rate>
      <rate type="ypRicePaddy" resource="Food">0.500000</rate>
      <rate type="AbstractTradeMarket">1.500000</rate>
      <rate type="ypBerryBuilding">0.670000</rate>
      <rate type="ypRicePaddy" resource="Gold">0.340000</rate>
      <rate type="ypGroveBuilding">0.500000</rate>
      <rate type="deFurTrade" yield="1.100000">0.600000</rate>
      <rate type="AbstractInfiniteCrate">8.000000</rate>
      <rate type="deTorpBush2">0.670000</rate>
      <rate type="AbstractMountainMonastery">0.600000</rate>
      <rate type="deField" resource="Food">0.500000</rate>
      <rate type="deField" resource="Gold">0.377000</rate>
      <rate type="deField" resource="Wood">0.34000</rate>
      <rate type="deField" resource="Influence">0.340000</rate>
      <rate type="deHacienda">0.500000</rate>
      <rate type="deHacienda" resource="Food">0.500000</rate>
      <rate type="deHacienda" resource="Gold">0.340000</rate>
      <rate type="deHacienda" resource="Wood">0.500000</rate>
    </protoaction>
    <protoaction>
      <name>HandAttack</name>
      <damage>10.000000</damage>
      <damagetype>Hand</damagetype>
      <rof>1.500000</rof>
      <damagebonus type="Llama">5.000000</damagebonus>
    </protoaction>
    <protoaction>
      <name>HandAttackCrate</name>
      <damage>10.000000</damage>
      <damagetype>Hand</damagetype>
      <rof>1.500000</rof>
    </protoaction>
    <protoaction>
      <name>Hunting</name>
      <rate type="Herdable">1.000000</rate>
      <rate type="Huntable">1.000000</rate>
      <rate type="Tree">1.000000</rate>
    </protoaction>
  </unit>
</protomods>

Then my Stringmods

stringmods>
	<Stringtable mergeMode="add">
		<Language name='English'>
			<string _locid="220058">Settler</string>
			<string _locid="220059">RusSettler</string>
		</Language>
	</Stringtable>
</stringmods>

Then my civsmods

<civmods>
  <civ>
	<name>Russians</name>
		<settlerprotoname mergeMode="add">RusSettler</settlerprotoname>
		<townstartingunit mergeMode="add">RusSettler</townstartingunit>
		<townstartingunit mergeMode="add">RusSettler</townstartingunit>
		<townstartingunit mergeMode="add">RusSettler</townstartingunit>
		<blocktrain mergeMode="add">
			<building>TownCenter</building>
			<unit>RusSettler</unit>
			<count>3</count>
		</blocktrain>
		<blocktrain mergeMode="add">
			<building>deSPCCommandPost</building>
			<unit>RusSettler</unit>
			<count>3</count>
		</blocktrain>
  </civ>
</civmods>

and Finally my techtreemods

<techtreemods>
   <tech name="Age0Russian" type="Normal">
	  <effects>
		<effect mergeMode="add" type="Data" amount="1.00" subtype="Enable" relativity="Absolute">
			<target type="ProtoUnit">RusSettler</target>
		</effect>
		<effect mergeMode="add" type="Data" amount="2.08" subtype="TrainPoints" relativity="BasePercent">
			<target type="ProtoUnit">RusSettler</target>
		</effect>
		<effect mergeMode="add" type="Data" amount="0.866666666666666667" subtype="Cost" resource="Food" relativity="BasePercent">
			<target type="ProtoUnit">RusSettler</target>
		</effect>
	 </effects>
   </Tech>
</techtreemods>

I’ve had mixed results with the mergeMode attribute, and I think it defaults to “add” if the attribute isn’t present, so I don’t use it if I’m just adding. Maybe try removing mergeMode entirely from the techtree, proto and civmods files?

I can’t check my own proto file at the moment, but the “train” addition looks fine to me, assuming the row, page and column numbers are correct.

So my first round I didn’t have the mergeMode present. Then I added it and I could get my custom settlers to appear on spawn(all 3 rather just one before using the mergeMode attribute)

I saw someone else’s post asking about the use of page, row and column and I’ll going to try some attempts with what I could understand from that post.
Thanks for the input!
On the forum “moding” it stated that mergeMode had 4 attributes:
Add
Replace
Remove
Merge

Of those 4, it stated that it merges if no attribute is stated

You’re right about mergeMode, I’d forgotten “merge” was the default. Even so, I don’t think you need any mergeMode for the techtree and proto files.

One way to check if things are working is to check the temporary data files, explained in the same modding forum post. If you go to that folder while the game is running, you can find Age0Russian tech and see if the lines you’ve added are present in the game.

Finally, I just put your techtreemods into an xml linter, and it didn’t like the capital letter in . XML files are case sensitive - it needs to be .

Oh shoot I must have missed that! With the capitalization. With that are you referring to the string line capitalization?
So I can run the game and look at the files?!
Could you send the link to that post or the title and I’ll read up.

Sorry, I did type out which line it was, but apparently the forum doesn’t like tags with <>. The line I was talking about was in techtree mods, where < /Tech > should be < /tech >. I think the capitalisation in stringmods is fine, as long as the in-game string files also use the capitalised Stringtable.

The article is here. The important section is this:

-There is a config variable called DebugOutputGameData. When this is defined the game will write out each data file after any additive mod files have been merged with the base data file every time the game data is loaded.
-This can be used to check that the additive mods are having the expected effect on the data. Write out the data files with no mods enabled and then with mods enabled and compare the files to see the differences.
-The files are written out to %TEMP%\Age of Empires 3 DE\Data (where %TEMP% is the location of your temp folder, eg. C:\Users\ < user>\AppData\Local\Temp).
-To set the config variable add DebugOutputGameData to the user.cfg file in the C:\Users\ < user>\Games\Age of Empires 3 DE\ < id>\Startup folder (create the file if it doesn’t exist)."

The temp folder is deleted and repopulated every time you start the game, so it’s a very quick way to see if your files are being read and interpreted properly.

You’re absolutely right about mergeMode—I’d actually forgotten that “merge” is the default setting. Even so, for files like techtree and proto, you likely don’t need to include any mergeMode at all.

A good way to confirm if your changes are working is to check the temporary data files (as mentioned in the modding forum). While the game is running, head to that folder and look for the Age0Russian tech—if everything’s gone right, your added lines should be there.

Also, I ran your techtreemods through an XML linter—it didn’t like the capital letter in one of the tags. Just a heads-up: XML is case-sensitive, so even something small like that can break it. You’re really close—just a few tweaks and it should work!

If you edit an existing unit / building you need to use mergemode, OR copy the entire builds entry over to the mod file.

though, Mergemode was only interesting in the time when the game still got updates, sicne it prevented that mods are outdated.

Nowerdays, you can also jsut take the entire techtree and edit that.

While this can be done, I don’t recommend it for two reasons:

  • It can cause compatibility issues with other mods. Some people prefer to combine different mods for a more diverse gaming experience. Personally, I try to make my mods as compatible with others as possible, and I don’t think it’s that difficult. For example, to avoid conflicts, in addition to always using additive data, all my tech names have the suffix “PWAO,” and the dbid for all my techs is always an 8-digit number starting with “770”. This way, it’s less likely that other players will use the same name or dbid for their techs.

  • While unlikely, there’s still a chance the devs will add a new update in the future (maybe after Japanese Civilization in AOMR).

That’s why I suggest keeping mods additive, which also reduces the chance of making mistakes that unexpectedly alter certain game mechanics, such as modifying certain techs that are linked to other techs, for example.

I know that for other modders, all of this may not be important. I mention it because it’s part of my design philosophy, but it’s optional.

Thanks for the tips guys. Hopefully I’ll have some time this weekend to try them out and I’ll let you know my results!

Got it to finally work!!! It was all entering errors on my end. Capitalizations and incorrect syntax. As for my row/page/column I placed it in row=0 page=0 and column=1 and it appeared. Thank you all for your guidance on this!!!
I ended up adding the entire proto line for each section and adding lines to the whole entry and kept the mergeMode and it worked.
in the techtree, it was the Capitol letter that messed my code up
Lastly that debug trick was amazing! I am new to modding this game(only have been playing for about 3months now) so i would open the game, and test with a skirmish match. Prior to that, i would decompile the data file with the resource manager, recompile and then test.

1 Like