[BNW] Unit not showing up on tech tree

Ginfade

Chieftain
Joined
Jan 18, 2020
Messages
2
I just started modding and I’ve tried making a new unit for my civ, but I can’t see it on the tech tree. How do I fix that?
 
  1. It's better to just take the mod from the game's MODS folder, zip it, and attach the result directly to a post. It is far easier to look at your actual code and the actual structure of the mod as it is being seen by the game than any attempt to determine what you are doing wrong by analyzing descriptions of the problem, or out-of-context snippets of the code.
  2. Very often what a new modder thinks the problem is and what the problem actually is are two different things. Having the actual mod as you are currently trying to use it allows us to look for the actual problem, and if all else fails to simply drop the mis-behaving mod into our MODS folder and run the mod to see what the game tells us.
  3. Zip the version of the mod the game is actually trying to use, which will be found as a sub-folder in ~\Documents\My Games\Sid Meier's Civilization 5\MODS. Zip the whole sub-folder for your mod.
  4. See: whoward69's zip your mods and attach tutorial Just bear in mind that the process for actually adding the zip to a forum post is now different since the CFC website software was updated a few months ago about a year ago. To attach the zip to a forum post, look for a button called Upload A File when composing your thread reply: this button opens a browse menu where you can select the zipped folder to attach directly to a forum post.
  5. If the zipped folder is too large for the forum to accept then upload the zipped mod to a file-sharing site such as dropbox and provide a link where the mod can be downloaded.
    • Mediafire is not really a very good choice any more because they have become rife with spam and malware, as well as attempts to get you to download unwanted and uneeded kludge by confusing the layout of the download pages. You'll note for example that Mediafire links are no longer allowed on Steam, whereas CFC (this site) and dropbox links are still allowed.
 
… Just bear in mind that the process for actually adding the zip to a forum post is now different

I updated my post to reflect that several months back … just so you didn't have to keep typing that :)
 
  1. It's better to just take the mod from the game's MODS folder, zip it, and attach the result directly to a post. It is far easier to look at your actual code and the actual structure of the mod as it is being seen by the game than any attempt to determine what you are doing wrong by analyzing descriptions of the problem, or out-of-context snippets of the code.
  2. Very often what a new modder thinks the problem is and what the problem actually is are two different things. Having the actual mod as you are currently trying to use it allows us to look for the actual problem, and if all else fails to simply drop the mis-behaving mod into our MODS folder and run the mod to see what the game tells us.
  3. Zip the version of the mod the game is actually trying to use, which will be found as a sub-folder in ~\Documents\My Games\Sid Meier's Civilization 5\MODS. Zip the whole sub-folder for your mod.
  4. See: whoward69's zip your mods and attach tutorial Just bear in mind that the process for actually adding the zip to a forum post is now different since the CFC website software was updated a few months ago about a year ago. To attach the zip to a forum post, look for a button called Upload A File when composing your thread reply: this button opens a browse menu where you can select the zipped folder to attach directly to a forum post.
  5. If the zipped folder is too large for the forum to accept then upload the zipped mod to a file-sharing site such as dropbox and provide a link where the mod can be downloaded.
    • Mediafire is not really a very good choice any more because they have become rife with spam and malware, as well as attempts to get you to download unwanted and uneeded kludge by confusing the layout of the download pages. You'll note for example that Mediafire links are no longer allowed on Steam, whereas CFC (this site) and dropbox links are still allowed.
here is the mod, it is essentially redesigning venice, although a lot of it isn't working. the main thing I am concerned about is getting the unique unit to work, I want a normal galleass that can move through ocean.
 

Attachments

Code:
  <Civilization_UnitClassOverrides>
    <Row>
      <CivilizationType>CIVILIZATION_FN_VENICE</CivilizationType>
      <UnitClassType>UNITCLASS_GALLEASS</UnitClassType>
      <UnitType>UNIT_FN_VENICE_GREAT_GALLEASS</UnitType>
    </Row>
  </Civilization_UnitClassOverrides>
As compared to
Code:
  <Units>
    <Row>
		<Type>UNIT_FN_VENICE_GREAT_GALLEASS</Type>
                   ……………………………..
		<Class>UNITCLASS_FN_VENICE_GREAT_GALLEASS</Class>
There's no such UnitClass as UNITCLASS_FN_VENICE_GREAT_GALLEASS.

Nor does the following exist as an ArtDef
Code:
<UnitArtInfo>ART_DEF_UNIT_FN_VENICE_GREAT_GALLEASS</UnitArtInfo>

Leader LEADER_ENRICO_DANDOLO already exists within the game. You cannot therefore attempt to add a second version of LEADER_ENRICO_DANDOLO. The game rejects the entire contents of the XML file where this is attempted.

You custom Improvement has no associated "Build". This results in an unconstructable Terrain Improvement. See this as an example of how to copy the existing Polder and its art-define into a new custom Improvement:
Spoiler :
Code:
	<Improvements>
		<Row>
			<Type>IMPROVEMENT_POLDER2</Type>
			<Description>TXT_KEY_IMPROVEMENT_POLDER</Description>
			<Civilopedia>TXT_KEY_CIV5_IMPROVEMENTS_POLDER_TEXT</Civilopedia>
			<Help>TXT_KEY_CIV5_IMPROVEMENTS_POLDER_HELP</Help>
			<ArtDefineTag>ART_DEF_IMPROVEMENT_POLDER</ArtDefineTag>
			<RequiresFeature>true</RequiresFeature>
			<SpecificCivRequired>true</SpecificCivRequired>
			<CivilizationType>CIVILIZATION_AMERICA</CivilizationType>
			<PillageGold>18</PillageGold>
			<PortraitIndex>0</PortraitIndex>
			<IconAtlas>EXPANSION_TERRAIN_ATLAS</IconAtlas>
		</Row>
	</Improvements>
	<Improvement_TechYieldChanges>
		<Row>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<TechType>TECH_ECONOMICS</TechType>
			<YieldType>YIELD_PRODUCTION</YieldType>
			<Yield>1</Yield>
		</Row>
		<Row>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<TechType>TECH_ECONOMICS</TechType>
			<YieldType>YIELD_GOLD</YieldType>
			<Yield>2</Yield>
		</Row>
	</Improvement_TechYieldChanges>
	<Improvement_ValidFeatures>
		<Row>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<FeatureType>FEATURE_MARSH</FeatureType>
		</Row>
		<Row>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<FeatureType>FEATURE_FLOOD_PLAINS</FeatureType>
		</Row>
	</Improvement_ValidFeatures>
	<Improvement_Yields>
		<Row>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<YieldType>YIELD_FOOD</YieldType>
			<Yield>3</Yield>
		</Row>
	</Improvement_Yields>
	<Builds>
		<Row>
			<Type>BUILD_POLDER2</Type>
			<PrereqTech>TECH_GUILDS</PrereqTech>
			<Time>700</Time>
			<ImprovementType>IMPROVEMENT_POLDER2</ImprovementType>
			<Description>TXT_KEY_BUILD_POLDER</Description>
			<Recommendation>TXT_KEY_BUILD_FOOD_REC</Recommendation>
			<EntityEvent>ENTITY_EVENT_IRRIGATE</EntityEvent>
			<HotKey>KB_E</HotKey>
			<OrderPriority>98</OrderPriority>
			<IconIndex>0</IconIndex>
			<IconAtlas>EXPANSION_UNIT_ACTION_ATLAS</IconAtlas>
		</Row>
	</Builds>
	<Unit_Builds>
		<Row>
			<UnitType>UNIT_WORKER</UnitType>
			<BuildType>BUILD_POLDER2</BuildType>
		</Row>
	</Unit_Builds>

See whoward69's enable error logging tutorial Follow the procedures shown therein to enable error logging and then examine the error messages you are likely getting in file Database.log.
 
Back
Top Bottom