diff --git a/src/main/java/cr0s/warpdrive/compat/CompatIndustrialCraft2.java b/src/main/java/cr0s/warpdrive/compat/CompatIndustrialCraft2.java index e49afeea..c7380f63 100644 --- a/src/main/java/cr0s/warpdrive/compat/CompatIndustrialCraft2.java +++ b/src/main/java/cr0s/warpdrive/compat/CompatIndustrialCraft2.java @@ -4,7 +4,7 @@ import net.minecraft.block.Block; import net.minecraft.nbt.NBTBase; import net.minecraft.nbt.NBTTagCompound; import net.minecraft.tileentity.TileEntity; -import cpw.mods.fml.common.Optional; + import cr0s.warpdrive.api.IBlockTransformer; import cr0s.warpdrive.api.ITransformation; import cr0s.warpdrive.config.WarpDriveConfig; @@ -33,14 +33,12 @@ public class CompatIndustrialCraft2 implements IBlockTransformer { } @Override - @Optional.Method(modid = "IC2") public NBTBase saveExternals(final TileEntity tileEntity) { // nothing to do return null; } @Override - @Optional.Method(modid = "IC2") public void remove(TileEntity tileEntity) { // nothing to do } @@ -69,7 +67,6 @@ public class CompatIndustrialCraft2 implements IBlockTransformer { } @Override - @Optional.Method(modid = "IC2") public void restoreExternals(TileEntity tileEntity, ITransformation transformation, NBTBase nbtBase) { // nothing to do } diff --git a/src/main/java/cr0s/warpdrive/data/BlockMetaRotation.java b/src/main/java/cr0s/warpdrive/data/BlockMetaRotation.java deleted file mode 100644 index cfab3bce..00000000 --- a/src/main/java/cr0s/warpdrive/data/BlockMetaRotation.java +++ /dev/null @@ -1,34 +0,0 @@ -package cr0s.warpdrive.data; - -import net.minecraft.block.Block; - -public class BlockMetaRotation { - public final Block block; - public final int[] metaRotation; - private int bitMask; - - protected BlockMetaRotation(Block block, int[] metarotation, int bitmask) { - if (metarotation.length != 4) { - throw new IllegalArgumentException("MetaRotation int array must have length 4"); - } else { - this.block = block; - this.metaRotation = metarotation; - this.bitMask = bitmask; - } - } - - public int getRotatedMeta(int currentmeta, int rotate) { - for (int i = 0; i < this.metaRotation.length; ++i) { - if (this.metaRotation[i] == (currentmeta & this.bitMask)) { - int mr = currentmeta & ~this.bitMask | this.metaRotation[wrapRotationIndex(i + rotate)] & this.bitMask; - return mr; - } - } - - return currentmeta; - } - - public static int wrapRotationIndex(int i) { - return i & 3; - } -}