-
Notifications
You must be signed in to change notification settings - Fork 15
Processor Conditions
Apollo edited this page Jan 9, 2025
·
3 revisions
Processor conditions are used alongside the condition processor type for more readable and flexible processor code.
Checks a list of processor conditions. If all pass, this passes.
{
"type": "lithostitched:all_of",
"conditions": [
{
"type": "lithostitched:true"
}
]
}-
conditions: The list of conditions to check.
Checks a list of processor conditions. If any pass, this passes.
{
"type": "lithostitched:any_of",
"conditions": [
{
"type": "lithostitched:true"
}
]
}-
conditions: The list of conditions to check.
Checks if the current blocks either in the template or in the world match given conditions.
{
"type": "lithostitched:matching_blocks",
"blocks": "#example:stone_stairs",
"properties": {
"waterlogged": "false"
},
"match_type": "input"
}-
blocks: A block, list of blocks, or tag of blocks to check against. -
properties: An optional list of block properties to check. Defaults to not checking any states. -
match_type: The type of matching to do.inputchecks against the block in the structure template,locationchecks against the block in the world getting replaced. Defaults toinput.
Inverts the supplied condition. If the condition fails, this passes.
{
"type": "lithostitched:not",
"condition": {
"type": "lithostitched:true"
}
}-
condition: The structure conditions to invert.
Checks a position rule test.
{
"type": "lithostitched:position",
"predicate": {
"predicate_type": "minecraft:linear_pos",
"max_chance": 0.3,
"max_dist": 10,
"min_chance": 0.1,
"min_dist": 0
},
"anchor": "piece"
},-
predicate: The position rule test to check. -
anchor: The positional anchor to base the check on. Possible fields arestructure_startfor current/vanilla behavior andpiecefor piece-relative position checks.
The random_chance processor condition will randomly pass.
{
"type": "lithostitched:random_chance",
"chance": 0.4
}-
chance: The chance the processor condition will pass. A float from 0.0 to 1.0.
Always passes. No further fields.
All json here can be generated using the Lithostitched generator website!