fix merge conflict

This commit is contained in:
AEnterprise 2014-09-20 11:46:31 +02:00
commit 8d6dc8c29b
2 changed files with 8 additions and 0 deletions

View file

@ -35,6 +35,7 @@ public class ItemWrench extends ItemBuildCraft implements IToolWrench {
shiftRotations.add(BlockLever.class);
shiftRotations.add(BlockButton.class);
shiftRotations.add(BlockChest.class);
setHarvestLevel("wrench", 0);
}
private boolean isShiftRotation(Class<? extends Block> cls) {

View file

@ -30,6 +30,7 @@ import net.minecraft.entity.player.EntityPlayerMP;
import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.IIcon;
@ -50,6 +51,7 @@ import buildcraft.api.core.BCLog;
import buildcraft.api.core.BlockIndex;
import buildcraft.api.events.BlockInteractionEvent;
import buildcraft.api.events.PipePlacedEvent;
import buildcraft.api.events.RobotPlacementEvent;
import buildcraft.api.gates.GateExpansions;
import buildcraft.api.gates.IGateExpansion;
import buildcraft.api.tools.IToolWrench;
@ -792,6 +794,11 @@ public class BlockGenericPipe extends BlockBuildCraft {
if (((ItemRobot) currentItem.getItem()).getRobotNBT(currentItem) == null) {
return true;
}
RobotPlacementEvent event = new RobotPlacementEvent(player, ((NBTTagCompound) currentItem.stackTagCompound.getTag("board")).getString("id"));
FMLCommonHandler.instance().bus().post(event);
if (event.isCanceled()) {
return true;
}
EntityRobot robot = ((ItemRobot) currentItem.getItem())
.createRobot(currentItem, world);
robot.setUniqueRobotId(robot.getRegistry().getNextRobotId());