Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-271182

Give commands with the minecraft:food component don't seem to work

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Awaiting Response
    • None
    • 1.20.5, 1.20.6 Release Candidate 1
    • None
    • Unconfirmed
    • (Unassigned)

      /give @p apple[food=

      {nutrition:2,saturation:0.4,is_meat:false,can_always_eat:false,eat_seconds:1}

      ] 1

      Running this command will give an error that the component minecraft:food is malformed, and it says that no key eat_sound in MapLike[

      {can_always_eat:0b,eat_seconds:1,is_meat:0b,nutrition:2,saturation:0.4d}

      ]
      The expected output is that the command is successfully executed and the player is given an apple with the components.
      This has been tested in 1.20.6rc1 and gives the same results as being in 1.20.5

            Unassigned Unassigned
            CaptainFlame54 CaptainFlame54
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: