Updated to 1.4.6 Forge/FML, fixed some refactoring
Never push code that doesn't compile!
This commit is contained in:
parent
4a318d8a9b
commit
7a7aabb0d7
12 changed files with 22 additions and 26 deletions
|
@ -9,8 +9,8 @@ import net.minecraft.world.World;
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import assemblyline.common.AssemblyLine;
|
import assemblyline.common.AssemblyLine;
|
||||||
import cpw.mods.fml.common.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public class GuiAutoCrafting extends GuiContainer
|
public class GuiAutoCrafting extends GuiContainer
|
||||||
|
|
|
@ -5,8 +5,8 @@ import net.minecraft.client.gui.GuiButton;
|
||||||
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
import cpw.mods.fml.common.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Copied from GSM lib and modified for this mod only
|
* Copied from GSM lib and modified for this mod only
|
||||||
|
|
|
@ -9,8 +9,8 @@ import assemblyline.client.model.ModelConveyorBelt;
|
||||||
import assemblyline.common.AssemblyLine;
|
import assemblyline.common.AssemblyLine;
|
||||||
import assemblyline.common.machine.belt.TileEntityConveyorBelt;
|
import assemblyline.common.machine.belt.TileEntityConveyorBelt;
|
||||||
import assemblyline.common.machine.belt.TileEntityConveyorBelt.SlantType;
|
import assemblyline.common.machine.belt.TileEntityConveyorBelt.SlantType;
|
||||||
import cpw.mods.fml.common.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public class RenderConveyorBelt extends TileEntitySpecialRenderer
|
public class RenderConveyorBelt extends TileEntitySpecialRenderer
|
||||||
|
@ -19,7 +19,7 @@ public class RenderConveyorBelt extends TileEntitySpecialRenderer
|
||||||
|
|
||||||
private void renderAModelAt(TileEntityConveyorBelt tileEntity, double x, double y, double z, float f)
|
private void renderAModelAt(TileEntityConveyorBelt tileEntity, double x, double y, double z, float f)
|
||||||
{
|
{
|
||||||
boolean mid = tileEntity.isMiddleBelt();
|
boolean mid = tileEntity.getIsMiddleBelt();
|
||||||
SlantType slantType = tileEntity.getSlant();
|
SlantType slantType = tileEntity.getSlant();
|
||||||
int face = tileEntity.getDirection().ordinal();
|
int face = tileEntity.getDirection().ordinal();
|
||||||
|
|
||||||
|
@ -76,7 +76,7 @@ public class RenderConveyorBelt extends TileEntitySpecialRenderer
|
||||||
}
|
}
|
||||||
|
|
||||||
int ent = tileEntity.worldObj.getBlockId(tileEntity.xCoord, tileEntity.yCoord, tileEntity.zCoord);
|
int ent = tileEntity.worldObj.getBlockId(tileEntity.xCoord, tileEntity.yCoord, tileEntity.zCoord);
|
||||||
model.render(0.0625F, (float) Math.toRadians(tileEntity.wheelRotation), tileEntity.isLastBelt(), tileEntity.isFirstBelt(), false);
|
model.render(0.0625F, (float) Math.toRadians(tileEntity.wheelRotation), tileEntity.getIsLastBelt(), tileEntity.getIsFirstBelt(), false);
|
||||||
|
|
||||||
GL11.glPopMatrix();
|
GL11.glPopMatrix();
|
||||||
|
|
||||||
|
|
|
@ -14,8 +14,8 @@ import assemblyline.common.machine.BlockMulti.MachineType;
|
||||||
import cpw.mods.fml.client.FMLClientHandler;
|
import cpw.mods.fml.client.FMLClientHandler;
|
||||||
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
|
||||||
import cpw.mods.fml.client.registry.RenderingRegistry;
|
import cpw.mods.fml.client.registry.RenderingRegistry;
|
||||||
import cpw.mods.fml.common.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
@SideOnly(Side.CLIENT)
|
@SideOnly(Side.CLIENT)
|
||||||
public class RenderHelper implements ISimpleBlockRenderingHandler
|
public class RenderHelper implements ISimpleBlockRenderingHandler
|
||||||
|
|
|
@ -42,7 +42,7 @@ public class ArmHelper
|
||||||
List<EntityItem> itemsList = world.getEntitiesWithinAABB(EntityItem.class, bounds);
|
List<EntityItem> itemsList = world.getEntitiesWithinAABB(EntityItem.class, bounds);
|
||||||
for (EntityItem item : itemsList)
|
for (EntityItem item : itemsList)
|
||||||
{
|
{
|
||||||
ItemStack stackItem = item.item;
|
ItemStack stackItem = item.func_92014_d();
|
||||||
if (stackItem.itemID != stack.itemID || stackItem.getItemDamage() != stack.getItemDamage())
|
if (stackItem.itemID != stack.itemID || stackItem.getItemDamage() != stack.getItemDamage())
|
||||||
{
|
{
|
||||||
itemsList.remove(item);
|
itemsList.remove(item);
|
||||||
|
|
|
@ -16,9 +16,9 @@ import universalelectricity.prefab.UETab;
|
||||||
import universalelectricity.prefab.implement.IRedstoneReceptor;
|
import universalelectricity.prefab.implement.IRedstoneReceptor;
|
||||||
import assemblyline.client.render.RenderHelper;
|
import assemblyline.client.render.RenderHelper;
|
||||||
import assemblyline.common.AssemblyLine;
|
import assemblyline.common.AssemblyLine;
|
||||||
import cpw.mods.fml.common.Side;
|
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
|
||||||
import cpw.mods.fml.common.network.PacketDispatcher;
|
import cpw.mods.fml.common.network.PacketDispatcher;
|
||||||
|
import cpw.mods.fml.relauncher.Side;
|
||||||
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A metadata block containing a bunch of machines with direction.
|
* A metadata block containing a bunch of machines with direction.
|
||||||
|
|
|
@ -15,17 +15,13 @@ import net.minecraft.tileentity.TileEntityChest;
|
||||||
import net.minecraft.util.AxisAlignedBB;
|
import net.minecraft.util.AxisAlignedBB;
|
||||||
import net.minecraftforge.common.ForgeDirection;
|
import net.minecraftforge.common.ForgeDirection;
|
||||||
import net.minecraftforge.common.ISidedInventory;
|
import net.minecraftforge.common.ISidedInventory;
|
||||||
import universalelectricity.core.electricity.ElectricityPack;
|
|
||||||
import universalelectricity.core.implement.IConductor;
|
|
||||||
import universalelectricity.core.vector.Vector3;
|
import universalelectricity.core.vector.Vector3;
|
||||||
import universalelectricity.prefab.implement.IRedstoneReceptor;
|
import universalelectricity.prefab.implement.IRedstoneReceptor;
|
||||||
import universalelectricity.prefab.network.IPacketReceiver;
|
import universalelectricity.prefab.network.IPacketReceiver;
|
||||||
import universalelectricity.prefab.network.PacketManager;
|
import universalelectricity.prefab.network.PacketManager;
|
||||||
import universalelectricity.prefab.tile.TileEntityElectricityReceiver;
|
|
||||||
import assemblyline.api.IManipulator;
|
import assemblyline.api.IManipulator;
|
||||||
import assemblyline.common.AssemblyLine;
|
import assemblyline.common.AssemblyLine;
|
||||||
import assemblyline.common.machine.BlockMulti.MachineType;
|
import assemblyline.common.machine.BlockMulti.MachineType;
|
||||||
import assemblyline.common.machine.belt.TileEntityConveyorBelt.SlantType;
|
|
||||||
|
|
||||||
import com.google.common.io.ByteArrayDataInput;
|
import com.google.common.io.ByteArrayDataInput;
|
||||||
|
|
||||||
|
@ -76,7 +72,7 @@ public class TileEntityManipulator extends TileEntityAssemblyNetwork implements
|
||||||
* Try top first, then bottom, then the sides to see if it is possible to
|
* Try top first, then bottom, then the sides to see if it is possible to
|
||||||
* insert the item into a inventory.
|
* insert the item into a inventory.
|
||||||
*/
|
*/
|
||||||
ItemStack remainingStack = this.tryPlaceInPosition(entity.item.copy(), outputUp, ForgeDirection.DOWN);
|
ItemStack remainingStack = this.tryPlaceInPosition(entity.func_92014_d().copy(), outputUp, ForgeDirection.DOWN);
|
||||||
|
|
||||||
if (remainingStack != null)
|
if (remainingStack != null)
|
||||||
{
|
{
|
||||||
|
|
|
@ -194,7 +194,7 @@ public class TileEntityRejector extends TileEntityElectricityReceiver implements
|
||||||
if (entity instanceof EntityItem)
|
if (entity instanceof EntityItem)
|
||||||
{
|
{
|
||||||
EntityItem itemE = (EntityItem) entity;
|
EntityItem itemE = (EntityItem) entity;
|
||||||
ItemStack item = itemE.item;
|
ItemStack item = itemE.func_92014_d();
|
||||||
|
|
||||||
if (this.guiButtons[4])
|
if (this.guiButtons[4])
|
||||||
{
|
{
|
||||||
|
|
|
@ -13,8 +13,8 @@ import universalelectricity.prefab.BlockMachine;
|
||||||
import universalelectricity.prefab.UETab;
|
import universalelectricity.prefab.UETab;
|
||||||
import assemblyline.client.render.RenderHelper;
|
import assemblyline.client.render.RenderHelper;
|
||||||
import assemblyline.common.machine.belt.TileEntityConveyorBelt.SlantType;
|
import assemblyline.common.machine.belt.TileEntityConveyorBelt.SlantType;
|
||||||
import cpw.mods.fml.common.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.common.asm.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The block for the actual conveyor belt!
|
* The block for the actual conveyor belt!
|
||||||
|
|
|
@ -100,7 +100,7 @@ public class TileEntityConveyorBelt extends TileEntityAssemblyNetwork implements
|
||||||
/**
|
/**
|
||||||
* Is this belt in the front of a conveyor line? Used for rendering.
|
* Is this belt in the front of a conveyor line? Used for rendering.
|
||||||
*/
|
*/
|
||||||
public boolean isFirstBelt()
|
public boolean getIsFirstBelt()
|
||||||
{
|
{
|
||||||
|
|
||||||
ForgeDirection front = this.getDirection();
|
ForgeDirection front = this.getDirection();
|
||||||
|
@ -119,7 +119,7 @@ public class TileEntityConveyorBelt extends TileEntityAssemblyNetwork implements
|
||||||
/**
|
/**
|
||||||
* Is this belt in the middile of two belts? Used for rendering.
|
* Is this belt in the middile of two belts? Used for rendering.
|
||||||
*/
|
*/
|
||||||
public boolean isMiddleBelt()
|
public boolean getIsMiddleBelt()
|
||||||
{
|
{
|
||||||
|
|
||||||
ForgeDirection front = this.getDirection();
|
ForgeDirection front = this.getDirection();
|
||||||
|
@ -139,7 +139,7 @@ public class TileEntityConveyorBelt extends TileEntityAssemblyNetwork implements
|
||||||
/**
|
/**
|
||||||
* Is this belt in the back of a conveyor line? Used for rendering.
|
* Is this belt in the back of a conveyor line? Used for rendering.
|
||||||
*/
|
*/
|
||||||
public boolean isLastBelt()
|
public boolean getIsLastBelt()
|
||||||
{
|
{
|
||||||
|
|
||||||
ForgeDirection front = this.getDirection();
|
ForgeDirection front = this.getDirection();
|
||||||
|
|
|
@ -244,7 +244,7 @@ public class EntityCraftingArm extends Entity
|
||||||
*/
|
*/
|
||||||
private void grabItem()
|
private void grabItem()
|
||||||
{
|
{
|
||||||
itemStackBeingHeld = itemEntityTarget.item;
|
itemStackBeingHeld = itemEntityTarget.func_92014_d();
|
||||||
playGrabbingEffects(itemEntityTarget.posX, itemEntityTarget.posY, itemEntityTarget.posZ);
|
playGrabbingEffects(itemEntityTarget.posX, itemEntityTarget.posY, itemEntityTarget.posZ);
|
||||||
itemEntityTarget.setDead();
|
itemEntityTarget.setDead();
|
||||||
itemEntityTarget = null;
|
itemEntityTarget = null;
|
||||||
|
|
|
@ -209,7 +209,7 @@ public abstract class BlockMachine extends BlockContainer
|
||||||
|
|
||||||
if (var7.hasTagCompound())
|
if (var7.hasTagCompound())
|
||||||
{
|
{
|
||||||
var12.item.setTagCompound((NBTTagCompound) var7.getTagCompound().copy());
|
var12.func_92014_d().setTagCompound((NBTTagCompound) var7.getTagCompound().copy());
|
||||||
}
|
}
|
||||||
|
|
||||||
float var13 = 0.05F;
|
float var13 = 0.05F;
|
||||||
|
|
Loading…
Reference in a new issue