From 6a72a83076897cf55f9be73b992d59c4ebc22d95 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Sat, 20 Apr 2024 16:22:22 -0400 Subject: [PATCH] Must be in a building and in city --- src/engine/gameManager/ItemManager.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/engine/gameManager/ItemManager.java b/src/engine/gameManager/ItemManager.java index 83e8213f..eeb28808 100644 --- a/src/engine/gameManager/ItemManager.java +++ b/src/engine/gameManager/ItemManager.java @@ -244,6 +244,12 @@ public enum ItemManager { ItemTemplate template = ItemTemplate.templates.get(workOrder.templateID); + if (workOrder.vendor.getBuilding() == null) + return 58; //58: The formula is beyond the means of this facility + + if (workOrder.vendor.getBuilding().getCity() == null) + return 58; //58: The formula is beyond the means of this facility + if (!workOrder.vendor.charItemManager.hasRoomInventory(template.item_wt)) return 30; //30: That person cannot carry that item