Log In  


Cart #voroterrain-5 | 2021-06-26 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
9


Another season, another terrain generator.

Below is an old version of the pipeline that was used for the generator. This has since been reworked a bit to add features.

  • Generate every possible syllable through structure "CV(n)" (Consonant, vowel, and an optional "n")
  • Pregenerate name with 2-5 syllables

  • Create n points and n/16 biome centres
  • Generate basic (polygonal) shape using voronoi
  • Apply "life" n/6.4 generations

  • Add name on screen

Tada! You've got yourself a basic map. You can also disable the "terrain" boolean to make it just generate a voronoi diagram, but that's boring and I don't need it so I leave "terrain" as True in the above cart. Feel free to play around though.


Here are some examples of pretty islands:


Have fun generating endless islands with silly names. Later!

P.S. v1.2.1 has introduced "Manual Mode". At any time in the generation process, you can press Z. When generation is over, you should see that the name of the landmass and the names of the nations don't show up. This is so that you can hide either. If you want the name of the landmass to show up, press Z during Manual Mode. Do the same for nations but with X instead of Z. This should let you have more versatility with my little toy.

Notes for modders:

  • The "quality" variable is what defines A) The amount of points for veronoi rendering B) The amount of biome centres and C) The amount of generations to run my little life thing(n, n/16 and n/6.4 respectively)
  • The syllable generator generates every single syllable in the given CV(n) structure. The code for this is very simple:
for c in all(consonants) do
	for v in all(vowels) do
		add(syllables,c..v)
		add(syllables,c..v..'n')
	end
end

Since v1.2.2, there is another syllable type, generated separately: VV.

for v in all(vowels)do
	for ov in all(vowels)do
		add(syllables,v..ov)
	end
end
  • The voronoi calculations can certainly be improved; I just don't know how. I'm not a pro at optimization or math.
  • The "biomes" are just sets of colours. There is no limit to the amount of colours each biome can have(I wanted as free of an environment as possible)
  • Do not uncomment "music()". It's for your own good.
  • The "colex" table simply excludes colours from being switched to their secondary palette alternatives. This is simply to make it look nice.

Have fun doing deranged things to the island generator. I hope that was a comprehensive list of notes.


Possible ideas:

  • Maybe a mode where you can look around the map with a zoomed in camera?

Version history:
  • V1.0.X: Initial Version
  • v1.1.X: Biome Update
  • v1.2.X: Nation Update
    • v1.2.1: Manual Mode
    • v1.2.2:
      • One new syllable type, VV
      • Experimental roughing which uses a symbol instead of a circle to rough up the edges of the islands
  • 9


    interesting - code looks relatively compact, a good quality attribute for pico!


    Released 1.2.0. Now, we have nations! They can be disabled with the "nations" bool.


    Awesome :)


    Neat. The little mix up at the end makes everything look mint. Before that it seems a functional but plain.


    Released 1.2.1. This update introduces Manual Mode, which you can enable during the generation process using Z. More info in the post!


    Just realised that the three pictures in the post used to demonstrate examples tile together when stacked. Neat!


    Released 1.2.2. This adds an experimental roughing type, and adds the VV syllable type for name generation.



    [Please log in to post a comment]