Imperialism Mod

Hmmm...

Ok something is causing the XML to crash.. no error just crash.. That usually means a , in the art defines, but I haven't touched any art defines yet...

Two other possibilities..

It doesn't like YIELD_GOLD as a consumption for professions, or it doesn't like : in text names of things...

I don't know..

Ok now it works...

I THINK it was because I had a text entry that was repeated several times, got rid of the extras and it loaded..
 
Night, with the unit consumption code, where they would buy goods for gold locally, is this currently still functional?
It worked the last time I checked. Nobody removed it, but I have to admit I don't go around verifying if the DLL can still handle features, which can't be reached ingame due to xml setup.

I am not sure how it all worked in the first place, I think Kail changed it so that you had to have a merchant working in a market place and then each merchant could set X goods for sale... I can't remember...
I set it up to limit the number of traded yields to 2/turn (set in xml). This number can then be increased by buildings/techs/civics (can't remember which). We didn't agree that it was a good design and might be subject to change. I don't remember anything about this being affected by assigning units to work as merchants.

Anyway, the reason I ask is I am going to try an experiment where a lot of the yields (particularly virtual ones) will require gold to build, as a kind of 'Upkeep' so I was wanting to reintroduce the small constant stream of cash from domestic sales.
I'm not sure what you are doing, but I kind of suspect you are trying to do something the code wasn't designed to handle. It might work in most cases, but what if you consume 5 gold when the player has 2?

I'm not saying you shouldn't experiment, but we might need DLL updates to get it to work precisely as you imagine it will work. Don't say you haven't been warned that it could be problematic to use virtual yields as profession input or whatever you are doing.
 
The only online source I can think of offhand, which would be easily available online would be this one: https://www.youtube.com/watch?v=xFQ-f1Ax_Pg&list=PLBwC0sil0vDlO828OYQfPiSBHivdePxNK

I haven't watched it in years or even all the episodes (I think it had 20 when I saw it). However from what I remember, it is rather decent for providing an overview of important technological advances and their effects. Being an overview, it can provide some of the info we need and it can provide hints for what to search for to provide other info we need. Some things are better explained than others and some are mentioned very briefly.
 
Cool I shall take a look!
(Oh it's Industrial Revelations! I know that show! :D)

Brief explanations would be all that are needed for now, until a point where we want to turn the pedia into a historical education! :D

I will sit down and maybe have a watch when it comes time to tech tree and expand the building roster. I won't touch techs until civeffects is finished though. So for a while medeval technolgies will be discovering some rather peculiar things!

I have done a first pass on the names of buildings, now I have to go through and change their effects to continue to make sense!
(most of them actually look pretty good already)

Except I need to change the Military Admin buildings into Colonial Admin buildings so that they boost production to colonial yields instead of weapons and now confusingly wood products! :D

I also just split the Monk/Missionary Profession into a Rural Recruiter(Missionary) and Rural Settler (Monastery Founder) and now the Monastery will be a Rural Settlement, good for all things raw resourcey!

I think VIE may just work out as having some cool new gameplay style! :D

Buildings are 'done' for now.

Last Stop...... Unit Names and skills! Plus i need to add the Victoria PoP Types.
 
It is the idea that this mod would be on a world map right? I'd get myself Civ4Col if you guys pull this off. :b:
 
in essence yes, it would probably be something of a scenario map to begin with, then if we could fix it a more random 'four continent' map. With a Europe, Africa, Asia, America, type setup.

Everything is already technically possible, M:C is a 'Europe Empire' based mod, as opposed to a colonial mod. So there is no technical block to it. (Other than waiting for a few bits of awesome code to be finished.) We just need to do all the leg work with it.
 
OK!

I am officially exhausted!

But before I leave you all to curl up in a ball for the foreseeable future, I leave this test build for any brave soul willing to pick up the gauntlet and drive it further upon this quest!

It is Incredibly rough and unfinished by a LONG way!

Here's what we have so far:

Names:
Buildings
Yields
Professions
Some Units

Art:
Yields

New Content:
Some New Victoria PoP inspired units with some very specific work skill sets (No art yet)
3 New Continental Terrains (Africa, America, Asia) each with a unique yield.
Terrain: Terrains have had their yield outputs changed somewhat (This still needs work as I don't fully understand how some things in terrain work. Like Hills)
Some buildings have had there effects changed(needs more work I think)

I think that might be it.... Doesn't feel like much for a whole weekend, but I am pretty sure there is about 20 hours of work done. (Though my pace is probably rubbish!)

Victorian Imperial Empires Test Build Mk1
 
Ok so I have found a visual bug that I don't really understand the solution to, I think it is a gamefont thing.

In the 'what would you like to build list' for the city, the tooltip displays wood instead of tinned food graphic. I just don't know why... It seems to be the only one so far, and the only place!

Also my experiment in yield gold has discovered that it can't take gold from the 'bank' to spend as an input yield. I need to get a market and see if I can make gold from that pay upkeep (if it still does it, not sure).

Ok, so the gold yield works when it is produced and consumed in the same town. Interesting... I wonder if gold produced on the same turn can be shared across a plot group...either way I may have just found a potential and important use for clerks or Capitalists, or both. Unfortunately I don't think I can change the input yield on a building... I wonder if the profession could change from building to building, so a small building uses Profession A, then a factory of the same type of yield requires profession B instead. Or 2 professions on the same building, one for unskilled people and another for skilled people, with the input yelds of the skilled person being different from the yield of the unskilled...hmmm
 
Yield icons are all stored in GameFont. The idea is that you download GameFontEditor and store the yield icons in the same order as they are stored in XML. However you don't have to redo the whole row if you make tiny xml changes (like adding a single yield). I added an xml tag to dictate the id and an ingame debug screen to get the id. I will look up the details on this system if/when it will be needed.

The first 4? rows have a bunch of unused icons. Do not clear those. They serve the purpose of ensuring the bullet icon having the correct ID as that ID is hardcoded in the exe, which mean clearing those unused icons will result in the wrong icon being used as bullet. That's an obscene unwritten limitation we just have to live with.

I'm not sure it's wise to deal with GameFont right now. Just ignore the issue.
 
Yeah I use gamefont editor, like I say it is just one yield and in one list, everywhere else it is fine.. just that one place it seems.

At some point I may go back and double check that the order of the font and font75 files are the same, to make sure I just didn't muddle up two somewhere, but I can't bovvered right now :D
 
Bad news...had some time to attempt to use this tutorial:

http://forums.civfanatics.com/showthread.php?t=317419

Extracted the Art assets from Civ4 Vanilla, Warlords, and BTS using this tool:

http://forums.civfanatics.com/showthread.php?t=136023

I downloaded NifSkope.
Block List and Block Details are checked.
Show Blocks in List is highlighted.

Problem is, I cannot find TeamColor.bmp as an NiSourceTexture in any of the *_fx files I looked at (machinegunner, artillery, etc.).

Dead stop for now.
 
Hello there I have been informed that you were trying to convert civ 4 units to colonization, unfortunately it does not involve mr house :(

Alright for this method your gonna need Blender, its nif tools, and nifskope.

In case you don't already have blender here is a link for all of the files you'll need to download to get it working properly:
http://niftools.sourceforge.net/wiki/Blender

For this example I'm going to use the vanilla artillery.

enclosed instruction book:
Spoiler :

1. Open your nif in nifskope, click on the mesh, expand the NiTextuingProperty node and copy the text of the decal0 texture node(its usually the last one)


2. Paste that text over the TeamColor.bmp text of the base texture node(its usually the first one) and save your nif.


3. Open up Blender, press A to select all, and press delete to delete your selection. We want to be working with a clean scene.


4. Click on the file tab, the import submenu, and the Netimmerse/Gamebyro button


5. navigate to where your nif is saved at and click on it


6. Click the restore default settings if you changed them for some reason. And then press ok to start the import.


7. Now your mesh/armature are in blender, we don't actually need to change it any way. So just click on the file tab, the export submenu, and the Netimmerse/Gamebyro button


8. The default settings are also good for exporting for the most part. Except for one minor thing. Make sure skin partition is turned ON for colonization. And turned OFF for civ 4. So in this case leave it turned on. And press the ok button.


9. And thats it your nif should be working in colonization now. Note that this does not include teamcolor and your mesh will have transparent bits. Never did figure out how to do that.

 
Hello there I have been informed that you were trying to convert civ 4 units to colonization, unfortunately it does not involve mr house :(

Alright for this method your gonna Blender, its nif tools, and nifskope.

In case you don't already have blender here is a link for all of the files you'll need to download to get it working properly:

Thank you VERY much, clanky4!
 
OK, so I have a weird situation when trying to remove units from the game.

I appear to be down to a last hurdle, which is something about UNITCLASS_NOBLE, INVENTOR and SLAVE in the gamefontinfos file... it is just a bunch of numbers in that file though?!

The game now loads ok, and the pedia seems stable, I have not tried playing yet though, so i have no idea what the consequences from that file might be... I guess if it comes to it I may just had to add back in those three units.
 
GameFontInfos xml requires you to enter the GameFont ID of the first (whatever) in each line. This mean if you enter 8700 for units, unit 0 will have 8700 and unit 42 will have 8742. However odds are that you did something wrong if you need to change that file. Also the game should play just fine even if that file is set incorrectly. It will provide wrong GameFont icons, but that's not a fatal error.


UNITCLASS_NOBLE has a hardcoded meaning in the DLL and I did something to allow not using it. However I can't remember the details of that offhand. If the game complains about a missing unit, then add that unit. You could set it to graphical only, which should prevent it from appearing ingame.
 
So in order to add a new unit you will need to open 4 files.

XML/Units/CIV4UnitInfos
XML/Units/CIV4UnitClassInfos
XML/Art/Civ4ArtDefines_Units
XML/Text/CIV4GameText_VIE_Units

We also need to add all the art elements, a folder of the units graphics, and a button, there are two types of button in Col., I think one is the standard button.
(with a border and background that you could pinch- from an equivalent bts unit or make, I have a button maker tool for gimp which I found on the forums and modified to help me in FTTW)
The CM version I think is a pic with a transparent background used on things like the city management screen, but the simplest thing is to just look at an existing example in a col. unit graphic folder and work on the basis of that!)

Then do the following:
CIV4UnitInfos:

Find a suitable entry that you can copy, for artillery to begin with probably something like the CATAPULT or TREBUCHET, for a Ship something like the KOGGE or COASTAL_TRADER.

Then you copy that whole entry between:
<UnitInfo>
</UnitInfo>

Like this:
Spoiler :
Code:
		<UnitInfo>
			<Type>UNIT_[COLOR="Red"]TREBUCHET[/COLOR]</Type>
			<Class>UNITCLASS_[COLOR="Red"]TREBUCHET[/COLOR]</Class>
			<UniqueNames/>
			<Special>NONE</Special>
			<Capture>NONE</Capture>
			<Combat>UNITCOMBAT_SIEGE</Combat>
			<Domain>DOMAIN_LAND</Domain>
			<DefaultUnitAI>UNITAI_OFFENSIVE</DefaultUnitAI>
			<DefaultProfession>NONE</DefaultProfession>
			<bNativesInvalid>1</bNativesInvalid>
			<bEuropeInvalid>0</bEuropeInvalid>
			<bColonialInvalid>0</bColonialInvalid>
			<Invisible>NONE</Invisible>
			<SeeInvisible>NONE</SeeInvisible>
			<Description>TXT_KEY_UNIT_[COLOR="Red"]CANNON[/COLOR]</Description>
			<Civilopedia>TXT_KEY_UNIT_[COLOR="Red"]CANNON[/COLOR]_PEDIA</Civilopedia>
			<Strategy>TXT_KEY_UNIT_[COLOR="Red"]CANNON[/COLOR]_STRATEGY</Strategy>
			<bGraphicalOnly>0</bGraphicalOnly>
			<bNoBadGoodies>0</bNoBadGoodies>
			<bOnlyDefensive>0</bOnlyDefensive>
			<bNoCapture>0</bNoCapture>
			<bQuickCombat>0</bQuickCombat>
			<bRivalTerritory>0</bRivalTerritory>
			<bMilitaryProduction>1</bMilitaryProduction>
			<bFound>0</bFound>
			<bInvisible>0</bInvisible>
			<bNoDefensiveBonus>1</bNoDefensiveBonus>
			<bCanMoveImpassable>0</bCanMoveImpassable>
			<bCanMoveAllTerrain>0</bCanMoveAllTerrain>
			<bFlatMovementCost>0</bFlatMovementCost>
			<bIgnoreTerrainCost>0</bIgnoreTerrainCost>
			<bMechanized>1</bMechanized>
			<bLineOfSight>0</bLineOfSight>
			<bHiddenNationality>0</bHiddenNationality>
			<bAlwaysHostile>0</bAlwaysHostile>
			<bTreasure>0</bTreasure>
			<bAnimal>0</bAnimal>
			<UnitClassUpgrades/>
			<UnitAIs>
				<UnitAI>
					<UnitAIType>UNITAI_OFFENSIVE</UnitAIType>
					<bUnitAI>1</bUnitAI>
				</UnitAI>
			</UnitAIs>
			<NotUnitAIs/>
			<Builds/>
			[COLOR="Lime"]<PrereqBuilding>BUILDINGCLASS_SIEGEWORKSHOP</PrereqBuilding>[/COLOR]
			<PrereqOrBuildings/>
			<ProductionTraits/>
			<iAIWeight>0</iAIWeight>
			[COLOR="Lime"]<YieldCosts>
				<YieldCost>
					<YieldType>YIELD_HAMMERS</YieldType>
					<iCost>200</iCost>
				</YieldCost>
				<YieldCost>
					<YieldType>YIELD_TOOLS</YieldType>
					<iCost>40</iCost>
				</YieldCost>
			</YieldCosts>[/COLOR]
			<iHurryCostModifier>0</iHurryCostModifier>
			<iAdvancedStartCost>-1</iAdvancedStartCost>
			<iAdvancedStartCostIncrease>0</iAdvancedStartCostIncrease>
			<iEuropeCost>800</iEuropeCost>
			<iEuropeCostIncrease>100</iEuropeCostIncrease>
			<iImmigrationWeight>0</iImmigrationWeight>
			<iImmigrationWeightDecay>0</iImmigrationWeightDecay>
			<iMinAreaSize>-1</iMinAreaSize>
			[COLOR="Lime"]<iMoves>1</iMoves>[/COLOR]
			<bCapturesCargo>0</bCapturesCargo>
			<iWorkRate>0</iWorkRate>
			<iWorkRateModifier>0</iWorkRateModifier>
			<iMissionaryRateModifier>0</iMissionaryRateModifier>
			<TerrainImpassables/>
			<FeatureImpassables/>
			<TerrainNatives/>
			<FeatureNatives/>
			<BonusNatives/>
			<EvasionBuildings/>
			[COLOR="Lime"]<iCombat>4</iCombat>[/COLOR]
			<iXPValueAttack>4</iXPValueAttack>
			<iXPValueDefense>2</iXPValueDefense>
			<iWithdrawalProb>0</iWithdrawalProb>
			[COLOR="Lime"]<iCityAttack>100</iCityAttack>
			<iCityDefense>50</iCityDefense>[/COLOR]
			<iHillsAttack>0</iHillsAttack>
			<iHillsDefense>0</iHillsDefense>
			<TerrainAttacks/>
			<TerrainDefenses/>
			<FeatureAttacks/>
			<FeatureDefenses/>
			<UnitClassAttackMods/>
			<UnitClassDefenseMods/>
			<UnitCombatMods/>
			<DomainMods/>
			<YieldModifiers/>
			<YieldChanges/>
			<BonusYieldChanges/>
			<bLandYieldChanges>1</bLandYieldChanges>
			<bWaterYieldChanges>1</bWaterYieldChanges>
			<YieldDemands/>
			[COLOR="Lime"]<iBombardRate>12</iBombardRate>[/COLOR]
			<SpecialCargo>NONE</SpecialCargo>
			<DomainCargo>NONE</DomainCargo>
			<iCargo>0</iCargo>
			<iRequiredTransportSize>1</iRequiredTransportSize>
			<iAsset>100</iAsset>
			<iPower>300</iPower>
			<iNativeLearnTime>-1</iNativeLearnTime>
			<iStudentWeight>0</iStudentWeight>
			<iTeacherWeight>0</iTeacherWeight>
			<iTeachLevel>0</iTeachLevel>
			<iAnimalPatrolWeight>-1</iAnimalPatrolWeight>
			<iAnimalAttackWeight>-1</iAnimalAttackWeight>
			<ProfessionMeshGroups>
				<UnitMeshGroups>
					<ProfessionType>NONE</ProfessionType>
					<fMaxSpeed>1.25</fMaxSpeed>
					<fPadTime>1</fPadTime>
					<iMeleeWaveSize>1</iMeleeWaveSize>
					<iRangedWaveSize>1</iRangedWaveSize>
					<UnitMeshGroup>
						<iRequired>1</iRequired>
						<ArtDefineTag>ART_DEF_UNIT_[COLOR="Red"]TREBUCHET[/COLOR]</ArtDefineTag>
					</UnitMeshGroup>
				</UnitMeshGroups>
			</ProfessionMeshGroups>
			<FormationType>FORMATION_TYPE_MACHINE</FormationType>
			<HotKey/>
			<bAltDown>0</bAltDown>
			<bShiftDown>0</bShiftDown>
			<bCtrlDown>0</bCtrlDown>
			<iHotKeyPriority>0</iHotKeyPriority>
			<FreePromotions/>
			<LeaderPromotion>NONE</LeaderPromotion>
			<iLeaderExperience>0</iLeaderExperience>
			<ProfessionsNotAllowed/>
			<KnightDubbingWeight>0</KnightDubbingWeight>
			<iCasteAttribute>0</iCasteAttribute>
			<bPreventFounding>0</bPreventFounding>
			<bPreventTraveling>0</bPreventTraveling>
			<EducationUnitClass>NONE</EducationUnitClass>
			<RehibilitateUnitClass>NONE</RehibilitateUnitClass>
			<LaborForceUnitClass>NONE</LaborForceUnitClass>
			<iTradeBonus>0</iTradeBonus>
			<ConvertsToYield>NONE</ConvertsToYield>
			<ConvertsToBuildingClass>NONE</ConvertsToBuildingClass>
			<ConvertsToGold>0</ConvertsToGold>
		</UnitInfo>

Then modify the text in red to match your new unit e.g. FIELD_ARTILLERY

We can worry about changing the stats of the unit later, but some of the important lines are highlighted in green. (At least for artillery)

Next we move to:
CIV4UnitClassInfos:
Spoiler :
Code:
		<UnitClassInfo>
			<Type>UNITCLASS_[COLOR="Red"]WELLBORN[/COLOR]</Type>
			<Description>[COLOR="Red"]Field Artillery[/COLOR]</Description>
			<DefaultUnit>UNIT_[COLOR="Red"]WELLBORN[/COLOR]</DefaultUnit>
		</UnitClassInfo>

These file seems to be pretty much redundant in Col, in bts it has some important unit amount definitions but they don't seem to be present in M:C and I don't know if they exist in Col. at all... I have no idea what the description is used for, or what it may or may not take priority over in terms of unit names..

Again change the red words to match the unitinfo file e.g. FIELD_ARTILLERY

Next:
Civ4ArtDefines_Units:
Again we copy everything between the <UnitArtInfo> and </UnitArtInfo>
Spoiler :
Code:
<UnitArtInfo>
			<Type>ART_DEF_UNIT_[COLOR="Red"]CATAPULT[/COLOR]</Type>
			<Button>Art/Buttons/Units/[COLOR="Lime"]catapult[/COLOR].dds</Button>
			<FullLengthIcon>Art/Interface/Buttons/Units/[COLOR="Lime"]catapultCM[/COLOR].dds</FullLengthIcon>
			<fScale>0.65</fScale>
			<fInterfaceScale>0.7</fInterfaceScale>
			<NIF>Art/Units/[COLOR="Lime"]catapult/catapult_fx[/COLOR].nif</NIF>
			<KFM>Art/Units/[COLOR="Lime"]catapult/catapult[/COLOR].kfm</KFM>
			<TrailDefinition>
				<Texture>Art/Shared/wheeltread.dds</Texture>
				<fWidth>1.0</fWidth>
				<fLength>180.0</fLength>
				<fTaper>0.0</fTaper>
				<fFadeStartTime>0.2</fFadeStartTime>
				<fFadeFalloff>0.35</fFadeFalloff>
			</TrailDefinition>
			<fBattleDistance>0.5</fBattleDistance>
			<fRangedDeathTime>0.31</fRangedDeathTime>
			<bActAsRanged>1</bActAsRanged>
			<TrainSound>AS2D_UNIT_BUILD_UNIT</TrainSound>
			<AudioRunSounds>
				<AudioRunTypeLoop>LOOPSTEP_WHEELS</AudioRunTypeLoop>
				<AudioRunTypeEnd>ENDSTEP_WHEELS</AudioRunTypeEnd>
			</AudioRunSounds>
		</UnitArtInfo>
Change the red parts to match the unit entry you made, for the other parts it is matching it up to the relevant graphic file paths. The two button types .dds, a .nif and .kfm file. These are usually pretty easy to pick out in a unit graphic folder from the forums. (How they work is above my pay grade)

Then Finally we change:
CIV4GameText_VIE_Units:
The text is grouped into 3 parts, the name, the pedia and the strategy. the pedia text appears in the pedia box, and the strategy text may appear in the pedia and also in a pop up box on the build selection screen I think (If it is like Bts).
Spoiler :
Code:
	<TEXT>
		<Tag>TXT_KEY_UNIT_[COLOR="Red"]CAPITALIST[/COLOR]</Tag>
		<English>[COLOR="Red"]Field Artillery[/COLOR]</English>
	</TEXT>
	<TEXT>
		<Tag>TXT_KEY_UNIT_[COLOR="Red"]CAPITALIST[/COLOR]_PEDIA</Tag>
		<English>[COLOR="Red"]Historically Field Artillery go bang![/COLOR]</English>
	</TEXT>
	<TEXT>
		<Tag>TXT_KEY_UNIT_[COLOR="Red"]CAPITALIST[/COLOR]_STRATEGY</Tag>
		<English>[COLOR="Red"]Use them to make other things go splat![/COLOR]</English>
	</TEXT>

And fingers crossed when you load the game you have a new unit in the unit section and no nasty XML errors!
 
Top Bottom