forked from MagicBane/Server
Renamed class to not conflict with the java.lang version.
This commit is contained in:
@@ -9,12 +9,12 @@
|
||||
|
||||
package engine.objects;
|
||||
|
||||
import engine.Enum;
|
||||
import engine.InterestManagement.WorldGrid;
|
||||
import engine.gameManager.BuildingManager;
|
||||
import engine.gameManager.ChatManager;
|
||||
import engine.gameManager.DbManager;
|
||||
import engine.gameManager.ZoneManager;
|
||||
import engine.mbEnums;
|
||||
import engine.net.ByteBufferWriter;
|
||||
import engine.net.client.msg.ErrorPopupMsg;
|
||||
import engine.server.MBServerStatics;
|
||||
@@ -45,7 +45,7 @@ public class Mine extends AbstractGameObject {
|
||||
public GuildTag guildTag;
|
||||
public String nationName;
|
||||
public GuildTag nationTag;
|
||||
private Enum.ResourceType production;
|
||||
private mbEnums.ResourceType production;
|
||||
private Guild owningGuild;
|
||||
private int flags;
|
||||
private int buildingID;
|
||||
@@ -88,7 +88,7 @@ public class Mine extends AbstractGameObject {
|
||||
this.nationTag = GuildTag.ERRANT;
|
||||
}
|
||||
|
||||
this.production = Enum.ResourceType.valueOf(rs.getString("mine_resource"));
|
||||
this.production = mbEnums.ResourceType.valueOf(rs.getString("mine_resource"));
|
||||
this.lastClaimer = null;
|
||||
|
||||
}
|
||||
@@ -114,7 +114,7 @@ public class Mine extends AbstractGameObject {
|
||||
if (mine.getBlueprint() == null)
|
||||
return;
|
||||
|
||||
if (mine.getBlueprint().getBuildingGroup() != Enum.BuildingGroup.MINE)
|
||||
if (mine.getBlueprint().getBuildingGroup() != mbEnums.BuildingGroup.MINE)
|
||||
return;
|
||||
|
||||
|
||||
@@ -310,7 +310,7 @@ public class Mine extends AbstractGameObject {
|
||||
return mineCnt <= tolRank;
|
||||
}
|
||||
|
||||
public boolean changeProductionType(Enum.ResourceType resource) {
|
||||
public boolean changeProductionType(mbEnums.ResourceType resource) {
|
||||
if (!this.validForMine(resource))
|
||||
return false;
|
||||
//update resource in database;
|
||||
@@ -333,7 +333,7 @@ public class Mine extends AbstractGameObject {
|
||||
return this.zoneName;
|
||||
}
|
||||
|
||||
public Enum.ResourceType getProduction() {
|
||||
public mbEnums.ResourceType getProduction() {
|
||||
return this.production;
|
||||
}
|
||||
|
||||
@@ -380,7 +380,7 @@ public class Mine extends AbstractGameObject {
|
||||
building.isDeranking.compareAndSet(true, false);
|
||||
}
|
||||
|
||||
public boolean validForMine(Enum.ResourceType r) {
|
||||
public boolean validForMine(mbEnums.ResourceType r) {
|
||||
if (this.mineType == null)
|
||||
return false;
|
||||
return this.mineType.validForMine(r, this.isExpansion());
|
||||
@@ -444,7 +444,7 @@ public class Mine extends AbstractGameObject {
|
||||
|
||||
// remove hirelings
|
||||
|
||||
Building building = (Building) getObject(Enum.GameObjectType.Building, this.buildingID);
|
||||
Building building = (Building) getObject(mbEnums.GameObjectType.Building, this.buildingID);
|
||||
BuildingManager.cleanupHirelings(building);
|
||||
}
|
||||
|
||||
@@ -482,7 +482,7 @@ public class Mine extends AbstractGameObject {
|
||||
if (this.owningGuild.getOwnedCity().warehouse == null)
|
||||
return false;
|
||||
|
||||
return Warehouse.depositFromMine(this, Enum.ResourceType.resourceLookup.get(this.production.templateID), this.getModifiedProductionAmount(), this.owningGuild.getOwnedCity().warehouse);
|
||||
return Warehouse.depositFromMine(this, mbEnums.ResourceType.resourceLookup.get(this.production.templateID), this.getModifiedProductionAmount(), this.owningGuild.getOwnedCity().warehouse);
|
||||
}
|
||||
|
||||
public boolean updateGuildOwner(PlayerCharacter playerCharacter) {
|
||||
|
||||
Reference in New Issue
Block a user