Browse Source

cleanup

lakebane-master
fatboy 7 months ago
parent
commit
d8f1cf2087
  1. 30
      src/engine/objects/Bane.java

30
src/engine/objects/Bane.java

@ -209,6 +209,22 @@ public final class Bane {
return false; return false;
} }
for(Guild subGuild : baningGuild.getNation().getSubGuildList()) {
if (getBaneByAttackerGuild(subGuild) != null) {
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "Your Nation Already Has a Bane Placed");
return false;
}
}
if(targetCity.getGuild().getNation().getSubGuildList() != null) {
for (Guild subGuild : targetCity.getGuild().getNation().getSubGuildList()) {
if (getBaneByAttackerGuild(subGuild) != null) {
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "This Nation Already Has a Bane Placed On It");
return false;
}
}
}
Blueprint blueprint = Blueprint.getBlueprint(24300); // Banestone Blueprint blueprint = Blueprint.getBlueprint(24300); // Banestone
//Let's drop a banestone! //Let's drop a banestone!
@ -225,21 +241,7 @@ public final class Bane {
return false; return false;
} }
for(Guild subGuild : baningGuild.getNation().getSubGuildList()) {
if (getBaneByAttackerGuild(subGuild) != null) {
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "Your Nation Already Has a Bane Placed");
return false;
}
}
if(targetCity.getGuild().getNation().getSubGuildList() != null) {
for (Guild subGuild : targetCity.getGuild().getNation().getSubGuildList()) {
if (getBaneByAttackerGuild(subGuild) != null) {
PlaceAssetMsg.sendPlaceAssetError(player.getClientConnection(), 1, "This Nation Already Has a Bane Placed On It");
return false;
}
}
}
stone.addEffectBit((1 << 19)); stone.addEffectBit((1 << 19));
stone.setMaxHitPoints(stone.getBlueprint().getMaxHealth(stone.getRank())); stone.setMaxHitPoints(stone.getBlueprint().getMaxHealth(stone.getRank()));
stone.setCurrentHitPoints(stone.getMaxHitPoints()); stone.setCurrentHitPoints(stone.getMaxHitPoints());

Loading…
Cancel
Save