Clean up TE implementations

Offload some work to base classes that provide some helpers

TODO: Implementations for Inventories (using caps) and ticking tiles with inventories.
This commit is contained in:
Nicholas Ignoffo 2016-09-07 17:46:06 -07:00
parent 4d331aa758
commit 798bad5583
23 changed files with 280 additions and 493 deletions

View file

@ -282,9 +282,9 @@ public class TileMimic extends TileInventory implements ITickable
}
@Override
public void readFromNBT(NBTTagCompound tag)
public void deserialize(NBTTagCompound tag)
{
super.readFromNBT(tag);
super.deserialize(tag);
dropItemsOnBreak = tag.getBoolean("dropItemsOnBreak");
tileTag = tag.getCompoundTag("tileTag");
@ -296,9 +296,9 @@ public class TileMimic extends TileInventory implements ITickable
}
@Override
public NBTTagCompound writeToNBT(NBTTagCompound tag)
public NBTTagCompound serialize(NBTTagCompound tag)
{
super.writeToNBT(tag);
super.serialize(tag);
tag.setBoolean("dropItemsOnBreak", dropItemsOnBreak);
tag.setTag("tileTag", tileTag);