sephiria-fantasy-0.2.10.16.1-a.jar
Curse Maven Snippet
What's new
A patch release fixing "items obtained with a full inventory get swallowed" — whatever does not fit now drops from the player instead.
Fix: items no longer vanish when the inventory is full Affected delivery points: the Upgrade Chest from experience, shop purchases, chest rewards, and dice granted by potions.
The root cause was the check itself: these sites decided whether to drop with "if inventory.add(stack) returns false, drop it", but add's return value only answers "did anything go in", not "did everything go in". Two ways to lose items followed:
with a genuinely full inventory in creative mode, add clears the whole stack and returns true (vanilla assumes creative players can spawn anything), so the drop never ran and nobody got the item; when only part of the stack fits (e.g. a potion grants 5 dice with room for 3), add also returns true, the caller believes it is done, and the remaining dice are swallowed. All of them now go through vanilla's own "fill slot by slot, drop the whole remainder when nothing fits" path (Inventory#placeItemBackInInventory), behaving the same in survival and creative. Bonus: when only part of a stack fits, the remainder now drops as well (it used to be silently swallowed).
This mod has no additional files