Mekanism-tilera-Edition/common/calclavia/lib/flag/FlagBase.java

27 lines
454 B
Java
Raw Normal View History

package calclavia.lib.flag;
import net.minecraft.nbt.NBTTagCompound;
public abstract class FlagBase
{
public abstract void readFromNBT(NBTTagCompound nbt);
public abstract void writeToNBT(NBTTagCompound nbt);
public NBTTagCompound getNBT()
{
NBTTagCompound nbt = new NBTTagCompound();
try
{
this.writeToNBT(nbt);
}
catch (Exception e)
{
System.out.println("Failed to read flag");
e.printStackTrace();
}
return nbt;
}
}