v5.5.6 Beta #9 (FINAL for @CannibalVox)

*Minor javadoc additions.
*Fixed Chargepad pick block crash.
*Minor touchups
This commit is contained in:
Aidan Brady 2013-05-23 23:03:06 -04:00
parent 841d329f51
commit 8c75f707c0
5 changed files with 18 additions and 12 deletions

View file

@ -24,10 +24,10 @@ public class RenderChargepad extends TileEntitySpecialRenderer
switch(tileEntity.facing)
{
case 2: GL11.glRotatef(180, 0.0F, 1.0F, 0.0F); break;
case 3: GL11.glRotatef(0, 0.0F, 1.0F, 0.0F); break;
case 4: GL11.glRotatef(270, 0.0F, 1.0F, 0.0F); break;
case 5: GL11.glRotatef(90, 0.0F, 1.0F, 0.0F); break;
case 2: GL11.glRotatef(0, 0.0F, 1.0F, 0.0F); break;
case 3: GL11.glRotatef(180, 0.0F, 1.0F, 0.0F); break;
case 4: GL11.glRotatef(90, 0.0F, 1.0F, 0.0F); break;
case 5: GL11.glRotatef(270, 0.0F, 1.0F, 0.0F); break;
}
GL11.glRotatef(180F, 0.0F, 0.0F, 1.0F);

View file

@ -699,8 +699,11 @@ public class BlockMachine extends BlockContainer
energizedItem.setEnergy(itemStack, ((TileEntityElectricBlock)tileEntity).electricityStored);
}
ISustainedInventory inventory = (ISustainedInventory)itemStack.getItem();
inventory.setInventory(((ISustainedInventory)tileEntity).getInventory(), itemStack);
if(tileEntity instanceof TileEntityContainerBlock && ((TileEntityContainerBlock)tileEntity).inventory.length > 0)
{
ISustainedInventory inventory = (ISustainedInventory)itemStack.getItem();
inventory.setInventory(((ISustainedInventory)tileEntity).getInventory(), itemStack);
}
if(((ISustainedTank)itemStack.getItem()).hasTank(itemStack))
{

View file

@ -165,7 +165,10 @@ public class ItemBlockMachine extends ItemBlock implements IEnergizedItem, IItem
list.add(EnumColor.PURPLE + "Speed: " + EnumColor.GREY + "x" + (getSpeedMultiplier(itemstack)+1));
}
list.add(EnumColor.AQUA + "Inventory: " + EnumColor.GREY + (getInventory(itemstack) != null && getInventory(itemstack).tagCount() != 0));
if(itemstack.getItemDamage() != 14)
{
list.add(EnumColor.AQUA + "Inventory: " + EnumColor.GREY + (getInventory(itemstack) != null && getInventory(itemstack).tagCount() != 0));
}
}
}
@ -457,7 +460,7 @@ public class ItemBlockMachine extends ItemBlock implements IEnergizedItem, IItem
{
if(data[0] instanceof ItemStack)
{
if(((ItemStack)data[0]).getItemDamage() != 11 && ((ItemStack)data[0]).getItemDamage() != 12 && ((ItemStack)data[0]).getItemDamage() != 13)
if(((ItemStack)data[0]).getItemDamage() != 11 && ((ItemStack)data[0]).getItemDamage() != 12 && ((ItemStack)data[0]).getItemDamage() != 13 && ((ItemStack)data[0]).getItemDamage() != 14)
{
return true;
}

View file

@ -236,7 +236,7 @@ public class TileEntityChargepad extends TileEntityElectricBlock implements IAct
@Override
public boolean canReceiveEnergy(ForgeDirection side)
{
return side == ForgeDirection.DOWN || side == ForgeDirection.getOrientation(facing);
return side == ForgeDirection.DOWN || side == ForgeDirection.getOrientation(facing).getOpposite();
}
@Override
@ -272,7 +272,7 @@ public class TileEntityChargepad extends TileEntityElectricBlock implements IAct
@Override
public boolean acceptsEnergyFrom(TileEntity emitter, Direction direction)
{
return direction.toForgeDirection() == ForgeDirection.DOWN || direction.toForgeDirection() == ForgeDirection.getOrientation(facing);
return direction.toForgeDirection() == ForgeDirection.DOWN || direction.toForgeDirection() == ForgeDirection.getOrientation(facing).getOpposite();
}
@Override

View file

@ -10,10 +10,10 @@ import dan200.computer.api.IComputerAccess;
public class TileEntityWindTurbine extends TileEntityGenerator implements IBoundingBlock
{
public boolean canSpin;
/** The angle the blades of this Wind Turbine are currently at. */
public int angle;
/** How much energy this generator produces per-tick. */
public int GENERATION_RATE = 30;
public TileEntityWindTurbine()