Declare the bane local at the top of placeWarehouse

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
MagicBotandClaude Opus 5.5 committed 2026-10-18 10:12:56 -04:00
1 parent e450224902
commit c97b4d7c3d
1 file changed
+4 -1
@@ -496,6 +496,7 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
Zone serverZone;
City cityObject;
Bane bane;
PlacementInfo buildingList;
// Retrieve the building details we're placing
@@ -534,7 +535,9 @@ public class PlaceAssetMsgHandler extends AbstractClientMsgHandler {
// A rebuilt warehouse would orphan the destroyed warehouse's loot
if (cityObject.getBane() != null) {
bane = cityObject.getBane();
if (bane != null) {
PlaceAssetMsg.sendPlaceAssetError(origin, 1, "Cannot place a warehouse during an active bane.");
return false;
}