Bug fixes!

This commit is contained in:
Aidan C. Brady 2014-06-09 16:19:36 +02:00
parent 726d9ebb0a
commit dd83381774
5 changed files with 17 additions and 5 deletions

View file

@ -793,7 +793,7 @@ public class Mekanism
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.fence), new ChanceOutput(new ItemStack(Items.stick, 3)));
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.fence_gate), new ChanceOutput(new ItemStack(Blocks.planks, 2), new ItemStack(Items.stick, 4), 1));
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.noteblock), new ChanceOutput(new ItemStack(Blocks.planks, 8), new ItemStack(Items.redstone, 1), 1));
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.unlit_redstone_torch), new ChanceOutput(new ItemStack(Items.stick, 1), new ItemStack(Items.redstone), 1));
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.redstone_torch), new ChanceOutput(new ItemStack(Items.stick, 1), new ItemStack(Items.redstone), 1));
RecipeHandler.addPrecisionSawmillRecipe(new ItemStack(Blocks.crafting_table), new ChanceOutput(new ItemStack(Blocks.planks, 4)));
//Metallurgic Infuser Recipes

View file

@ -66,10 +66,15 @@ public class BlockCardboardBox extends BlockContainer
if(tileEntity.storedData != null)
{
BlockData data = tileEntity.storedData;
if(!data.block.canPlaceBlockAt(world, x, y, z))
{
return true;
}
if(data.block != null)
{
data.meta =data.block.onBlockPlaced(world, x, y, z, facing, hitX, hitY, hitZ, data.meta);
data.meta = data.block.onBlockPlaced(world, x, y, z, facing, hitX, hitY, hitZ, data.meta);
}
world.setBlock(x, y, z, data.block, data.meta, 3);

View file

@ -76,7 +76,7 @@ public class ItemBlockCardboardBox extends ItemBlock
Block block = world.getBlock(x, y, z);
int meta = world.getBlockMetadata(x, y, z);
if(!world.isRemote && MekanismAPI.isBlockCompatible(Item.getItemFromBlock(block), meta))//TODO
if(!world.isRemote && MekanismAPI.isBlockCompatible(Item.getItemFromBlock(block), meta))
{
BlockData data = new BlockData();
data.block = block;

View file

@ -77,7 +77,7 @@ public class ThreadMinerSearch extends Thread
info.block = tileEntity.getWorldObj().getBlock(x, y, z);
info.meta = tileEntity.getWorldObj().getBlockMetadata(x, y, z);
if(info.block != null && info.block != Blocks.bedrock)
if(info.block != null && !tileEntity.getWorldObj().isAirBlock(x, y, z) && info.block != Blocks.bedrock)
{
boolean canFilter = false;

View file

@ -20,6 +20,7 @@ import mekanism.common.IEjector;
import mekanism.common.IFactory.RecipeType;
import mekanism.common.IInvConfiguration;
import mekanism.common.IRedstoneControl;
import mekanism.common.IUpgradeManagement;
import mekanism.common.IUpgradeTile;
import mekanism.common.Mekanism;
import mekanism.common.SideData;
@ -182,9 +183,15 @@ public class TileEntityFactory extends TileEntityElectricBlock implements IPerip
else if(recipeTicks == RECIPE_TICKS_REQUIRED)
{
recipeTicks = 0;
ItemStack returnStack = getMachineStack();
IUpgradeManagement mgmt = (IUpgradeManagement)inventory[2].getItem();
((IUpgradeManagement)returnStack.getItem()).setEnergyMultiplier(mgmt.getEnergyMultiplier(inventory[2]), returnStack);
((IUpgradeManagement)returnStack.getItem()).setSpeedMultiplier(mgmt.getSpeedMultiplier(inventory[2]), returnStack);
inventory[2] = null;
inventory[3] = getMachineStack();
inventory[3] = returnStack;
recipeType = toSet.ordinal();
gasTank.setGas(null);