Skip to content

Conditional Patterns

platz1de edited this page Jun 1, 2023 · 20 revisions

These Patterns allow control over when to set certain blocks

<argument> - required Argument
[argument] - optional Argument
patterns - children patterns, can be separated by a comma

Pattern Usage Description
Checkblock Pattern block;<block>(patterns) Executes Patterns if the block is the same as the specified block (like in //replace)
Solid Pattern solid(patterns) Executes Patterns if the block is a non-nature block
Above Pattern above;<block>(patterns) Executes Patterns if the block is above the specified block
Below Pattern below;<block>(patterns) Executes Patterns if the block is below the specified block
Not Pattern not(condition(patterns)) Executes Patterns of next Pattern is false (only works when nested)
Odd Pattern odd;[x];[y];[z](patterns) Executes Patterns if the block is at odd coordinates at x, y and z Axis, the x, y and z can be left out (only given ones will be checked)
Even Pattern even;[x];[y];[z](patterns) Executes Patterns if the block is at even coordinates (see odd for more info)
Checkblock Pattern divisible;<number>;[x];[y];[z](patterns) Executes Patterns if the block is at coordinates which are divisible by the given number (see odd for more info)
Wall Pattern walls;[thickness](patterns) Executes Patterns if the block is one of the walls of the selection
Sides Pattern sides;[thickness](patterns) Executes Patterns if the block is one of the sides of the selection (walls + bottom and top)
Center Pattern center(patterns) Executes Patterns if the block is in the center of the selection
Embed Pattern embed;<block>(patterns) Executes Patterns if the block is around a higher specified block