#Prevent items from stacking

1 messages · Page 1 of 1 (latest)

azure ridge
#

I want to prevent all dropped raw iron, and all coal to stop stacking when near each other.
Made a simple "furnace" command that melts if they are close together, but it doesn't work if item stack is not 1.

naive frostBOT
#

<@&1201956957406109788>

Someone will come and help soon!

💬 While you wait, take this time to provide more context and details.

🙇 If nobody has answered you by <t:1745303857:t>, feel free to use the Summon Helpers button to ping our helper team.

✅ Once your question has been resolved (or you no longer need it), please click Resolve Question or run /resolve

#
⚠️ You already have a question open!

Don't forget to close or resolve your old questions once you're done with them. It makes our lives much easier! :D

Open question: #1361761331061068007

azure ridge
spice raptor
#

Why don't you just fix your furnace command??

azure ridge
# spice raptor Why don't you just fix your furnace command??

Because I don't know how to

function furnace() {
    // Craft iron logic
    execute as @e[type=item,tag=source] run {
        tag @s remove source;
    }

    execute as @e[type=item,tag=!source] if data entity @s {Item:{id:"minecraft:raw_iron",count:1}} run {
        // Search for coal
        execute at @s as @e[type=item, distance=0..1, tag=!fuel] if data entity @s {Item:{id:"minecraft:coal",count:1}} run {
            tag @s add fuel;
            tag @e[type=item,tag=!source,sort=nearest,limit=1] add source;
            kill @s;
            kill @e[type=item,tag=source,sort=nearest,limit=1];
    
            summon minecraft:item ~ ~ ~ {Item:{id:"minecraft:iron_ingot",count:1}};
        }
    }
}
ebon notch
#

Oh i know why it doesnt work

#

You are killing that last item and sumnoning a new one

#

Just use /data merge entity ...

#

I can provide the whole command if you want

azure ridge
#

I think I understand what you are saying, but that wouldn't be possible, as that would allow for smelting a stack with a singular coal

#

(Also, anyone can ping me as wish)

spice raptor