mirror of
https://github.com/GTNewHorizons/ForestryMC.git
synced 2026-11-24 22:04:34 +00:00
Fix recent issue with item inventories potentially losing items
This commit is contained in:
1 parent
f6d8005e03
commit
4cf7fd84b9
1 file changed
+3
-2
@@ -145,12 +145,12 @@ public abstract class ItemInventory implements IInventory, IFilterSlotDelegate {
|
||||
}
|
||||
}
|
||||
|
||||
migrateToNewNBT();
|
||||
writeToParentNBT();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void migrateToNewNBT() {
|
||||
private void writeToParentNBT() {
|
||||
ItemStack parent = getParent();
|
||||
if (parent == null) {
|
||||
return;
|
||||
@@ -254,6 +254,7 @@ public abstract class ItemInventory implements IInventory, IFilterSlotDelegate {
|
||||
|
||||
@Override
|
||||
public final void markDirty() {
|
||||
writeToParentNBT();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user