mirror of
https://github.com/GTNewHorizons/StorageDrawers.git
synced 2026-11-19 11:59:19 +00:00
Fix compression drawer contents preservation
This commit is contained in:
1 parent
5443d013d9
commit
105188da16
1 file changed
+5
-1
@@ -64,7 +64,7 @@ public class TileEntityCompDrawers extends TileEntityDrawersBase implements ISto
|
||||
if (!isSlotValid(slot))
|
||||
return 0;
|
||||
|
||||
return data[slot].maxCapacity() * convRate[slot];
|
||||
return data[slot].maxCapacity();
|
||||
}
|
||||
|
||||
public int getItemStackSize (int slot) {
|
||||
@@ -184,6 +184,8 @@ public class TileEntityCompDrawers extends TileEntityDrawersBase implements ISto
|
||||
data[i].readFromNBT(slot);
|
||||
}
|
||||
|
||||
pooledCount = tag.getInteger("Count");
|
||||
|
||||
for (int i = 0; i < convRate.length; i++)
|
||||
convRate[i] = 0;
|
||||
|
||||
@@ -209,6 +211,8 @@ public class TileEntityCompDrawers extends TileEntityDrawersBase implements ISto
|
||||
slots.appendTag(slot);
|
||||
}
|
||||
|
||||
tag.setInteger("Count", pooledCount);
|
||||
|
||||
if (convRate[0] > 0)
|
||||
tag.setByte("Conv0", (byte)convRate[0]);
|
||||
if (convRate[1] > 0)
|
||||
|
||||
Reference in new issue
Block a user