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

[Map Script] Planet Generator

Discussion in 'Civ4 - Map Scripts' started by Nercury, Aug 5, 2006.

  1. bonniee

    bonniee Chieftain

    Joined:
    Nov 14, 2008
    Messages:
    2
    Location:
    doodah
    <sigh> I'm running 2 gig ram on Win XP with a generic system
    and I keep running into program crashes - bad memory allocation
    I've been cutting back the size of the generated map
    down from max to, now, just 2 steps above normal huge mapsize

    I'm still seeing the problem of not enough resources
    and have been trying the "Full_of_resources" mod to fix this
    - it doesn't seem to be helping.

    I still like the idea of having this map generator create ringworld maps
    :):):)

    *please* let me know when you have time to finish another update
    of this planet generator.

    and thanks in advance for your wonderful work

    bonniee
     
  2. Swodhawk

    Swodhawk Chieftain

    Joined:
    Jun 29, 2007
    Messages:
    40
    I second your petition Bonnie :goodjob:
     
  3. lpw

    lpw Chieftain

    Joined:
    Nov 4, 2006
    Messages:
    6
    Me too :goodjob:

    Especially when combined with a 40 civ DLL there are way to few resources on the really big maps.
     
  4. mechaerik

    mechaerik Tuturuu!

    Joined:
    Oct 28, 2008
    Messages:
    7,064
    Location:
    Los Angeles
    ^:agree:^

    I was playing a game with 13 islands, and only 2 had iron, and 1 of those had 3, the other had it in the middle of the desert. Guess which one i had to get.
     
  5. tdb

    tdb Chieftain

    Joined:
    Nov 12, 2005
    Messages:
    205
    Location:
    Finland
    This is my new favorite map script. I like it so much I decided to address the problem of too many forests myself. Modified version attached.

    The changes I made with explanations for those that might be interested (Nercury, you still there?):

    Spoiler :

    Code:
    @@ -2776,7 +2776,7 @@
           if feature == None and plot.getFeatureType() == featNone:
             randomFeat = probabilityArray()
     
    -        randomFeat[distanceFromRiver * 14 * (1 - climateHumidity)] = None # how many tiles have no forest and no jungle
    +        randomFeat[distanceFromRiver * 40 * (1 - climateHumidity)] = None # how many tiles have no forest and no jungle
             if tileTemperature > 28:
               randomFeat[(distanceFromRiver / 3 + (tileTemperature - 22) / 2) * (1 - (climateHumidity * 0.5) - 0.5)] = None
     
    @@ -3038,7 +3038,7 @@
                           else:
                             tilePlot.setTerrainType(plot.getTerrainType(),False,False)
     
    -        posList[len(posList) / 2] = None # add some none probability
    +        posList[len(posList) * (1.5 - climateHumidity)] = None # add some none probability
             item = posList.random(dice)
             if item != None:
               seedList[world.getOffset([item[0],item[1]])] = item
    @@ -3199,9 +3199,9 @@
             if ay >= 0 and ay < iH:
               if (not (ax == x and ay == y)):
                 if ax < 0:
    -              ax = iW - 1
    +              ax += iW
                 elif ax >= iW:
    -              ax = 0
    +              ax -= iW
                 l.append([ax,ay])
       else:
         for by in range(distance * 2 + 1):
    @@ -3211,9 +3211,9 @@
             if ay >= 0 and ay < iH:
               if (not (ax == x and ay == y)):
                 if ax < 0:
    -              ax = iW - 1
    +              ax += iW
                 elif ax >= iW:
    -              ax = 0
    +              ax -= iW
                 if map.plot(ax, ay).getPlotType() in plotTypes:
                   l.append([ax,ay])
       return l
    
    First hunk: Reduce the chance of initial forests and jungles.

    Second hunk: Make feature spread dependent on humidity.

    Third and fourth hunks: Fix some minor bugs in wrapping.

    See, I was able to fix the forest problem by just changing numbers :p

    With this version, the lowest humidity setting will generate an occasional small forest, but most of the terrain will be bare. The "normal" setting has a fair amount of vegetation, but not overly much. The highest setting will fill the world almost completely with plants, as before.
     

    Attached Files:

  6. Formica

    Formica Chieftain

    Joined:
    Mar 6, 2002
    Messages:
    20
    I love the maps this script generates, but it does not provide its options when used with the Pitboss. Or maybe I'm doing it wrong. Is there a way to make it work with the Pitboss?
     
  7. OnmyojiOmn

    OnmyojiOmn Chieftain

    Joined:
    Aug 4, 2006
    Messages:
    371
    Thanks for posting!
     
  8. Senap

    Senap Chieftain

    Joined:
    Feb 22, 2009
    Messages:
    81
    I second this.
    This is my favorite script as well, the maps are amazing :eek:
     
  9. Krill

    Krill Chieftain

    Joined:
    Jan 30, 2004
    Messages:
    3,332
    Location:
    Stoke-on-Trent, England
    Is there a way to edit this map script so that it generates more resources on map sizes larger than huge? I'm seeing islands that can fit 8 cities with 2 resources.
     
  10. DireAussie

    DireAussie Chieftain

    Joined:
    Nov 12, 2005
    Messages:
    60
    Just like to say I'm another supporter of this map script. Finally found something which gives true control over creation. I can now make Snaky Continents / channel maps WITHOUT excessive ocean and 1-2 landmass islands which all the other scripts do.

     
  11. Oddible

    Oddible signal / noise > 1

    Joined:
    Apr 7, 2002
    Messages:
    906
    Location:
    Vancouver, BC
    Hey, I've been digging this map generator but the (many) settings pages have no options for 'players per map'. I'm curious how many are set for the larger maps. Since huge maps are such a time investment I have been reluctant to start one until I know that these will have correctly scaled up the number of players. I started one recently and was surprised to find far much more space for myself than I would have expected leading me to believe that perhaps this is not using the same number of civs as vanilla.

    Thanks for the great mod!
     
  12. Temudjin

    Temudjin Chieftain

    Joined:
    Oct 16, 2007
    Messages:
    90
    Actually the (default) number of players per map is defined within a XML-File in
    ...\Assets\XML\GameInfo\CIV4WorldInfo.xml:
    Code:
    <WorldInfo>
    	<Type>WORLDSIZE_DUEL</Type>
    	<Description>TXT_KEY_WORLD_DUEL</Description>
    	<Help>TXT_KEY_WORLD_DUEL_HELP</Help>
    	<iDefaultPlayers>2</iDefaultPlayers>
    	:
    
    That means it's probably depending on the mod.

    Incidently I would love to know how to change the default from within the map-script,
    so that the custom map option would show the new default number of players. Anyone?
     
  13. Nercury

    Nercury Chieftain

    Joined:
    Aug 5, 2006
    Messages:
    126
    Location:
    Lithuania
    Number of players depend on map type, but you can select any number if you load new game over "custom game" window.

    So far I am not placing players with this script myself, I just rely on the way firaxis' default placement works, i.e. if you have 4 continents and 5 players, it places 3 of them into separate continents, and 2 of them into single continent. But when you select "by player count" in my script, i would generate one continent twice bigger, and firaxis' algorithm would recognize that.

    By the way, what default settings you guys use? I am planning to make second, "lite" planet generator variant with less settings, and i am planning how best to streamline it by cutting out necessary options. So far I am considering removing "Map size override", "Relative continent size", "Land near pole ice" (always allow), "One tile islands" (always disallow), "Hills" (default setting), "Flood plains" (standard).
     
  14. PPQ_Purple

    PPQ_Purple Techpriest Engineer

    Joined:
    Oct 11, 2008
    Messages:
    3,374
    edit-the bug is with my PC, not the script.
     
  15. A_Hamster

    A_Hamster Small Furry Animal

    Joined:
    Dec 20, 2007
    Messages:
    627
    Of the ones listed, I use "Relative continent size", "Land near pole ice" (set to "Never"), and "Hills" (varies on mood). Since I'm away from my PC, I can't look at the other options, but I'll edit in the other ones I use later.


    Incidentally, right now you only have a "Standard" setting for options. If it's not too difficult, could you enable a variable modifier there to allow an increase in resources from 5% to 100%?

    EDIT 1: My usual settings are Standard map, Smart Selector, 3 continents, Rough Edges, Rare Small Islands (although I often use no Islands), min 4 tiles of ocean, Relative continent size by player count, Default Ocean, No Land near pole ice, Default Lonely Islands, Default lonely island size, No one tile islands, usually default on mountains and hills, usually default on climate, vegetation, and temperature settings (although I like playing "Dawn of Time" worlds which call for more jungle and forest, so I often reset for humid tropical climates with lots of vegetation), Standard flood plains.
     
  16. jauggy

    jauggy Chieftain

    Joined:
    Dec 18, 2008
    Messages:
    240
    What does map size override do? Could someone please explain.
     
  17. phoinix

    phoinix Chieftain

    Joined:
    Feb 7, 2008
    Messages:
    118
    Location:
    Greece
    I use this script in conjuction with the XXL world mod. I use no map overdrive and get bigger map sizes through the standard size selector (xxl, giant, ultra are all big enough for my tastes). Resources are ok. Copy the py in the Program files> Firaxis>Civ> Beyond the Sword>Mods>XXL World>Private Maps. It should appear in the map menu.

    It overides the stock map sizes and produces bigger maps.
     
  18. rlbond86

    rlbond86 Chieftain

    Joined:
    Jul 15, 2009
    Messages:
    13
    Request: Is it possible to select independently width and height of a map? It would be cool.
     
  19. Zacar

    Zacar Chieftain

    Joined:
    Jan 7, 2006
    Messages:
    160
    Best map script I've tried so far.

    I'm trying to achieve a map with many continents, some of which have start locations, and some of which are empty. It would also be nice to have later contact between continents and some ocean between continents (not glued to each other).

    So when I select the options like this:

    I get this:


    Would be nice to have a bit more space between continents, and some continents without starting locations.. I tried forcing 160x100 map size but one such generation actually crashed to desktop, and they kinda increased the land area too much, with these exact settings.

    The terrain placement is great with this script. few hills/few mountains in groups of 5 produces more balanced terrain than the default, but that is just my opinion of course.

    I think the high number in "continent separation" somehow kills the uninhabited continents. They may appear with these settings, but only a tiny one and rarely, so far. =/

    Maybe I'll have to test more to get better results still..

    EDIT: Ok, after further testing, I probably got good enough maps for actually start playing :lol:.

    Overriding Huge to 160x100 and lowering land % to 50 seems to work quite well:

    Then I slightly lowered map size (to have a bit less space for cities) and tried the "use all empty space for small islands"-setting:

    Well, now I have some seas. Still difficult to generate many islands. The islands are also quite tiny.. maybe because you want to ensure that the default placement (that you probably use?) won't place anyone to these islands. They are mostly for flavour though.
     
  20. deathbystarship

    deathbystarship Chieftain

    Joined:
    Dec 4, 2006
    Messages:
    5
    i think it's perfect, except for just one thing. no way of making a terra style map!
     

Share This Page