From cbda740cba80fce140bb545efbd50d64c601aff1 Mon Sep 17 00:00:00 2001 From: Hea3veN Date: Thu, 16 Apr 2015 20:24:42 -0300 Subject: [PATCH] fix not being able to set blueprints to the construction markers --- common/buildcraft/builders/BlockConstructionMarker.java | 3 ++- common/buildcraft/builders/BlockMarker.java | 2 +- common/buildcraft/builders/ItemBlueprint.java | 4 ++++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/common/buildcraft/builders/BlockConstructionMarker.java b/common/buildcraft/builders/BlockConstructionMarker.java index 99c2a0f8..bcdc3520 100755 --- a/common/buildcraft/builders/BlockConstructionMarker.java +++ b/common/buildcraft/builders/BlockConstructionMarker.java @@ -80,9 +80,10 @@ public class BlockConstructionMarker extends BlockMarker { } else if (equipped instanceof ItemConstructionMarker) { if (ItemConstructionMarker.linkStarted(entityplayer.getCurrentEquippedItem())) { ItemConstructionMarker.link(entityplayer.getCurrentEquippedItem(), world, x, y, z); + return true; } } - return true; + return false; } } diff --git a/common/buildcraft/builders/BlockMarker.java b/common/buildcraft/builders/BlockMarker.java index 78e0a4fb..105ddcff 100644 --- a/common/buildcraft/builders/BlockMarker.java +++ b/common/buildcraft/builders/BlockMarker.java @@ -97,7 +97,7 @@ public class BlockMarker extends BlockBuildCraft { if (tile instanceof TileMarker) { ((TileMarker) tile).tryConnection(); } - return true; + return false; } @Override diff --git a/common/buildcraft/builders/ItemBlueprint.java b/common/buildcraft/builders/ItemBlueprint.java index c5d61bc6..88ef412b 100644 --- a/common/buildcraft/builders/ItemBlueprint.java +++ b/common/buildcraft/builders/ItemBlueprint.java @@ -123,6 +123,10 @@ public abstract class ItemBlueprint extends ItemBuildCraft implements IBlueprint } LibraryId id = getId(stack); + if (id == null) { + return null; + } + NBTTagCompound nbt = BuildCraftBuilders.serverDB.load(id); BlueprintBase base; if (((IBlueprintItem) stack.getItem()).getType(stack) == IBlueprintItem.Type.TEMPLATE) {