Civilization IV Custom Civilization Modding Trouble

BonafideDog

Chieftain
Joined
Aug 13, 2020
Messages
33
So I've been trying fruitlessly for a few days just to add a simple custom civilization into Civ IV BtS but even using a bunch of different guides I've been hitting no end of roadblocks and can't figure out what I'm doing wrong. I've exhausted every possible search and was hoping someone here with more experience than myself could help.

Currently, I'm as far as choosing the music, art files, and have messed around with the XML extensively but still can't get anywhere. My problem is that I have edited my civ into the CivInfos, inserted my civ's ai into LeaderHeadInfos, and even managed to link the models and animations of a unique unit. The problem I have is that whenever I boot up my mod from BtS it looks exactly like the base game and nothing related to the mod shows up. Can anyone more experienced with XML help me? For reference, I've been using this guide: https://forums.civfanatics.com/threads/how-to-create-a-civilization-in-bts.348539/

And here's my mod as is:
Thanks a ton in advance.

Moderator Action: Moved to C&C for modding help. leif
 

Attachments

  • Andy Civ 2.0.zip
    509.9 KB · Views: 34
  • Andy Civ 2.0.zip
    509.9 KB · Views: 31
Last edited by a moderator:
Oh, you made it modular, that's the problem. So open the config file Andy Civ.ini and change
PHP:
[CONFIG]

; Modular XML Loading
ModularLoading = 0
to
PHP:
[CONFIG]

; Modular XML Loading
ModularLoading = 1
 
I d
Oh, you made it modular, that's the problem. So open the config file Andy Civ.ini and change
PHP:
[CONFIG]

; Modular XML Loading
ModularLoading = 0
to
PHP:
[CONFIG]

; Modular XML Loading
ModularLoading = 1
I did that and the mod loaded, I know that because an erroneous file (alter) failed to load. The rest if the mods content still didn't show up though?
 
I d

I did that and the mod loaded, I know that because an erroneous file (alter) failed to load. The rest if the mods content still didn't show up though?
I didn't load up because for your civlization Alter there is no art, Unique Unit, and Unique Building.
There are at least 5 more files you have to add, the CIV4CivlizationScheme.xml, the CIV4ArtDefinesCivilizations.xml, the CIV4ArtDefinesScheme.xml, and if you want the civ to have a custom UU and or UB also the CIV4UnitInfos.xml, unit scheme, Building infos.xml, and the BuildingInfosscehem.xml and you also need the art.
upload_2021-1-15_10-1-59.png
 
I did a bunch of work on it to make it resemble another mod in the same format and I've fixed most of the issues like missing artwork. My new problem is there's an issue with the XMl (I think) I can't track down that makes it crash before it can open the mod. I'm restructuring the whole thing again but thanks for your suggestions. As far as I know in my new version most everything is there
 
I did a bunch of work on it to make it resemble another mod in the same format and I've fixed most of the issues like missing artwork. My new problem is there's an issue with the XMl (I think) I can't track down that makes it crash before it can open the mod. I'm restructuring the whole thing again but thanks for your suggestions. As far as I know in my new version most everything is there
Ah yes, making even the smallest mistake in XML can cause a lot of problems. Usually when my for me it doesn't work or it crashes without giving an error I check every single XML file I edited and make sure I didn't accidentally press a key on my keyboard or made a spelling mistake. Or if you didn't do that much modding to your mod and think you can restart without losing too much time you could restart.
 
Hi BonafideDog there's some great, easy to use checking tools available in the utilities section that output in an easy - to - cope - with manner. I recommend civcheck and xmlvalidator.
 
Hi BonafideDog there's some great, easy to use checking tools available in the utilities section that output in an easy - to - cope - with manner. I recommend civcheck and xmlvalidator.
I have been using a debug DLL but for some reason my current version keeps crashing at Init XML (Uncached) even though another person says my mod worked for them. My current version is in another thread. The DLL hasn't given me any pop-ups yet, would these work in it's stead?
 
Sorry you've just moved beyond my pay grade! If it's failing to initialize then these simple tag/art file checkers are no use ... sorry boss. OK, if it's an xml problem, try:
1. using civchecker/ xmlvalidator to iron out any errors
... runup
2. if that still doesn't work launch a vanilla game, then add test xml files one by one and see which crashes on runup
3. i've never really read a guide/used anything more complex than files directly dumped in customassets. i recently switched on debug logging, this helped with python errors but didn't really point out xml problems ... crashes take place before the errors are recorded, you could try this ... but first check your existing xml files don't have any problems. Civchecker has issues in that: (i) it skips past alphanumeric strings, including strings with [space] in, so i'd start by changing all the xml tags that read GAME_OBJECT_1 to GAME_OBJECT_ONE for clarity.
4. iffy art files can cause ctd, ahead of being viewed in the 'pedia/ before you run up the game, so test every new art file you add ... they might be fine in the 'pedia too but if you've done something horrible too them, or assigned the wrong anim set, cause ctd
5. finally, i'm a total amateur don't read guides, never learn anything unless it's accompanied by threats - but i do have great legs. You could try contacting tantanmen, who works with mods, and is terribly bright, also sword-of-geddon knows his onions. Both are older than the universe itself and wise beyond our mortal kenning.
 
Problem:
Code:
            <DerivativeCiv>AMERICA</DerivativeCiv>
            <CivilizationSelectionSound>AS3D_AMERICA_SELECT</CivilizationSelectionSound>
            <CivilizationActionSound>AS3D_AMERICA_ORDER</CivilizationActionSound>
        </CivilizationInfo>
    </CivilizationInfos>
<Civ4CivilizationInfos>
Solution:
Code:
            <DerivativeCiv>CIVILIZATION_AMERICA</DerivativeCiv>
            <CivilizationSelectionSound>AS3D_AMERICA_SELECT</CivilizationSelectionSound>
            <CivilizationActionSound>AS3D_AMERICA_ORDER</CivilizationActionSound>
        </CivilizationInfo>
    </CivilizationInfos>
</Civ4CivilizationInfos>
See if that helps.

EDIT:

Plus there are no BUILDING_ANTHRAXIAN_OPPRESSION_DOME building defined anywhere. Same goes for UNIT_ANTHRAXIAN_AUSLANDER unit.

Other problem:
Code:
<ImprovementType>IMPROVEMENT_FARM</ImprovementType>
                    <iWeightModifier>20</iWeightModifier>
                </ImprovementWeightModifier>
                <ImprovementWeightModifier>
                    <ImprovementType>IMPROVEMENT_MINE</ImprovementType>
                    <iWeightModifier>20</iWeightModifier>
                </ImprovementWeightModifier>
                <ImprovementWeightModifiers/>

Solution:
Code:
            <ImprovementWeightModifiers>
                <ImprovementWeightModifier>
                <ImprovementType>IMPROVEMENT_FARM</ImprovementType>
                    <iWeightModifier>20</iWeightModifier>
                </ImprovementWeightModifier>
                <ImprovementWeightModifier>
                    <ImprovementType>IMPROVEMENT_MINE</ImprovementType>
                    <iWeightModifier>20</iWeightModifier>
                </ImprovementWeightModifier>
            </ImprovementWeightModifiers>
 
Last edited:
Top Bottom