I will be streaming March 7th, at 15:00 GMT
When creating new plants or objects that we want to naturally spawn in the world we can use decorations to place the items and only have them place when the map chunk is generated. This is far better than using an ABM to populate the world with the items, as this only runs once and keeps the map from getting overpopulated with a node.

Example Code:
        deco_type = "simple",
        place_on = {"mod:node"},
        sidelen = 16,
        noise_params = { --Read about perlin noise if you want to know what this actually does.
            offset = 0,
            scale = 0.02, --How many/often the object is placed, higher is more.
            spread = {x = 100, y = 100, z = 100},
            seed = 219, --Random number to keep placement from being the same.
            octaves = 3,
            persist = 0.6
        y_min = 1, --Lowest point the decoration will be placed.
        y_max = 30, --Highest point the decoration will be placed.
        decoration = "mod:node",
        height = 3, --Optional for if you want the node to be stacked.
        height_max = 4, --Optional, how high the tallest stack should be.

Read More:
Dev Wiki

Add new comment