Mojira Archive
MC-100236

Dispenser ignores DisabledSlots value of armor stands

The bug

Dispensers ignore the DisabledSlots value of armor stands. This means players can just place dispensers next to armor stands to equip armor even if they normally are not allowed to do this.

How to reproduce

  1. Use the following command, the armor stand should prevent the player from placing any item in one of the slots of it
    /summon armor_stand ~ ~ ~ {DisabledSlots:2031616,ShowArms:1b}
    
  2. Place a dispenser next to the armor stand facing it
  3. Place some piece of armor in the dispenser and activate it
    The armor item is placed in the slot of the armor stand

The reason

The following is based on decompiled version of Minecraft 1.9 using MCP 9.24 beta. All method and class names are the names used in the decompiled version.

The reason why this happens is because the method net.minecraft.item.ItemArmor.func_185082_a(IBlockSource, ItemStack) is used which just places the armor piece in one of the slots.

Unresolved

Marcono1234

2016-03-29, 05:53 PM

2024-07-09, 09:43 PM

14

6

Confirmed

(Unassigned)

DisabledSlots, armor_stand, dispenser

Minecraft 1.9.1 Pre-Release 3 - 1.21Minecraft 1.9.1 Pre-Release 3, Minecraft 1.9.1, Minecraft 1.9.2, Minecraft 1.11, Minecraft 1.12.2, Minecraft 1.13-pre1, Minecraft 1.13.1, 1.16.1, 20w27a, 1.16.4, 20w48a, 21w03a, 21w05b, 21w06a, 21w07a, 21w15a, 1.17.1, 1.21

-