From e2b221eed070d02bace51e376bb8d6c7326ab0f0 Mon Sep 17 00:00:00 2001 From: Mark Rapson Date: Thu, 15 May 2025 22:24:08 +0100 Subject: [PATCH] Added Trowel Fixed issue with wrench Organised tools into folders --- LICENSE.txt => LICENSE | 1 + README.md | 47 +++------ .../lzstools/models/items/trowel/diamond.json | 6 ++ assets/lzstools/models/items/trowel/iron.json | 6 ++ .../lzstools/textures/item/trowel/diamond.png | Bin 0 -> 392 bytes assets/lzstools/textures/item/trowel/iron.png | Bin 0 -> 346 bytes assets/minecraft/items/carrot_on_a_stick.json | 4 +- data/lzstools/advancement/visible/root.json | 8 +- .../advancement/visible/trowel_diamond.json | 32 ++++++ .../advancement/visible/trowel_iron.json | 32 ++++++ data/lzstools/advancement/visible/wrench.json | 57 +++++------ .../function/give/trowel_diamond.mcfunction | 1 + .../function/give/trowel_iron.mcfunction | 1 + data/lzstools/function/give/wrench.mcfunction | 2 +- data/lzstools/function/load.mcfunction | 13 ++- data/lzstools/function/player.mcfunction | 8 +- data/lzstools/function/recipes.mcfunction | 4 +- data/lzstools/predicate/trowel/mainhand.json | 17 ++++ data/lzstools/predicate/trowel/offhand.json | 17 ++++ .../predicate/unbreaking/mainhand/1.json | 18 ++++ .../predicate/unbreaking/mainhand/2.json | 18 ++++ .../predicate/unbreaking/mainhand/3.json | 18 ++++ .../predicate/unbreaking/mainhand/all.json | 21 ++++ .../predicate/unbreaking/offhand/1.json | 18 ++++ .../predicate/unbreaking/offhand/2.json | 18 ++++ .../predicate/unbreaking/offhand/3.json | 18 ++++ .../predicate/unbreaking/offhand/all.json | 21 ++++ data/lzstools/predicate/wrench/mainhand.json | 25 +++-- data/lzstools/predicate/wrench/offhand.json | 23 ++--- .../tags/block/banners.json | 0 .../tags/block/glazed_terracotta.json | 0 .../{wrench => lzstools}/tags/block/nesw.json | 0 .../tags/block/neswud.json | 0 .../tags/block/partialbox.json | 0 .../tags/block/unique.json | 0 .../tags/block/updates.json | 0 data/{wrench => lzstools}/tags/block/xyz.json | 0 .../function/block/place.mcfunction | 4 + .../function/block/place/leaves.mcfunction | 2 + .../function/block/place/nesw.mcfunction | 5 + .../function/block/place/neswud.mcfunction | 7 ++ .../function/block/place/slabs.mcfunction | 3 + .../function/block/place/stairs.mcfunction | 9 ++ .../function/block/place/trapdoors.mcfunction | 10 ++ .../function/block/place/xyz.mcfunction | 7 ++ .../function/block/place_normal.mcfunction | 16 +++ .../function/block/remove_item.mcfunction | 1 + .../function/block/target_coords.mcfunction | 22 ++++ .../durability/mainhand/apply.mcfunction | 1 + .../durability/mainhand/break.mcfunction | 4 + .../durability/mainhand/handle.mcfunction | 13 +++ .../durability/mainhand/unbreaking.mcfunction | 4 + .../durability/offhand/apply.mcfunction | 1 + .../durability/offhand/break.mcfunction | 4 + .../durability/offhand/handle.mcfunction | 13 +++ .../durability/offhand/unbreaking.mcfunction | 4 + .../function/mainhand.mcfunction | 3 + .../function/offhand.mcfunction | 3 + .../function/random/block_macro.mcfunction | 7 ++ .../function/random/check_block.mcfunction | 3 + .../function/random/check_hotbar.mcfunction | 35 +++++++ .../function/random/get_block.mcfunction | 2 + .../function/random/random.mcfunction | 1 + .../function/random/start.mcfunction | 30 ++++++ .../function/raycast/hit.mcfunction | 16 +++ .../function/raycast/rayloop.mcfunction | 14 +++ .../function/raycast/start.mcfunction | 9 ++ .../predicate/mainhand/diamond.json | 17 ++++ .../predicate/mainhand/iron.json | 17 ++++ .../predicate/offhand/diamond.json | 17 ++++ .../predicate/offhand/iron.json | 17 ++++ data/lzstools_trowel/recipe/diamond.json | 36 +++++++ data/lzstools_trowel/recipe/iron.json | 36 +++++++ .../function/raycast/partialbox.mcfunction | 29 ++++++ .../raycast/partialbox/anvils.mcfunction | 32 +++--- .../raycast/partialbox/banners.mcfunction | 2 + .../raycast/partialbox/bell.mcfunction | 5 + .../calibrated_sculk_sensor.mcfunction | 2 + .../raycast/partialbox/campfires.mcfunction | 2 + .../raycast/partialbox/chain.mcfunction | 6 +- .../raycast/partialbox/comparator.mcfunction | 2 + .../partialbox/decorated_pot.mcfunction | 2 +- .../raycast/partialbox/end_rod.mcfunction | 12 +-- .../raycast/partialbox/ender_chest.mcfunction | 2 +- .../raycast/partialbox/fence_gates.mcfunction | 16 +-- .../raycast/partialbox/grindstone.mcfunction | 96 +++++++++--------- .../raycast/partialbox/hopper.mcfunction | 14 +-- .../partialbox/lightning_rod.mcfunction | 12 +-- .../raycast/partialbox/pistons.mcfunction | 17 ++++ .../raycast/partialbox/rails.mcfunction | 6 ++ .../raycast/partialbox/repeater.mcfunction | 2 + .../raycast/partialbox/signs.mcfunction | 50 ++++----- .../raycast/partialbox/slabs.mcfunction | 3 + .../raycast/partialbox/stairs.mcfunction | 28 ++--- .../raycast/partialbox/stonecutter.mcfunction | 2 +- .../raycast/partialbox/trapdoors.mcfunction | 13 +++ .../function/raycast/rayloop.mcfunction | 26 +++++ .../function/raycast/start.mcfunction | 2 +- .../function/raycast/target_coords.mcfunction | 0 .../function/raycast/unique.mcfunction | 3 + .../function/rotate/banners/click.mcfunction | 4 +- .../function/rotate/banners/cycle.mcfunction | 0 .../function/rotate/banners/flip.mcfunction | 0 .../function/rotate/banners/player.mcfunction | 2 +- .../function/rotate/banners/rotate.mcfunction | 7 ++ .../rotate/glazed_terracotta/cycle.mcfunction | 0 .../rotate/glazed_terracotta/mode.mcfunction | 2 +- .../glazed_terracotta/rotate.mcfunction | 4 + .../function/rotate/nesw/click.mcfunction | 4 +- .../function/rotate/nesw/cycle.mcfunction | 0 .../function/rotate/nesw/flip.mcfunction | 0 .../function/rotate/nesw/player.mcfunction | 9 ++ .../function/rotate/nesw/rotate.mcfunction | 7 ++ .../function/rotate/neswud/click.mcfunction | 4 +- .../function/rotate/neswud/cycle.mcfunction | 0 .../function/rotate/neswud/flip.mcfunction | 0 .../function/rotate/neswud/player.mcfunction | 2 +- .../function/rotate/neswud/rotate.mcfunction | 7 ++ .../function/rotate/rails/cycle.mcfunction | 0 .../function/rotate/rails/player.mcfunction | 0 .../function/rotate/rails/rotate.mcfunction | 5 + .../function/rotate/signs/click.mcfunction | 4 +- .../function/rotate/signs/cycle.mcfunction | 0 .../function/rotate/signs/flip.mcfunction | 0 .../function/rotate/signs/player.mcfunction | 2 +- .../function/rotate/signs/rotate.mcfunction | 7 ++ .../rotate/signs_hanging/cycle.mcfunction | 0 .../rotate/signs_hanging/flip.mcfunction | 0 .../rotate/signs_hanging/player.mcfunction | 2 +- .../rotate/signs_hanging/rotate.mcfunction | 6 ++ .../rotate/signs_wall/flip.mcfunction | 0 .../rotate/signs_wall/rotate.mcfunction | 4 + .../function/rotate/slabs/flip.mcfunction | 0 .../function/rotate/slabs/rotate.mcfunction | 4 + .../function/rotate/stairs/click.mcfunction | 4 +- .../function/rotate/stairs/cycle.mcfunction | 0 .../function/rotate/stairs/flip.mcfunction | 0 .../function/rotate/stairs/player.mcfunction | 2 +- .../function/rotate/stairs/rotate.mcfunction | 7 ++ .../rotate/trapdoors/click.mcfunction | 4 +- .../rotate/trapdoors/cycle.mcfunction | 0 .../function/rotate/trapdoors/flip.mcfunction | 0 .../rotate/trapdoors/player.mcfunction | 2 +- .../rotate/trapdoors/rotate.mcfunction | 7 ++ .../calibrated_sculk_sensor/click.mcfunction | 4 +- .../calibrated_sculk_sensor/cycle.mcfunction | 0 .../calibrated_sculk_sensor/flip.mcfunction | 0 .../calibrated_sculk_sensor/player.mcfunction | 2 +- .../calibrated_sculk_sensor/rotate.mcfunction | 7 ++ .../unique_blocks/campfires/cycle.mcfunction | 0 .../unique_blocks/campfires/rotate.mcfunction | 3 + .../unique_blocks/comparator/click.mcfunction | 4 +- .../unique_blocks/comparator/cycle.mcfunction | 0 .../unique_blocks/comparator/flip.mcfunction | 0 .../comparator/player.mcfunction | 2 +- .../comparator/rotate.mcfunction | 7 ++ .../unique_blocks/crafter/click.mcfunction | 4 +- .../unique_blocks/crafter/cycle.mcfunction | 0 .../unique_blocks/crafter/flip.mcfunction | 0 .../unique_blocks/crafter/player.mcfunction | 2 +- .../unique_blocks/crafter/rotate.mcfunction | 7 ++ .../unique_blocks/grindstone/cycle.mcfunction | 0 .../unique_blocks/grindstone/flip.mcfunction | 0 .../grindstone/player.mcfunction | 2 +- .../grindstone/rotate.mcfunction | 6 ++ .../unique_blocks/hopper/click.mcfunction | 4 +- .../unique_blocks/hopper/cycle.mcfunction | 0 .../unique_blocks/hopper/flip.mcfunction | 0 .../unique_blocks/hopper/player.mcfunction | 2 +- .../unique_blocks/hopper/rotate.mcfunction | 7 ++ .../unique_blocks/repeater/click.mcfunction | 4 +- .../unique_blocks/repeater/cycle.mcfunction | 0 .../unique_blocks/repeater/flip.mcfunction | 0 .../unique_blocks/repeater/player.mcfunction | 2 +- .../unique_blocks/repeater/rotate.mcfunction | 7 ++ .../function/rotate/xyz/click.mcfunction | 2 +- .../function/rotate/xyz/cycle.mcfunction | 0 .../function/rotate/xyz/player.mcfunction | 0 .../function/rotate/xyz/rotate.mcfunction | 6 ++ .../function/wrench/offhand.mcfunction | 19 ++++ .../function/wrench/rotate.mcfunction | 2 +- .../function/wrench/terracotta.mcfunction | 8 +- .../item_modifier/default.json} | 0 .../item_modifier/face_click.json} | 0 .../item_modifier/face_player.json} | 0 .../item_modifier/flip.json} | 0 .../item_modifier/terracotta_east.json} | 0 .../item_modifier/terracotta_north.json} | 0 .../item_modifier/terracotta_south.json} | 0 .../item_modifier/terracotta_west.json} | 0 .../recipe/wrench.json | 14 ++- .../function/raycast/partialbox.mcfunction | 29 ------ .../raycast/partialbox/banners.mcfunction | 2 - .../raycast/partialbox/bell.mcfunction | 5 - .../calibrated_sculk_sensor.mcfunction | 2 - .../raycast/partialbox/campfires.mcfunction | 2 - .../raycast/partialbox/comparator.mcfunction | 2 - .../raycast/partialbox/pistons.mcfunction | 17 ---- .../raycast/partialbox/rails.mcfunction | 6 -- .../raycast/partialbox/repeater.mcfunction | 2 - .../raycast/partialbox/slabs.mcfunction | 3 - .../raycast/partialbox/trapdoors.mcfunction | 13 --- .../function/raycast/rayloop.mcfunction | 26 ----- .../wrench/function/raycast/unique.mcfunction | 3 - .../function/rotate/banners/rotate.mcfunction | 7 -- .../glazed_terracotta/rotate.mcfunction | 4 - .../function/rotate/nesw/player.mcfunction | 9 -- .../function/rotate/nesw/rotate.mcfunction | 7 -- .../function/rotate/neswud/rotate.mcfunction | 7 -- .../function/rotate/rails/rotate.mcfunction | 5 - .../function/rotate/signs/rotate.mcfunction | 7 -- .../rotate/signs_hanging/rotate.mcfunction | 6 -- .../rotate/signs_wall/rotate.mcfunction | 4 - .../function/rotate/slabs/rotate.mcfunction | 4 - .../function/rotate/stairs/rotate.mcfunction | 7 -- .../rotate/trapdoors/rotate.mcfunction | 7 -- .../calibrated_sculk_sensor/rotate.mcfunction | 7 -- .../unique_blocks/campfires/rotate.mcfunction | 3 - .../comparator/rotate.mcfunction | 7 -- .../unique_blocks/crafter/rotate.mcfunction | 7 -- .../grindstone/rotate.mcfunction | 6 -- .../unique_blocks/hopper/rotate.mcfunction | 7 -- .../unique_blocks/repeater/rotate.mcfunction | 7 -- .../function/rotate/xyz/rotate.mcfunction | 6 -- .../wrench/function/wrench/offhand.mcfunction | 19 ---- 225 files changed, 1191 insertions(+), 536 deletions(-) rename LICENSE.txt => LICENSE (97%) create mode 100644 assets/lzstools/models/items/trowel/diamond.json create mode 100644 assets/lzstools/models/items/trowel/iron.json create mode 100644 assets/lzstools/textures/item/trowel/diamond.png create mode 100644 assets/lzstools/textures/item/trowel/iron.png create mode 100644 data/lzstools/advancement/visible/trowel_diamond.json create mode 100644 data/lzstools/advancement/visible/trowel_iron.json create mode 100644 data/lzstools/function/give/trowel_diamond.mcfunction create mode 100644 data/lzstools/function/give/trowel_iron.mcfunction create mode 100644 data/lzstools/predicate/trowel/mainhand.json create mode 100644 data/lzstools/predicate/trowel/offhand.json create mode 100644 data/lzstools/predicate/unbreaking/mainhand/1.json create mode 100644 data/lzstools/predicate/unbreaking/mainhand/2.json create mode 100644 data/lzstools/predicate/unbreaking/mainhand/3.json create mode 100644 data/lzstools/predicate/unbreaking/mainhand/all.json create mode 100644 data/lzstools/predicate/unbreaking/offhand/1.json create mode 100644 data/lzstools/predicate/unbreaking/offhand/2.json create mode 100644 data/lzstools/predicate/unbreaking/offhand/3.json create mode 100644 data/lzstools/predicate/unbreaking/offhand/all.json rename data/{wrench => lzstools}/tags/block/banners.json (100%) rename data/{wrench => lzstools}/tags/block/glazed_terracotta.json (100%) rename data/{wrench => lzstools}/tags/block/nesw.json (100%) rename data/{wrench => lzstools}/tags/block/neswud.json (100%) rename data/{wrench => lzstools}/tags/block/partialbox.json (100%) rename data/{wrench => lzstools}/tags/block/unique.json (100%) rename data/{wrench => lzstools}/tags/block/updates.json (100%) rename data/{wrench => lzstools}/tags/block/xyz.json (100%) create mode 100644 data/lzstools_trowel/function/block/place.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/leaves.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/nesw.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/neswud.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/slabs.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/stairs.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/trapdoors.mcfunction create mode 100644 data/lzstools_trowel/function/block/place/xyz.mcfunction create mode 100644 data/lzstools_trowel/function/block/place_normal.mcfunction create mode 100644 data/lzstools_trowel/function/block/remove_item.mcfunction create mode 100644 data/lzstools_trowel/function/block/target_coords.mcfunction create mode 100644 data/lzstools_trowel/function/durability/mainhand/apply.mcfunction create mode 100644 data/lzstools_trowel/function/durability/mainhand/break.mcfunction create mode 100644 data/lzstools_trowel/function/durability/mainhand/handle.mcfunction create mode 100644 data/lzstools_trowel/function/durability/mainhand/unbreaking.mcfunction create mode 100644 data/lzstools_trowel/function/durability/offhand/apply.mcfunction create mode 100644 data/lzstools_trowel/function/durability/offhand/break.mcfunction create mode 100644 data/lzstools_trowel/function/durability/offhand/handle.mcfunction create mode 100644 data/lzstools_trowel/function/durability/offhand/unbreaking.mcfunction create mode 100644 data/lzstools_trowel/function/mainhand.mcfunction create mode 100644 data/lzstools_trowel/function/offhand.mcfunction create mode 100644 data/lzstools_trowel/function/random/block_macro.mcfunction create mode 100644 data/lzstools_trowel/function/random/check_block.mcfunction create mode 100644 data/lzstools_trowel/function/random/check_hotbar.mcfunction create mode 100644 data/lzstools_trowel/function/random/get_block.mcfunction create mode 100644 data/lzstools_trowel/function/random/random.mcfunction create mode 100644 data/lzstools_trowel/function/random/start.mcfunction create mode 100644 data/lzstools_trowel/function/raycast/hit.mcfunction create mode 100644 data/lzstools_trowel/function/raycast/rayloop.mcfunction create mode 100644 data/lzstools_trowel/function/raycast/start.mcfunction create mode 100644 data/lzstools_trowel/predicate/mainhand/diamond.json create mode 100644 data/lzstools_trowel/predicate/mainhand/iron.json create mode 100644 data/lzstools_trowel/predicate/offhand/diamond.json create mode 100644 data/lzstools_trowel/predicate/offhand/iron.json create mode 100644 data/lzstools_trowel/recipe/diamond.json create mode 100644 data/lzstools_trowel/recipe/iron.json create mode 100644 data/lzstools_wrench/function/raycast/partialbox.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/anvils.mcfunction (82%) create mode 100644 data/lzstools_wrench/function/raycast/partialbox/banners.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/partialbox/bell.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/partialbox/campfires.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/chain.mcfunction (71%) create mode 100644 data/lzstools_wrench/function/raycast/partialbox/comparator.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/decorated_pot.mcfunction (72%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/end_rod.mcfunction (67%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/ender_chest.mcfunction (59%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/fence_gates.mcfunction (56%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/grindstone.mcfunction (71%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/hopper.mcfunction (71%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/lightning_rod.mcfunction (65%) create mode 100644 data/lzstools_wrench/function/raycast/partialbox/pistons.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/partialbox/rails.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/partialbox/repeater.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/signs.mcfunction (66%) create mode 100644 data/lzstools_wrench/function/raycast/partialbox/slabs.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/stairs.mcfunction (76%) rename data/{wrench => lzstools_wrench}/function/raycast/partialbox/stonecutter.mcfunction (52%) create mode 100644 data/lzstools_wrench/function/raycast/partialbox/trapdoors.mcfunction create mode 100644 data/lzstools_wrench/function/raycast/rayloop.mcfunction rename data/{wrench => lzstools_wrench}/function/raycast/start.mcfunction (87%) rename data/{wrench => lzstools_wrench}/function/raycast/target_coords.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/raycast/unique.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/banners/click.mcfunction (87%) rename data/{wrench => lzstools_wrench}/function/rotate/banners/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/banners/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/banners/player.mcfunction (97%) create mode 100644 data/lzstools_wrench/function/rotate/banners/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/glazed_terracotta/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/glazed_terracotta/mode.mcfunction (97%) create mode 100644 data/lzstools_wrench/function/rotate/glazed_terracotta/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/nesw/click.mcfunction (87%) rename data/{wrench => lzstools_wrench}/function/rotate/nesw/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/nesw/flip.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/nesw/player.mcfunction create mode 100644 data/lzstools_wrench/function/rotate/nesw/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/neswud/click.mcfunction (90%) rename data/{wrench => lzstools_wrench}/function/rotate/neswud/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/neswud/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/neswud/player.mcfunction (93%) create mode 100644 data/lzstools_wrench/function/rotate/neswud/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/rails/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/rails/player.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/rails/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/signs/click.mcfunction (93%) rename data/{wrench => lzstools_wrench}/function/rotate/signs/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/signs/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/signs/player.mcfunction (98%) create mode 100644 data/lzstools_wrench/function/rotate/signs/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/signs_hanging/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/signs_hanging/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/signs_hanging/player.mcfunction (98%) create mode 100644 data/lzstools_wrench/function/rotate/signs_hanging/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/signs_wall/flip.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/signs_wall/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/slabs/flip.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/slabs/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/stairs/click.mcfunction (97%) rename data/{wrench => lzstools_wrench}/function/rotate/stairs/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/stairs/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/stairs/player.mcfunction (97%) create mode 100644 data/lzstools_wrench/function/rotate/stairs/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/trapdoors/click.mcfunction (98%) rename data/{wrench => lzstools_wrench}/function/rotate/trapdoors/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/trapdoors/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/trapdoors/player.mcfunction (98%) create mode 100644 data/lzstools_wrench/function/rotate/trapdoors/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction (92%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/calibrated_sculk_sensor/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/calibrated_sculk_sensor/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction (93%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/campfires/cycle.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/comparator/click.mcfunction (92%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/comparator/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/comparator/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/comparator/player.mcfunction (95%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/crafter/click.mcfunction (94%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/crafter/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/crafter/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/crafter/player.mcfunction (96%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/grindstone/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/grindstone/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/grindstone/player.mcfunction (96%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/hopper/click.mcfunction (92%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/hopper/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/hopper/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/hopper/player.mcfunction (93%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/repeater/click.mcfunction (95%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/repeater/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/repeater/flip.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/unique_blocks/repeater/player.mcfunction (97%) create mode 100644 data/lzstools_wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction rename data/{wrench => lzstools_wrench}/function/rotate/xyz/click.mcfunction (93%) rename data/{wrench => lzstools_wrench}/function/rotate/xyz/cycle.mcfunction (100%) rename data/{wrench => lzstools_wrench}/function/rotate/xyz/player.mcfunction (100%) create mode 100644 data/lzstools_wrench/function/rotate/xyz/rotate.mcfunction create mode 100644 data/lzstools_wrench/function/wrench/offhand.mcfunction rename data/{wrench => lzstools_wrench}/function/wrench/rotate.mcfunction (78%) rename data/{wrench => lzstools_wrench}/function/wrench/terracotta.mcfunction (58%) rename data/{wrench/item_modifier/wrench_default.json => lzstools_wrench/item_modifier/default.json} (100%) rename data/{wrench/item_modifier/wrench_face_click.json => lzstools_wrench/item_modifier/face_click.json} (100%) rename data/{wrench/item_modifier/wrench_face_player.json => lzstools_wrench/item_modifier/face_player.json} (100%) rename data/{wrench/item_modifier/wrench_flip.json => lzstools_wrench/item_modifier/flip.json} (100%) rename data/{wrench/item_modifier/wrench_terracotta_east.json => lzstools_wrench/item_modifier/terracotta_east.json} (100%) rename data/{wrench/item_modifier/wrench_terracotta_north.json => lzstools_wrench/item_modifier/terracotta_north.json} (100%) rename data/{wrench/item_modifier/wrench_terracotta_south.json => lzstools_wrench/item_modifier/terracotta_south.json} (100%) rename data/{wrench/item_modifier/wrench_terracotta_west.json => lzstools_wrench/item_modifier/terracotta_west.json} (100%) rename data/{wrench => lzstools_wrench}/recipe/wrench.json (79%) delete mode 100644 data/wrench/function/raycast/partialbox.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/banners.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/bell.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/campfires.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/comparator.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/pistons.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/rails.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/repeater.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/slabs.mcfunction delete mode 100644 data/wrench/function/raycast/partialbox/trapdoors.mcfunction delete mode 100644 data/wrench/function/raycast/rayloop.mcfunction delete mode 100644 data/wrench/function/raycast/unique.mcfunction delete mode 100644 data/wrench/function/rotate/banners/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/glazed_terracotta/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/nesw/player.mcfunction delete mode 100644 data/wrench/function/rotate/nesw/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/neswud/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/rails/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/signs/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/signs_hanging/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/signs_wall/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/slabs/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/stairs/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/trapdoors/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction delete mode 100644 data/wrench/function/rotate/xyz/rotate.mcfunction delete mode 100644 data/wrench/function/wrench/offhand.mcfunction diff --git a/LICENSE.txt b/LICENSE similarity index 97% rename from LICENSE.txt rename to LICENSE index 1933520..0b19416 100644 --- a/LICENSE.txt +++ b/LICENSE @@ -2,6 +2,7 @@ MIT License Copyright (c) 2025 Mark Rapson (LZStealth) Copyright (c) 2021 GoldenDelicios +Copyright (c) 2024 maybejake Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index 7536649..9862f73 100644 --- a/README.md +++ b/README.md @@ -1,39 +1,18 @@ -# LZ Wrench (Block Rotator) +# LZs Tools -## How to use: +## Tools +- Wrench - Rotates blocks +- Trowels - Places random blocks from the hotbar + +Additionally, you can change the Wrench's mode by right clicking in your offhand. +Information on how the different wrench modes work is available [here](WrenchModes.md). + +## Install * Drop the datapack into your world's datapacks folder. * Type `/reload` or restart your world/server to enable the datapack. -* Craft the wrench using two stick and a copper ingot. - -The wrench can currently rotate these blocks: -* Pillars and other similarly placed blocks - * All bark and logs, of all tree types, stripped or not - * Quartz and purpur pillars - * Hay bales - * Bone blocks -* The following redstone components: - * pistons - * sticky pistons - * barrel - * dispensers - * droppers - * observers - * hoppers - * repeaters - * comparators - * calibrated sculk sensor -* Glazed terracotta -* Rails -* End rods -* Stairs -* Slabs -* Trapdoors -...and many more - -Additionally, you can change the Wrench's mode by right clicking in your offhand. -Information on how the different modes work is available in `WrenchModes.md`. - -## Options +* Recepies will be given when entering the world. +* +## Uninstall The Datapack can also be removed using `/function lzstools:uninstall`, this will remove all scoreboard components. -Version 2.0 +Version 2.2 \ No newline at end of file diff --git a/assets/lzstools/models/items/trowel/diamond.json b/assets/lzstools/models/items/trowel/diamond.json new file mode 100644 index 0000000..ddd7723 --- /dev/null +++ b/assets/lzstools/models/items/trowel/diamond.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/handheld", + "textures": { + "layer0": "lzstools:item/trowel/diamond" + } +} \ No newline at end of file diff --git a/assets/lzstools/models/items/trowel/iron.json b/assets/lzstools/models/items/trowel/iron.json new file mode 100644 index 0000000..3733ace --- /dev/null +++ b/assets/lzstools/models/items/trowel/iron.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/handheld", + "textures": { + "layer0": "lzstools:item/trowel/iron" + } +} \ No newline at end of file diff --git a/assets/lzstools/textures/item/trowel/diamond.png b/assets/lzstools/textures/item/trowel/diamond.png new file mode 100644 index 0000000000000000000000000000000000000000..a35ef9137c44554b63e43262a08cd9d2f7bd8f61 GIT binary patch literal 392 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D%zH9TD$Lo9la zPIA;>DHJ(YpKQK!#-c4I&e72_YrBms-?$bB1ufF>J9YMGrvJOFew9;KU8@UcNUsc4 zI-Qw)TTD0kcJ5^vm$mb_>(`nkt3S2gd-(Ug?|Z-7{>aa8^l;PCY-Fnu>TO|ls7vlH z(00i#lWMsANtq#k=_dP&9;&JCSwT~Gg)G%G<`*}rs?>=6Jeldjv(@u9+&DLH)1$bF z$C5Ya&v^P{M$rGl1D}6xU1j{6-6C(IiCi{!cg68^sR#AVzZdf`RBe%GIIe5<=AKDw z-;IW@m3QAPEzWX^wcEaH-Idu^8+>CcY7c2vN*(Zi*f&9P;-BMIipG~Ntglt?=jRJt z5qjhFy)EBTwyiwgTe~DWM4fJ@ch4 literal 0 HcmV?d00001 diff --git a/assets/lzstools/textures/item/trowel/iron.png b/assets/lzstools/textures/item/trowel/iron.png new file mode 100644 index 0000000000000000000000000000000000000000..30425622aeb27ff033f2638c4dd766d520b73d39 GIT binary patch literal 346 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|etEh$hFJ6- zowU*Gh=Yi$f68kXmf0V;96M5{sLl*QyX>G@Mf4^H<{$T$@UB%GQRB_H87ePh`&7-dbl4OoE@Em4nFihKj zz(eQsrK?kd-d%~Rb}zo{+OjND#?UvoYtaD-<^yq!>t5g4n;We@>A7W8Hvf$Kj`zPa zusD8r%c)$pY{HuBddmV@G`j9Qd%dgda=F!sBir}b7T>S0G0ino@igLWdw8DD=;Pba zl5?kjPuqR``eD0BwS9Z{?%Oi+N7=sWLtGD@J-RYacK(MCTjs9$FQj+Ob=!ZY`8g@k oG4YGv90rC0UuuMBny)W|7Ld&W#2|1fcru9cboFyt=akR{0D}#XSpWb4 literal 0 HcmV?d00001 diff --git a/assets/minecraft/items/carrot_on_a_stick.json b/assets/minecraft/items/carrot_on_a_stick.json index f7b06be..7e68d2f 100644 --- a/assets/minecraft/items/carrot_on_a_stick.json +++ b/assets/minecraft/items/carrot_on_a_stick.json @@ -11,7 +11,9 @@ { "when": "lzstools:wrench_flip", "model": { "type": "model", "model": "lzstools:items/wrench/flip" } }, { "when": "lzstools:wrench_face_player", "model": { "type": "model", "model": "lzstools:items/wrench/face_player" } }, { "when": "lzstools:wrench_face_click", "model": { "type": "model", "model": "lzstools:items/wrench/face_click" } }, - { "when": "lzstools:wrench_terracotta", "model": { "type": "model", "model": "lzstools:items/wrench/terracotta" } } + { "when": "lzstools:wrench_terracotta", "model": { "type": "model", "model": "lzstools:items/wrench/terracotta" } }, + { "when": "lzstools:trowel_iron", "model": { "type": "model", "model": "lzstools:items/trowel/iron" } }, + { "when": "lzstools:trowel_diamond", "model": { "type": "model", "model": "lzstools:items/trowel/diamond" } } ] } } \ No newline at end of file diff --git a/data/lzstools/advancement/visible/root.json b/data/lzstools/advancement/visible/root.json index ecfdf82..0b8f7d2 100644 --- a/data/lzstools/advancement/visible/root.json +++ b/data/lzstools/advancement/visible/root.json @@ -1,20 +1,20 @@ { "display": { "icon": { - "id": "minecraft:warped_fungus_on_a_stick", + "id": "minecraft:carrot_on_a_stick", "components": { "minecraft:custom_model_data": { "strings": [ - "lzstools:wrench" + "lzstools:wrench_default" ] } } }, - "title": "LZ's Build Things", + "title": "LZ's Tools", "description": { "text": "Tools that you may find useful!" }, - "background": "minecraft:block/dirt", + "background": "minecraft:block/deepslate_tiles", "show_toast": false, "announce_to_chat": false }, diff --git a/data/lzstools/advancement/visible/trowel_diamond.json b/data/lzstools/advancement/visible/trowel_diamond.json new file mode 100644 index 0000000..45eea26 --- /dev/null +++ b/data/lzstools/advancement/visible/trowel_diamond.json @@ -0,0 +1,32 @@ +{ + "display": { + "icon": { + "id": "minecraft:carrot_on_a_stick", + "components": { + "minecraft:custom_model_data": { + "strings": [ + "lzstools:trowel_diamond" + ] + } + } + }, + "title": { + "text": "Trowel and error" + }, + "description": { + "text": "Craft a Diamond Trowel" + }, + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "parent": "lzstools:visible/trowel_iron", + "criteria": { + "": { + "trigger": "minecraft:recipe_crafted", + "conditions": { + "recipe_id": "lzstools_trowel:diamond" + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/advancement/visible/trowel_iron.json b/data/lzstools/advancement/visible/trowel_iron.json new file mode 100644 index 0000000..fab173b --- /dev/null +++ b/data/lzstools/advancement/visible/trowel_iron.json @@ -0,0 +1,32 @@ +{ + "display": { + "icon": { + "id": "minecraft:carrot_on_a_stick", + "components": { + "minecraft:custom_model_data": { + "strings": [ + "lzstools:trowel_iron" + ] + } + } + }, + "title": { + "text": "It's a shovel for lil' you!" + }, + "description": { + "text": "Craft a Trowel" + }, + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "parent": "lzstools:visible/root", + "criteria": { + "": { + "trigger": "minecraft:recipe_crafted", + "conditions": { + "recipe_id": "lzstools_trowel:iron" + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/advancement/visible/wrench.json b/data/lzstools/advancement/visible/wrench.json index dbe954d..aa95580 100644 --- a/data/lzstools/advancement/visible/wrench.json +++ b/data/lzstools/advancement/visible/wrench.json @@ -1,33 +1,32 @@ { - "display": { - "icon": { - "id": "minecraft:carrot_on_a_stick", - "components": { - "minecraft:custom_model_data": { - "strings": [ - "lzstools:wrench", - "lzstools:wrench_default" - ] + "display": { + "icon": { + "id": "minecraft:carrot_on_a_stick", + "components": { + "minecraft:custom_model_data": { + "strings": [ + "lzstools:wrench_default" + ] + } + } + }, + "title": { + "text": "Pivot, PIVOT!" + }, + "description": { + "text": "Craft a Block Wrench" + }, + "show_toast": true, + "announce_to_chat": false, + "hidden": false + }, + "parent": "lzstools:visible/root", + "criteria": { + "": { + "trigger": "minecraft:recipe_crafted", + "conditions": { + "recipe_id": "lzstools_wrench:wrench" + } } - } - }, - "title": { - "text": "Pivot, PIVOT!" - }, - "description": { - "text": "Craft a Block Wrench" - }, - "show_toast": true, - "announce_to_chat": true, - "hidden": false - }, - "parent": "lzstools:visible/root", - "criteria": { - "": { - "trigger": "minecraft:recipe_crafted", - "conditions": { - "recipe_id": "wrench:wrench" - } } - } } \ No newline at end of file diff --git a/data/lzstools/function/give/trowel_diamond.mcfunction b/data/lzstools/function/give/trowel_diamond.mcfunction new file mode 100644 index 0000000..39a76b7 --- /dev/null +++ b/data/lzstools/function/give/trowel_diamond.mcfunction @@ -0,0 +1 @@ +give @s minecraft:carrot_on_a_stick[minecraft:custom_name={"text":"Diamond Trowel","color":"aqua"},minecraft:custom_model_data={strings:["lzstools:trowel_diamond"]},minecraft:custom_data={"lzstools":["trowel","trowel_diamond"]}] \ No newline at end of file diff --git a/data/lzstools/function/give/trowel_iron.mcfunction b/data/lzstools/function/give/trowel_iron.mcfunction new file mode 100644 index 0000000..43ad3dd --- /dev/null +++ b/data/lzstools/function/give/trowel_iron.mcfunction @@ -0,0 +1 @@ +give @s minecraft:carrot_on_a_stick[minecraft:custom_name={"text":"Iron Trowel","color":"aqua"},minecraft:custom_model_data={strings:["lzstools:trowel_iron"]},minecraft:custom_data={"lzstools":["trowel","trowel_iron"]}] \ No newline at end of file diff --git a/data/lzstools/function/give/wrench.mcfunction b/data/lzstools/function/give/wrench.mcfunction index c074163..a3d57c2 100644 --- a/data/lzstools/function/give/wrench.mcfunction +++ b/data/lzstools/function/give/wrench.mcfunction @@ -1 +1 @@ -give @s minecraft:carrot_on_a_stick[minecraft:custom_name={"text":"Rotator Wrench","color":"aqua"},minecraft:lore=["Default"],minecraft:custom_model_data={strings:["lzstools:wrench_default"]},minecraft:custom_data={lzstools:"wrench"},minecraft:unbreakable={},minecraft:enchantment_glint_override=false,minecraft:tooltip_display={hidden_components:["minecraft:unbreakable"]}] \ No newline at end of file +give @s minecraft:carrot_on_a_stick[minecraft:custom_name={"text":"Rotator Wrench","color":"aqua"},minecraft:lore=["Default"],minecraft:custom_model_data={strings:["lzstools:wrench_default"]},minecraft:custom_data={"lzstools":["wrench"]},minecraft:unbreakable={},minecraft:enchantment_glint_override=false,minecraft:tooltip_display={hidden_components:["minecraft:unbreakable"]}] \ No newline at end of file diff --git a/data/lzstools/function/load.mcfunction b/data/lzstools/function/load.mcfunction index 3b3aae1..9834cca 100644 --- a/data/lzstools/function/load.mcfunction +++ b/data/lzstools/function/load.mcfunction @@ -3,4 +3,15 @@ scoreboard objectives add lz_click_check minecraft.used:minecraft.carrot_on_a_st # Wrench scoreboard objectives add lz_wrench_success dummy -scoreboard objectives add lz_wrench_raycast dummy \ No newline at end of file +scoreboard objectives add lz_wrench_raycast dummy + +# Trowel +scoreboard objectives add lz_trowel_success dummy +scoreboard objectives add lz_trowel_raycast dummy +scoreboard objectives add lz_trowel_raycast_hit dummy +scoreboard objectives add lz_trowel_block_length dummy +scoreboard objectives add lz_chosen_block_check dummy +scoreboard objectives add lz_trowel_unbreaking_check dummy +scoreboard objectives add lz_trowel_unbreaking_chance dummy +scoreboard objectives add lz_trowel_damage dummy +scoreboard objectives add lz_trowel_max_damage dummy \ No newline at end of file diff --git a/data/lzstools/function/player.mcfunction b/data/lzstools/function/player.mcfunction index c9998a6..a5393a8 100644 --- a/data/lzstools/function/player.mcfunction +++ b/data/lzstools/function/player.mcfunction @@ -2,5 +2,9 @@ scoreboard players set @s lz_click_check 0 # Wrench -execute if predicate lzstools:wrench/mainhand run function wrench:wrench/rotate -execute if predicate lzstools:wrench/offhand run function wrench:wrench/offhand \ No newline at end of file +execute if predicate lzstools:wrench/mainhand run function lzstools_wrench:wrench/rotate +execute if predicate lzstools:wrench/offhand run function lzstools_wrench:wrench/offhand + +# Trowel +execute if predicate lzstools:trowel/mainhand run function lzstools_trowel:mainhand +execute if predicate lzstools:trowel/offhand run function lzstools_trowel:offhand \ No newline at end of file diff --git a/data/lzstools/function/recipes.mcfunction b/data/lzstools/function/recipes.mcfunction index c0618d9..2a5ed95 100644 --- a/data/lzstools/function/recipes.mcfunction +++ b/data/lzstools/function/recipes.mcfunction @@ -1 +1,3 @@ -recipe give @s wrench:wrench \ No newline at end of file +recipe give @s lzstools_wrench:wrench +recipe give @s lzstools_trowel:iron +recipe give @s lzstools_trowel:diamond \ No newline at end of file diff --git a/data/lzstools/predicate/trowel/mainhand.json b/data/lzstools/predicate/trowel/mainhand.json new file mode 100644 index 0000000..d6b22a0 --- /dev/null +++ b/data/lzstools/predicate/trowel/mainhand.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/trowel/offhand.json b/data/lzstools/predicate/trowel/offhand.json new file mode 100644 index 0000000..e02967b --- /dev/null +++ b/data/lzstools/predicate/trowel/offhand.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "offhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/mainhand/1.json b/data/lzstools/predicate/unbreaking/mainhand/1.json new file mode 100644 index 0000000..db5e9ba --- /dev/null +++ b/data/lzstools/predicate/unbreaking/mainhand/1.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 1 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/mainhand/2.json b/data/lzstools/predicate/unbreaking/mainhand/2.json new file mode 100644 index 0000000..d8e9724 --- /dev/null +++ b/data/lzstools/predicate/unbreaking/mainhand/2.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 2 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/mainhand/3.json b/data/lzstools/predicate/unbreaking/mainhand/3.json new file mode 100644 index 0000000..047dbdf --- /dev/null +++ b/data/lzstools/predicate/unbreaking/mainhand/3.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 3 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/mainhand/all.json b/data/lzstools/predicate/unbreaking/mainhand/all.json new file mode 100644 index 0000000..1a8b64b --- /dev/null +++ b/data/lzstools/predicate/unbreaking/mainhand/all.json @@ -0,0 +1,21 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": { + "min": 1, + "max": 3 + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/offhand/1.json b/data/lzstools/predicate/unbreaking/offhand/1.json new file mode 100644 index 0000000..db5e9ba --- /dev/null +++ b/data/lzstools/predicate/unbreaking/offhand/1.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 1 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/offhand/2.json b/data/lzstools/predicate/unbreaking/offhand/2.json new file mode 100644 index 0000000..d8e9724 --- /dev/null +++ b/data/lzstools/predicate/unbreaking/offhand/2.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 2 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/offhand/3.json b/data/lzstools/predicate/unbreaking/offhand/3.json new file mode 100644 index 0000000..047dbdf --- /dev/null +++ b/data/lzstools/predicate/unbreaking/offhand/3.json @@ -0,0 +1,18 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": 3 + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/unbreaking/offhand/all.json b/data/lzstools/predicate/unbreaking/offhand/all.json new file mode 100644 index 0000000..1a8b64b --- /dev/null +++ b/data/lzstools/predicate/unbreaking/offhand/all.json @@ -0,0 +1,21 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantment": "minecraft:unbreaking", + "levels": { + "min": 1, + "max": 3 + } + } + ] + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools/predicate/wrench/mainhand.json b/data/lzstools/predicate/wrench/mainhand.json index 1ba8c37..9e49244 100644 --- a/data/lzstools/predicate/wrench/mainhand.json +++ b/data/lzstools/predicate/wrench/mainhand.json @@ -1,18 +1,17 @@ { - "condition": "minecraft:any_of", - "terms": [ - { - "condition": "minecraft:entity_properties", - "entity": "this", - "predicate": { - "equipment": { - "mainhand": { - "predicates": { - "minecraft:custom_data": "{lzstools:wrench}" - } + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "wrench" + ] } } } - } - ] + } + } } \ No newline at end of file diff --git a/data/lzstools/predicate/wrench/offhand.json b/data/lzstools/predicate/wrench/offhand.json index 5071f31..1dfc17c 100644 --- a/data/lzstools/predicate/wrench/offhand.json +++ b/data/lzstools/predicate/wrench/offhand.json @@ -1,18 +1,17 @@ { - "condition": "minecraft:any_of", - "terms": [ - { - "condition": "minecraft:entity_properties", - "entity": "this", - "predicate": { - "equipment": { - "offhand": { - "predicates": { - "minecraft:custom_data": "{lzstools:wrench}" - } + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "offhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "wrench" + ] } } } } - ] + } } \ No newline at end of file diff --git a/data/wrench/tags/block/banners.json b/data/lzstools/tags/block/banners.json similarity index 100% rename from data/wrench/tags/block/banners.json rename to data/lzstools/tags/block/banners.json diff --git a/data/wrench/tags/block/glazed_terracotta.json b/data/lzstools/tags/block/glazed_terracotta.json similarity index 100% rename from data/wrench/tags/block/glazed_terracotta.json rename to data/lzstools/tags/block/glazed_terracotta.json diff --git a/data/wrench/tags/block/nesw.json b/data/lzstools/tags/block/nesw.json similarity index 100% rename from data/wrench/tags/block/nesw.json rename to data/lzstools/tags/block/nesw.json diff --git a/data/wrench/tags/block/neswud.json b/data/lzstools/tags/block/neswud.json similarity index 100% rename from data/wrench/tags/block/neswud.json rename to data/lzstools/tags/block/neswud.json diff --git a/data/wrench/tags/block/partialbox.json b/data/lzstools/tags/block/partialbox.json similarity index 100% rename from data/wrench/tags/block/partialbox.json rename to data/lzstools/tags/block/partialbox.json diff --git a/data/wrench/tags/block/unique.json b/data/lzstools/tags/block/unique.json similarity index 100% rename from data/wrench/tags/block/unique.json rename to data/lzstools/tags/block/unique.json diff --git a/data/wrench/tags/block/updates.json b/data/lzstools/tags/block/updates.json similarity index 100% rename from data/wrench/tags/block/updates.json rename to data/lzstools/tags/block/updates.json diff --git a/data/wrench/tags/block/xyz.json b/data/lzstools/tags/block/xyz.json similarity index 100% rename from data/wrench/tags/block/xyz.json rename to data/lzstools/tags/block/xyz.json diff --git a/data/lzstools_trowel/function/block/place.mcfunction b/data/lzstools_trowel/function/block/place.mcfunction new file mode 100644 index 0000000..8b05b05 --- /dev/null +++ b/data/lzstools_trowel/function/block/place.mcfunction @@ -0,0 +1,4 @@ +scoreboard players set @s lz_trowel_success 0 + +execute if score @s lz_trowel_success matches 0 run function lzstools_trowel:block/place_normal with storage lzstools:trowel +execute if score @s lz_trowel_success matches 1 run function lzstools_trowel:block/remove_item with storage lzstools:trowel \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/leaves.mcfunction b/data/lzstools_trowel/function/block/place/leaves.mcfunction new file mode 100644 index 0000000..03ebe48 --- /dev/null +++ b/data/lzstools_trowel/function/block/place/leaves.mcfunction @@ -0,0 +1,2 @@ +# Place Leaves +$setblock ~ ~ ~ $(chosen_block)[persistent=true] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/nesw.mcfunction b/data/lzstools_trowel/function/block/place/nesw.mcfunction new file mode 100644 index 0000000..b5e8c43 --- /dev/null +++ b/data/lzstools_trowel/function/block/place/nesw.mcfunction @@ -0,0 +1,5 @@ +# Place NESW +$execute as @s[y_rotation=-45..45] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=north] keep +$execute as @s[y_rotation=45..135] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=east] keep +$execute as @s[y_rotation=135..-135] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=south] keep +$execute as @s[y_rotation=-135..-45] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=west] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/neswud.mcfunction b/data/lzstools_trowel/function/block/place/neswud.mcfunction new file mode 100644 index 0000000..92f0c4c --- /dev/null +++ b/data/lzstools_trowel/function/block/place/neswud.mcfunction @@ -0,0 +1,7 @@ +# Place NESWUD +$execute as @s[x_rotation=45..90] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=up] keep +$execute as @s[x_rotation=-90..-45] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=down] keep +$execute as @s[x_rotation=-45..45, y_rotation=-45..45] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=north] keep +$execute as @s[x_rotation=-45..45, y_rotation=45..135] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=east] keep +$execute as @s[x_rotation=-45..45, y_rotation=135..-135] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=south] keep +$execute as @s[x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_trowel_raycast run setblock ~ ~ ~ $(chosen_block)[facing=west] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/slabs.mcfunction b/data/lzstools_trowel/function/block/place/slabs.mcfunction new file mode 100644 index 0000000..8664988 --- /dev/null +++ b/data/lzstools_trowel/function/block/place/slabs.mcfunction @@ -0,0 +1,3 @@ +# Place Slabs +$execute as @s if score py lz_trowel_raycast matches 8.. store result score @s lz_wrench_success run setblock ~ ~ ~ $(chosen_block)[type=top] keep +$execute as @s if score py lz_trowel_raycast matches ..7 store result score @s lz_wrench_success run setblock ~ ~ ~ $(chosen_block)[type=bottom] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/stairs.mcfunction b/data/lzstools_trowel/function/block/place/stairs.mcfunction new file mode 100644 index 0000000..aa50afb --- /dev/null +++ b/data/lzstools_trowel/function/block/place/stairs.mcfunction @@ -0,0 +1,9 @@ +# Place Stairs +$execute as @s[y_rotation=-45..45] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=south] keep +$execute as @s[y_rotation=45..135] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=west] keep +$execute as @s[y_rotation=135..-135] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=north] keep +$execute as @s[y_rotation=-135..-45] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=east] keep +$execute as @s[y_rotation=-45..45] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=south] keep +$execute as @s[y_rotation=45..135] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=west] keep +$execute as @s[y_rotation=135..-135] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=north] keep +$execute as @s[y_rotation=-135..-45] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=east] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place/trapdoors.mcfunction b/data/lzstools_trowel/function/block/place/trapdoors.mcfunction new file mode 100644 index 0000000..e46b5bd --- /dev/null +++ b/data/lzstools_trowel/function/block/place/trapdoors.mcfunction @@ -0,0 +1,10 @@ +# Place Trapdoors +$execute as @s[y_rotation=-45..45] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=north] keep +$execute as @s[y_rotation=45..135] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=east] keep +$execute as @s[y_rotation=135..-135] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=south] keep +$execute as @s[y_rotation=-135..-45] if score py lz_trowel_raycast matches ..7 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=bottom,facing=west] keep +$execute as @s[y_rotation=-45..45] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=north] keep +$execute as @s[y_rotation=45..135] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=east] keep +$execute as @s[y_rotation=135..-135] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=south] keep +$execute as @s[y_rotation=-135..-45] if score py lz_trowel_raycast matches 8.. store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[half=top,facing=west] keep + diff --git a/data/lzstools_trowel/function/block/place/xyz.mcfunction b/data/lzstools_trowel/function/block/place/xyz.mcfunction new file mode 100644 index 0000000..62c417f --- /dev/null +++ b/data/lzstools_trowel/function/block/place/xyz.mcfunction @@ -0,0 +1,7 @@ +# Place XYZ +$execute as @s if score py lz_trowel_raycast matches 0 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=y] keep +$execute as @s if score py lz_trowel_raycast matches 15 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=y] keep +$execute as @s if score px lz_trowel_raycast matches 0 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=x] keep +$execute as @s if score px lz_trowel_raycast matches 15 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=x] keep +$execute as @s if score pz lz_trowel_raycast matches 0 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=z] keep +$execute as @s if score pz lz_trowel_raycast matches 15 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block)[axis=z] keep \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/place_normal.mcfunction b/data/lzstools_trowel/function/block/place_normal.mcfunction new file mode 100644 index 0000000..a5026a6 --- /dev/null +++ b/data/lzstools_trowel/function/block/place_normal.mcfunction @@ -0,0 +1,16 @@ +# Get Raycast Target Coords +function lzstools_trowel:block/target_coords + +$setblock ~ -64 ~ $(chosen_block) + +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #lzstools:xyz run function lzstools_trowel:block/place/xyz with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #lzstools:neswud run function lzstools_trowel:block/place/neswud with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #lzstools:nesw run function lzstools_trowel:block/place/nesw with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #lzstools:glazed_terracotta run function lzstools_trowel:block/place/nesw with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #minecraft:leaves run function lzstools_trowel:block/place/leaves with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #minecraft:trapdoors run function lzstools_trowel:block/place/trapdoors with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #minecraft:stairs run function lzstools_trowel:block/place/stairs with storage lzstools:trowel +execute if score @s lz_trowel_success matches 0 if block ~ -64 ~ #minecraft:slabs run function lzstools_trowel:block/place/slabs with storage lzstools:trowel +$execute if score @s lz_trowel_success matches 0 store result score @s lz_trowel_success run setblock ~ ~ ~ $(chosen_block) keep + +setblock ~ -64 ~ bedrock diff --git a/data/lzstools_trowel/function/block/remove_item.mcfunction b/data/lzstools_trowel/function/block/remove_item.mcfunction new file mode 100644 index 0000000..118173a --- /dev/null +++ b/data/lzstools_trowel/function/block/remove_item.mcfunction @@ -0,0 +1 @@ +$execute if entity @s[gamemode=!creative] run clear @s $(chosen_block) 1 \ No newline at end of file diff --git a/data/lzstools_trowel/function/block/target_coords.mcfunction b/data/lzstools_trowel/function/block/target_coords.mcfunction new file mode 100644 index 0000000..3af421d --- /dev/null +++ b/data/lzstools_trowel/function/block/target_coords.mcfunction @@ -0,0 +1,22 @@ +## Get Raycast Target Coords + +# Stored Value for Calc +scoreboard players set c16 lz_trowel_raycast 16 +# Summon Invisible Entity +summon area_effect_cloud ~ ~ ~ {Radius:0.01,Duration:1,Tags:["RaycastMark"]} + +# Pixel Calculations +execute store result score px lz_trowel_raycast run data get entity @e[tag=RaycastMark,sort=nearest,limit=1] Pos[0] 16 +scoreboard players operation px lz_trowel_raycast %= c16 lz_trowel_raycast +execute if score px lz_trowel_raycast matches ..-1 run scoreboard players add px lz_trowel_raycast 16 + +execute store result score py lz_trowel_raycast run data get entity @e[tag=RaycastMark,sort=nearest,limit=1] Pos[1] 16 +scoreboard players operation py lz_trowel_raycast %= c16 lz_trowel_raycast +execute if score py lz_trowel_raycast matches ..-1 run scoreboard players add py lz_trowel_raycast 16 + +execute store result score pz lz_trowel_raycast run data get entity @e[tag=RaycastMark,sort=nearest,limit=1] Pos[2] 16 +scoreboard players operation pz lz_trowel_raycast %= c16 lz_trowel_raycast +execute if score pz lz_trowel_raycast matches ..-1 run scoreboard players add pz lz_trowel_raycast 16 + +# Remove Entity +kill @e[tag=RaycastMark,sort=nearest,limit=1] \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/mainhand/apply.mcfunction b/data/lzstools_trowel/function/durability/mainhand/apply.mcfunction new file mode 100644 index 0000000..df40173 --- /dev/null +++ b/data/lzstools_trowel/function/durability/mainhand/apply.mcfunction @@ -0,0 +1 @@ +$item modify entity @s weapon.mainhand {"function":"minecraft:set_components","components":{"minecraft:damage":$(damage)}} \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/mainhand/break.mcfunction b/data/lzstools_trowel/function/durability/mainhand/break.mcfunction new file mode 100644 index 0000000..35b80d5 --- /dev/null +++ b/data/lzstools_trowel/function/durability/mainhand/break.mcfunction @@ -0,0 +1,4 @@ +execute if entity @s[predicate=lzstools_trowel:mainhand/iron] at @s anchored eyes run particle minecraft:item{item:"minecraft:iron_sword"} ^ ^-0.35 ^0.65 0.1 0.1 0.1 0.06 10 force +execute if entity @s[predicate=lzstools_trowel:mainhand/diamond] at @s anchored eyes run particle minecraft:item{item:"minecraft:diamond_sword"} ^ ^-0.35 ^0.65 0.1 0.1 0.1 0.06 10 force +item replace entity @s weapon.mainhand with minecraft:air +playsound minecraft:entity.item.break master @a ~ ~ ~ 1 1 \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/mainhand/handle.mcfunction b/data/lzstools_trowel/function/durability/mainhand/handle.mcfunction new file mode 100644 index 0000000..11850d9 --- /dev/null +++ b/data/lzstools_trowel/function/durability/mainhand/handle.mcfunction @@ -0,0 +1,13 @@ +scoreboard players reset @s lz_trowel_unbreaking_check +execute if entity @s[predicate=lzstools:unbreaking/mainhand/all] run function lzstools_trowel:durability/mainhand/unbreaking +execute if score @s lz_trowel_unbreaking_check matches 1 run return fail + +# Handle Damage +data modify storage lzstools:trowel components set from entity @s SelectedItem.components +execute store result score @s lz_trowel_damage run data get storage lzstools:trowel components."minecraft:damage" +execute store result score @s lz_trowel_max_damage run data get storage lzstools:trowel components."minecraft:max_damage" +scoreboard players add @s lz_trowel_damage 1 +execute store result storage lzstools:trowel damage int 1 run scoreboard players get @s lz_trowel_damage + +function lzstools_trowel:durability/mainhand/apply with storage lzstools:trowel +execute if score @s lz_trowel_damage >= @s lz_trowel_max_damage run function lzstools_trowel:durability/mainhand/break \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/mainhand/unbreaking.mcfunction b/data/lzstools_trowel/function/durability/mainhand/unbreaking.mcfunction new file mode 100644 index 0000000..94d1c4e --- /dev/null +++ b/data/lzstools_trowel/function/durability/mainhand/unbreaking.mcfunction @@ -0,0 +1,4 @@ +execute store result score @s lz_trowel_unbreaking_chance run random value 1..100 +execute if entity @s[predicate=lzstools:unbreaking/mainhand/3] if score @s lz_trowel_unbreaking_chance matches ..75 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 +execute if entity @s[predicate=lzstools:unbreaking/mainhand/2] if score @s lz_trowel_unbreaking_chance matches ..66 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 +execute if entity @s[predicate=lzstools:unbreaking/mainhand/1] if score @s lz_trowel_unbreaking_chance matches ..50 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 diff --git a/data/lzstools_trowel/function/durability/offhand/apply.mcfunction b/data/lzstools_trowel/function/durability/offhand/apply.mcfunction new file mode 100644 index 0000000..3025191 --- /dev/null +++ b/data/lzstools_trowel/function/durability/offhand/apply.mcfunction @@ -0,0 +1 @@ +$item modify entity @s weapon.offhand {"function":"minecraft:set_components","components":{"minecraft:damage":$(damage)}} \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/offhand/break.mcfunction b/data/lzstools_trowel/function/durability/offhand/break.mcfunction new file mode 100644 index 0000000..c3ac31d --- /dev/null +++ b/data/lzstools_trowel/function/durability/offhand/break.mcfunction @@ -0,0 +1,4 @@ +execute if entity @s[predicate=lzstools_trowel:offhand/iron] at @s anchored eyes run particle minecraft:item{item:"minecraft:iron_sword"} ^ ^-0.35 ^0.65 0.1 0.1 0.1 0.06 10 force +execute if entity @s[predicate=lzstools_trowel:offhand/diamond] at @s anchored eyes run particle minecraft:item{item:"minecraft:diamond_sword"} ^ ^-0.35 ^0.65 0.1 0.1 0.1 0.06 10 force +item replace entity @s weapon.offhand with minecraft:air +playsound minecraft:entity.item.break master @a ~ ~ ~ 1 1 \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/offhand/handle.mcfunction b/data/lzstools_trowel/function/durability/offhand/handle.mcfunction new file mode 100644 index 0000000..88280e7 --- /dev/null +++ b/data/lzstools_trowel/function/durability/offhand/handle.mcfunction @@ -0,0 +1,13 @@ +scoreboard players reset @s lz_trowel_unbreaking_check +execute if entity @s[predicate=lzstools:unbreaking/offhand/all] run function lzstools_trowel:durability/offhand/unbreaking +execute if score @s lz_trowel_unbreaking_check matches 1 run return fail + +# Handle Damage +data modify storage lzstools:trowel components set from entity @s SelectedItem.components +execute store result score @s lz_trowel_damage run data get storage lzstools:trowel components."minecraft:damage" +execute store result score @s lz_trowel_max_damage run data get storage lzstools:trowel components."minecraft:max_damage" +scoreboard players add @s lz_trowel_damage 1 +execute store result storage lzstools:trowel damage int 1 run scoreboard players get @s lz_trowel_damage + +function lzstools_trowel:durability/offhand/apply with storage lzstools:trowel +execute if score @s lz_trowel_damage >= @s lz_trowel_max_damage run function lzstools_trowel:durability/offhand/break \ No newline at end of file diff --git a/data/lzstools_trowel/function/durability/offhand/unbreaking.mcfunction b/data/lzstools_trowel/function/durability/offhand/unbreaking.mcfunction new file mode 100644 index 0000000..224b524 --- /dev/null +++ b/data/lzstools_trowel/function/durability/offhand/unbreaking.mcfunction @@ -0,0 +1,4 @@ +execute store result score @s lz_trowel_unbreaking_chance run random value 1..100 +execute if entity @s[predicate=lzstools:unbreaking/offhand/3] if score @s lz_trowel_unbreaking_chance matches ..75 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 +execute if entity @s[predicate=lzstools:unbreaking/offhand/2] if score @s lz_trowel_unbreaking_chance matches ..66 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 +execute if entity @s[predicate=lzstools:unbreaking/offhand/1] if score @s lz_trowel_unbreaking_chance matches ..50 run return run scoreboard players set @s lz_trowel_unbreaking_check 1 diff --git a/data/lzstools_trowel/function/mainhand.mcfunction b/data/lzstools_trowel/function/mainhand.mcfunction new file mode 100644 index 0000000..5263ba6 --- /dev/null +++ b/data/lzstools_trowel/function/mainhand.mcfunction @@ -0,0 +1,3 @@ +tag @s add lzstools_trowel_mainhand +# Raycast from player's position +function lzstools_trowel:raycast/start \ No newline at end of file diff --git a/data/lzstools_trowel/function/offhand.mcfunction b/data/lzstools_trowel/function/offhand.mcfunction new file mode 100644 index 0000000..d2649f7 --- /dev/null +++ b/data/lzstools_trowel/function/offhand.mcfunction @@ -0,0 +1,3 @@ +tag @s add lzstools_trowel_offhand +# Raycast from player's position +function lzstools_trowel:raycast/start \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/block_macro.mcfunction b/data/lzstools_trowel/function/random/block_macro.mcfunction new file mode 100644 index 0000000..d4bd741 --- /dev/null +++ b/data/lzstools_trowel/function/random/block_macro.mcfunction @@ -0,0 +1,7 @@ +# No Shulkers +$execute if items entity @s hotbar.$(temp_slot) #minecraft:shulker_boxes run return fail + +$setblock ~ -64 ~ $(temp_id) +setblock ~ -64 ~ bedrock +$data modify storage lzstools:trowel blocks append value "$(temp_id)" +$data modify storage lzstools:trowel slots append value "$(temp_slot)" \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/check_block.mcfunction b/data/lzstools_trowel/function/random/check_block.mcfunction new file mode 100644 index 0000000..5b6cd23 --- /dev/null +++ b/data/lzstools_trowel/function/random/check_block.mcfunction @@ -0,0 +1,3 @@ +function lzstools_trowel:random/block_macro with storage lzstools:trowel +data remove storage lzstools:trowel temp_id +data remove storage lzstools:trowel temp_slot \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/check_hotbar.mcfunction b/data/lzstools_trowel/function/random/check_hotbar.mcfunction new file mode 100644 index 0000000..622d831 --- /dev/null +++ b/data/lzstools_trowel/function/random/check_hotbar.mcfunction @@ -0,0 +1,35 @@ +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:0b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:0b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:1b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:1b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:2b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:2b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:3b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:3b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:4b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:4b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:5b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:5b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:6b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:6b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:7b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:7b}].Slot +function lzstools_trowel:random/check_block + +data modify storage lzstools:trowel temp_id set from storage lzstools:trowel inventory[{Slot:8b}].id +data modify storage lzstools:trowel temp_slot set from storage lzstools:trowel inventory[{Slot:8b}].Slot +function lzstools_trowel:random/check_block \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/get_block.mcfunction b/data/lzstools_trowel/function/random/get_block.mcfunction new file mode 100644 index 0000000..64db666 --- /dev/null +++ b/data/lzstools_trowel/function/random/get_block.mcfunction @@ -0,0 +1,2 @@ +$data modify storage lzstools:trowel chosen_block set from storage lzstools:trowel blocks[$(chosen_index)] +$data modify storage lzstools:trowel chosen_slot set from storage lzstools:trowel slots[$(chosen_index)] \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/random.mcfunction b/data/lzstools_trowel/function/random/random.mcfunction new file mode 100644 index 0000000..9ce8896 --- /dev/null +++ b/data/lzstools_trowel/function/random/random.mcfunction @@ -0,0 +1 @@ +$return run random value 0..$(length) \ No newline at end of file diff --git a/data/lzstools_trowel/function/random/start.mcfunction b/data/lzstools_trowel/function/random/start.mcfunction new file mode 100644 index 0000000..a3b94f5 --- /dev/null +++ b/data/lzstools_trowel/function/random/start.mcfunction @@ -0,0 +1,30 @@ +# Clear Storage +data remove storage lzstools:trowel slots +data remove storage lzstools:trowel blocks +data remove storage lzstools:trowel length +data remove storage lzstools:trowel temp_slot +data remove storage lzstools:trowel temp_id +data remove storage lzstools:trowel chosen_index +data remove storage lzstools:trowel chosen_block +data remove storage lzstools:trowel chosen_slot + +data modify storage lzstools:trowel inventory set from entity @s Inventory + +#store valid blocks +function lzstools_trowel:random/check_hotbar with storage lzstools:trowel + +# Get blocks length +execute store result score @s lz_trowel_block_length run data get storage lzstools:trowel blocks +scoreboard players remove @s lz_trowel_block_length 1 + +# Stop if no blocks +execute if score @s lz_trowel_block_length matches ..-1 run return fail + +# Store result +execute store result storage lzstools:trowel length int 1 run scoreboard players get @s lz_trowel_block_length + +# Pick Block +execute store result storage lzstools:trowel chosen_index int 1 run function lzstools_trowel:random/random with storage lzstools:trowel + +# Get Block +function lzstools_trowel:random/get_block with storage lzstools:trowel \ No newline at end of file diff --git a/data/lzstools_trowel/function/raycast/hit.mcfunction b/data/lzstools_trowel/function/raycast/hit.mcfunction new file mode 100644 index 0000000..5b826cf --- /dev/null +++ b/data/lzstools_trowel/function/raycast/hit.mcfunction @@ -0,0 +1,16 @@ +# Cancel if intercepting entity +execute if entity @n[distance=..1] run return fail + +# Choose Block +function lzstools_trowel:random/start + +# No block, don't place and end +execute store result score @s lz_chosen_block_check run data get storage lzstools:trowel chosen_block +execute if score @s lz_chosen_block_check matches 0 run return fail + +# Place block +function lzstools_trowel:block/place + +# Durability +execute if entity @s[tag=lztools_trowel_mainhand,gamemode=!creative] run function lzstools_trowel:durability/mainhand/handle +execute if entity @s[tag=lztools_trowel_offhand,gamemode=!creative] run function lzstools_trowel:durability/offhand/handle \ No newline at end of file diff --git a/data/lzstools_trowel/function/raycast/rayloop.mcfunction b/data/lzstools_trowel/function/raycast/rayloop.mcfunction new file mode 100644 index 0000000..6321337 --- /dev/null +++ b/data/lzstools_trowel/function/raycast/rayloop.mcfunction @@ -0,0 +1,14 @@ +## Raycast + +# Set block data +execute as @s store result score @s lz_trowel_raycast_hit run loot spawn ~ -65 ~ mine ~ ~ ~ minecraft:netherite_pickaxe[minecraft:enchantments={"minecraft:silk_touch":1}] +execute as @s run kill @n[type=minecraft:item,distance=..0.5,y=-65] + + +execute as @s if score @s lz_trowel_raycast_hit matches 1 positioned ^ ^ ^-0.01 run function lzstools_trowel:raycast/hit +execute if score @s lz_trowel_raycast_hit matches 1 run tag @s remove lzstools_trowel_mainhand +execute if score @s lz_trowel_raycast_hit matches 1 run tag @s remove lzstools_trowel_offhand + +# Advance forward and if nothing found +scoreboard players add #distance lz_trowel_raycast 1 +execute if score @s lz_trowel_raycast_hit matches 0 if score #distance lz_trowel_raycast matches ..451 positioned ^ ^ ^0.01 run function lzstools_trowel:raycast/rayloop \ No newline at end of file diff --git a/data/lzstools_trowel/function/raycast/start.mcfunction b/data/lzstools_trowel/function/raycast/start.mcfunction new file mode 100644 index 0000000..023a614 --- /dev/null +++ b/data/lzstools_trowel/function/raycast/start.mcfunction @@ -0,0 +1,9 @@ +#Setting up the raycasting data. +scoreboard players set #distance lz_trowel_raycast 0 +tag @s add lz_trowel_raycast + +#Activating the raycast. This function will call itself until it is done. +execute as @e[tag=lz_trowel_raycast] at @s anchored eyes positioned ^ ^ ^ run function lzstools_trowel:raycast/rayloop + +#Raycasting finished, removing tag from the raycaster. +tag @s remove lz_trowel_raycast \ No newline at end of file diff --git a/data/lzstools_trowel/predicate/mainhand/diamond.json b/data/lzstools_trowel/predicate/mainhand/diamond.json new file mode 100644 index 0000000..a5a8346 --- /dev/null +++ b/data/lzstools_trowel/predicate/mainhand/diamond.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel_diamond" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_trowel/predicate/mainhand/iron.json b/data/lzstools_trowel/predicate/mainhand/iron.json new file mode 100644 index 0000000..a5a8346 --- /dev/null +++ b/data/lzstools_trowel/predicate/mainhand/iron.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "mainhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel_diamond" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_trowel/predicate/offhand/diamond.json b/data/lzstools_trowel/predicate/offhand/diamond.json new file mode 100644 index 0000000..ee3fffa --- /dev/null +++ b/data/lzstools_trowel/predicate/offhand/diamond.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "offhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel_diamond" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_trowel/predicate/offhand/iron.json b/data/lzstools_trowel/predicate/offhand/iron.json new file mode 100644 index 0000000..ee3fffa --- /dev/null +++ b/data/lzstools_trowel/predicate/offhand/iron.json @@ -0,0 +1,17 @@ +{ + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "equipment": { + "offhand": { + "predicates": { + "minecraft:custom_data": { + "lzstools": [ + "trowel_diamond" + ] + } + } + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_trowel/recipe/diamond.json b/data/lzstools_trowel/recipe/diamond.json new file mode 100644 index 0000000..50e8b56 --- /dev/null +++ b/data/lzstools_trowel/recipe/diamond.json @@ -0,0 +1,36 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "equipment", + "pattern": [ + " ", + "s ", + " dd" + ], + "key": { + "s": "minecraft:stick", + "d": "minecraft:diamond" + }, + "result": { + "id": "minecraft:carrot_on_a_stick", + "count": 1, + "components": { + "minecraft:max_damage": 4500, + "minecraft:custom_name": { + "text": "Diamond Trowel", + "color": "aqua", + "italic": false + }, + "minecraft:custom_model_data": { + "strings": [ + "lzstools:trowel_diamond" + ] + }, + "minecraft:custom_data": { + "lzstools": [ + "trowel", + "trowel_diamond" + ] + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_trowel/recipe/iron.json b/data/lzstools_trowel/recipe/iron.json new file mode 100644 index 0000000..6928e5e --- /dev/null +++ b/data/lzstools_trowel/recipe/iron.json @@ -0,0 +1,36 @@ +{ + "type": "minecraft:crafting_shaped", + "category": "equipment", + "pattern": [ + " ", + "s ", + " ii" + ], + "key": { + "s": "minecraft:stick", + "i": "minecraft:iron_ingot" + }, + "result": { + "id": "minecraft:carrot_on_a_stick", + "count": 1, + "components": { + "minecraft:max_damage": 750, + "minecraft:custom_name": { + "text": "Iron Trowel", + "color": "aqua", + "italic": false + }, + "minecraft:custom_model_data": { + "strings": [ + "lzstools:trowel_iron" + ] + }, + "minecraft:custom_data": { + "lzstools": [ + "trowel", + "trowel_iron" + ] + } + } + } +} \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox.mcfunction b/data/lzstools_wrench/function/raycast/partialbox.mcfunction new file mode 100644 index 0000000..fd7ca8b --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox.mcfunction @@ -0,0 +1,29 @@ +## Raycast Partial-box + +# Get Raycast Target Coords +function lzstools_wrench:raycast/target_coords + +# Partial Boxes +execute if block ~ ~ ~ #lzstools:banners run function lzstools_wrench:raycast/partialbox/banners +execute if block ~ ~ ~ #minecraft:rails run function lzstools_wrench:raycast/partialbox/rails +execute if block ~ ~ ~ #minecraft:trapdoors run function lzstools_wrench:raycast/partialbox/trapdoors +execute if block ~ ~ ~ #minecraft:slabs run function lzstools_wrench:raycast/partialbox/slabs +execute if block ~ ~ ~ #minecraft:stairs run function lzstools_wrench:raycast/partialbox/stairs +execute if block ~ ~ ~ #minecraft:fence_gates run function lzstools_wrench:raycast/partialbox/fence_gates +execute if block ~ ~ ~ #minecraft:campfires run function lzstools_wrench:raycast/partialbox/campfires +execute if block ~ ~ ~ #minecraft:all_signs run function lzstools_wrench:raycast/partialbox/signs +execute if block ~ ~ ~ #minecraft:anvil run function lzstools_wrench:raycast/partialbox/anvils +execute if block ~ ~ ~ minecraft:repeater run function lzstools_wrench:raycast/partialbox/repeater +execute if block ~ ~ ~ minecraft:comparator run function lzstools_wrench:raycast/partialbox/comparator +execute if block ~ ~ ~ minecraft:calibrated_sculk_sensor run function lzstools_wrench:raycast/partialbox/calibrated_sculk_sensor +execute if block ~ ~ ~ minecraft:piston run function lzstools_wrench:raycast/partialbox/pistons +execute if block ~ ~ ~ minecraft:sticky_piston run function lzstools_wrench:raycast/partialbox/pistons +execute if block ~ ~ ~ minecraft:hopper run function lzstools_wrench:raycast/partialbox/hopper +execute if block ~ ~ ~ minecraft:end_rod run function lzstools_wrench:raycast/partialbox/end_rod +execute if block ~ ~ ~ minecraft:lightning_rod run function lzstools_wrench:raycast/partialbox/lightning_rod +execute if block ~ ~ ~ minecraft:chain run function lzstools_wrench:raycast/partialbox/chain +execute if block ~ ~ ~ minecraft:decorated_pot run function lzstools_wrench:raycast/partialbox/decorated_pot +execute if block ~ ~ ~ minecraft:stonecutter run function lzstools_wrench:raycast/partialbox/stonecutter +execute if block ~ ~ ~ minecraft:ender_chest run function lzstools_wrench:raycast/partialbox/ender_chest +execute if block ~ ~ ~ minecraft:bell run function lzstools_wrench:raycast/partialbox/bell +execute if block ~ ~ ~ minecraft:grindstone run function lzstools_wrench:raycast/partialbox/grindstone diff --git a/data/wrench/function/raycast/partialbox/anvils.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/anvils.mcfunction similarity index 82% rename from data/wrench/function/raycast/partialbox/anvils.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/anvils.mcfunction index faf955c..d19927b 100644 --- a/data/wrench/function/raycast/partialbox/anvils.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/anvils.mcfunction @@ -1,20 +1,20 @@ # Anvils -execute if score px lz_wrench_raycast matches 3..12 if score pz lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=north] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=north] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=north] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=north] run function wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 3..12 if score pz lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=north] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=north] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=north] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=north] run function lzstools_wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 3..12 if score pz lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=south] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=south] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=south] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=south] run function wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 3..12 if score pz lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=south] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=south] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=south] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=south] run function lzstools_wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 3..12 if score px lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=east] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=east] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score px lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=east] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 6..9 if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=east] run function wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 3..12 if score px lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=east] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=east] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score px lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=east] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 6..9 if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=east] run function lzstools_wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 3..12 if score px lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=west] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=west] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score px lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=west] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 6..9 if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=west] run function wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 3..12 if score px lz_wrench_raycast matches 0..15 if score py lz_wrench_raycast matches 10..15 if block ~ ~ ~ #minecraft:anvil[facing=west] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 0..3 if block ~ ~ ~ #minecraft:anvil[facing=west] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score px lz_wrench_raycast matches 3..12 if score py lz_wrench_raycast matches 4 if block ~ ~ ~ #minecraft:anvil[facing=west] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 6..9 if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 5..9 if block ~ ~ ~ #minecraft:anvil[facing=west] run function lzstools_wrench:rotate/nesw/rotate diff --git a/data/lzstools_wrench/function/raycast/partialbox/banners.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/banners.mcfunction new file mode 100644 index 0000000..52bf6cd --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/banners.mcfunction @@ -0,0 +1,2 @@ +# Banners +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #lzstools:banners run function lzstools_wrench:rotate/banners/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/bell.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/bell.mcfunction new file mode 100644 index 0000000..59b1efc --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/bell.mcfunction @@ -0,0 +1,5 @@ +# Bell +execute if score px lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=north] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=east] run function lzstools_wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=south] run function lzstools_wrench:rotate/nesw/rotate +execute if score pz lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=west] run function lzstools_wrench:rotate/nesw/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction new file mode 100644 index 0000000..29b80ce --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction @@ -0,0 +1,2 @@ +# Calibrated Sculk Sensor +execute if block ~ ~ ~ minecraft:calibrated_sculk_sensor if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/campfires.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/campfires.mcfunction new file mode 100644 index 0000000..ca91977 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/campfires.mcfunction @@ -0,0 +1,2 @@ +# Campfires +execute if block ~ ~ ~ #minecraft:campfires if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/unique_blocks/campfires/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/chain.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/chain.mcfunction similarity index 71% rename from data/wrench/function/raycast/partialbox/chain.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/chain.mcfunction index a7afb50..c84c4e7 100644 --- a/data/wrench/function/raycast/partialbox/chain.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/chain.mcfunction @@ -1,4 +1,4 @@ # Chain -execute if block ~ ~ ~ minecraft:chain[axis=x] if score py lz_wrench_raycast matches 7..8 if score pz lz_wrench_raycast matches 7..8 run function wrench:rotate/xyz/rotate -execute if block ~ ~ ~ minecraft:chain[axis=y] if score px lz_wrench_raycast matches 7..8 if score pz lz_wrench_raycast matches 7..8 run function wrench:rotate/xyz/rotate -execute if block ~ ~ ~ minecraft:chain[axis=z] if score px lz_wrench_raycast matches 7..8 if score py lz_wrench_raycast matches 7..8 run function wrench:rotate/xyz/rotate +execute if block ~ ~ ~ minecraft:chain[axis=x] if score py lz_wrench_raycast matches 7..8 if score pz lz_wrench_raycast matches 7..8 run function lzstools_wrench:rotate/xyz/rotate +execute if block ~ ~ ~ minecraft:chain[axis=y] if score px lz_wrench_raycast matches 7..8 if score pz lz_wrench_raycast matches 7..8 run function lzstools_wrench:rotate/xyz/rotate +execute if block ~ ~ ~ minecraft:chain[axis=z] if score px lz_wrench_raycast matches 7..8 if score py lz_wrench_raycast matches 7..8 run function lzstools_wrench:rotate/xyz/rotate diff --git a/data/lzstools_wrench/function/raycast/partialbox/comparator.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/comparator.mcfunction new file mode 100644 index 0000000..36f4a71 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/comparator.mcfunction @@ -0,0 +1,2 @@ +# Redstone Comprator +execute if block ~ ~ ~ minecraft:comparator if score py lz_wrench_raycast matches ..1 run function lzstools_wrench:rotate/unique_blocks/comparator/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/decorated_pot.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/decorated_pot.mcfunction similarity index 72% rename from data/wrench/function/raycast/partialbox/decorated_pot.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/decorated_pot.mcfunction index 0e38b2f..7bf46b4 100644 --- a/data/wrench/function/raycast/partialbox/decorated_pot.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/decorated_pot.mcfunction @@ -1,2 +1,2 @@ # Decorated Pot -execute if score px lz_wrench_raycast matches 1..14 if score pz lz_wrench_raycast matches 1..14 if block ~ ~ ~ minecraft:decorated_pot run function wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 1..14 if score pz lz_wrench_raycast matches 1..14 if block ~ ~ ~ minecraft:decorated_pot run function lzstools_wrench:rotate/nesw/rotate diff --git a/data/wrench/function/raycast/partialbox/end_rod.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/end_rod.mcfunction similarity index 67% rename from data/wrench/function/raycast/partialbox/end_rod.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/end_rod.mcfunction index 2382072..ea94b96 100644 --- a/data/wrench/function/raycast/partialbox/end_rod.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/end_rod.mcfunction @@ -1,7 +1,7 @@ # End Rod -execute if block ~ ~ ~ minecraft:end_rod[facing=up] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:end_rod[facing=down] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:end_rod[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:end_rod[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:end_rod[facing=east] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:end_rod[facing=west] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=up] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=down] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=east] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:end_rod[facing=west] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate diff --git a/data/wrench/function/raycast/partialbox/ender_chest.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/ender_chest.mcfunction similarity index 59% rename from data/wrench/function/raycast/partialbox/ender_chest.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/ender_chest.mcfunction index 3597b8f..fa006e5 100644 --- a/data/wrench/function/raycast/partialbox/ender_chest.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/ender_chest.mcfunction @@ -1,2 +1,2 @@ # Ender Chest -execute if score px lz_wrench_raycast matches 1..14 if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches ..14 if block ~ ~ ~ minecraft:ender_chest run function wrench:rotate/nesw/rotate +execute if score px lz_wrench_raycast matches 1..14 if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches ..14 if block ~ ~ ~ minecraft:ender_chest run function lzstools_wrench:rotate/nesw/rotate diff --git a/data/wrench/function/raycast/partialbox/fence_gates.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/fence_gates.mcfunction similarity index 56% rename from data/wrench/function/raycast/partialbox/fence_gates.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/fence_gates.mcfunction index 0c62d39..1bb6b82 100644 --- a/data/wrench/function/raycast/partialbox/fence_gates.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/fence_gates.mcfunction @@ -1,9 +1,9 @@ # Fence Gates -execute if block ~ ~ ~ #minecraft:fence_gates[facing=north] if score px lz_wrench_raycast matches 6..9 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=east] if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=south] if score px lz_wrench_raycast matches 6..9 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=west] if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=north,in_wall=true] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=east,in_wall=true] if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=south,in_wall=true] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function wrench:rotate/nesw/rotate -execute if block ~ ~ ~ #minecraft:fence_gates[facing=west,in_wall=true] if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=north] if score px lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=east] if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=south] if score px lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=west] if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=north,in_wall=true] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=east,in_wall=true] if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=south,in_wall=true] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function lzstools_wrench:rotate/nesw/rotate +execute if block ~ ~ ~ #minecraft:fence_gates[facing=west,in_wall=true] if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..12 run function lzstools_wrench:rotate/nesw/rotate diff --git a/data/wrench/function/raycast/partialbox/grindstone.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/grindstone.mcfunction similarity index 71% rename from data/wrench/function/raycast/partialbox/grindstone.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/grindstone.mcfunction index 2535e08..08593e3 100644 --- a/data/wrench/function/raycast/partialbox/grindstone.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/grindstone.mcfunction @@ -1,64 +1,64 @@ # Grindstone # Floor -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4..15 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 7..12 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=floor,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate # Wall -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 0..11 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 4..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 4..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 0..11 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 0..11 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 4..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score pz lz_wrench_raycast matches 4..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 2..13 if score px lz_wrench_raycast matches 0..11 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score pz lz_wrench_raycast matches 3..8 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score px lz_wrench_raycast matches 7..12 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score pz lz_wrench_raycast matches 7..12 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score px lz_wrench_raycast matches 3..8 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score pz lz_wrench_raycast matches 3..8 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score px lz_wrench_raycast matches 7..12 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score pz lz_wrench_raycast matches 7..12 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 5..10 if score px lz_wrench_raycast matches 3..8 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 6..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score pz lz_wrench_raycast matches 0..6 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 0..6 if score px lz_wrench_raycast matches 9..15 if block ~ ~ ~ minecraft:grindstone[face=wall,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate # Ceiling -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score pz lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 0..11 if score px lz_wrench_raycast matches 2..13 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score pz lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..13 if score py lz_wrench_raycast matches 3..8 if score px lz_wrench_raycast matches 5..10 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 2..3 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function wrench:rotate/unique_blocks/grindstone/rotate -execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=north] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=east] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score px lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score pz lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=south] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate +execute if score pz lz_wrench_raycast matches 12..13 if score py lz_wrench_raycast matches 9..15 if score px lz_wrench_raycast matches 6..9 if block ~ ~ ~ minecraft:grindstone[face=ceiling,facing=west] run function lzstools_wrench:rotate/unique_blocks/grindstone/rotate diff --git a/data/wrench/function/raycast/partialbox/hopper.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/hopper.mcfunction similarity index 71% rename from data/wrench/function/raycast/partialbox/hopper.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/hopper.mcfunction index 0f5dde6..5f79ec7 100644 --- a/data/wrench/function/raycast/partialbox/hopper.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/hopper.mcfunction @@ -1,8 +1,8 @@ # Hopper -execute if block ~ ~ ~ minecraft:hopper[facing=down] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..3 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 12.. run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches ..3 run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper[facing=east] if score px lz_wrench_raycast matches 12.. if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper[facing=west] if score px lz_wrench_raycast matches ..3 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4.. if score pz lz_wrench_raycast matches 4..11 run function wrench:rotate/unique_blocks/hopper/rotate -execute if block ~ ~ ~ minecraft:hopper if score py lz_wrench_raycast matches 10.. run function wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper[facing=down] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches ..3 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 12.. run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches ..3 run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper[facing=east] if score px lz_wrench_raycast matches 12.. if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper[facing=west] if score px lz_wrench_raycast matches ..3 if score py lz_wrench_raycast matches 4..7 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper if score px lz_wrench_raycast matches 4..11 if score py lz_wrench_raycast matches 4.. if score pz lz_wrench_raycast matches 4..11 run function lzstools_wrench:rotate/unique_blocks/hopper/rotate +execute if block ~ ~ ~ minecraft:hopper if score py lz_wrench_raycast matches 10.. run function lzstools_wrench:rotate/unique_blocks/hopper/rotate diff --git a/data/wrench/function/raycast/partialbox/lightning_rod.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/lightning_rod.mcfunction similarity index 65% rename from data/wrench/function/raycast/partialbox/lightning_rod.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/lightning_rod.mcfunction index aee71b8..d09c3a8 100644 --- a/data/wrench/function/raycast/partialbox/lightning_rod.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/lightning_rod.mcfunction @@ -1,7 +1,7 @@ # Lightning Rod -execute if block ~ ~ ~ minecraft:lightning_rod[facing=up] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:lightning_rod[facing=down] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:lightning_rod[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:lightning_rod[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:lightning_rod[facing=east] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:lightning_rod[facing=west] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=up] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=down] if score px lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=south] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=north] if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=east] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:lightning_rod[facing=west] if score py lz_wrench_raycast matches 6..9 if score pz lz_wrench_raycast matches 6..9 run function lzstools_wrench:rotate/neswud/rotate diff --git a/data/lzstools_wrench/function/raycast/partialbox/pistons.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/pistons.mcfunction new file mode 100644 index 0000000..530583c --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/pistons.mcfunction @@ -0,0 +1,17 @@ +# Piston +execute if block ~ ~ ~ minecraft:piston[extended=false] run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=up] if score py lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=down] if score py lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=south] if score pz lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=north] if score pz lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=east] if score px lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:piston[facing=west] if score px lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate + +# Sticky Piston +execute if block ~ ~ ~ minecraft:sticky_piston[extended=false] run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=up] if score py lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=down] if score py lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=south] if score pz lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=north] if score pz lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=east] if score px lz_wrench_raycast matches ..11 run function lzstools_wrench:rotate/neswud/rotate +execute if block ~ ~ ~ minecraft:sticky_piston[facing=west] if score px lz_wrench_raycast matches 4.. run function lzstools_wrench:rotate/neswud/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/rails.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/rails.mcfunction new file mode 100644 index 0000000..0fbdc60 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/rails.mcfunction @@ -0,0 +1,6 @@ +# Rails +execute if block ~ ~ ~ #minecraft:rails if score py lz_wrench_raycast matches ..1 run function lzstools_wrench:rotate/rails/rotate +execute if block ~ ~ ~ #minecraft:rails[shape=ascending_west] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/rails/rotate +execute if block ~ ~ ~ #minecraft:rails[shape=ascending_east] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/rails/rotate +execute if block ~ ~ ~ #minecraft:rails[shape=ascending_north] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/rails/rotate +execute if block ~ ~ ~ #minecraft:rails[shape=ascending_south] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/rails/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/repeater.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/repeater.mcfunction new file mode 100644 index 0000000..cddd949 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/repeater.mcfunction @@ -0,0 +1,2 @@ +# Redstone Repeater +execute if block ~ ~ ~ minecraft:repeater if score py lz_wrench_raycast matches ..1 run function lzstools_wrench:rotate/unique_blocks/repeater/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/signs.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/signs.mcfunction similarity index 66% rename from data/wrench/function/raycast/partialbox/signs.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/signs.mcfunction index e033f15..b646fc3 100644 --- a/data/wrench/function/raycast/partialbox/signs.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/signs.mcfunction @@ -1,31 +1,31 @@ # Signs -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:standing_signs run function wrench:rotate/signs/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:standing_signs run function lzstools_wrench:rotate/signs/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=1] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=2] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=3] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=5] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=6] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=7] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=9] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=10] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=11] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=13] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=14] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=15] run function wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=1] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=2] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=3] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=5] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=6] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=7] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=9] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=10] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=11] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=13] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=14] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=15] run function lzstools_wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=0] run function wrench:rotate/signs_hanging/rotate -execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=8] run function wrench:rotate/signs_hanging/rotate -execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=4] run function wrench:rotate/signs_hanging/rotate -execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=12] run function wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=0] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=8] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=4] run function lzstools_wrench:rotate/signs_hanging/rotate +execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:ceiling_hanging_signs[rotation=12] run function lzstools_wrench:rotate/signs_hanging/rotate # Wall hanging signs can't be defined with the current method of getting the block ID so these fail as it's updated to the standard hanging sign -# execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=north] run function wrench:rotate/signs_wall/rotate -# execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=east] run function wrench:rotate/signs_wall/rotate -# execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=south] run function wrench:rotate/signs_wall/rotate -# execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=west] run function wrench:rotate/signs_wall/rotate +# execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=north] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=east] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score pz lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=south] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score pz lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 0..9 if score px lz_wrench_raycast matches 7..8 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=west] run function lzstools_wrench:rotate/signs_wall/rotate -# execute if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=north] run function wrench:rotate/signs_wall/rotate -# execute if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=east] run function wrench:rotate/signs_wall/rotate -# execute if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=south] run function wrench:rotate/signs_wall/rotate -# execute if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=west] run function wrench:rotate/signs_wall/rotate \ No newline at end of file +# execute if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=north] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=east] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score px lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=south] run function lzstools_wrench:rotate/signs_wall/rotate +# execute if score pz lz_wrench_raycast matches 6..9 if score py lz_wrench_raycast matches 14..15 if block ~ ~ ~ #minecraft:wall_hanging_signs[facing=west] run function lzstools_wrench:rotate/signs_wall/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/slabs.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/slabs.mcfunction new file mode 100644 index 0000000..efc5879 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/slabs.mcfunction @@ -0,0 +1,3 @@ +# Slabs +execute if block ~ ~ ~ #minecraft:slabs[type=top] if score py lz_wrench_raycast matches 8.. run function lzstools_wrench:rotate/slabs/rotate +execute if block ~ ~ ~ #minecraft:slabs[type=bottom] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/slabs/rotate diff --git a/data/wrench/function/raycast/partialbox/stairs.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/stairs.mcfunction similarity index 76% rename from data/wrench/function/raycast/partialbox/stairs.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/stairs.mcfunction index bddfa93..7d185f9 100644 --- a/data/wrench/function/raycast/partialbox/stairs.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/stairs.mcfunction @@ -1,20 +1,20 @@ # Stairs -execute if block ~ ~ ~ #minecraft:stairs[half=bottom] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs[half=top] if score py lz_wrench_raycast matches 8.. run function wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs[half=bottom] if score py lz_wrench_raycast matches ..7 run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs[half=top] if score py lz_wrench_raycast matches 8.. run function lzstools_wrench:rotate/stairs/rotate # -x-z -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 unless block ~ ~ ~ #minecraft:stairs[facing=west,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=north,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=east] unless block ~ ~ ~ #minecraft:stairs[facing=south] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=east,shape=inner_left] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=south,shape=inner_right] run function wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 unless block ~ ~ ~ #minecraft:stairs[facing=west,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=north,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=east] unless block ~ ~ ~ #minecraft:stairs[facing=south] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=east,shape=inner_left] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=south,shape=inner_right] run function lzstools_wrench:rotate/stairs/rotate # -x+z -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. unless block ~ ~ ~ #minecraft:stairs[facing=south,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=west,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=north] unless block ~ ~ ~ #minecraft:stairs[facing=east] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=north,shape=inner_left] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=east,shape=inner_right] run function wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. unless block ~ ~ ~ #minecraft:stairs[facing=south,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=west,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=north] unless block ~ ~ ~ #minecraft:stairs[facing=east] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=north,shape=inner_left] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches ..7 if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=east,shape=inner_right] run function lzstools_wrench:rotate/stairs/rotate # +x+z -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. unless block ~ ~ ~ #minecraft:stairs[facing=east,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=south,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=west] unless block ~ ~ ~ #minecraft:stairs[facing=north] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=west,shape=inner_left] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=north,shape=inner_right] run function wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. unless block ~ ~ ~ #minecraft:stairs[facing=east,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=south,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=west] unless block ~ ~ ~ #minecraft:stairs[facing=north] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=west,shape=inner_left] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches 8.. if block ~ ~ ~ #minecraft:stairs[facing=north,shape=inner_right] run function lzstools_wrench:rotate/stairs/rotate # +x-z -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 unless block ~ ~ ~ #minecraft:stairs[facing=north,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=east,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=south] unless block ~ ~ ~ #minecraft:stairs[facing=west] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=south,shape=inner_left] run function wrench:rotate/stairs/rotate -execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=west,shape=inner_right] run function wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 unless block ~ ~ ~ #minecraft:stairs[facing=north,shape=outer_left] unless block ~ ~ ~ #minecraft:stairs[facing=east,shape=outer_right] unless block ~ ~ ~ #minecraft:stairs[facing=south] unless block ~ ~ ~ #minecraft:stairs[facing=west] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=south,shape=inner_left] run function lzstools_wrench:rotate/stairs/rotate +execute if block ~ ~ ~ #minecraft:stairs if score px lz_wrench_raycast matches 8.. if score pz lz_wrench_raycast matches ..7 if block ~ ~ ~ #minecraft:stairs[facing=west,shape=inner_right] run function lzstools_wrench:rotate/stairs/rotate diff --git a/data/wrench/function/raycast/partialbox/stonecutter.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/stonecutter.mcfunction similarity index 52% rename from data/wrench/function/raycast/partialbox/stonecutter.mcfunction rename to data/lzstools_wrench/function/raycast/partialbox/stonecutter.mcfunction index 24ff339..abefc66 100644 --- a/data/wrench/function/raycast/partialbox/stonecutter.mcfunction +++ b/data/lzstools_wrench/function/raycast/partialbox/stonecutter.mcfunction @@ -1,2 +1,2 @@ # Stonecutter -execute if block ~ ~ ~ minecraft:stonecutter if score py lz_wrench_raycast matches ..9 run function wrench:rotate/nesw/rotate \ No newline at end of file +execute if block ~ ~ ~ minecraft:stonecutter if score py lz_wrench_raycast matches ..9 run function lzstools_wrench:rotate/nesw/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/partialbox/trapdoors.mcfunction b/data/lzstools_wrench/function/raycast/partialbox/trapdoors.mcfunction new file mode 100644 index 0000000..2292c11 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/partialbox/trapdoors.mcfunction @@ -0,0 +1,13 @@ +# Trapdoors + +execute if block ~ ~ ~ #minecraft:trapdoors[open=false,half=top] if score py lz_wrench_raycast matches 13.. run function lzstools_wrench:rotate/trapdoors/rotate +execute if block ~ ~ ~ #minecraft:trapdoors[open=false,half=bottom] if score py lz_wrench_raycast matches ..2 run function lzstools_wrench:rotate/trapdoors/rotate + +# North +execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=north] if score pz lz_wrench_raycast matches 13.. run function lzstools_wrench:rotate/trapdoors/rotate +# East +execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=east] if score px lz_wrench_raycast matches ..2 run function lzstools_wrench:rotate/trapdoors/rotate +# South +execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=south] if score pz lz_wrench_raycast matches ..2 run function lzstools_wrench:rotate/trapdoors/rotate +# West +execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=west] if score px lz_wrench_raycast matches 13.. run function lzstools_wrench:rotate/trapdoors/rotate \ No newline at end of file diff --git a/data/lzstools_wrench/function/raycast/rayloop.mcfunction b/data/lzstools_wrench/function/raycast/rayloop.mcfunction new file mode 100644 index 0000000..1f3872b --- /dev/null +++ b/data/lzstools_wrench/function/raycast/rayloop.mcfunction @@ -0,0 +1,26 @@ +## Raycast + +# Set block data +execute as @s run loot spawn ~ -65 ~ mine ~ ~ ~ minecraft:netherite_pickaxe[minecraft:enchantments={"minecraft:silk_touch":1}] +execute as @s run data modify storage lzstools:wrench block set from entity @n[type=minecraft:item,distance=..0.5,y=-65] Item.id +execute as @s run execute as @s run kill @n[type=minecraft:item,distance=..0.5,y=-65] + +# Partial Blocks +execute if block ~ ~ ~ #lzstools:partialbox run function lzstools_wrench:raycast/partialbox +execute if block ~ ~ ~ #lzstools:banners run function lzstools_wrench:raycast/partialbox + +# Remaining Blocks +execute unless block ~ ~ ~ #lzstools:partialbox if block ~ ~ ~ #lzstools:neswud run function lzstools_wrench:rotate/neswud/rotate +execute unless block ~ ~ ~ #lzstools:partialbox if block ~ ~ ~ #lzstools:nesw run function lzstools_wrench:rotate/nesw/rotate +execute unless block ~ ~ ~ #lzstools:partialbox if block ~ ~ ~ #lzstools:xyz run function lzstools_wrench:rotate/xyz/rotate +execute unless block ~ ~ ~ #lzstools:partialbox if block ~ ~ ~ #lzstools:glazed_terracotta run function lzstools_wrench:rotate/glazed_terracotta/rotate +execute unless block ~ ~ ~ #lzstools:partialbox if block ~ ~ ~ #lzstools:unique run function lzstools_wrench:raycast/unique + +# Force Update on block +execute as @s[scores={lz_wrench_success=1..}] if block ~ ~ ~ #lzstools:updates run clone ~-1 ~ ~ ~1 ~ ~ ~-1 ~ ~ replace force +execute as @s[scores={lz_wrench_success=1..}] if block ~ ~ ~ #lzstools:updates run clone ~ ~ ~-1 ~ ~ ~1 ~ ~ ~-1 replace force +execute as @s[scores={lz_wrench_success=1..}] run playsound minecraft:entity.item_frame.rotate_item block @s ~ ~ ~ + +# Advance forward and if nothing found +scoreboard players add #distance lz_wrench_raycast 1 +execute if score @s lz_wrench_success matches 0 if score #distance lz_wrench_raycast matches ..451 positioned ^ ^ ^0.01 run function lzstools_wrench:raycast/rayloop \ No newline at end of file diff --git a/data/wrench/function/raycast/start.mcfunction b/data/lzstools_wrench/function/raycast/start.mcfunction similarity index 87% rename from data/wrench/function/raycast/start.mcfunction rename to data/lzstools_wrench/function/raycast/start.mcfunction index 21995ba..b3a628a 100644 --- a/data/wrench/function/raycast/start.mcfunction +++ b/data/lzstools_wrench/function/raycast/start.mcfunction @@ -3,7 +3,7 @@ scoreboard players set #distance lz_wrench_raycast 0 tag @s add lz_wrench_raycast #Activating the raycast. This function will call itself until it is done. -execute as @e[tag=lz_wrench_raycast] at @s anchored eyes positioned ^ ^ ^ run function wrench:raycast/rayloop +execute as @e[tag=lz_wrench_raycast] at @s anchored eyes positioned ^ ^ ^ run function lzstools_wrench:raycast/rayloop #Raycasting finished, removing tag from the raycaster. tag @s remove lz_wrench_raycast diff --git a/data/wrench/function/raycast/target_coords.mcfunction b/data/lzstools_wrench/function/raycast/target_coords.mcfunction similarity index 100% rename from data/wrench/function/raycast/target_coords.mcfunction rename to data/lzstools_wrench/function/raycast/target_coords.mcfunction diff --git a/data/lzstools_wrench/function/raycast/unique.mcfunction b/data/lzstools_wrench/function/raycast/unique.mcfunction new file mode 100644 index 0000000..d388019 --- /dev/null +++ b/data/lzstools_wrench/function/raycast/unique.mcfunction @@ -0,0 +1,3 @@ +## Unique Items + +execute if block ~ ~ ~ minecraft:crafter run function lzstools_wrench:rotate/unique_blocks/crafter/rotate \ No newline at end of file diff --git a/data/wrench/function/rotate/banners/click.mcfunction b/data/lzstools_wrench/function/rotate/banners/click.mcfunction similarity index 87% rename from data/wrench/function/rotate/banners/click.mcfunction rename to data/lzstools_wrench/function/rotate/banners/click.mcfunction index 4adbee7..8d7209a 100644 --- a/data/wrench/function/rotate/banners/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/banners/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Banners # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Signs and Banners don't have full hitboxes, nothing else uses numeric rotation $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 4 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[rotation=8] replace @@ -10,4 +10,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 4 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[rotation=4] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/banners/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/banners/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/banners/cycle.mcfunction b/data/lzstools_wrench/function/rotate/banners/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/banners/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/banners/cycle.mcfunction diff --git a/data/wrench/function/rotate/banners/flip.mcfunction b/data/lzstools_wrench/function/rotate/banners/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/banners/flip.mcfunction rename to data/lzstools_wrench/function/rotate/banners/flip.mcfunction diff --git a/data/wrench/function/rotate/banners/player.mcfunction b/data/lzstools_wrench/function/rotate/banners/player.mcfunction similarity index 97% rename from data/wrench/function/rotate/banners/player.mcfunction rename to data/lzstools_wrench/function/rotate/banners/player.mcfunction index a2eb67a..955ff63 100644 --- a/data/wrench/function/rotate/banners/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/banners/player.mcfunction @@ -18,4 +18,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=-56.25..-33.75] store re $execute as @s[scores={lz_wrench_success=0}, y_rotation=-33.75..-11.25] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[rotation=7] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/banners/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/banners/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/banners/rotate.mcfunction b/data/lzstools_wrench/function/rotate/banners/rotate.mcfunction new file mode 100644 index 0000000..e303c20 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/banners/rotate.mcfunction @@ -0,0 +1,7 @@ +## Banners + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/banners/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/banners/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/banners/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/banners/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/glazed_terracotta/cycle.mcfunction b/data/lzstools_wrench/function/rotate/glazed_terracotta/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/glazed_terracotta/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/glazed_terracotta/cycle.mcfunction diff --git a/data/wrench/function/rotate/glazed_terracotta/mode.mcfunction b/data/lzstools_wrench/function/rotate/glazed_terracotta/mode.mcfunction similarity index 97% rename from data/wrench/function/rotate/glazed_terracotta/mode.mcfunction rename to data/lzstools_wrench/function/rotate/glazed_terracotta/mode.mcfunction index 48d84af..a82069f 100644 --- a/data/wrench/function/rotate/glazed_terracotta/mode.mcfunction +++ b/data/lzstools_wrench/function/rotate/glazed_terracotta/mode.mcfunction @@ -12,7 +12,7 @@ $execute as @s[scores={lz_wrench_success=0}, tag=TerracottaSOUTH] store result s $execute as @s[scores={lz_wrench_success=0}, tag=TerracottaWEST] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Advance Terracotta Mode Rotation -function wrench:wrench/terracotta +function lzstools_wrench:wrench/terracotta tag @s[tag=TerracottaNORTH] remove TerracottaNORTH tag @s[tag=TerracottaEAST] remove TerracottaEAST tag @s[tag=TerracottaSOUTH] remove TerracottaSOUTH diff --git a/data/lzstools_wrench/function/rotate/glazed_terracotta/rotate.mcfunction b/data/lzstools_wrench/function/rotate/glazed_terracotta/rotate.mcfunction new file mode 100644 index 0000000..7ac6f83 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/glazed_terracotta/rotate.mcfunction @@ -0,0 +1,4 @@ +## Glazed Terracotta + +execute as @s[nbt={SelectedItem:{components:{"minecraft:lore":["Terracotta"]}}}] run function lzstools_wrench:rotate/glazed_terracotta/mode with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/glazed_terracotta/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/nesw/click.mcfunction b/data/lzstools_wrench/function/rotate/nesw/click.mcfunction similarity index 87% rename from data/wrench/function/rotate/nesw/click.mcfunction rename to data/lzstools_wrench/function/rotate/nesw/click.mcfunction index 8e36a4c..a6d869b 100644 --- a/data/wrench/function/rotate/nesw/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/nesw/click.mcfunction @@ -1,7 +1,7 @@ ## Click NESW # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=north] replace $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 15 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=east] replace @@ -9,4 +9,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/nesw/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/nesw/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/nesw/cycle.mcfunction b/data/lzstools_wrench/function/rotate/nesw/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/nesw/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/nesw/cycle.mcfunction diff --git a/data/wrench/function/rotate/nesw/flip.mcfunction b/data/lzstools_wrench/function/rotate/nesw/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/nesw/flip.mcfunction rename to data/lzstools_wrench/function/rotate/nesw/flip.mcfunction diff --git a/data/lzstools_wrench/function/rotate/nesw/player.mcfunction b/data/lzstools_wrench/function/rotate/nesw/player.mcfunction new file mode 100644 index 0000000..ba68cae --- /dev/null +++ b/data/lzstools_wrench/function/rotate/nesw/player.mcfunction @@ -0,0 +1,9 @@ +## Face Player NESW + +$execute as @s[scores={lz_wrench_success=0}, y_rotation=-45..45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=north] replace +$execute as @s[scores={lz_wrench_success=0}, y_rotation=45..135] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=east] replace +$execute as @s[scores={lz_wrench_success=0}, y_rotation=135..-135] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=south] replace +$execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace + +# Otherwise, Flip +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/nesw/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/nesw/rotate.mcfunction b/data/lzstools_wrench/function/rotate/nesw/rotate.mcfunction new file mode 100644 index 0000000..96ca186 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/nesw/rotate.mcfunction @@ -0,0 +1,7 @@ +## NESW + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/nesw/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/nesw/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/nesw/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/nesw/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/neswud/click.mcfunction b/data/lzstools_wrench/function/rotate/neswud/click.mcfunction similarity index 90% rename from data/wrench/function/rotate/neswud/click.mcfunction rename to data/lzstools_wrench/function/rotate/neswud/click.mcfunction index d79b53c..e4c3913 100644 --- a/data/wrench/function/rotate/neswud/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/neswud/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click NESWUD # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords $execute as @s[scores={lz_wrench_success=0}] if score py lz_wrench_raycast matches 15 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=up] replace $execute as @s[scores={lz_wrench_success=0}] if score py lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=down] replace @@ -11,4 +11,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/neswud/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/neswud/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/neswud/cycle.mcfunction b/data/lzstools_wrench/function/rotate/neswud/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/neswud/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/neswud/cycle.mcfunction diff --git a/data/wrench/function/rotate/neswud/flip.mcfunction b/data/lzstools_wrench/function/rotate/neswud/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/neswud/flip.mcfunction rename to data/lzstools_wrench/function/rotate/neswud/flip.mcfunction diff --git a/data/wrench/function/rotate/neswud/player.mcfunction b/data/lzstools_wrench/function/rotate/neswud/player.mcfunction similarity index 93% rename from data/wrench/function/rotate/neswud/player.mcfunction rename to data/lzstools_wrench/function/rotate/neswud/player.mcfunction index bf0af4a..18454ad 100644 --- a/data/wrench/function/rotate/neswud/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/neswud/player.mcfunction @@ -8,4 +8,4 @@ $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=135. $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/neswud/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/neswud/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/neswud/rotate.mcfunction b/data/lzstools_wrench/function/rotate/neswud/rotate.mcfunction new file mode 100644 index 0000000..30aec47 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/neswud/rotate.mcfunction @@ -0,0 +1,7 @@ +## NESW UD + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/neswud/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/neswud/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/neswud/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/neswud/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/rails/cycle.mcfunction b/data/lzstools_wrench/function/rotate/rails/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/rails/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/rails/cycle.mcfunction diff --git a/data/wrench/function/rotate/rails/player.mcfunction b/data/lzstools_wrench/function/rotate/rails/player.mcfunction similarity index 100% rename from data/wrench/function/rotate/rails/player.mcfunction rename to data/lzstools_wrench/function/rotate/rails/player.mcfunction diff --git a/data/lzstools_wrench/function/rotate/rails/rotate.mcfunction b/data/lzstools_wrench/function/rotate/rails/rotate.mcfunction new file mode 100644 index 0000000..24b3653 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/rails/rotate.mcfunction @@ -0,0 +1,5 @@ +## Rails + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/rails/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/rails/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/signs/click.mcfunction b/data/lzstools_wrench/function/rotate/signs/click.mcfunction similarity index 93% rename from data/wrench/function/rotate/signs/click.mcfunction rename to data/lzstools_wrench/function/rotate/signs/click.mcfunction index b1c7236..a07f6c3 100644 --- a/data/wrench/function/rotate/signs/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/signs/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Signs # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Signs and Banners don't have full hitboxes, nothing else uses numeric rotation $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 4 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true] run setblock ~ ~ ~ $(block)[waterlogged=true,rotation=8] replace @@ -15,4 +15,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 4 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[waterlogged=false,rotation=4] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/signs/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/signs/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/signs/cycle.mcfunction b/data/lzstools_wrench/function/rotate/signs/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/signs/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/signs/cycle.mcfunction diff --git a/data/wrench/function/rotate/signs/flip.mcfunction b/data/lzstools_wrench/function/rotate/signs/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/signs/flip.mcfunction rename to data/lzstools_wrench/function/rotate/signs/flip.mcfunction diff --git a/data/wrench/function/rotate/signs/player.mcfunction b/data/lzstools_wrench/function/rotate/signs/player.mcfunction similarity index 98% rename from data/wrench/function/rotate/signs/player.mcfunction rename to data/lzstools_wrench/function/rotate/signs/player.mcfunction index c229650..d4f88c4 100644 --- a/data/wrench/function/rotate/signs/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/signs/player.mcfunction @@ -35,4 +35,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=-56.25..-33.75] store re $execute as @s[scores={lz_wrench_success=0}, y_rotation=-33.75..-11.25] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[waterlogged=false,rotation=7] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/signs/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/signs/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/signs/rotate.mcfunction b/data/lzstools_wrench/function/rotate/signs/rotate.mcfunction new file mode 100644 index 0000000..80b1009 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/signs/rotate.mcfunction @@ -0,0 +1,7 @@ +## Signs + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/signs/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/signs/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/signs/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/signs/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/signs_hanging/cycle.mcfunction b/data/lzstools_wrench/function/rotate/signs_hanging/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/signs_hanging/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/signs_hanging/cycle.mcfunction diff --git a/data/wrench/function/rotate/signs_hanging/flip.mcfunction b/data/lzstools_wrench/function/rotate/signs_hanging/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/signs_hanging/flip.mcfunction rename to data/lzstools_wrench/function/rotate/signs_hanging/flip.mcfunction diff --git a/data/wrench/function/rotate/signs_hanging/player.mcfunction b/data/lzstools_wrench/function/rotate/signs_hanging/player.mcfunction similarity index 98% rename from data/wrench/function/rotate/signs_hanging/player.mcfunction rename to data/lzstools_wrench/function/rotate/signs_hanging/player.mcfunction index f9dee69..c6e033c 100644 --- a/data/wrench/function/rotate/signs_hanging/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/signs_hanging/player.mcfunction @@ -35,4 +35,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=-56.25..-33.75] store re $execute as @s[scores={lz_wrench_success=0}, y_rotation=-33.75..-11.25] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[attached=true,waterlogged=false,rotation=7] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/signs_hanging/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/signs_hanging/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/signs_hanging/rotate.mcfunction b/data/lzstools_wrench/function/rotate/signs_hanging/rotate.mcfunction new file mode 100644 index 0000000..c96bf04 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/signs_hanging/rotate.mcfunction @@ -0,0 +1,6 @@ +## Signs Hanging + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/signs_hanging/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/signs_hanging/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/signs_hanging/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/signs_wall/flip.mcfunction b/data/lzstools_wrench/function/rotate/signs_wall/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/signs_wall/flip.mcfunction rename to data/lzstools_wrench/function/rotate/signs_wall/flip.mcfunction diff --git a/data/lzstools_wrench/function/rotate/signs_wall/rotate.mcfunction b/data/lzstools_wrench/function/rotate/signs_wall/rotate.mcfunction new file mode 100644 index 0000000..e323045 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/signs_wall/rotate.mcfunction @@ -0,0 +1,4 @@ +## Signs Wall + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/signs_wall/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/slabs/flip.mcfunction b/data/lzstools_wrench/function/rotate/slabs/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/slabs/flip.mcfunction rename to data/lzstools_wrench/function/rotate/slabs/flip.mcfunction diff --git a/data/lzstools_wrench/function/rotate/slabs/rotate.mcfunction b/data/lzstools_wrench/function/rotate/slabs/rotate.mcfunction new file mode 100644 index 0000000..7bf622b --- /dev/null +++ b/data/lzstools_wrench/function/rotate/slabs/rotate.mcfunction @@ -0,0 +1,4 @@ +## Slabs + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/slabs/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/stairs/click.mcfunction b/data/lzstools_wrench/function/rotate/stairs/click.mcfunction similarity index 97% rename from data/wrench/function/rotate/stairs/click.mcfunction rename to data/lzstools_wrench/function/rotate/stairs/click.mcfunction index c7a43f5..804f454 100644 --- a/data/wrench/function/rotate/stairs/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/stairs/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Stairs # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 if score py lz_wrench_raycast matches ..7 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true] run setblock ~ ~ ~ $(block)[half=bottom,facing=south,waterlogged=true] replace $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 15 if score py lz_wrench_raycast matches ..7 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true] run setblock ~ ~ ~ $(block)[half=bottom,facing=west,waterlogged=true] replace @@ -21,4 +21,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 if score py lz_wrench_raycast matches 8.. store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[half=top,facing=east] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/stairs/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/stairs/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/stairs/cycle.mcfunction b/data/lzstools_wrench/function/rotate/stairs/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/stairs/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/stairs/cycle.mcfunction diff --git a/data/wrench/function/rotate/stairs/flip.mcfunction b/data/lzstools_wrench/function/rotate/stairs/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/stairs/flip.mcfunction rename to data/lzstools_wrench/function/rotate/stairs/flip.mcfunction diff --git a/data/wrench/function/rotate/stairs/player.mcfunction b/data/lzstools_wrench/function/rotate/stairs/player.mcfunction similarity index 97% rename from data/wrench/function/rotate/stairs/player.mcfunction rename to data/lzstools_wrench/function/rotate/stairs/player.mcfunction index 597fceb..b28e902 100644 --- a/data/wrench/function/rotate/stairs/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/stairs/player.mcfunction @@ -20,4 +20,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] if score py l ## Non-processed # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/stairs/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/stairs/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/stairs/rotate.mcfunction b/data/lzstools_wrench/function/rotate/stairs/rotate.mcfunction new file mode 100644 index 0000000..0c3cdc0 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/stairs/rotate.mcfunction @@ -0,0 +1,7 @@ +## Stairs + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/stairs/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/stairs/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/stairs/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/stairs/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/trapdoors/click.mcfunction b/data/lzstools_wrench/function/rotate/trapdoors/click.mcfunction similarity index 98% rename from data/wrench/function/rotate/trapdoors/click.mcfunction rename to data/lzstools_wrench/function/rotate/trapdoors/click.mcfunction index 52f7873..c85e6ae 100644 --- a/data/wrench/function/rotate/trapdoors/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/trapdoors/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Trapdoors # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 if score py lz_wrench_raycast matches 8.. store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true,open=true] run setblock ~ ~ ~ $(block)[half=top,facing=south,waterlogged=true,open=true] replace $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 15 if score py lz_wrench_raycast matches 8.. store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true,open=true] run setblock ~ ~ ~ $(block)[half=top,facing=west,waterlogged=true,open=true] replace @@ -37,4 +37,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 if score py lz_wrench_raycast matches ..7 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false,open=false] run setblock ~ ~ ~ $(block)[half=bottom,facing=east,open=false] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/trapdoors/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/trapdoors/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/trapdoors/cycle.mcfunction b/data/lzstools_wrench/function/rotate/trapdoors/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/trapdoors/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/trapdoors/cycle.mcfunction diff --git a/data/wrench/function/rotate/trapdoors/flip.mcfunction b/data/lzstools_wrench/function/rotate/trapdoors/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/trapdoors/flip.mcfunction rename to data/lzstools_wrench/function/rotate/trapdoors/flip.mcfunction diff --git a/data/wrench/function/rotate/trapdoors/player.mcfunction b/data/lzstools_wrench/function/rotate/trapdoors/player.mcfunction similarity index 98% rename from data/wrench/function/rotate/trapdoors/player.mcfunction rename to data/lzstools_wrench/function/rotate/trapdoors/player.mcfunction index 2a37259..9e8e45c 100644 --- a/data/wrench/function/rotate/trapdoors/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/trapdoors/player.mcfunction @@ -34,4 +34,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=135..-135] if score py l $execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] if score py lz_wrench_raycast matches 8.. store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false,open=false] run setblock ~ ~ ~ $(block)[half=top,facing=west,open=false] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/trapdoors/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/trapdoors/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/trapdoors/rotate.mcfunction b/data/lzstools_wrench/function/rotate/trapdoors/rotate.mcfunction new file mode 100644 index 0000000..79385a6 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/trapdoors/rotate.mcfunction @@ -0,0 +1,7 @@ +## Trapdoors + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/trapdoors/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/trapdoors/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/trapdoors/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/trapdoors/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction similarity index 92% rename from data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction index 4662248..b0a3a9f 100644 --- a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Calibrated Sculk Sensor # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Calibrated Sculk Sensor $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=true] run setblock ~ ~ ~ $(block)[waterlogged=true,facing=south] replace @@ -14,4 +14,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[waterlogged=false,facing=east] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction similarity index 93% rename from data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction index 723057d..cde2901 100644 --- a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/player.mcfunction @@ -10,4 +10,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=135..-135] store result $execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[waterlogged=false] run setblock ~ ~ ~ $(block)[waterlogged=false,facing=east] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction new file mode 100644 index 0000000..c6f26e8 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction @@ -0,0 +1,7 @@ +## Calibrated Sculk Sensor + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/calibrated_sculk_sensor/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/campfires/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/campfires/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/campfires/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/campfires/cycle.mcfunction diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction new file mode 100644 index 0000000..aa56574 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction @@ -0,0 +1,3 @@ +## Campfires + +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/campfires/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/comparator/click.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/click.mcfunction similarity index 92% rename from data/wrench/function/rotate/unique_blocks/comparator/click.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/comparator/click.mcfunction index 8df59dc..66dd9dc 100644 --- a/data/wrench/function/rotate/unique_blocks/comparator/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Comparator # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Compare mode $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[mode=compare] run setblock ~ ~ ~ $(block)[mode=compare,facing=north] replace @@ -15,4 +15,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[mode=subtract] run setblock ~ ~ ~ $(block)[mode=subtract,facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/unique_blocks/comparator/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/comparator/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/comparator/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/comparator/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/comparator/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/comparator/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/comparator/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/player.mcfunction similarity index 95% rename from data/wrench/function/rotate/unique_blocks/comparator/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/comparator/player.mcfunction index 2545be0..9b1109c 100644 --- a/data/wrench/function/rotate/unique_blocks/comparator/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/player.mcfunction @@ -12,4 +12,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=135..-135] store result $execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] store result score @s lz_wrench_success unless block ~ ~ ~ $(block)[facing=west] run execute if block ~ ~ ~ $(block)[mode=subtract] run setblock ~ ~ ~ $(block)[mode=subtract,facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction new file mode 100644 index 0000000..8b2bdd5 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction @@ -0,0 +1,7 @@ +## Comparator + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/comparator/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/unique_blocks/comparator/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/comparator/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/crafter/click.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/click.mcfunction similarity index 94% rename from data/wrench/function/rotate/unique_blocks/crafter/click.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/crafter/click.mcfunction index e5d69ab..0b33928 100644 --- a/data/wrench/function/rotate/unique_blocks/crafter/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Crafter # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords $execute as @s[scores={lz_wrench_success=0}, y_rotation=-45..45] if score py lz_wrench_raycast matches 15 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[orientation=up_south] replace $execute as @s[scores={lz_wrench_success=0}, y_rotation=45..135] if score py lz_wrench_raycast matches 15 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[orientation=up_west] replace @@ -17,4 +17,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[orientation=west_up] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/crafter/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/crafter/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/crafter/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/crafter/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/crafter/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/crafter/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/crafter/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/player.mcfunction similarity index 96% rename from data/wrench/function/rotate/unique_blocks/crafter/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/crafter/player.mcfunction index f93eb6b..d5bc4bd 100644 --- a/data/wrench/function/rotate/unique_blocks/crafter/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/player.mcfunction @@ -14,4 +14,4 @@ $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=135. $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[orientation=west_up] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction new file mode 100644 index 0000000..4ef401d --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction @@ -0,0 +1,7 @@ +## Crafter + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/crafter/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/unique_blocks/crafter/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/crafter/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/grindstone/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/grindstone/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/grindstone/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/grindstone/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/grindstone/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/grindstone/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/grindstone/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/player.mcfunction similarity index 96% rename from data/wrench/function/rotate/unique_blocks/grindstone/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/grindstone/player.mcfunction index 066e046..f632182 100644 --- a/data/wrench/function/rotate/unique_blocks/grindstone/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/player.mcfunction @@ -14,4 +14,4 @@ $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=135. $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[face=floor,facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/grindstone/flip with storage lzstools:wrench \ No newline at end of file +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/grindstone/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction new file mode 100644 index 0000000..46536c0 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction @@ -0,0 +1,6 @@ +## Grindstone + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/grindstone/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/grindstone/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/grindstone/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/hopper/click.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/click.mcfunction similarity index 92% rename from data/wrench/function/rotate/unique_blocks/hopper/click.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/hopper/click.mcfunction index 6fc7f77..07bafe7 100644 --- a/data/wrench/function/rotate/unique_blocks/hopper/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Hopper # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Check pointed at Full Block execute if score px lz_wrench_raycast matches 1..14 if score py lz_wrench_raycast matches 1..14 if score pz lz_wrench_raycast matches 1..14 run scoreboard players set @s lz_wrench_success -2 @@ -16,4 +16,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success unless block ~ ~ ~ $(block)[facing=west] run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/hopper/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/hopper/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/hopper/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/hopper/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/hopper/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/hopper/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/hopper/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/player.mcfunction similarity index 93% rename from data/wrench/function/rotate/unique_blocks/hopper/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/hopper/player.mcfunction index 29dc1d9..3b6f007 100644 --- a/data/wrench/function/rotate/unique_blocks/hopper/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/player.mcfunction @@ -9,4 +9,4 @@ $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=135. $execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_wrench_success unless block ~ ~ ~ $(block)[facing=west] run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction new file mode 100644 index 0000000..62fe7f5 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction @@ -0,0 +1,7 @@ +## Hopper + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/hopper/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/unique_blocks/hopper/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/hopper/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/repeater/click.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/click.mcfunction similarity index 95% rename from data/wrench/function/rotate/unique_blocks/repeater/click.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/repeater/click.mcfunction index 454df48..324b825 100644 --- a/data/wrench/function/rotate/unique_blocks/repeater/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/click.mcfunction @@ -1,7 +1,7 @@ ## Face Click Repeater # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords # Delay 1 $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[delay=1] run setblock ~ ~ ~ $(block)[delay=1,facing=north] replace @@ -25,4 +25,4 @@ $execute as @s[scores={lz_wrench_success=0}] if score pz lz_wrench_raycast match $execute as @s[scores={lz_wrench_success=0}] if score px lz_wrench_raycast matches 0 store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block)[delay=4] run setblock ~ ~ ~ $(block)[delay=4,facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/repeater/cycle.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/repeater/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/repeater/cycle.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/repeater/flip.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/flip.mcfunction similarity index 100% rename from data/wrench/function/rotate/unique_blocks/repeater/flip.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/repeater/flip.mcfunction diff --git a/data/wrench/function/rotate/unique_blocks/repeater/player.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/player.mcfunction similarity index 97% rename from data/wrench/function/rotate/unique_blocks/repeater/player.mcfunction rename to data/lzstools_wrench/function/rotate/unique_blocks/repeater/player.mcfunction index 80a9f75..4fffab3 100644 --- a/data/wrench/function/rotate/unique_blocks/repeater/player.mcfunction +++ b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/player.mcfunction @@ -22,4 +22,4 @@ $execute as @s[scores={lz_wrench_success=0}, y_rotation=135..-135] store result $execute as @s[scores={lz_wrench_success=0}, y_rotation=-135..-45] store result score @s lz_wrench_success unless block ~ ~ ~ $(block)[facing=west] run execute if block ~ ~ ~ $(block)[delay=4] run setblock ~ ~ ~ $(block)[delay=4,facing=west] replace # Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function lzstools_wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench diff --git a/data/lzstools_wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction new file mode 100644 index 0000000..00d2725 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction @@ -0,0 +1,7 @@ +## Repeater + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function lzstools_wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/unique_blocks/repeater/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/unique_blocks/repeater/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/unique_blocks/repeater/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/xyz/click.mcfunction b/data/lzstools_wrench/function/rotate/xyz/click.mcfunction similarity index 93% rename from data/wrench/function/rotate/xyz/click.mcfunction rename to data/lzstools_wrench/function/rotate/xyz/click.mcfunction index 13661b6..91886ca 100644 --- a/data/wrench/function/rotate/xyz/click.mcfunction +++ b/data/lzstools_wrench/function/rotate/xyz/click.mcfunction @@ -1,7 +1,7 @@ ## X Y Z Click # Get Raycast Target Coords -function wrench:raycast/target_coords +function lzstools_wrench:raycast/target_coords ## Rotate X Y Z $execute as @s[scores={lz_wrench_success=0}] unless score pz lz_wrench_raycast matches 1..14 store result score @s lz_wrench_success run setblock ~ ~ ~ $(block)[axis=z] replace diff --git a/data/wrench/function/rotate/xyz/cycle.mcfunction b/data/lzstools_wrench/function/rotate/xyz/cycle.mcfunction similarity index 100% rename from data/wrench/function/rotate/xyz/cycle.mcfunction rename to data/lzstools_wrench/function/rotate/xyz/cycle.mcfunction diff --git a/data/wrench/function/rotate/xyz/player.mcfunction b/data/lzstools_wrench/function/rotate/xyz/player.mcfunction similarity index 100% rename from data/wrench/function/rotate/xyz/player.mcfunction rename to data/lzstools_wrench/function/rotate/xyz/player.mcfunction diff --git a/data/lzstools_wrench/function/rotate/xyz/rotate.mcfunction b/data/lzstools_wrench/function/rotate/xyz/rotate.mcfunction new file mode 100644 index 0000000..498deb8 --- /dev/null +++ b/data/lzstools_wrench/function/rotate/xyz/rotate.mcfunction @@ -0,0 +1,6 @@ +## X Y Z + +# Rotate Based on Wrench Mode +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function lzstools_wrench:rotate/xyz/player with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function lzstools_wrench:rotate/xyz/click with storage lzstools:wrench +execute as @s[scores={lz_wrench_success=0}] run function lzstools_wrench:rotate/xyz/cycle with storage lzstools:wrench diff --git a/data/lzstools_wrench/function/wrench/offhand.mcfunction b/data/lzstools_wrench/function/wrench/offhand.mcfunction new file mode 100644 index 0000000..6e29652 --- /dev/null +++ b/data/lzstools_wrench/function/wrench/offhand.mcfunction @@ -0,0 +1,19 @@ +# Reset scores +scoreboard players set @s lz_wrench_success 0 + +# Change wrench mode +execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Default"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand lzstools_wrench:flip +execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Flip"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand lzstools_wrench:face_player +execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Face Player"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand lzstools_wrench:face_click +execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Face Click"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand lzstools_wrench:terracotta_north + +# Return to Default +execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Terracotta"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand lzstools_wrench:default + + +# Confirm with action bar +title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Default"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Default","color":"white"}] +title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Flip"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Flip","color":"white"}] +title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Face Player"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Face Player","color":"white"}] +title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Face Click"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Face Click","color":"white"}] +title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":["wrench"]},"minecraft:lore":["Terracotta"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Terracotta","color":"white"}] \ No newline at end of file diff --git a/data/wrench/function/wrench/rotate.mcfunction b/data/lzstools_wrench/function/wrench/rotate.mcfunction similarity index 78% rename from data/wrench/function/wrench/rotate.mcfunction rename to data/lzstools_wrench/function/wrench/rotate.mcfunction index 0859271..2f7c7eb 100644 --- a/data/wrench/function/wrench/rotate.mcfunction +++ b/data/lzstools_wrench/function/wrench/rotate.mcfunction @@ -3,4 +3,4 @@ scoreboard players set @s lz_wrench_success 0 scoreboard players set @s lz_wrench_raycast 0 #Raycast from player's position -function wrench:raycast/start +function lzstools_wrench:raycast/start diff --git a/data/wrench/function/wrench/terracotta.mcfunction b/data/lzstools_wrench/function/wrench/terracotta.mcfunction similarity index 58% rename from data/wrench/function/wrench/terracotta.mcfunction rename to data/lzstools_wrench/function/wrench/terracotta.mcfunction index e1ca233..cd1bd18 100644 --- a/data/wrench/function/wrench/terracotta.mcfunction +++ b/data/lzstools_wrench/function/wrench/terracotta.mcfunction @@ -1,8 +1,8 @@ #Advance terracotta mode rotation, show title -item modify entity @s[tag=TerracottaNORTH] weapon.mainhand wrench:wrench_terracotta_east -item modify entity @s[tag=TerracottaEAST] weapon.mainhand wrench:wrench_terracotta_south -item modify entity @s[tag=TerracottaSOUTH] weapon.mainhand wrench:wrench_terracotta_west -item modify entity @s[tag=TerracottaWEST] weapon.mainhand wrench:wrench_terracotta_north +item modify entity @s[tag=TerracottaNORTH] weapon.mainhand lzstools_wrench:terracotta_east +item modify entity @s[tag=TerracottaEAST] weapon.mainhand lzstools_wrench:terracotta_south +item modify entity @s[tag=TerracottaSOUTH] weapon.mainhand lzstools_wrench:terracotta_west +item modify entity @s[tag=TerracottaWEST] weapon.mainhand lzstools_wrench:terracotta_north title @s[tag=TerracottaNORTH] actionbar [{"text":"Terracotta Mode: ","color":"green"},{"text":"East","color":"white"}] title @s[tag=TerracottaEAST] actionbar [{"text":"Terracotta Mode: ","color":"green"},{"text":"South","color":"white"}] title @s[tag=TerracottaSOUTH] actionbar [{"text":"Terracotta Mode: ","color":"green"},{"text":"West","color":"white"}] diff --git a/data/wrench/item_modifier/wrench_default.json b/data/lzstools_wrench/item_modifier/default.json similarity index 100% rename from data/wrench/item_modifier/wrench_default.json rename to data/lzstools_wrench/item_modifier/default.json diff --git a/data/wrench/item_modifier/wrench_face_click.json b/data/lzstools_wrench/item_modifier/face_click.json similarity index 100% rename from data/wrench/item_modifier/wrench_face_click.json rename to data/lzstools_wrench/item_modifier/face_click.json diff --git a/data/wrench/item_modifier/wrench_face_player.json b/data/lzstools_wrench/item_modifier/face_player.json similarity index 100% rename from data/wrench/item_modifier/wrench_face_player.json rename to data/lzstools_wrench/item_modifier/face_player.json diff --git a/data/wrench/item_modifier/wrench_flip.json b/data/lzstools_wrench/item_modifier/flip.json similarity index 100% rename from data/wrench/item_modifier/wrench_flip.json rename to data/lzstools_wrench/item_modifier/flip.json diff --git a/data/wrench/item_modifier/wrench_terracotta_east.json b/data/lzstools_wrench/item_modifier/terracotta_east.json similarity index 100% rename from data/wrench/item_modifier/wrench_terracotta_east.json rename to data/lzstools_wrench/item_modifier/terracotta_east.json diff --git a/data/wrench/item_modifier/wrench_terracotta_north.json b/data/lzstools_wrench/item_modifier/terracotta_north.json similarity index 100% rename from data/wrench/item_modifier/wrench_terracotta_north.json rename to data/lzstools_wrench/item_modifier/terracotta_north.json diff --git a/data/wrench/item_modifier/wrench_terracotta_south.json b/data/lzstools_wrench/item_modifier/terracotta_south.json similarity index 100% rename from data/wrench/item_modifier/wrench_terracotta_south.json rename to data/lzstools_wrench/item_modifier/terracotta_south.json diff --git a/data/wrench/item_modifier/wrench_terracotta_west.json b/data/lzstools_wrench/item_modifier/terracotta_west.json similarity index 100% rename from data/wrench/item_modifier/wrench_terracotta_west.json rename to data/lzstools_wrench/item_modifier/terracotta_west.json diff --git a/data/wrench/recipe/wrench.json b/data/lzstools_wrench/recipe/wrench.json similarity index 79% rename from data/wrench/recipe/wrench.json rename to data/lzstools_wrench/recipe/wrench.json index 3b9f396..b4692ab 100644 --- a/data/wrench/recipe/wrench.json +++ b/data/lzstools_wrench/recipe/wrench.json @@ -2,13 +2,14 @@ "type": "minecraft:crafting_shaped", "category": "equipment", "pattern": [ - " c", - " s ", + " lg", + " sg", "s " ], "key": { "s": "minecraft:stick", - "c": "minecraft:copper_ingot" + "g": "minecraft:gold_ingot", + "l": "#minecraft:logs" }, "result": { "id": "minecraft:carrot_on_a_stick", @@ -16,7 +17,8 @@ "components": { "minecraft:custom_name": { "text": "Rotator Wrench", - "color": "aqua" + "color": "aqua", + "italic": false }, "minecraft:lore": [ "Default" @@ -27,7 +29,9 @@ ] }, "minecraft:custom_data": { - "lzstools": "wrench" + "lzstools": [ + "wrench" + ] }, "minecraft:unbreakable": {}, "minecraft:tooltip_display": { diff --git a/data/wrench/function/raycast/partialbox.mcfunction b/data/wrench/function/raycast/partialbox.mcfunction deleted file mode 100644 index 4805ec7..0000000 --- a/data/wrench/function/raycast/partialbox.mcfunction +++ /dev/null @@ -1,29 +0,0 @@ -## Raycast Partial-box - -# Get Raycast Target Coords -function wrench:raycast/target_coords - -# Partial Boxes -execute if block ~ ~ ~ #wrench:banners run function wrench:raycast/partialbox/banners -execute if block ~ ~ ~ #minecraft:rails run function wrench:raycast/partialbox/rails -execute if block ~ ~ ~ #minecraft:trapdoors run function wrench:raycast/partialbox/trapdoors -execute if block ~ ~ ~ #minecraft:slabs run function wrench:raycast/partialbox/slabs -execute if block ~ ~ ~ #minecraft:stairs run function wrench:raycast/partialbox/stairs -execute if block ~ ~ ~ #minecraft:fence_gates run function wrench:raycast/partialbox/fence_gates -execute if block ~ ~ ~ #minecraft:campfires run function wrench:raycast/partialbox/campfires -execute if block ~ ~ ~ #minecraft:all_signs run function wrench:raycast/partialbox/signs -execute if block ~ ~ ~ #minecraft:anvil run function wrench:raycast/partialbox/anvils -execute if block ~ ~ ~ minecraft:repeater run function wrench:raycast/partialbox/repeater -execute if block ~ ~ ~ minecraft:comparator run function wrench:raycast/partialbox/comparator -execute if block ~ ~ ~ minecraft:calibrated_sculk_sensor run function wrench:raycast/partialbox/calibrated_sculk_sensor -execute if block ~ ~ ~ minecraft:piston run function wrench:raycast/partialbox/pistons -execute if block ~ ~ ~ minecraft:sticky_piston run function wrench:raycast/partialbox/pistons -execute if block ~ ~ ~ minecraft:hopper run function wrench:raycast/partialbox/hopper -execute if block ~ ~ ~ minecraft:end_rod run function wrench:raycast/partialbox/end_rod -execute if block ~ ~ ~ minecraft:lightning_rod run function wrench:raycast/partialbox/lightning_rod -execute if block ~ ~ ~ minecraft:chain run function wrench:raycast/partialbox/chain -execute if block ~ ~ ~ minecraft:decorated_pot run function wrench:raycast/partialbox/decorated_pot -execute if block ~ ~ ~ minecraft:stonecutter run function wrench:raycast/partialbox/stonecutter -execute if block ~ ~ ~ minecraft:ender_chest run function wrench:raycast/partialbox/ender_chest -execute if block ~ ~ ~ minecraft:bell run function wrench:raycast/partialbox/bell -execute if block ~ ~ ~ minecraft:grindstone run function wrench:raycast/partialbox/grindstone diff --git a/data/wrench/function/raycast/partialbox/banners.mcfunction b/data/wrench/function/raycast/partialbox/banners.mcfunction deleted file mode 100644 index 989921f..0000000 --- a/data/wrench/function/raycast/partialbox/banners.mcfunction +++ /dev/null @@ -1,2 +0,0 @@ -# Banners -execute if score px lz_wrench_raycast matches 4..11 if score pz lz_wrench_raycast matches 4..11 if block ~ ~ ~ #wrench:banners run function wrench:rotate/banners/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/bell.mcfunction b/data/wrench/function/raycast/partialbox/bell.mcfunction deleted file mode 100644 index 74d08bd..0000000 --- a/data/wrench/function/raycast/partialbox/bell.mcfunction +++ /dev/null @@ -1,5 +0,0 @@ -# Bell -execute if score px lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=north] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=east] run function wrench:rotate/nesw/rotate -execute if score px lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=south] run function wrench:rotate/nesw/rotate -execute if score pz lz_wrench_raycast matches 5..12 if block ~ ~ ~ minecraft:bell[attachment=floor,facing=west] run function wrench:rotate/nesw/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction b/data/wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction deleted file mode 100644 index 1206787..0000000 --- a/data/wrench/function/raycast/partialbox/calibrated_sculk_sensor.mcfunction +++ /dev/null @@ -1,2 +0,0 @@ -# Calibrated Sculk Sensor -execute if block ~ ~ ~ minecraft:calibrated_sculk_sensor if score py lz_wrench_raycast matches ..7 run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/campfires.mcfunction b/data/wrench/function/raycast/partialbox/campfires.mcfunction deleted file mode 100644 index e7afe29..0000000 --- a/data/wrench/function/raycast/partialbox/campfires.mcfunction +++ /dev/null @@ -1,2 +0,0 @@ -# Campfires -execute if block ~ ~ ~ #minecraft:campfires if score py lz_wrench_raycast matches ..7 run function wrench:rotate/unique_blocks/campfires/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/comparator.mcfunction b/data/wrench/function/raycast/partialbox/comparator.mcfunction deleted file mode 100644 index a1fe6b6..0000000 --- a/data/wrench/function/raycast/partialbox/comparator.mcfunction +++ /dev/null @@ -1,2 +0,0 @@ -# Redstone Comprator -execute if block ~ ~ ~ minecraft:comparator if score py lz_wrench_raycast matches ..1 run function wrench:rotate/unique_blocks/comparator/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/pistons.mcfunction b/data/wrench/function/raycast/partialbox/pistons.mcfunction deleted file mode 100644 index c4c3789..0000000 --- a/data/wrench/function/raycast/partialbox/pistons.mcfunction +++ /dev/null @@ -1,17 +0,0 @@ -# Piston -execute if block ~ ~ ~ minecraft:piston[extended=false] run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=up] if score py lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=down] if score py lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=south] if score pz lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=north] if score pz lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=east] if score px lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:piston[facing=west] if score px lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate - -# Sticky Piston -execute if block ~ ~ ~ minecraft:sticky_piston[extended=false] run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=up] if score py lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=down] if score py lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=south] if score pz lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=north] if score pz lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=east] if score px lz_wrench_raycast matches ..11 run function wrench:rotate/neswud/rotate -execute if block ~ ~ ~ minecraft:sticky_piston[facing=west] if score px lz_wrench_raycast matches 4.. run function wrench:rotate/neswud/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/rails.mcfunction b/data/wrench/function/raycast/partialbox/rails.mcfunction deleted file mode 100644 index d6306b2..0000000 --- a/data/wrench/function/raycast/partialbox/rails.mcfunction +++ /dev/null @@ -1,6 +0,0 @@ -# Rails -execute if block ~ ~ ~ #minecraft:rails if score py lz_wrench_raycast matches ..1 run function wrench:rotate/rails/rotate -execute if block ~ ~ ~ #minecraft:rails[shape=ascending_west] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/rails/rotate -execute if block ~ ~ ~ #minecraft:rails[shape=ascending_east] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/rails/rotate -execute if block ~ ~ ~ #minecraft:rails[shape=ascending_north] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/rails/rotate -execute if block ~ ~ ~ #minecraft:rails[shape=ascending_south] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/rails/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/repeater.mcfunction b/data/wrench/function/raycast/partialbox/repeater.mcfunction deleted file mode 100644 index f41a087..0000000 --- a/data/wrench/function/raycast/partialbox/repeater.mcfunction +++ /dev/null @@ -1,2 +0,0 @@ -# Redstone Repeater -execute if block ~ ~ ~ minecraft:repeater if score py lz_wrench_raycast matches ..1 run function wrench:rotate/unique_blocks/repeater/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/partialbox/slabs.mcfunction b/data/wrench/function/raycast/partialbox/slabs.mcfunction deleted file mode 100644 index cc7f598..0000000 --- a/data/wrench/function/raycast/partialbox/slabs.mcfunction +++ /dev/null @@ -1,3 +0,0 @@ -# Slabs -execute if block ~ ~ ~ #minecraft:slabs[type=top] if score py lz_wrench_raycast matches 8.. run function wrench:rotate/slabs/rotate -execute if block ~ ~ ~ #minecraft:slabs[type=bottom] if score py lz_wrench_raycast matches ..7 run function wrench:rotate/slabs/rotate diff --git a/data/wrench/function/raycast/partialbox/trapdoors.mcfunction b/data/wrench/function/raycast/partialbox/trapdoors.mcfunction deleted file mode 100644 index e12a545..0000000 --- a/data/wrench/function/raycast/partialbox/trapdoors.mcfunction +++ /dev/null @@ -1,13 +0,0 @@ -# Trapdoors - -execute if block ~ ~ ~ #minecraft:trapdoors[open=false,half=top] if score py lz_wrench_raycast matches 13.. run function wrench:rotate/trapdoors/rotate -execute if block ~ ~ ~ #minecraft:trapdoors[open=false,half=bottom] if score py lz_wrench_raycast matches ..2 run function wrench:rotate/trapdoors/rotate - -# North -execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=north] if score pz lz_wrench_raycast matches 13.. run function wrench:rotate/trapdoors/rotate -# East -execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=east] if score px lz_wrench_raycast matches ..2 run function wrench:rotate/trapdoors/rotate -# South -execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=south] if score pz lz_wrench_raycast matches ..2 run function wrench:rotate/trapdoors/rotate -# West -execute if block ~ ~ ~ #minecraft:trapdoors[open=true,facing=west] if score px lz_wrench_raycast matches 13.. run function wrench:rotate/trapdoors/rotate \ No newline at end of file diff --git a/data/wrench/function/raycast/rayloop.mcfunction b/data/wrench/function/raycast/rayloop.mcfunction deleted file mode 100644 index 434defe..0000000 --- a/data/wrench/function/raycast/rayloop.mcfunction +++ /dev/null @@ -1,26 +0,0 @@ -## Raycast - -# Set block data -execute as @s run loot spawn ~ -65 ~ mine ~ ~ ~ minecraft:netherite_pickaxe[minecraft:enchantments={"minecraft:silk_touch":1}] -execute as @s run data modify storage lzstools:wrench block set from entity @n[type=minecraft:item,distance=..0.5,y=-65] Item.id -execute as @s run execute as @s run kill @n[type=minecraft:item,distance=..0.5,y=-65] - -# Partial Blocks -execute if block ~ ~ ~ #wrench:partialbox run function wrench:raycast/partialbox -execute if block ~ ~ ~ #wrench:banners run function wrench:raycast/partialbox - -# Remaining Blocks -execute unless block ~ ~ ~ #wrench:partialbox if block ~ ~ ~ #wrench:neswud run function wrench:rotate/neswud/rotate -execute unless block ~ ~ ~ #wrench:partialbox if block ~ ~ ~ #wrench:nesw run function wrench:rotate/nesw/rotate -execute unless block ~ ~ ~ #wrench:partialbox if block ~ ~ ~ #wrench:xyz run function wrench:rotate/xyz/rotate -execute unless block ~ ~ ~ #wrench:partialbox if block ~ ~ ~ #wrench:glazed_terracotta run function wrench:rotate/glazed_terracotta/rotate -execute unless block ~ ~ ~ #wrench:partialbox if block ~ ~ ~ #wrench:unique run function wrench:raycast/unique - -# Force Update on block -execute as @s[scores={lz_wrench_success=1..}] if block ~ ~ ~ #wrench:updates run clone ~-1 ~ ~ ~1 ~ ~ ~-1 ~ ~ replace force -execute as @s[scores={lz_wrench_success=1..}] if block ~ ~ ~ #wrench:updates run clone ~ ~ ~-1 ~ ~ ~1 ~ ~ ~-1 replace force -execute as @s[scores={lz_wrench_success=1..}] run playsound minecraft:entity.item_frame.rotate_item block @s ~ ~ ~ - -# Advance forward and if nothing found -scoreboard players add #distance lz_wrench_raycast 1 -execute if score @s lz_wrench_success matches 0 if score #distance lz_wrench_raycast matches ..350 positioned ^ ^ ^0.01 run function wrench:raycast/rayloop \ No newline at end of file diff --git a/data/wrench/function/raycast/unique.mcfunction b/data/wrench/function/raycast/unique.mcfunction deleted file mode 100644 index 201561a..0000000 --- a/data/wrench/function/raycast/unique.mcfunction +++ /dev/null @@ -1,3 +0,0 @@ -## Unique Items - -execute if block ~ ~ ~ minecraft:crafter run function wrench:rotate/unique_blocks/crafter/rotate \ No newline at end of file diff --git a/data/wrench/function/rotate/banners/rotate.mcfunction b/data/wrench/function/rotate/banners/rotate.mcfunction deleted file mode 100644 index 63e019a..0000000 --- a/data/wrench/function/rotate/banners/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Banners - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/banners/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/banners/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/banners/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/banners/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/glazed_terracotta/rotate.mcfunction b/data/wrench/function/rotate/glazed_terracotta/rotate.mcfunction deleted file mode 100644 index 07425a8..0000000 --- a/data/wrench/function/rotate/glazed_terracotta/rotate.mcfunction +++ /dev/null @@ -1,4 +0,0 @@ -## Glazed Terracotta - -execute as @s[nbt={SelectedItem:{components:{"minecraft:lore":["Terracotta"]}}}] run function wrench:rotate/glazed_terracotta/mode with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/glazed_terracotta/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/nesw/player.mcfunction b/data/wrench/function/rotate/nesw/player.mcfunction deleted file mode 100644 index 2603fb6..0000000 --- a/data/wrench/function/rotate/nesw/player.mcfunction +++ /dev/null @@ -1,9 +0,0 @@ -## Face Player NESW - -$execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-45..45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=north] replace -$execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=45..135] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=east] replace -$execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=135..-135] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=south] replace -$execute as @s[scores={lz_wrench_success=0}, x_rotation=-45..45, y_rotation=-135..-45] store result score @s lz_wrench_success run execute if block ~ ~ ~ $(block) run setblock ~ ~ ~ $(block)[facing=west] replace - -# Otherwise, Flip -execute as @s[scores={lz_wrench_success=0}] store result score @s lz_wrench_success run function wrench:rotate/nesw/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/nesw/rotate.mcfunction b/data/wrench/function/rotate/nesw/rotate.mcfunction deleted file mode 100644 index b61ea3d..0000000 --- a/data/wrench/function/rotate/nesw/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## NESW - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/nesw/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/nesw/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/nesw/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/nesw/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/neswud/rotate.mcfunction b/data/wrench/function/rotate/neswud/rotate.mcfunction deleted file mode 100644 index 132b7c1..0000000 --- a/data/wrench/function/rotate/neswud/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## NESW UD - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/neswud/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/neswud/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/neswud/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/neswud/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/rails/rotate.mcfunction b/data/wrench/function/rotate/rails/rotate.mcfunction deleted file mode 100644 index 7a371c7..0000000 --- a/data/wrench/function/rotate/rails/rotate.mcfunction +++ /dev/null @@ -1,5 +0,0 @@ -## Rails - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/rails/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/rails/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/signs/rotate.mcfunction b/data/wrench/function/rotate/signs/rotate.mcfunction deleted file mode 100644 index 10065f8..0000000 --- a/data/wrench/function/rotate/signs/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Signs - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/signs/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/signs/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/signs/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/signs/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/signs_hanging/rotate.mcfunction b/data/wrench/function/rotate/signs_hanging/rotate.mcfunction deleted file mode 100644 index a35fddd..0000000 --- a/data/wrench/function/rotate/signs_hanging/rotate.mcfunction +++ /dev/null @@ -1,6 +0,0 @@ -## Signs Hanging - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/signs_hanging/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/signs_hanging/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/signs_hanging/cycle with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/signs_wall/rotate.mcfunction b/data/wrench/function/rotate/signs_wall/rotate.mcfunction deleted file mode 100644 index 2d8fd65..0000000 --- a/data/wrench/function/rotate/signs_wall/rotate.mcfunction +++ /dev/null @@ -1,4 +0,0 @@ -## Signs Wall - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/signs_wall/flip with storage lzstools:wrench \ No newline at end of file diff --git a/data/wrench/function/rotate/slabs/rotate.mcfunction b/data/wrench/function/rotate/slabs/rotate.mcfunction deleted file mode 100644 index 1cac3cf..0000000 --- a/data/wrench/function/rotate/slabs/rotate.mcfunction +++ /dev/null @@ -1,4 +0,0 @@ -## Slabs - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/slabs/flip with storage lzstools:wrench diff --git a/data/wrench/function/rotate/stairs/rotate.mcfunction b/data/wrench/function/rotate/stairs/rotate.mcfunction deleted file mode 100644 index fa2fe3f..0000000 --- a/data/wrench/function/rotate/stairs/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Stairs - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/stairs/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/stairs/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/stairs/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/stairs/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/trapdoors/rotate.mcfunction b/data/wrench/function/rotate/trapdoors/rotate.mcfunction deleted file mode 100644 index e552f56..0000000 --- a/data/wrench/function/rotate/trapdoors/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Trapdoors - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/trapdoors/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/trapdoors/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/trapdoors/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/trapdoors/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction deleted file mode 100644 index 69a37f1..0000000 --- a/data/wrench/function/rotate/unique_blocks/calibrated_sculk_sensor/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Calibrated Sculk Sensor - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/calibrated_sculk_sensor/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction deleted file mode 100644 index f54651f..0000000 --- a/data/wrench/function/rotate/unique_blocks/campfires/rotate.mcfunction +++ /dev/null @@ -1,3 +0,0 @@ -## Campfires - -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/campfires/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction deleted file mode 100644 index 4bdbe8e..0000000 --- a/data/wrench/function/rotate/unique_blocks/comparator/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Comparator - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/comparator/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/comparator/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/unique_blocks/comparator/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/comparator/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction deleted file mode 100644 index e495e4b..0000000 --- a/data/wrench/function/rotate/unique_blocks/crafter/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Crafter - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/crafter/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/crafter/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/unique_blocks/crafter/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/crafter/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction deleted file mode 100644 index 6c768e4..0000000 --- a/data/wrench/function/rotate/unique_blocks/grindstone/rotate.mcfunction +++ /dev/null @@ -1,6 +0,0 @@ -## Grindstone - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/grindstone/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/grindstone/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/grindstone/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction deleted file mode 100644 index 0805c37..0000000 --- a/data/wrench/function/rotate/unique_blocks/hopper/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Hopper - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/hopper/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/hopper/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/unique_blocks/hopper/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/hopper/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction b/data/wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction deleted file mode 100644 index f916b44..0000000 --- a/data/wrench/function/rotate/unique_blocks/repeater/rotate.mcfunction +++ /dev/null @@ -1,7 +0,0 @@ -## Repeater - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Flip"]}}}] run function wrench:rotate/unique_blocks/repeater/flip with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/unique_blocks/repeater/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/unique_blocks/repeater/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/unique_blocks/repeater/cycle with storage lzstools:wrench diff --git a/data/wrench/function/rotate/xyz/rotate.mcfunction b/data/wrench/function/rotate/xyz/rotate.mcfunction deleted file mode 100644 index 281dd89..0000000 --- a/data/wrench/function/rotate/xyz/rotate.mcfunction +++ /dev/null @@ -1,6 +0,0 @@ -## X Y Z - -# Rotate Based on Wrench Mode -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Player"]}}}] run function wrench:rotate/xyz/player with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0},nbt={SelectedItem:{components:{"minecraft:lore":["Face Click"]}}}] run function wrench:rotate/xyz/click with storage lzstools:wrench -execute as @s[scores={lz_wrench_success=0}] run function wrench:rotate/xyz/cycle with storage lzstools:wrench diff --git a/data/wrench/function/wrench/offhand.mcfunction b/data/wrench/function/wrench/offhand.mcfunction deleted file mode 100644 index af4e247..0000000 --- a/data/wrench/function/wrench/offhand.mcfunction +++ /dev/null @@ -1,19 +0,0 @@ -# Reset scores -scoreboard players set @s lz_wrench_success 0 - -# Change wrench mode -execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Default"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand wrench:wrench_flip -execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Flip"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand wrench:wrench_face_player -execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Face Player"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand wrench:wrench_face_click -execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Face Click"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand wrench:wrench_terracotta_north - -# Return to Default -execute as @s[scores={lz_wrench_success=0},nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Terracotta"]}}}}] store result score @s lz_wrench_success run item modify entity @s weapon.offhand wrench:wrench_default - - -# Confirm with action bar -title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Default"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Default","color":"white"}] -title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Flip"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Flip","color":"white"}] -title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Face Player"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Face Player","color":"white"}] -title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Face Click"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Face Click","color":"white"}] -title @s[nbt={equipment:{offhand:{components:{"minecraft:custom_data":{"lzstools":"wrench"},"minecraft:lore":["Terracotta"]}}}}] actionbar [{"text":"Mode: ","color":"red"},{"text":"Terracotta","color":"white"}] \ No newline at end of file