Dispenser that can shear players helmets

So now in hardcore you can take off the curse of binding carved pumpkin...

Supported Versions:

1.21.101.21.11+

Tutorial Steps:

  1. If you want this to work on all 4 sides change ^ ^1 ^1 to the other 3 sides
  2. You can also change this to other armor slots as well

Commands by Row:

Row 1

1. [repeat] /execute as @a[nbt={equipment:{head:{}}}] at @s rotated ~ 0 if block ^ ^1 ^1 minecraft:dispenser[triggered=true]{Items:[{id:"minecraft:shears"}]} run item replace block ^ ^1 ^1 container.0 from entity @s armor.head
2. [chain] /execute as @a[nbt={equipment:{head:{}}}] at @s rotated ~ 0 if block ^ ^1 ^1 minecraft:dispenser[triggered=true]{Items:[{id:"minecraft:shears"}]} run playsound minecraft:entity.sheep.shear ambient @s ~ ~ ~
3. [chain] /execute as @a[nbt={equipment:{head:{}}}] at @s rotated ~ 0 if block ^ ^1 ^1 minecraft:dispenser[triggered=true]{Items:[{id:"minecraft:shears"}]} run item replace entity @s armor.head with air

Preview

repeat
chain
chain

Video

Too lazy to copy and paste each command?