Need help with Improvements ArtDefine_Landmark

Earendel

Chieftain
Joined
Jun 26, 2014
Messages
12
I'm having some serious problems getting started with adding a ArtDefine_LandmarkType and ArtDefine_Landmarks. The only improvement related tutorials I can find skip this part of the process (probably because this part should be easy). I've made a simple test project to get to the root of the problem, but it's not working so maybe someone can point out what I'm doing wrong?

Using XML, I've made a new improvement called IMPROVEMENT_TESTING. The entries in the following tables are working: Improvements, Improvement_Yields, Improvement_ValidTerrains, Improvement_Flavors, Builds, BuildFeatures, Unit_Builds.
If I have the above set to use the default IconAtlas of TERRAIN_ATLAS for the icon, and ArtDefineTag as something like ART_DEF_IMPROVEMENT_TRADING_POST1, then everything works fine. I can have the worker build the improvement and it looks like a trading post.

The problems start when I try to add my own ArtDefineTag.

I'm using sql to add a new ArtDefine_LandmarkTypes, ArtDefine_StrategicView, and ArtDefine_Landmarks. Even if I base the the ArtDefine_Landmarks on existing assets (Assets/Buildings/Improvements/Trading_Post/Medieval/HB_MED_Trading_Post1.fxsxml) it won't work. Looking at the Civ5DebugDatabase in SQLite, I can see the entries appearing there and they look fine (ie. like the trading post entries), but playing the game the improvement is invisible. I can't find any error logs to help me track down a problem.

For a while I thought that it might be something to do with the virtual file system, that I can only add references to fxsxml that's part of the same mod so I tried a few things including the foraging site from the prehistoric mod in the VFS, but that didn't work either.

Here's the code I'm using:

test.sql
Code:
INSERT INTO ArtDefine_LandmarkTypes (Type, LandmarkType, FriendlyName) VALUES	
  ('ART_DEF_IMPROVEMENT_TESTING','Improvement','TESTING Site');

INSERT INTO ArtDefine_StrategicView (StrategicViewType, TileType, Asset) VALUES	
  ('ART_DEF_IMPROVEMENT_TESTING','Improvement','SV_Uranium.dds');

INSERT INTO ArtDefine_Landmarks (Era, State, Scale, ImprovementType, LayoutHandler, ResourceType, Model, TerrainContour) VALUES	
	('Ancient','UnderConstruction',0.5,'ART_DEF_IMPROVEMENT_TESTING','SNAPSHOT','ART_DEF_RESOURCE_ALL','Assets/Buildings/Improvements/Trading_Post/Medieval/HB_MED_Trading_Post1.fxsxml',1),
	('Ancient','Constructed',0.5,'ART_DEF_IMPROVEMENT_TESTING','SNAPSHOT','ART_DEF_RESOURCE_ALL','Assets/Buildings/Improvements/Trading_Post/Medieval/MED_Trading_Post1.fxsxml',1),
	('Ancient','Pillaged',0.5,'ART_DEF_IMPROVEMENT_TESTING','SNAPSHOT','ART_DEF_RESOURCE_ALL','Assets/Buildings/Improvements/Trading_Post/Medieval/PL_MED_Trading_Post1.fxsxml',1);

test.xml
Code:
<?xml version="1.0" encoding="utf-8"?>

<GameData>
  <Improvements>
    <Row>
      <Type>IMPROVEMENT_TESTING</Type>
      <Description>TESTING Site</Description>
      <Civilopedia>TESTING Civopedia</Civilopedia>
      <Help>TESTING site - food</Help>
      <ArtDefineTag>ART_DEF_IMPROVEMENT_TESTING</ArtDefineTag>
		<PillageGold>2</PillageGold>
		<PortraitIndex>26</PortraitIndex>
		<IconAtlas>TERRAIN_ATLAS</IconAtlas>
    </Row>
  </Improvements>
	
	<Improvement_Yields>
		<Row>
			<ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
			<YieldType>YIELD_FOOD</YieldType>
			<Yield>1</Yield>
		</Row>
	</Improvement_Yields>

  <Improvement_ValidTerrains>
    <Row>
      <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
      <TerrainType>TERRAIN_GRASS</TerrainType>
    </Row>
    <Row>
      <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
      <TerrainType>TERRAIN_PLAINS</TerrainType>
    </Row>
	  <Row>
		  <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
		  <TerrainType>TERRAIN_DESERT</TerrainType>
	  </Row>
    <Row>
      <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
      <TerrainType>TERRAIN_TUNDRA</TerrainType>
    </Row>
  </Improvement_ValidTerrains> 
  
  <Improvement_Flavors>
    <Row>
      <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
      <FlavorType>FLAVOR_GROWTH</FlavorType>
      <Flavor>5</Flavor>
    </Row>
  </Improvement_Flavors>
	
  <Builds>
    <Row>
      <Type>BUILD_TESTING</Type>
		<PrereqTech>TECH_AGRICULTURE</PrereqTech>
      <Time>100</Time>
      <ImprovementType>IMPROVEMENT_TESTING</ImprovementType>
      <Description>Build TESTING Site</Description>
      <Help>Build a [COLOR_POSITIVE_TEXT]TESTING Site[ENDCOLOR] for [ICON_FOOD] [COLOR_POSITIVE_TEXT]Food[ENDCOLOR] output +1.</Help>
      <Recommendation>More [ICON_FOOD].</Recommendation>
      <EntityEvent>ENTITY_EVENT_BUILD</EntityEvent>
      <OrderPriority>98</OrderPriority>
		<IconIndex>59</IconIndex>
		<IconAtlas>UNIT_ACTION_ATLAS</IconAtlas>
    </Row>
  </Builds>

  
  <BuildFeatures>
    <Row>
      <BuildType>BUILD_TESTING</BuildType>
      <FeatureType>FEATURE_FOREST</FeatureType>
      <Time>100</Time>
      <Remove>false</Remove>
    </Row>
    <Row>
      <BuildType>BUILD_TESTING</BuildType>
      <FeatureType>FEATURE_JUNGLE</FeatureType>
      <Time>200</Time>
      <Remove>false</Remove>
    </Row>    
  </BuildFeatures>
  

  <Unit_Builds>
    <Row>
      <UnitType>UNIT_WORKER</UnitType>
      <BuildType>BUILD_TESTING</BuildType>
    </Row>
  </Unit_Builds>

</GameData>

Any help would be appreciated.
 
Ekmek helped me find the solution here.

Basically, in Mod Buddy, on the Mod Info tab, there are systems checkboxes that need to be checked. 'Reload Landmark System' needs to be enabled for the model to appear.
 
Top Bottom