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

Switching game modes while in inventory can delete items

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • 1.16.1, 1.16.4
    • Confirmed
    • (Unassigned)

      The bug

      If your gamemode is switched between survival and creative via a datapack when you pick up an item in your inventory with your cursor, that item will be unexpectedly deleted. This makes it difficult to create datapacks or gamemodes that involve switching between the two, especially if important items are involved, or if those items are supposed to trigger the gamemode change themselves.

      How to reproduce

      1. Obtain an item in survival
      2. Make a datapack that changes your gamemode while your in your inventory screen (on an interval, triggered by another player, etc.)
      3. Attempt to move that item in your inventory, and hold it as your gamemode changes

      What I'd expect to happen: The item remains under my cursor, or is dropped in front of me
      What actually happens: The item disappears.

            Unassigned Unassigned
            Pacca Pacca
            Votes:
            3 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              CHK: