Block conditions and probability
Advanced block placing for masters
All blocks are placed based on configuration options. To accompany this, some additional advanced settings were implemented.
The settings that were implemented may look simple, but they offer quite advanced features. It implements support for dependent and interdependent probability and also condition based block selections.

Conditions

There are multiple conditions under which a block can be placed. You can combine them however you want. "Or" statements can be a applied by adding the block multiple times.
These are the current possible conditions;
    Height condition
    Inclination condition
    Relative altitude condition
Height condition
1
"heightConditions": [
2
{
3
"minHeight": 54,
4
"maxHeight": 54
5
},
6
{
7
"minHeight": 60,
8
"maxHeight": 70
9
}
10
]
Copied!
This condition allows you to make the block only spawn between certain heights.
Inclination condition
The plugin takes raw data of the terrain and finds the height differences between the location and the locations around it. This value can then be compared with the absolute value of the derivative to the terrain generated in a 3D environment. See this Wikipedia page on the derivative.
1
"inclinationsConditions": [
2
{
3
"minInclination": 0.0,
4
"maxInclination": 1.7
5
},
6
{
7
"minInclination": 2.2,
8
"maxInclination": 3.5
9
}
10
]
Copied!
This condition is mostly used to place blocks in crags.

Probability

Block groups are automatically assigned into dependent and independent groups.
Two events are dependent on the outcome or occurrence of the first. This affects the outcome or occurrence of the second so that the probability is changed. To make it a bit more complex (because why not), the generator operates with two different probabilities each time a location is checked to see if a block should be placed.
Lets explain using an example. Taken this configuration;
1
"surfaceBlocks": [
2
[
3
[
4
{
5
"type": "SAND",
6
"data": 1,
7
"heightConditions": [
8
{
9
"minHeight": 80,
10
"maxHeight": 256
11
}
12
],
13
"inclinationsConditions": [
14
{
15
"minInclination": 0.0,
16
"maxInclination": 0.5
17
}
18
]
19
},
20
0.6
21
]
22
],
23
[
24
[
25
{
26
"type": "STAINED_CLAY",
27
"data": 6,
28
"heightConditions": [
29
{
30
"minHeight": 80,
31
"maxHeight": 81
32
}
33
]
34
},
35
0.8
36
],
37
[
38
{
39
"type": "STAINED_CLAY",
40
"data": 7,
41
"heightConditions": [
42
{
43
"minHeight": 84,
44
"maxHeight": 85
45
}
46
]
47
},
48
0.8
49
],
50
[
51
{
52
"type": "STAINED_CLAY",
53
"data": 8,
54
"heightConditions": [
55
{
56
"minHeight": 88,
57
"maxHeight": 89
58
}
59
]
60
},
61
0.8
62
],
63
[
64
{
65
"type": "STAINED_CLAY",
66
"data": 9,
67
"heightConditions": [
68
{
69
"minHeight": 92,
70
"maxHeight": 57
71
}
72
]
73
},
74
0.8
75
],
76
[
77
{
78
"type": "STAINED_CLAY",
79
"data": 10,
80
"heightConditions": [
81
{
82
"minHeight": 96,
83
"maxHeight": 97
84
}
85
]
86
},
87
0.8
88
]
Copied!
The example above is using independent probability by putting each of the blocks that can be generated into its own group. This means the plugin go through to each of the groups until it find a block that fits the location.
Normally, by putting all of the blocks into the same group, the probability for the next block to be chosen would increase with the probability of the previous picked block.

Support

Please try to resolve this yourself, as even the most experienced among our support have serious trouble doing this themselves, let alone explain it.
If you don't care, and have any issues with any of the settings in this file, make sure to contact our support team at Discord.
Last modified 1yr ago
Copy link