Modular unit's building dependency doen't work?

tucoow

Chieftain
Joined
May 1, 2008
Messages
52
Location
A pasture, somewhere GMT+8
Sorry I have to post another thread before previous question gets answer. :)

My units worked fine before modular; but their dependency to a world wonder "drop down" to another one after I made them modular.

Here's my folder structure(here use one unit MULCARN as example; I have other similar units like GAINT SPIDER, DRIFA etc:))

the unit Mulcarn: a "world unit", requires meditation and resource Gold, requires a world wonder "the Stag Hide":
D:\Program Files (x86)\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\Shen Hua World\Assets\modules\ShenHua\Mulcarn\
Mulcarn_CIV4ArtDefinesSchema.xml
Mulcarn_CIV4UnitSchema.xml
MULCARN_CIV4ArtDefines_Unit.xml
MULCARN_CIV4UnitInfos.xml
Code:
<Civ4UnitInfos xmlns="x-schema:Mulcarn_CIV4UnitSchema.xml">
    <UnitInfos>
        <UnitInfo>
            <Class>UNITCLASS_MULCARN</Class>
            <Type>UNIT_MULCARN</Type>
            ...
            <PrereqBuilding>BUILDINGCLASS_STAG_HIDE</PrereqBuilding>
            <PrereqTech>TECH_MEDITATION</PrereqTech>
            ...
MULCARN_CIV4UnitClassInfos.xml
and other MULCARN art files of course

the world wonder "Stag Hide"(3 allowed, because I want other CIVs have counterpart units to compete): require meditation:
D:\Program Files (x86)\Firaxis Games\Sid Meier's Civilization 4\Beyond the Sword\Mods\Shen Hua World\Assets\modules\ShenHua\Stag Hide\
Stag Hide_CIV4ArtDefinesSchema.xml
Stag Hide_CIV4BuildingsSchema.xml
Stag Hide_CIV4BuildingInfos.xml
Code:
<Civ4BuildingInfos xmlns="x-schema:Stag Hide_CIV4BuildingsSchema.xml">
    <BuildingInfos>
        <BuildingInfo>
            <BuildingClass>BUILDINGCLASS_STAG_HIDE</BuildingClass>
            <Type>BUILDING_STAG_HIDE</Type>
            ...
            <PrereqTech>TECH_MEDITATION</PrereqTech>
            ...
Stag Hide_CIV4ArtDefines_Building.xml
Stag Hide_CIV4BuildingClassInfos.xml
and other Stag Hide art files

In the game I found that Mulcarn (and GAINT SPIDER, DRIFA etc) requires Angkor Wat rather than Stag Hide. They worked fine when I build them in CustomAssets(not modular).

I wonder whether the space between "Stag" and "Hide" can do harm?

Any one can help? Thanks.
 
Tryied placing the building XML in CustomAssets, but no really work...
Somebody has any idea? Does the game loads modules in some order and how to control it?
 
This is a flaw in how Firaxis did Modular Loading. Take a look at the World of Civilization (WoC) base to get better Modular Loading capabilities.

The short of it is that the method in which files are loaded cause the majority of all references to another file (all the same file and anything loaded after it) to fail in Modular Loading. This problem will appear in numerous non-numeric fields throughout the XML
 
Back
Top Bottom