Decoration API: Add lightweight ability to have complete coverage (#7456)
When the noise value or fill_ratio >= 10.0 complete coverage is enabled. This disables random placement to avoid redundant multiple placements at one position. Instead, 1 decoration per surface node is placed by looping across each division. '10' was chosen as this is the fill_ratio that previously created very near complete coverage. The complete coverage feature therefore integrates smoothly when noise is used for variable decoration density. 'fill_ratio = 10' should be used by modders who want a decoration placed on every surface node. Compared to before such a decoration placement will be 10 times faster.
This commit is contained in:
@@ -5769,6 +5769,8 @@ Definition tables
|
||||
fill_ratio = 0.02,
|
||||
-- ^ The value determines 'decorations per surface node'.
|
||||
-- ^ Used only if noise_params is not specified.
|
||||
-- ^ If >= 10.0 complete coverage is enabled and decoration placement uses
|
||||
-- ^ a different and much faster method.
|
||||
noise_params = {
|
||||
offset = 0,
|
||||
scale = 0.45,
|
||||
@@ -5783,6 +5785,8 @@ Definition tables
|
||||
-- ^ distribution.
|
||||
-- ^ A noise value is calculated for each square division and determines
|
||||
-- ^ 'decorations per surface node' within each division.
|
||||
-- ^ If the noise value >= 10.0 complete coverage is enabled and decoration
|
||||
-- ^ placement uses a different and much faster method.
|
||||
biomes = {"Oceanside", "Hills", "Plains"},
|
||||
-- ^ List of biomes in which this decoration occurs. Occurs in all biomes
|
||||
-- ^ if this is omitted, and ignored if the Mapgen being used does not
|
||||
|
Reference in New Issue
Block a user