diff --git a/src/engine/gameManager/BuildingManager.java b/src/engine/gameManager/BuildingManager.java index d1f24b9a..ae9fc246 100644 --- a/src/engine/gameManager/BuildingManager.java +++ b/src/engine/gameManager/BuildingManager.java @@ -207,14 +207,12 @@ public enum BuildingManager { return false; } - ItemBase elanIB = ItemBase.getItemBase(1705032); - ItemTemplate template = ItemTemplate.itemTemplates.get(1705032); // Elan Stone if (!player.getCharItemManager().hasRoomInventory(template.item_wt)) return false; - if (!Item.MakeItemForPlayer(elanIB, player, amount)) + if (!Item.MakeItemForPlayer(template.template_id, player, amount)) return false; shrine.setFavors(0); diff --git a/src/engine/objects/Item.java b/src/engine/objects/Item.java index 1f43d1bb..64e87ac0 100644 --- a/src/engine/objects/Item.java +++ b/src/engine/objects/Item.java @@ -353,11 +353,11 @@ public class Item extends AbstractWorldObject { } - public static boolean MakeItemForPlayer(ItemBase toCreate, PlayerCharacter reciever, int amount) { + public static boolean MakeItemForPlayer(int templateID, PlayerCharacter reciever, int amount) { boolean itemWorked = false; - Item item = new Item(toCreate.getUUID()); + Item item = new Item(templateID); item.ownerID = reciever.getObjectUUID(); item.ownerType = OwnerType.PlayerCharacter;