where you have these lines here:
Code:
</Language_en_US>
[COLOR="Red"]<?xml version="1.0" encoding="utf-8"?>
<!-- Created by ModBuddy on 2/24/2013 5:11:29 PM -->
<GameData>[/COLOR]
<BuildingClasses>
<Row>
<Type>BUILDINGCLASS_TRAIT</Type>
<DefaultBuilding>BUILDING_TRAIT</DefaultBuilding>
<Description>TXT_KEY_BUILDING_TRAIT</Description>
</Row>
</BuildingClasses>
<Civilization_BuildingClassOverrides>
<Row>
<CivilizationType>CIVILIZATION_BARBARIAN</CivilizationType>
<BuildingClassType>BUILDINGCLASS_TRAIT_BUILDING</BuildingClassType>
<BuildingType/>
</Row>
<Row>
<CivilizationType>CIVILIZATION_MINOR</CivilizationType>
<BuildingClassType>BUILDINGCLASS_TRAIT</BuildingClassType>
<BuildingType/>
</Row>
</Civilization_BuildingClassOverrides>
[COLOR="red"]</GameData>[/COLOR]
</GameData>
there is already an open
<GameData> prior to those lines, so you are going to get failure of the
traitBuilding.xml file from syntax errors. The two
<GameData> --
</GameData> lines as shown absolutely must be eliminated. You should also get rid of the
<?xml version="1.0" encoding="utf-8"?> line since that is never included within
<GameData> wraps. I would eliminate these lines:
Code:
<Civilopedia>TXT_KEY_CIV5_BUILDINGS_TRAIT_TEXT</Civilopedia>
<Strategy>TXT_KEY_BUILDING_TRAIT_STRATEGY</Strategy>
<Help>TXT_KEY_BUILDING_TRAIT_HELP</Help>
Since they tend to conflict with hiding the building. As well as these lines here:
Code:
<Row Tag="TXT_KEY_CIV5_BUILDINGS_TRAIT_TEXT">
<Text>
<!-- Add Civilopedia text here -->
</Text>
</Row>
<Row Tag="TXT_KEY_BUILDING_TRAIT_STRATEGY">
<Text>The Trait Building can only be constructed in a city with an improved source of [ICON_RES_HORSE] Horses or [ICON_RES_IVORY] Ivory nearby. The Trait Building increases a civilization's [ICON_HAPPINESS_1] Happiness.</Text>
</Row>
<Row Tag="TXT_KEY_BUILDING_TRAIT_HELP">
<Text>City must have an improved source of [ICON_RES_HORSE] Horses or [ICON_RES_IVORY] Ivory nearby.</Text>
</Row>
All you should really need in that file is this:
Code:
<GameData>
<Buildings>
<Row>
<Type>BUILDING_TRAIT</Type>
<Description>TXT_KEY_BUILDING_TRAIT</Description>
<Cost>-1</Cost>
<PrereqTech>NULL</PrereqTech>
<GreatWorkCount>-1</GreatWorkCount>
<FaithCost>-1</FaithCost>
<NeverCapture>true</NeverCapture>
<MinAreaSize>-1</MinAreaSize>
<Happiness>2</Happiness>
<BuildingClass>BUILDINGCLASS_TRAIT</BuildingClass>
<ArtDefineTag>NONE</ArtDefineTag>
<PortraitIndex>44</PortraitIndex>
<IconAtlas>BW_ATLAS_1</IconAtlas>
</Row>
</Buildings>
<Building_YieldChanges>
<Row>
<BuildingType>BUILDING_TRAIT</BuildingType>
<YieldType>YIELD_CULTURE</YieldType>
<Yield>4</Yield>
</Row>
</Building_YieldChanges>
<Language_en_US>
<Row Tag="TXT_KEY_BUILDING_TRAIT">
<Text>Trait Building</Text>
</Row>
</Language_en_US>
<BuildingClasses>
<Row>
<Type>BUILDINGCLASS_TRAIT</Type>
<DefaultBuilding>BUILDING_TRAIT</DefaultBuilding>
<Description>TXT_KEY_BUILDING_TRAIT</Description>
</Row>
</BuildingClasses>
</GameData>
Plus you had some other errors related to wrong building designation in
<Building_YieldChanges> and you had some repeats of column commands within the
<Buildings> table, each of which would cause the entire file to fail until you root them out.
Plus, for dummy/hidden buildings it is always better to include no more commands than the minimum necessary to (a) get the game to accept the building as valid, and (b), get the effects you want so far as yields and the like go.
Having just made the previous statement, note that I always include a
<IconAtlas> and
<PortraitIndex> command even though the building is intended to be hidden: I'm not sure if I can get by without them so far as the game accepting the building as valid, though they have no effect on the building showing anywhere.