forked from MagicBane/Server
siege engineer can be slotted in siege tents
This commit is contained in:
@@ -8,6 +8,7 @@ import engine.mobileAI.utilities.MovementUtilities;
|
||||
import engine.objects.Building;
|
||||
import engine.objects.City;
|
||||
import engine.objects.Mob;
|
||||
import engine.server.MBServerStatics;
|
||||
|
||||
public class SiegeHandler {
|
||||
public static void run(Mob engine){
|
||||
@@ -30,7 +31,7 @@ public class SiegeHandler {
|
||||
if(!engine.despawned) {
|
||||
engine.despawn();
|
||||
}else{
|
||||
if(engine.deathTime + (engine.spawnTime * 1000) > System.currentTimeMillis()){
|
||||
if(engine.deathTime + MBServerStatics.FIFTEEN_MINUTES > System.currentTimeMillis()){
|
||||
engine.respawn();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -737,6 +737,9 @@ public class Contract extends AbstractGameObject {
|
||||
if (this.allowedBuildings.size() == 0)
|
||||
return false;
|
||||
|
||||
if(this.name.equals("Siege Engineer") && building.getBlueprint().getBuildingGroup().equals(Enum.BuildingGroup.SIEGETENT))
|
||||
return true;
|
||||
|
||||
// Binary match
|
||||
return (building.getBlueprint().getBuildingGroup().elementOf(this.allowedBuildings));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user