2

How whould i make it so every time i right click item will dissapear

idkmanXDDDlelXD's Avatar idkmanXDDDlelXD7/25/21 8:57 pm history
7/26/2021 1:41 am
idkmanXDDDlelXD's Avatar idkmanXDDDlelXD
So, i have 3 command blocks (which when the item is right clicked it will summon something)
Now.. how whould i make it so when i summon the thing im supposed to summon the item will dissapear? (so they cant abuse it)

Here are the commands:


Repeating always active command block:
---------
scoreboard objectives add carrotstick minecraft.used:minecraft.carrot_on_a_stick
-------
Chain always active command block:
-------
execute as @a[​scores={carrotstick=1..},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{TestName:1b}}}] at @s run summon minecraft:pig
---------
Chain always active command block:
-------
scoreboard players remove @a[​scores={carrotstick=1..}] carrotstick 1

Thanks!!
Posted by idkmanXDDDlelXD's Avatar
idkmanXDDDlelXD
Level 1 : New Miner
1

Create an account or sign in to comment.

4

2
07/25/2021 9:12 pmhistory
Level 52 : Grandmaster Blob
HoboMaggot
HoboMaggot's Avatar
clear the coas just after they summon the pig.

execute as @a[​scores={carrotstick=1..}] run clear @s carrot_on_a_stick{nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",TestName:1b}}}
1
07/25/2021 9:21 pm
Level 1 : New Miner
idkmanXDDDlelXD
idkmanXDDDlelXD's Avatar
So just do clear @s after summoning the pig?
1
07/25/2021 10:01 pm
Level 52 : Grandmaster Blob
HoboMaggot
HoboMaggot's Avatar
yes
1
07/26/2021 1:41 am
Level 1 : New Miner
idkmanXDDDlelXD
idkmanXDDDlelXD's Avatar
Alr ty
Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome