Skip to content

Commit

Permalink
Remove hardcoded field mapgen (CleverRaven#70122)
Browse files Browse the repository at this point in the history
* Remove hardcoded field mapgen

I expected that to be much harder.

* lint

* Update regions.json

* remove from mods

This may need some adjusting

* Update ice_fields.json

no longer builtin

* Update desert_overmap_terrain.json

* Update tropical_overmap_terrain.json

* deletion typo

* Another accidental deletion

* Update tropical_overmap_terrain.json

* Update tropical_overmap_terrain.json

* add mapgen for tropicataclysm desert

Could be fine tuned but I don't know tropicataclysm
  • Loading branch information
I-am-Erk authored Dec 20, 2023
1 parent fecbe9c commit 132c285
Show file tree
Hide file tree
Showing 19 changed files with 109 additions and 533 deletions.
55 changes: 55 additions & 0 deletions data/json/mapgen/basic/field.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
[
{
"type": "mapgen",
"method": "json",
"om_terrain": [ "field" ],
"object": {
"fill_ter": "t_region_groundcover",
"rows": [
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312"
],
"//": "1: reserve for furniture. 2: reserve for terrain. 3: reserve for items.",
"terrain": {
"1": "t_region_groundcover",
"2": [ [ "t_region_groundcover", 35000 ], [ "t_region_shrub_plains", 6 ], [ "t_region_tree", 2 ] ],
"3": "t_region_groundcover"
},
"furniture": {
"1": [
[ "f_null", 35000 ],
[ "f_region_plain", 100 ],
[ "f_boulder_small", 10 ],
[ "f_boulder_medium", 8 ],
[ "f_boulder_large", 2 ],
[ "f_region_flower", 1 ]
],
"2": "f_null",
"3": "f_null"
},
"items": { "3": { "item": "field", "chance": 1 } }
}
}
]
File renamed without changes.
67 changes: 0 additions & 67 deletions data/json/regional_map_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -276,73 +276,6 @@
}
},
"river_scale": 1.0,
"field_coverage": {
"percent_coverage": 0.2,
"default_ter": "t_shrub",
"other": {
"t_region_tree": 1,
"t_region_shrub": 3,
"f_region_plain": 49,
"f_boulder_small": 5,
"f_boulder_medium": 4,
"f_boulder_large": 1
},
"boost_chance": 0.833,
"boosted_percent_coverage": 2.5,
"boosted_other": {
"t_tree_young": 0.2,
"t_tree": 0.08,
"t_tree_birch": 0.05,
"t_tree_elm": 0.05,
"t_tree_cottonwood": 0.05,
"t_tree_basswood": 0.07,
"t_tree_alder": 2,
"t_tree_pine": 0.1,
"t_tree_maple": 0.1,
"t_tree_willow": 0.1,
"t_tree_hickory": 0.1,
"t_tree_walnut": 0.05,
"t_tree_butternut": 0.02,
"t_tree_chestnut": 0.05,
"t_tree_hazelnut": 0.02,
"t_tree_beech": 0.02,
"t_tree_blackjack": 0.05,
"t_tree_coffee": 0.02,
"t_tree_apple": 0.02,
"t_tree_apricot": 0.02,
"t_tree_cherry": 0.02,
"t_tree_peach": 0.02,
"t_tree_juniper": 0.02,
"t_tree_pear": 0.02,
"t_tree_plum": 0.02,
"t_tree_elderberry": 0.02,
"t_tree_mulberry": 0.02,
"t_tree_sassafras": 0.02,
"t_region_tree_dead": 0.15,
"t_shrub_blueberry": 8.0,
"t_shrub_strawberry": 5.0,
"t_shrub_blackberry": 5.0,
"t_shrub_raspberry": 8.0,
"t_shrub_huckleberry": 5.0,
"t_shrub_grape": 5.0,
"t_shrub_rose": 3,
"t_shrub_hydrangea": 3,
"t_shrub_lilac": 3,
"f_black_eyed_susan": 3,
"f_lily": 3,
"f_flower_tulip": 3,
"f_flower_spurge": 3.5,
"f_chicory": 3,
"f_mutpoppy": 3.5,
"f_bluebell": 3.5,
"f_dahlia": 3.5,
"f_datura": 0.2,
"f_dandelion": 5.0,
"f_sunflower": 3.5,
"f_mustard": 0.2
},
"boosted_other_percent": 50.0
},
"overmap_lake_settings": {
"noise_threshold_lake": 0.25,
"lake_size_min": 20,
Expand Down
9 changes: 0 additions & 9 deletions data/mods/Backrooms/regional_map_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,6 @@
"furniture": { "f_region_flower": { "f_rack_coat": 1, "f_sign_warning": 1, "f_sign": 1 } }
},
"river_scale": 0.0,
"field_coverage": {
"percent_coverage": 0.1333,
"default_ter": "t_carpet_red",
"other": { "f_mutpoppy": 1 },
"boost_chance": 0.833,
"boosted_percent_coverage": 2.5,
"boosted_other": { "f_dandelion": 5.0 },
"boosted_other_percent": 50.0
},
"overmap_lake_settings": {
"noise_threshold_lake": 1.0,
"lake_size_min": 0,
Expand Down
1 change: 0 additions & 1 deletion data/mods/Magiclysm/worldgen/regional_overlay.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
"houses": { "house_technomancer": 20, "wizard_tower_1": 10, "wizard_tower_2": 20 },
"shops": { "magic_shop": 100, "used_bookstore": 225, "magic_academy": 150 }
},
"field_coverage": { "other": { "f_boulder_large": 0.98, "f_glow_boulder": 0.02 } },
"region_terrain_and_furniture": {
"terrain": { "t_region_groundcover_swamp": { "t_horn_moss": 10 } },
"furniture": {
Expand Down
65 changes: 0 additions & 65 deletions data/mods/No_Hope/regional_map_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -252,71 +252,6 @@
}
},
"river_scale": 1.0,
"field_coverage": {
"percent_coverage": 0.2,
"default_ter": "t_shrub",
"other": {
"t_region_tree": 1,
"t_region_shrub": 3,
"f_region_plain": 49,
"f_boulder_small": 5,
"f_boulder_medium": 4,
"f_boulder_large": 1
},
"boost_chance": 0.833,
"boosted_percent_coverage": 2.5,
"boosted_other": {
"t_tree_young": 0.2,
"t_tree": 0.1,
"t_tree_birch": 0.05,
"t_tree_elm": 0.05,
"t_tree_cottonwood": 0.05,
"t_tree_basswood": 0.07,
"t_tree_alder": 2,
"t_tree_pine": 0.1,
"t_tree_maple": 0.1,
"t_tree_willow": 0.1,
"t_tree_hickory": 0.1,
"t_tree_walnut": 0.05,
"t_tree_chestnut": 0.05,
"t_tree_hazelnut": 0.02,
"t_tree_beech": 0.02,
"t_tree_blackjack": 0.05,
"t_tree_coffee": 0.02,
"t_tree_apple": 0.02,
"t_tree_apricot": 0.02,
"t_tree_cherry": 0.02,
"t_tree_peach": 0.02,
"t_tree_juniper": 0.02,
"t_tree_pear": 0.02,
"t_tree_plum": 0.02,
"t_tree_elderberry": 0.02,
"t_tree_mulberry": 0.02,
"t_region_tree_dead": 0.15,
"t_shrub_blueberry": 8.0,
"t_shrub_strawberry": 5.0,
"t_shrub_blackberry": 5.0,
"t_shrub_raspberry": 8.0,
"t_shrub_huckleberry": 5.0,
"t_shrub_grape": 5.0,
"t_shrub_rose": 3,
"t_shrub_hydrangea": 3,
"t_shrub_lilac": 3,
"f_black_eyed_susan": 3,
"f_lily": 3,
"f_flower_tulip": 3,
"f_flower_spurge": 3.5,
"f_chicory": 3,
"f_mutpoppy": 3.5,
"f_bluebell": 3.5,
"f_dahlia": 3.5,
"f_datura": 0.2,
"f_dandelion": 5.0,
"f_sunflower": 3.5,
"f_mustard": 0.2
},
"boosted_other_percent": 50.0
},
"overmap_lake_settings": {
"noise_threshold_lake": 0.25,
"lake_size_min": 20,
Expand Down
9 changes: 0 additions & 9 deletions data/mods/TEST_DATA/regions.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,6 @@
},
"furniture": { "f_region_flower": { "f_mutcactus_test": 1 } }
},
"field_coverage": {
"percent_coverage": 1.9333,
"default_ter": "t_sand",
"other": { "t_shrub": 0.4166, "f_mutpoppy": 5.3333, "f_mutcactus_test": 10.3333 },
"boost_chance": 2.833,
"boosted_percent_coverage": 12.5,
"boosted_other": { "t_shrub_blueberry": 0.0001, "t_shrub": 4.9, "f_mutcactus_test": 50.0 },
"boosted_other_percent": 20.0
},
"overmap_lake_settings": {
"noise_threshold_lake": 0.25,
"lake_size_min": 20,
Expand Down
54 changes: 53 additions & 1 deletion data/mods/TropiCataclysm/tropical_overmap_terrain.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,57 @@
[
{
"type": "mapgen",
"method": "json",
"om_terrain": [ "desert" ],
"object": {
"fill_ter": "t_region_groundcover",
"rows": [
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312",
"123123123123123123123123",
"231231231231231231231231",
"312312312312312312312312"
],
"//": "1: reserve for furniture. 2: reserve for terrain. 3: reserve for items.",
"terrain": {
"1": "t_region_groundcover",
"2": [ [ "t_region_groundcover", 35000 ], [ "t_region_shrub_plains", 6 ], [ "t_region_tree", 2 ] ],
"3": "t_region_groundcover"
},
"furniture": {
"1": [
[ "f_null", 35000 ],
[ "f_region_plain", 100 ],
[ "f_boulder_small", 10 ],
[ "f_boulder_medium", 8 ],
[ "f_boulder_large", 2 ],
[ "f_region_flower", 1 ]
],
"2": "f_null",
"3": "f_null"
},
"items": { "3": { "item": "field", "chance": 1 } }
}
},
{
"type": "overmap_terrain",
"id": "desert",
Expand All @@ -9,7 +62,6 @@
"see_cost": 2,
"extras": "field",
"spawns": { "group": "GROUP_FOREST", "population": [ 0, 1 ], "chance": 13 },
"mapgen": [ { "method": "builtin", "name": "field" } ],
"flags": [ "NO_ROTATE" ]
}
]
67 changes: 0 additions & 67 deletions data/mods/TropiCataclysm/tropical_regional_map_settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -305,73 +305,6 @@
}
},
"river_scale": 1.0,
"field_coverage": {
"percent_coverage": 0.2,
"default_ter": "t_shrub",
"other": {
"t_region_tree": 1,
"t_region_shrub": 3,
"f_region_plain": 49,
"f_boulder_small": 5,
"f_boulder_medium": 4,
"f_boulder_large": 1
},
"boost_chance": 0.833,
"boosted_percent_coverage": 2.5,
"boosted_other": {
"t_tree_young": 0.2,
"t_tree": 0.1,
"t_tree_birch": 0.05,
"t_tree_elm": 0.05,
"t_tree_cottonwood": 0.05,
"t_tree_basswood": 0.07,
"t_tree_alder": 2,
"t_tree_pine": 0.1,
"t_tree_maple": 0.1,
"t_tree_willow": 0.1,
"t_tree_hickory": 0.1,
"t_tree_walnut": 0.05,
"t_tree_chestnut": 0.05,
"t_tree_hazelnut": 0.02,
"t_tree_beech": 0.02,
"t_tree_blackjack": 0.05,
"t_tree_coffee": 0.02,
"t_tree_apple": 0.02,
"t_tree_apricot": 0.02,
"t_tree_cherry": 0.02,
"t_tree_peach": 0.02,
"t_tree_juniper": 0.02,
"t_tree_pear": 0.02,
"t_tree_plum": 0.02,
"t_tree_elderberry": 0.02,
"t_tree_mulberry": 0.02,
"t_tree_deadpine": 0.05,
"t_tree_hickory_dead": 0.05,
"t_tree_dead": 0.05,
"t_shrub_blueberry": 8.0,
"t_shrub_strawberry": 5.0,
"t_shrub_blackberry": 5.0,
"t_shrub_raspberry": 8.0,
"t_shrub_huckleberry": 5.0,
"t_shrub_grape": 5.0,
"t_shrub_rose": 3,
"t_shrub_hydrangea": 3,
"t_shrub_lilac": 3,
"f_black_eyed_susan": 3,
"f_lily": 3,
"f_flower_tulip": 3,
"f_flower_spurge": 3.5,
"f_chicory": 3,
"f_mutpoppy": 3.5,
"f_bluebell": 3.5,
"f_dahlia": 3.5,
"f_datura": 0.2,
"f_dandelion": 5.0,
"f_sunflower": 3.5,
"f_mustard": 0.2
},
"boosted_other_percent": 50.0
},
"overmap_lake_settings": {
"noise_threshold_lake": 0.25,
"lake_size_min": 20,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
"color": "light_gray",
"see_cost": 2,
"extras": "field",
"mapgen": [ { "method": "builtin", "name": "field" } ],
"flags": [ "NO_ROTATE" ]
},
{
Expand Down
Loading

0 comments on commit 132c285

Please sign in to comment.