-
Notifications
You must be signed in to change notification settings - Fork 0
Function: mirror
theblackswitch edited this page May 15, 2026
·
2 revisions
#mtb-generated:<namespace>/<multiblock_id>/mirror
This function is used to mirror the blueprint. The structure is mirrored around the Z-axis in local space. This means that we first mirror the multiblock around the Z-axis and then apply the correct rotation. This will also mirror all the included blockstates accordingly.
This function needs to run as the root of the multiblock instance you want to edit.
Note
You can use the selector @e[type=minecraft:block_display,tag=<namespace>-<multiblock_id>,tag=mtb.root] to find the root
# mirror the multiblock when the player clicks with an item in the right menu
# The implementing datapack uses a player ID system to link the multiblocks with the player
scoreboard players operation #search tbs.ID = @s tbs.ID
execute if score @s schematic.menu matches 4 if score @s schematic.click matches 1.. as @e[type=minecraft:block_display,tag=tech_datapack-industrial_furnace,tag=mtb.root,tag=td.currently_placing,predicate=tech_datapack:match_player_id] run function #mtb-generated:tech_datapack/industrial_furnace/mirrorwiki written by ~theblackswitch