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

Fuel indicator (fire symbol) in furnace resets to full on world reload if no fuel is present.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • None
    • 1.20.4
    • None
    • Unconfirmed
    • (Unassigned)

      Reproduction steps:

      1. Smelt anything with a lava bucket as fuel in the furnace.
      2. Wait until the fuel bar (the fire in the furnace screen) is about half depleted.
      3. Save and quit the world.
      4. Rejoin the world and open the furnace.
      5. Notice that the fuel bar is at full again, despite the lava bucket being half out.

      Note

      Note that this is a visual bug, and does not affect the actual burn time of the furnace.

      Code analysis (yarn):

      Upon world load, this code is used to initialize a furnace block entity in `
      AbstractFurnaceBlockEntity#readNbt`:

      this.burnTime = nbt.getShort("BurnTime");
      this.cookTime = nbt.getShort("CookTime");
      this.cookTimeTotal = nbt.getShort("CookTimeTotal");
      this.fuelTime = this.getFuelTime(this.inventory.get(1)); 

      Notice that the `burnTime`, `cookTime`, and `cookTimeTotal` are all saved, but the `fuelTime` is not saved. If there is no fuel item in the fuel slot on world load, in the case of the lava bucket, `fuelTime` is 0, which causes the fuel bar to look full. (Note that the fuel time is set to 200 when rendering if the fuel time is zero, so no worry of crashes here.)

            Unassigned Unassigned
            Kevinthegreat Kevin
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: