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

/give'd items after death are destroyed

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • 1.18.2, 1.19.1
    • None
    • Community Consensus
    • Commands
    • Low
    • Platform

      If a command block or datapack uses /give on a dead player, the items appear in their inventory while they are dead. However, on respawn, instead of being dropped, they are destroyed. This possibly affects some maps with command blocks or data packs.

      STEPS TO REPRODUCE:

      1. Make a new creative world.

      2. Set up a repeating command block (or on a repeating redstone timer to make count slower and easier to track) with /give @p diamond

      3. Watch as diamonds increase in your inventory, then type /kill.

      4. Watch the diamonds on the ground from your inventory, and then the new diamonds increasing in your hotbar. Let these new diamonds reach a significant amount.

      5. Respawn, and go back to your death spot; the diamonds that were /give'd during death will have disappeared.

      POSSIBLE CODE FIXES BASED ON LIKELY CAUSES:

      1. Make /give fail on a dead player
      2. Drop inventory on respawning as well as death
      3. Disable the inventory during death; /give'd items could drop on floor like when your inventory is full.

       

            Unassigned Unassigned
            menderelcapBIG Miles Caprio
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              CHK: