Terrain Generation - Can you do overhangs?

Well, I guess I’m pretty confused on how terrain generation works in the first place. I’ve got the rest of my biome mod’s skeleton put together, but after looking through several biome generation_data.jsons, I’m as confused as ever.

From what I’ve seen, though, I think you can’t, just with your generation_data.json. Please let me know if that’s wrong.

… is there any way to make overhanging layers anyway?

1 Like

If that’s not possible… is there any way to spawn structures/items into the world, but have them be turn into actual, mineable, blocks?

We’re currently working on a feature that would allow this.


This day is quite the emotional rollercoaster for Stonehearth fans, I’d say.


Ah, okay. Much better than my original plan of trying to abuse the terrain generation to get want I want.

For the technically adept, the outline of this procedure would be:

  1. Create a static scenario and mixin to scenario_index.json (see fox_nest.json and critter_nest.json).
  2. Add a reference to the lua script for your code in the scenario (e.g. critter_nest.json references the script critter_nest.lua).
  3. Your script will be called when the static scenario is placed by the world generation code. You can add or deform the terrain in the initialize() method of the script (see critter_nest.lua). Call the radiant.terrain.* functions to manipulate the terrain.

From inside the initialize() method, you can get the world coordinates of where your scenario was placed in services._offset_x and services._offfset_y. The size of your scenario will be in properties.size.width and properties.size.length.

A few of the key terrain manipulation methods are listed below, but you can find the full implementation in terrain.lua:


Does this answer on landmarks:

mean that the feature you mentioned is getting in the game, or are they made manually with the terrain method Albert mentioned… or will the landmarks just be objects like the bunny statues?

The landmarks system is included in the current release. You can place them using the geomancer and they are rare-ish spawns in all newly generated maps in the default biomes. There are a few more landmarks to come, but we don’t plan any more changes to the system. They are created as QBs and enabled by creating JSON files for scenarios. See 128x_skeleton_caribou.json for an example of a landmark specification, and look in the comments in landmark_lib.lua for details on available options.

1 Like