Refactor warehouse part two.

This commit is contained in:
2024-03-17 09:01:35 -04:00
parent 3c70a09e12
commit b76a384e1f
6 changed files with 132 additions and 811 deletions
+3 -3
View File
@@ -271,7 +271,7 @@ public class Mine extends AbstractGameObject {
if (guildCity == null)
return false;
if (guildCity.getWarehouse() == null) {
if (guildCity.warehouse == null) {
ErrorPopupMsg.sendErrorMsg(playerCharacter, "No Warehouse exists for this claim.");
return false;
}
@@ -479,10 +479,10 @@ public class Mine extends AbstractGameObject {
if (this.owningGuild.getOwnedCity() == null)
return false;
if (this.owningGuild.getOwnedCity().getWarehouse() == null)
if (this.owningGuild.getOwnedCity().warehouse == null)
return false;
return Warehouse.depositFromMine(this, Enum.ResourceType.resourceLookup.get(this.production.templateID), this.getModifiedProductionAmount(), this.owningGuild.getOwnedCity().getWarehouse());
return Warehouse.depositFromMine(this, Enum.ResourceType.resourceLookup.get(this.production.templateID), this.getModifiedProductionAmount(), this.owningGuild.getOwnedCity().warehouse);
}
public boolean updateGuildOwner(PlayerCharacter playerCharacter) {