Mojira Archive
MC-269837

Stack sizes 65-99 from prior versions are not upgraded as expected when accounting for maximum stack size component

The bug

If a world containing items stacked above 64 is loaded in the latest 1.20.5 snapshot (24w12a), those stack sizes are decreased to 64. This is despite the fact that stack sizes up to 99 are now explicitly supported due to the implementation of the new max_stack_size component.

Unlike in MC-269536, this concerns stack sizes in an explicitly supported range.

How to reproduce

  1. Download the attached world
  2. Load it in an older version (I'm using 1.8.9 as I don't know when MC-267171 starts taking effect)
  3. Load it in the latest snapshot
  4. Run the command
    /give @s black_wool[minecraft:max_stack_size=99] 99

Expected results

Items with stack sizes 65 to 99 inclusive would remain as stacks of sizes 65 to 99 inclusive.

Actual results

They are decreased to 64, outright deleting many items. The executed command demonstrates that stack sizes 65-99 are clearly still possible.

How to fix

Cap stack sizes to 99, not 64, when upgrading worlds. Optionally, give these items max stack size components to account for their stack sizes as well.

Works As Intended

Connor Steppie

2024-03-24, 01:03 PM

2024-03-26, 08:09 AM

2024-03-26, 08:09 AM

1

1

Community Consensus

Datafixer

data-fixer

24w12a

-