Jump to content

KingGen - A Random World Generator for 7 Days to Die


KingSlayerGM

Recommended Posts

Thanks for this tool.

 

Now the problems! It seems that it is possible that the quantity of a POI is 0? How can this happen when we can sometimes find several dozen of the same POI while some are completely missing?

Couldn't the "min" value in the list be 1 by default to avoid this?

 

Another less important defect, why can't we choose the quantity for the forest biome? (I finally made my own biome on GIMP but it @%$#es me off)

Link to comment
Share on other sites

On 10/2/2021 at 1:12 PM, Fleshus said:

Now the problems! It seems that it is possible that the quantity of a POI is 0? How can this happen when we can sometimes find several dozen of the same POI while some are completely missing?

 

Kinggen ignores certain names. I think it's those which begin with 'aaa' or 'test', but I might be remembering wrong.

 

If you have other POIs not showing up maybe you could say which ones they are?

Link to comment
Share on other sites

@Fleshus  Bare with me for a moment:   With  only " , , " at the end of the poi line - KingGen has no particular guidance as to how many - min or max of any particular poi can occur.    I've no doubt that KS could set min to be "1" for every case - but that might/would force way too many POI's to be created - at least one of everything in the list, plus - with no particular limit on more than one, it could well cause the map generation to crash, hang, or at least take way too long to create the map. What is needed to prevent those "several dozen" of the same POI's appearing, is a "max" limit.

 

Right now - if, in the Advanced settings, you choose "Number of POI's in the wild" as "none" - then your new map will contain no pois.  

My own current poislist.txt contains a very much pared-down number of poi's - but it's still 480 poi's . . (default is 536 lines), and so - the way I read it - I would expect that when I choose "Number of POI's in the wild" as "decreased" - KingGen will randomly pick, say 60 out of that 480. Selecting "medium" might pick out, say - 90, and then for "increased" it might be as many as 120... Those figures may/will also depend on the map's size.

 

As it is atm - you can leave it at ", ," and let KingGen pick what it wants to: however - and this is where I think it is a useful feature - if you want to make a theme - like I did, with no modern buildings or highrises - I reckon putting ", ,0' (i.e. limiting the max to "0") would prevent the poi appearing. 


Putting a ",1,1" at the end of a line in the list, would cause that particular poi to appear on the map in only one place, with none anywhere else. Some cities contain lots of automobile sales, garages, etc., for e.g., and one might be tempted to limit that by using, say ",2,5" so that there are at least two on the map - (they make decent first bases) and maybe up to 5.    It really shines when adding poi's like those from Khaine's "Darkness Falls", or from Jax Teller's "Ravenhurst".

In your case - you need to identify those particular buildings that are bugging you, and give them a qty number as the second figure, leaving the first number as either a "0" or a "1".

Regarding the biomes: I seem to remember reading somewhere, that the PineForest biome is the default biome, and unless you create your own biome.png - it is the background for all the other biomes, and is probably set by the game itself.

Hope this helps.
 

Edited by paulj_3 (see edit history)
Link to comment
Share on other sites

When a POI gets rejected from the POI list when generating a world is there any way to go back and see why it was rejected?  Running into an issue with some POIs from bdubyah's The Wasteland mod where they're getting consistently rejected, even if I go back and comment out the line.

Link to comment
Share on other sites

Commenting out the line with the POI would guarantee that the POI is rejected, wouldn't it?

 

You might try generating a small map with only that one POI in the poi list to see what happens? If the POI gets rejected when it's the only POI, that would tell you that this was not a coincidence. (But if there are any sort of "required POIs" this might require a few tries to work through those issues...)

 

Anyways... it might be that there's something wrong with those POIs -- maybe bdubyah or people who have been working on that wasteland mod would know?

Link to comment
Share on other sites

On 9/25/2021 at 2:24 PM, pvr3 said:

I love this map generator. I have one saved that I use often, but I'm getting to know it too well. When I try to generate a new one, I've been getting error messages though. The latest one is below and I'm wondering if someone could help me figure out what I'm doing wrong? I'm trying to use custom POIs and I'm assuming this is the issue because it works fine when trying to generator a map with vanilla POIs.

 

"Discarded 992 lines in POIs list:
Traceback (most recent call last):
  File "crash_log.py", line 19, in handle_crash_log
  File "gui_generation.py", line 27, in generate
  File "ntime.py", line 11, in ntime
  File "world.py", line 1301, in run
  File "world.py", line 69, in __init__
  File "hub_factory.py", line 14, in __init__
Exception: Cannot find default hubs"

 

Focus on this line... Exception: Cannot find default hubs

 

KingGen 13.1 had a new format to its configuration file. If you're reusing a list of POIs from an earlier version then you probably don't have an @hubs section.

 

If you're making a custom configuration, then you need to start with a current KingGen configuration and paste in any POI definitions that you want to add.

Link to comment
Share on other sites

Hello there, I hope someone can help me.

 

I generated a map for a new run and used the Combo Pack. Everything worked great, the new POIs are in game - but:

 

The height map seems broken. I have too often a "San Francisco" feeling when I drive on the street and a big POI is surrounded by a wall of stone. This happens regularly and I wonder if the POIs are the ones to blame or did I something wrong? If you want more information, please ask me and I try to provide pictures of the game if you need it to see what I mean.

 

I like this run and I will stick with it but the next map I want to create should have a smoother heightmap. And most importantly I want to understand why some POIs are too high or too low in the ground.

Edited by Krisrennt (see edit history)
Link to comment
Share on other sites

Hi Shem:   As you asked about 'single biome' and 'snow - NONE' without specific quotes or capitalization - I'm answering for "Single biome" set to "none" first, and then to avoid misunderstanding - tackle it as you may have meant it to read: The reason for the issue appearing is at the bottom.
So:  1).
"Single biome" set to "none" implies that the map is not going to be a single biome map. If you only want a single biome - you could put "desert" there, instead of "none", and then "none" in all the other biome "size" slots.   That will give you a single biome map, without snow, period, regardless of #3). a). or b). below.

2).
"Snow size" set to 'none" implies that you don't care if it's large or medium - or small - snow: - it doesn't say "no snow" in the map:  - so with "Single biome" set to "none", "Snow size" set to "none", and all others set to medium" - there will be all other biomes as medium-sized, plus a few medium-sized lakes. and some medium-sized mountains - but there may well be some snow - because of  #3). below:

3).
The answer for your map above, is this: In the box where the Water level is, and Cities level below it is - the bottom part is. . . "Snow level" - and to guarantee that there will be no snow - that needs to be empty.
      a). If there is a number here, and you have mountains - only in the #1 scenario will there be no snow: "Single biome" is exactly that - regardless of a number in the "Snow level" box.        
      b). In the #2 scenario - the snow height must be higher than the highest mountain - or no number there at all.  Only then will there be no snow.
 

I reckon your map complies with the #2). scenario. . Ok?

pj

 

Edited by paulj_3 (see edit history)
Link to comment
Share on other sites

9 hours ago, Krisrennt said:

This happens regularly and I wonder if the POIs are the ones to blame or did I something wrong?

 

A picture would be clearer, but I suspect you and the POIs are okay. Speaking solely from my own experiences with KingGen, it has trouble placing things in rough terrain. What I suspect is happening is that some elevation at the front of the POI is okay and was the location used by KingGen to determine which height to place the POI. Then the rest of the POI either cuts into the terrain or is put on a plateau. Similarly, the slope of roads seems to be based on the elevation of an adjacent intersection and not the corners of the POI, so you don't get a level road running beside the POI. When the slope is gentle it kind of works, but a steep hill leads to awkward placement.

 

That's my guess, anyways. As fast as KG has been developed I'd think problems like this are to be expected. I'm sure they'll make improvements.

Link to comment
Share on other sites

7 hours ago, paulj_3 said:

2).
"Snow size" set to 'none" implies that you don't care if it's large or medium - or small - snow: - it doesn't say "no snow" in the map:  - so with "Single biome" set to "none", "Snow size" set to "none", and all others set to medium" - there will be all other biomes as medium-sized, plus a few medium-sized lakes. and some medium-sized mountains - but there may well be some snow - because of  #3). below:

 

 

Thanks for clarifying that -- I had imagined that "none" meant that the biome would not be used.  (Shouldn't this be labeled "Any" rather than "None"?)

Link to comment
Share on other sites

The problem Shem has, I had, and probably most of us had (it's a perfectly reasonable assumption) was that "none" in any of the other boxes means "none = NO biome" (or mountain, or lake) so I don't think "any" would make any difference, Vic/Shem:  The real control here is in the linking of the "Landscape Snow size" to an entry in the Elevation box:  for a guarantee of no snow - this box must be blank.  Now - I don't know what language KS uses, but the "Elevation" boxes are probably all numeric, so maybe a code snippet such as:-

 

[

    if landscape_snow_size=none
       then elevation_snow_level==""
    end
]
 

... might do the trick.

It's not really about fixing a bug, per se, but perhaps more about a little correction and making the user interface so that it's more instinctive.

Edited by paulj_3 (see edit history)
Link to comment
Share on other sites

3 hours ago, paulj_3 said:

It's not really about fixing a bug, per se, but perhaps more about a little correction and making the user interface so that it's more instinctive.

KingSlayerGM might need help on this.   Not that I am doubting his skills, but he is the one that wrote up and code the KingGen.  When he uses it, he understands how each item functions and not realize that laypeople like us do not have his thinking skills  😉

 

This happens all the time, even to me.  Sometimes the best thing to do is to have somone else run the program, ask the questions when certain things are not obvious, then go back and update the documentation for the programmer.

Link to comment
Share on other sites

        Creating an app requires lots of testing, and I believe that KS built KingGen on his own, @BFT2020, and English is not his first language. He has done a terrific job - and he has provided a pretty darned good tool for us "people who like to make maps" that really hadn't existed before.  As his program is free - most of us don't object to being part-time testers!     If he is successful - then we all benefit - right!

        That being said - over the last twenty-to-forty years, the internet has opened up the world and provided an unprecedented number of users with all kinds of electronic communication vehicles - one of which is the ability to use the written word to chat - with anyone - anywhere - and at any time - either by using online chat, forums, blogs, texting, news columns, comments, and so on.  These have never been so available to so many people, and a great part of that communicating is done using the 'English' written language - which is full of 'slightly ambiguous' words, with many words taken from Latin, many from German, from French, many from the Norse countries - and many invented by users on the internet!   Lots of English words may look the same as Italian words, for e.g., but they just may have very slightly different meaning, or a nuance from that word as he understands it.   
        Many words have much dependency upon context also. as here.  Much of the programming world is carried out, creating programs and applications for speakers of the English language - not necessarily the "British" English:   the non-native British English speaking programmer, without benefit of that native education, is at quite a disadvantage, and will interpret his ideas using the language as he understands it.   It will not always be correct, and I think this is the reason for this issue here - hence my remark about it not being really a bug.       
          If one has an instinctive user interface - there is no need for an Instruction Manual. Tallman Brad is native British English, and I'm sure - picking up on this immediately, he jumped in to help KS with the creation of his great series of videos. He has been very successful, and has, in good part, been KingSlayer's valuable assistant!

Of course - I may be just full of hot air . . . . .    😎 


pj

 

Link to comment
Share on other sites

New user of KingGen as always used Nitrogen in past. One thing I cannot see that could do with Nitrogen was set North and South borders so have snow in north and desert in south. Just how I like my maps. Is there option which I am missing or, if not,  will this possibly be included in future version of KingGen?

Link to comment
Share on other sites

1 hour ago, nickuk01 said:

New user of KingGen as always used Nitrogen in past. One thing I cannot see that could do with Nitrogen was set North and South borders so have snow in north and desert in south. Just how I like my maps. Is there option which I am missing or, if not,  will this possibly be included in future version of KingGen?


Best thing for this currently is to create your own biomes.png, then generate the map, that way you get biomes where you want them.



 

Link to comment
Share on other sites

8 minutes ago, Cpt Krunch said:


Best thing for this currently is to create your own biomes.png, then generate the map, that way you get biomes where you want them.



 

Cpt crunch if u have a link to something i can use to set predetermined biomes before generating the map in kinggen i'd like to check it out which reminds me I'm sure u know where all the biomes in your Texas map should be for real life accuracy and to be straightforward i think the texas map would be better suited for A20

Link to comment
Share on other sites

2 minutes ago, AndrewT said:

Cpt crunch if u have a link to something i can use to set predetermined biomes before generating the map in kinggen i'd like to check it out which reminds me I'm sure u know where all the biomes in your Texas map should be for real life accuracy and to be straightforward i think the texas map would be better suited for A20

2021-10-12_12h52_32.png.b7b71dc45a91ec06a441f41b3dcfdc44.png

'Custom biomes map' inside KG is where you set the file, you just need to create it. Ive got a video on how to do it here
 


If this is too complicated, there is also a stand alone tool to achieve the same thing
 


Far as A20/Texas is concerned, at least right now, A20 is going to make an absolute mess of just about every tool involved with map making. I think King is on break due to work/school, but Ive had a chance to look under the hood (theoretically) and read a lot about A20, and while Im excited about the changes theyve made, its going to require some serious retooling, probably this is the most change to the map system ever. I'm Kings primary test dummy/bug finder, and while Ive got most of the changes figured out, Im going to need King for the coding, primarily water and new rwg generation, they are a LOT different.


 

Link to comment
Share on other sites

  • 2 weeks later...
On 10/10/2021 at 11:23 PM, zztong said:

 

A picture would be clearer, but I suspect you and the POIs are okay. Speaking solely from my own experiences with KingGen, it has trouble placing things in rough terrain. What I suspect is happening is that some elevation at the front of the POI is okay and was the location used by KingGen to determine which height to place the POI. Then the rest of the POI either cuts into the terrain or is put on a plateau. Similarly, the slope of roads seems to be based on the elevation of an adjacent intersection and not the corners of the POI, so you don't get a level road running beside the POI. When the slope is gentle it kind of works, but a steep hill leads to awkward placement.

 

That's my guess, anyways. As fast as KG has been developed I'd think problems like this are to be expected. I'm sure they'll make improvements.

 

Thank you for your reply and you are right. After playing for a while, only the big POIs are placed sometimes strange (but not everyone). The map is good playable and all that matters.

Link to comment
Share on other sites

Was wondering if something is intentional or a bug.  When I generate 5 maps at once, for instance, it seems every time one of them has a significant difference.  Recently I generated 5 normal-ish maps with one city and no towns and one of them came out with no city or towns or anything other than wilderness POIs.  I thought it might be a fluke.  Then I generated 5 wasteland maps and with one city and no towns and it did the same thing... one of them had no city.  In between those I have generated at least one set that had cities in each of the 5 generated maps.  In each set I've noticed the missing city I have used a root seed and the wasteland example I used "Wasteland".  Here is the config file generated for this map (#4 in the sequence):

 

Spoiler

  _  ___              _____
 | |/ (_)            / ____|
 | ' / _ _ __   __ _| |  __  ___ _ __
 |  < | | '_ \ / _` | | |_ |/ _ \ '_ \
 | . \| | | | | (_| | |__| |  __/ | | |
 |_|\_\_|_| |_|\__, |\_____|\___|_| |_|
                __/ |
               |___/
v0.13.1 - A19.6
7 Days to Die Random World Generator
Find out more at https://community.7daystodie.com/topic/23988-kinggen-a-random-world-generator-for-7-days-to-die/

SETTINGS:
border_size=medium
border_type=water
burnt_size=small
check_output=false
cities_grid_size=large
cities_level=60
cities_number=one
cities_size=large
default_biome=wasteland
default_biome_tools=pine forest
desert_size=small
heightmap_smoothing=none
mountains_size=large
multiple_generations=5
name=Wasteland4
output_folder=
png_heightmap=no
poi_mode=false
pois_list=vanilla
pois_number=medium
seed=Wasteland4
single_biome=wasteland
size=8
skip_preview=false
snow_level=
snow_size=small
spacing=giant
spawn_points=medium
terrain_roughness=increased
towns_grid_size=large
towns_number=none
towns_size=medium
traders_location=cities
traders_number=none
villages_grid_size=large
villages_number=none
villages_size=medium
waste_size=large
water_level=43
water_size=small

 

Link to comment
Share on other sites

 

I created another set of 5 wasteland maps with a similar config and it did the same thing... #4 had no city.  Config file for this one:

 

Spoiler

  _  ___              _____
 | |/ (_)            / ____|
 | ' / _ _ __   __ _| |  __  ___ _ __
 |  < | | '_ \ / _` | | |_ |/ _ \ '_ \
 | . \| | | | | (_| | |__| |  __/ | | |
 |_|\_\_|_| |_|\__, |\_____|\___|_| |_|
                __/ |
               |___/
v0.13.1 - A19.6
7 Days to Die Random World Generator
Find out more at https://community.7daystodie.com/topic/23988-kinggen-a-random-world-generator-for-7-days-to-die/

SETTINGS:
border_size=medium
border_type=water
burnt_size=large
check_output=false
cities_grid_size=medium
cities_level=60
cities_number=one
cities_size=large
default_biome=wasteland
default_biome_tools=pine forest
desert_size=large
heightmap_smoothing=none
mountains_size=medium
multiple_generations=5
name=Wasteland4
output_folder=
png_heightmap=no
poi_mode=false
pois_list=vanilla
pois_number=decreased
seed=Wasteland4
single_biome=wasteland
size=8
skip_preview=false
snow_level=
snow_size=large
spacing=giant
spawn_points=medium
terrain_roughness=increased
towns_grid_size=medium
towns_number=none
towns_size=small
traders_location=cities
traders_number=none
villages_grid_size=medium
villages_number=none
villages_size=small
waste_size=large
water_level=43
water_size=medium

 

Link to comment
Share on other sites

Hey y'all!  I'm new to KingGen (and adding POIs in general), and had a question for ya.


I've added a bunch of prefabs, used the KingGen 'create custom' list, and generated worlds with them.  I have 5-6 custom POIs that are never added to any world I create (tried default settings, resizing biomes, etc.)  All of these custom POIs do populate if I run KingGen in "POI mode."  

 

I tested by trying a world with *only* those POIs in them (in various combinations), and I get an error:

 

Traceback (most recent call last):
  File "crash_log.py", line 19, in handle_crash_log
  File "gui_generation.py", line 27, in generate
  File "ntime.py", line 11, in ntime
  File "world.py", line 1301, in run
  File "world.py", line 265, in generate
  File "world.py", line 542, in init_cities
  File "world.py", line 642, in gen_cities
  File "hub_factory.py", line 25, in gen_random_city
  File "hub_factory.py", line 59, in gen_random_hub
  File "city.py", line 46, in __init__
  File "city.py", line 61, in generate
  File "city.py", line 274, in populate_grid
  File "city.py", line 246, in try_place
AttributeError: 'NoneType' object has no attribute 'rotate_to_face'

 

I also noticed that the entries for them all have something in common in the custom POI list created by KingGen:

 

Castle-Eltz,125,72,230,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,
zztong_Tent_01,2,1,2,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,
zztong_Tent_02,2,1,2,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,

 

(and so on)

 

They all have 'none' as their 'prob' field (if I'm reading the format correctly.)   So, if I am understanding it right, KingGen's custom POI tool is flagging these as "don't put these in any maps."  Indeed, when I remove that 'none' so it matches other entries, I get the above error again.

 

So... how can I tell what is causing KingGen to reject these POIs (which I am able to place manually)?  I poked around the xml for each POI but didn't see anything they shared in common that was different from the working ones, at first glance!

 

Any help is appreciated, but obviously this isn't a game-breaking thing :) I love KingGen and have made incredibly fun, varied maps with it, just curious as to why these particular ones are failing.

 

EDIT: Flying around in a POI-mode map, I do get the sense that the failing ones are *mostly* very large POIs.

 

Edited by drzachary (see edit history)
Link to comment
Share on other sites

22 minutes ago, drzachary said:

Hey y'all!  I'm new to KingGen (and adding POIs in general), and had a question for ya.


I've added a bunch of prefabs, used the KingGen 'create custom' list, and generated worlds with them.  I have 5-6 custom POIs that are never added to any world I create (tried default settings, resizing biomes, etc.)  All of these custom POIs do populate if I run KingGen in "POI mode."  

 

I tested by trying a world with *only* those POIs in them (in various combinations), and I get an error:

 

Traceback (most recent call last):
  File "crash_log.py", line 19, in handle_crash_log
  File "gui_generation.py", line 27, in generate
  File "ntime.py", line 11, in ntime
  File "world.py", line 1301, in run
  File "world.py", line 265, in generate
  File "world.py", line 542, in init_cities
  File "world.py", line 642, in gen_cities
  File "hub_factory.py", line 25, in gen_random_city
  File "hub_factory.py", line 59, in gen_random_hub
  File "city.py", line 46, in __init__
  File "city.py", line 61, in generate
  File "city.py", line 274, in populate_grid
  File "city.py", line 246, in try_place
AttributeError: 'NoneType' object has no attribute 'rotate_to_face'

 

I also noticed that the entries for them all have something in common in the custom POI list created by KingGen:

 

Castle-Eltz,125,72,230,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,
zztong_Tent_01,2,1,2,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,
zztong_Tent_02,2,1,2,0,2,burnt_forest/snow/pine_forest/desert/wasteland,,none,,

 

(and so on)

 

They all have 'none' as their 'prob' field (if I'm reading the format correctly.)   So, if I am understanding it right, KingGen's custom POI tool is flagging these as "don't put these in any maps."  Indeed, when I remove that 'none' so it matches other entries, I get the above error again.

 

So... how can I tell what is causing KingGen to reject these POIs (which I am able to place manually)?  I poked around the xml for each POI but didn't see anything they shared in common that was different from the working ones, at first glance!

 

Any help is appreciated, but obviously this isn't a game-breaking thing :) I love KingGen and have made incredibly fun, varied maps with it, just curious as to why these particular ones are failing.

 

"none" for the zones is used by the Vanilla RWG and basically means "no restrictions" but KingGen doesn't know that zone. You have to put there "any" if you want it to work with KG. Another thing is you have to put in there some township allowance or it won't work with KG either. The allowed values for township are : city, town, rural and wilderness and you have to put them between none/any and wasteland.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...