Implement missing map tiles, add a new meadow biome, make biomes more granular.

This commit is contained in:
Anna Rose Wiggins 2019-12-09 19:17:50 -05:00
parent cdced463ed
commit 89a63f59b8
2 changed files with 35 additions and 30 deletions

View file

@ -4,20 +4,25 @@ function init_mapgen()
uid_seed = 2229 -- arbitrarily chosen number
-- Metadata for different biomes
-- frequencies don't have to add up to 100, but they should by convention
-- tile_frequencies tuples are {frequency, sprite_index}, see index_map.md
-- frequencies by convention add up to 1000, but this is arbitrary, the
-- only concern is the space consumed by the resulting tables.
biome_data = {
meadow = {
biome_frequency = 20,
tile_frequencies = { {525, 2}, {200, 5}, {200, 6}, {55, 18}, {19, 3}, {1, 4} }
},
grassland = {
biome_frequency = 75,
tile_frequencies = { {40, 2}, {28, 5}, {28, 6}, {3, 3}, {1, 4} }
biome_frequency = 55,
tile_frequencies = { {500, 2}, {345, 18}, {4, 3}, {1, 4}, {100, 5}, {50, 6} }
},
forest = {
biome_frequency = 20,
tile_frequencies = { {60, 2}, {20, 4}, {5, 3}, {5, 5}, {4, 7}, {5, 6}, {1, 8} }
tile_frequencies = { {600, 2}, {200, 4}, {50, 3}, {50, 5}, {40, 7}, {59, 6}, {1, 8} }
},
desert = {
biome_frequency = 5,
tile_frequencies = { {80, 9}, {10, 11}, {6, 13}, {3, 12}, {1, 10} },
tile_frequencies = { {800, 9}, {109, 11}, {60, 13}, {30, 12}, {1, 10} },
}
}
@ -25,7 +30,7 @@ function init_mapgen()
-- Lua's pairs() function appears not to guarantee a consistent return order,
-- and we want our world to be deterministically generated,
-- so the biome_metadata array needs to have its entries appear consistently.
biome_list = {"grassland", "forest", "desert"}
biome_list = {"grassland", "meadow", "forest", "desert"}
-- this is the frequency list for the biomes themselves
biome_metadata = {}