mojira.dev
MC-112394

Numeral ids can still be used in some commands

See title, you are not supposed to be able to use numeral ids in commands anymore, yet in some places it still works:

  • Block with an item in it

    • setblock ~ ~ ~ chest default replace {Items:[{id:"1",Count:1b,Slot:0b}]}
  • Mob with armor/tools

    • /summon zombie ~ ~ ~ {ArmorItems:[{},{},{},{id:"1",Count:1b}]}
  • Item frames

    • /summon minecraft:item_frame ~ ~ ~ {Item:{id:"1",Count:1b}}
  • Items

    • /summon minecraft:item ~ ~ ~ {Item:{id:"1",Count:1b}}
  • Particles

    • /particle blockdust ~ ~ ~ 0 0 0 1 10 force @a 1
  • Loot tables

    • {
          "pools": [
              {
                  "rolls": 1,
                  "entries": [
                      {
                          "type": "item",
                          "name": "1",
                          "weight": 1
                      }
                  ]
              }
          ]
      }
  • CanPlaceOn and can destroy (MC-50795)

    • /give @p command_block 1 0 {CanPlaceOn:["137"]}

Expected behaviour: none of the items exist as it's an invalid id.

Note: it has to be defined as a string, any other tag type won't work
Note 2: It might be a good idea to hide the numeral ids from F3+H as they shouldn't be used anymore.

Linked issues

Comments 6

To address your Note 2, currently the numeric IDs are still used for particle parameters (as well as enderman holding blocks (bug, MC-75430)).

  • Particles

    • /particle blockdust ~ ~ ~ 0 0 0 1 10 force @a 1

I included this for a reason; and the enderman holding blocks already read the string variants, it's just still saved as a short, that's what that ticket is about. That's why I included that note.

Oh, I'm sorry, I must have missed that one. My bad.

If there are two blocks with same names, it would be confusing. For example, if a string ID of a cake in block form is minecraft:cake_block and a cake in item form is minecraft:cake, it would be very confusing, because they are very much the same.

user-f2760

(Unassigned)

Confirmed

Minecraft 1.11.2, Minecraft 17w06a, Minecraft 1.12, Minecraft 1.12.1 Pre-Release 1

Minecraft 17w47a

Retrieved