//bridge-file-version: #115 { "minecraft:block": { "description": { "properties": { "bridge:block_rotation": [ 0, 1, 2, 3, 4, 5 ] }, "identifier": "gb:gen_side" }, "permutations": [ { "condition": "query.block_property('bridge:block_rotation') == 0", "components": { "minecraft:rotation": [ 0, 0, 0 ] } }, { "condition": "query.block_property('bridge:block_rotation') == 1", "components": { "minecraft:rotation": [ 0, 0, 180 ] } }, { "condition": "query.block_property('bridge:block_rotation') == 2", "components": { "minecraft:rotation": [ 90, 0, 0 ] } }, { "condition": "query.block_property('bridge:block_rotation') == 3", "components": { "minecraft:rotation": [ -90, 0, 0 ] } }, { "condition": "query.block_property('bridge:block_rotation') == 4", "components": { "minecraft:rotation": [ 0, 0, -90 ] } } ], "components": { "minecraft:on_player_placing": { "event": "bridge:update_rotation" }, "minecraft:on_placed": { "event": "gb:gen", "target": "self", "condition": "query.block_property('bridge:block_rotation')" } }, "events": { "bridge:update_rotation": { "set_block_property": { "bridge:block_rotation": "query.block_face" } }, "gb:gen_one": { "run_command": { "target": "self", "command": [ "structure load gen_side ~-50~~ 180_degrees none block_by_block 5", "say gen1" ] } }, "gb:gen_two": { "run_command": { "target": "self", "command": [ "structure load gen_side ~~~ 0_degrees none block_by_block 5", "say gen2" ] } }, "gb:gen": { "randomize": [ { "trigger": { "event": "gb:gen_two", "condition": "a != a", "target": "self" } } ] } } }, "format_version": "1.16.100" }