1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Question about adding new terrain

Discussion in 'Civ4 - Creation & Customization' started by Yoda Power, Jun 25, 2017.

  1. Yoda Power

    Yoda Power ✫✫✫✫✫✫✫

    Joined:
    Sep 24, 2002
    Messages:
    13,866
    Hi there.

    I would like to add a new Wetlands or Marsh terrain to my personal mod like the one I've seen in various other mods. I'm not sure how to do it though. But before I figure that out I have a question:

    Will it appear in random generated maps with the existing map scripts? There's not much fun adding a new terrain if it won't show up in game.

    I'm not very experienced modding Civ4.

    Thanks in advance.
     
  2. ChaosSlayer

    ChaosSlayer Chieftain

    Joined:
    Feb 3, 2011
    Messages:
    587
    from personal experience to add Features like forests is very simple and I added plenty.
    So in my mod Marsh being a feature, you just add graphic reference to CIV4ArtDefines_Feature, and data about feature itself to CIV4FeatureInfos which also determines their appearance on the map based on which terrain type you assign them to.

    As far as adding base terrain types (like new grasslands or something) they may have to be added in map script generation files which I haven't yet figured out.
     
  3. Yoda Power

    Yoda Power ✫✫✫✫✫✫✫

    Joined:
    Sep 24, 2002
    Messages:
    13,866
    Thank you. I did mean as a base terrain, but I may opt for adding it as a feature as you propose if it's easier. :) What graphic do you use for the Marsh feature?

    So let me rephrase. Does added base terrains show up in random generated maps? I'm also considering adding more terrains.

    EDIT: I tried adding in the Marsh feature from the Sword of Islam mod. It does not show up when I generate a map with the Hemipheres script. But I can place it with the World Builder.
     
    Last edited: Jun 25, 2017
  4. ChaosSlayer

    ChaosSlayer Chieftain

    Joined:
    Feb 3, 2011
    Messages:
    587
    for Marsh feature - I pull it from Realism Evictus mod.
    From there I also pulled Fertile Soil, also Islands and Reefs for the ocean terrain.


    New Base terrain needs to be added to the map generator script engine and given a % and geographical range or otherwise it won't show up.
    But I never done ;) Someone else may know the details.
     
  5. Yoda Power

    Yoda Power ✫✫✫✫✫✫✫

    Joined:
    Sep 24, 2002
    Messages:
    13,866
    How did you get the features to show up though? I've just run several tests.

    Maybe someone can answer how base terrain is added to script? :)
     
  6. ChaosSlayer

    ChaosSlayer Chieftain

    Joined:
    Feb 3, 2011
    Messages:
    587
    My new features show up just fine. Make sure to assign them to proper terrains.

    Here is my new feature from CIV4FeatureInfos

    Spoiler :



    <FeatureInfo>
    <Type>FEATURE_SWAMP</Type>
    <Description>TXT_KEY_FEATURE_SWAMP</Description>
    <Civilopedia>TXT_KEY_FEATURE_SWAMP_PEDIA</Civilopedia>
    <ArtDefineTag>ART_DEF_FEATURE_SWAMP</ArtDefineTag>
    <YieldChanges>
    <iYieldChange>-1</iYieldChange>
    <iYieldChange>-1</iYieldChange>
    <iYieldChange>0</iYieldChange>
    </YieldChanges>
    <RiverYieldChange>
    <iYield>0</iYield>
    <iYield>0</iYield>
    <iYield>0</iYield>
    </RiverYieldChange>
    <HillsYieldChange/>
    <iMovement>3</iMovement>
    <iSeeThrough>1</iSeeThrough>
    <iHealthPercent>-100</iHealthPercent>
    <iDefense>-25</iDefense>
    <iAppearance>1000</iAppearance>
    <iDisappearance>0</iDisappearance>
    <iGrowth>0</iGrowth>
    <iTurnDamage>0</iTurnDamage>
    <bNoCoast>1</bNoCoast>
    <bNoRiver>0</bNoRiver>
    <bNoAdjacent>0</bNoAdjacent>
    <bRequiresFlatlands>1</bRequiresFlatlands>
    <bRequiresRiver>0</bRequiresRiver>
    <bAddsFreshWater>0</bAddsFreshWater>
    <bImpassable>0</bImpassable>
    <bNoCity>1</bNoCity>
    <bNoImprovement>0</bNoImprovement>
    <bVisibleAlways>0</bVisibleAlways>
    <bNukeImmune>0</bNukeImmune>
    <OnUnitChangeTo/>
    <TerrainBooleans>
    <TerrainBoolean>
    <TerrainType>TERRAIN_GRASS</TerrainType>
    <bTerrain>1</bTerrain>
    </TerrainBoolean>
    <TerrainBoolean>
    <TerrainType>TERRAIN_TUNDRA</TerrainType>
    <bTerrain>1</bTerrain>
    </TerrainBoolean>
    </TerrainBooleans>
    <FootstepSounds>
    <FootstepSound>
    <FootstepAudioType>FOOTSTEP_AUDIO_HUMAN</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_FOOT_UNIT_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>FOOTSTEP_AUDIO_HUMAN_LOW</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_FOOT_UNIT_LOW_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>FOOTSTEP_AUDIO_ANIMAL</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_ANIMAL_FOOT_LARGE_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>FOOTSTEP_AUDIO_ANIMAL_LOW</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_ANIMAL_FOOT_LARGE_LOW_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>FOOTSTEP_AUDIO_HORSE</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_HORSE_RUN_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_WHEELS</FootstepAudioType>
    <FootstepAudioScript/>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_WHEELS</FootstepAudioType>
    <FootstepAudioScript/>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_WHEELS_2</FootstepAudioType>
    <FootstepAudioScript/>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_WHEELS_2</FootstepAudioType>
    <FootstepAudioScript/>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_TANK</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_TANK_LOOP_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_TANK</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_TANK_END_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_MOD_ARMOUR</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_MOD_ARMOUR_LOOP_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_MOD_ARMOUR</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_MOD_ARMOUR_END_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_ARTILLERY</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_ARTILL_RUN_LOOP_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_ARTILLERY</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_ARTILL_RUN_END_FOREST</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>LOOPSTEP_WHEELS_3</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_TREBUCHET_RUN_LEAVES</FootstepAudioScript>
    </FootstepSound>
    <FootstepSound>
    <FootstepAudioType>ENDSTEP_WHEELS_3</FootstepAudioType>
    <FootstepAudioScript>AS3D_UN_TREBUCHET_STOP_LEAVES</FootstepAudioScript>
    </FootstepSound>
    </FootstepSounds>
    <WorldSoundscapeAudioScript></WorldSoundscapeAudioScript>
    <EffectType>NONE</EffectType>
    <iEffectProbability>0</iEffectProbability>
    <iAdvancedStartRemoveCost>0</iAdvancedStartRemoveCost>
    </FeatureInfo>


     
  7. Yoda Power

    Yoda Power ✫✫✫✫✫✫✫

    Joined:
    Sep 24, 2002
    Messages:
    13,866
    I copied your settings and it worked! Thank you! :D

    So far so good. Now I just need to figure out how to add base terrain to the script.
     

Share This Page