magic-sorting-system icon indicating copy to clipboard operation
magic-sorting-system copied to clipboard

Request: disable a frame

Open Galaxarum opened this issue 4 years ago • 3 comments

Can you add a way to disable a frame, ie place it horizontal or rotate the item inside?

Galaxarum avatar May 08 '20 10:05 Galaxarum

Great idea, thanks! I'll see if this is possible, when I do the update for 1.16.

jhuckaby avatar May 08 '20 23:05 jhuckaby

Another possibility might be to disable if a frame has a named item. Not sure if the nbt selector gives enough info to allow that?

Then I could have a row of chests with the input hoppers / frames up top, but still have frames in the user-facing area to show what is inside. I could just name the items I put on the user-facing side to indicate what is inside the chests.

captncraig avatar May 18 '20 18:05 captncraig

Checking the rotation would require nbt checks, which are a source of lag. Do a less-often check for the rotation and set a tag, then check for the tag in subsequent commands. I modified it to tag frames when a specially named item is inserted. This function uses tag:! to not re-run on frames that are already tagged. I needed multiple tags for my purposes, so if the targetshulker function is fired it will remove other tags and add the correct tag.

example: execute as @e[type=minecraft:item_frame,tag=!sss_shulker_target,nbt={Item:{id:"minecraft:command_block",tag:{display:{Name:'{"text":"Shulker Target"}'}}}}] run function sss:targetshulker

targetshulker.mchfunction: tag @s add sss_shulker_target tag @s remove sss_sort_target tag @s remove sss_smelt_target tag @s remove sss_smoker_target tag @s remove sss_furnace_target tag @s remove sss_smelt_fuel tag @s remove sss_smoker_fuel tag @s remove sss_furnace_fuel

isaaclepes avatar Oct 06 '20 16:10 isaaclepes