//lastly, check mobs inventory for godly or disc runes to send a server announcement
for(Itemit:mob.getInventory()){
mobBootySet=mob.bootySet;
if(mobBootySet!=0){
RunBootySetIfPresent(mobBootySet,mob);
}
ItemBaseib=it.getItemBase();
if(ib==null)
break;
if(ib.getName().toLowerCase().contains("of the gods")){
ChatSystemMsgchatMsg=newChatSystemMsg(null,mob.getName()+" in "+mob.getParentZone().getName()+" has found the "+ib.getName()+". Are you tough enough to take it?");
// Check mob's inventory for godly or disc runes to send a server announcement
for(Itemitem:mob.getInventory()){
ItemBaseitemBase=item.getItemBase();
if(itemBase!=null&&itemBase.getName().toLowerCase().contains("of the gods")){
ChatSystemMsgchatMsg=newChatSystemMsg(
null,
mob.getName()+" in "+mob.getParentZone().getName()+" has found the "+itemBase.getName()+". Are you tough enough to take it?"
ChatSystemMsgchatMsg=newChatSystemMsg(null,mob.getName()+" in "+mob.getParentZone().getName()+" has found the "+specialDrop.getName()+". Are you tough enough to take it?");
chatMsg.setMessageType(10);
@ -189,100 +199,81 @@ public enum LootManager {
@@ -189,100 +199,81 @@ public enum LootManager {
ChatSystemMsgchatMsg=newChatSystemMsg(null,mob.getName()+" in "+mob.getParentZone().getName()+" has found the "+ItemBase.getItemBase(bse.itemBase).getName()+". Are you tough enough to take it?");
@ -148,6 +148,12 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -148,6 +148,12 @@ public class ClientMessagePump implements NetMsgHandler {
@ -340,18 +346,11 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -340,18 +346,11 @@ public class ClientMessagePump implements NetMsgHandler {
ChatManager.chatSystemInfo(player,"You Have Attempted To Dupe. Please Don't");
return;//catch gold dupe for negative numbers
}
if(itemManager==null)
return;
@ -404,17 +403,11 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -404,17 +403,11 @@ public class ClientMessagePump implements NetMsgHandler {
ChatManager.chatSystemInfo(player,"You Have Attempted To Dupe. Please Don't");
return;//catch gold dupe for negative numbers
}
if(itemManager==null)
return;
@ -458,6 +451,7 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -458,6 +451,7 @@ public class ClientMessagePump implements NetMsgHandler {
@ -471,6 +465,8 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -471,6 +465,8 @@ public class ClientMessagePump implements NetMsgHandler {
//call this if the transfer fails server side to kick the item back to inventory from vault
@ -517,7 +513,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -517,7 +513,6 @@ public class ClientMessagePump implements NetMsgHandler {
@ -528,11 +523,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -528,11 +523,6 @@ public class ClientMessagePump implements NetMsgHandler {
if(player==null)
return;
if(msg.getAmount()<1){
ChatManager.chatSystemInfo(player,"You Have Attempted To Dupe. Please Don't");
return;//catch gold dupe for negative numbers
}
Accountaccount=player.getAccount();
if(account==null)
@ -549,11 +539,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -549,11 +539,6 @@ public class ClientMessagePump implements NetMsgHandler {
if(player==null)
return;
if(msg.getAmount()<1){
ChatManager.chatSystemInfo(player,"You Have Attempted To Dupe. Please Don't");
return;//catch gold dupe for negative numbers
}
Accountaccount=player.getAccount();
if(account==null)
@ -603,7 +588,7 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -603,7 +588,7 @@ public class ClientMessagePump implements NetMsgHandler {
@ -945,7 +930,7 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -945,7 +930,7 @@ public class ClientMessagePump implements NetMsgHandler {
//TODO send group loot message if player is grouped and visible
@ -969,9 +954,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -969,9 +954,6 @@ public class ClientMessagePump implements NetMsgHandler {
// this is done to prevent the temporary goldItem item
// (from the mob) from appearing in player's inventory.
@ -1005,7 +987,7 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1005,7 +987,7 @@ public class ClientMessagePump implements NetMsgHandler {
//TODO send group loot message if player is grouped and visible
@ -1016,7 +998,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1016,7 +998,6 @@ public class ClientMessagePump implements NetMsgHandler {
Stringtext=player.getFirstName()+" has looted "+name+'.';
ChatManager.chatGroupInfoCanSee(player,text);
}
}catch(Exceptione){
Logger.info(e.getMessage());
}finally{
@ -1024,6 +1005,7 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1024,6 +1005,7 @@ public class ClientMessagePump implements NetMsgHandler {
}
}
}
// called when player types /show
@ -1488,11 +1470,39 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1488,11 +1470,39 @@ public class ClientMessagePump implements NetMsgHandler {
ChatManager.chatSystemError(sourcePlayer,"Failed To Buy Item");
@ -1632,8 +1642,9 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1632,8 +1642,9 @@ public class ClientMessagePump implements NetMsgHandler {
@ -1898,9 +1909,6 @@ public class ClientMessagePump implements NetMsgHandler {
@@ -1898,9 +1909,6 @@ public class ClientMessagePump implements NetMsgHandler {
@ -62,7 +62,7 @@ public class DestroyBuildingHandler extends AbstractClientMsgHandler {
@@ -62,7 +62,7 @@ public class DestroyBuildingHandler extends AbstractClientMsgHandler {
@ -71,9 +71,12 @@ public class DestroyBuildingHandler extends AbstractClientMsgHandler {
@@ -71,9 +71,12 @@ public class DestroyBuildingHandler extends AbstractClientMsgHandler {
@ -62,7 +63,6 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -62,7 +63,6 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
Buildingbuilding;
msg=(ManageCityAssetsMsg)baseMsg;
player=SessionManager.getPlayerCharacter(origin);
if(player==null)
@ -72,34 +72,21 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -72,34 +72,21 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@ -111,20 +98,18 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -111,20 +98,18 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@ -132,95 +117,58 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -132,95 +117,58 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@ -228,49 +176,36 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -228,49 +176,36 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@ -278,14 +213,11 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@@ -278,14 +213,11 @@ public class ManageCityAssetMsgHandler extends AbstractClientMsgHandler {
@ -160,7 +160,7 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -160,7 +160,7 @@ public class PlayerCharacter extends AbstractCharacter {
@ -178,9 +178,11 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -178,9 +178,11 @@ public class PlayerCharacter extends AbstractCharacter {
@ -1827,20 +1829,18 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -1827,20 +1829,18 @@ public class PlayerCharacter extends AbstractCharacter {
@ -2916,14 +2916,21 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -2916,14 +2916,21 @@ public class PlayerCharacter extends AbstractCharacter {
@ -4633,10 +4640,10 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -4633,10 +4640,10 @@ public class PlayerCharacter extends AbstractCharacter {
@ -4852,7 +4859,7 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -4852,7 +4859,7 @@ public class PlayerCharacter extends AbstractCharacter {
@ -4865,25 +4872,19 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -4865,25 +4872,19 @@ public class PlayerCharacter extends AbstractCharacter {
@ -4894,11 +4895,23 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -4894,11 +4895,23 @@ public class PlayerCharacter extends AbstractCharacter {
@ -4910,17 +4923,15 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -4910,17 +4923,15 @@ public class PlayerCharacter extends AbstractCharacter {
if(pc.equals(player))
continue;
if(pc.isBoxed==false){
player.isBoxed=true;
InterestManager.setObjectDirty(player);
return;
player.title=CharacterTitle.BOX;
returntrue;
}
}
player.isBoxed=false;
InterestManager.setObjectDirty(player);
player.title=CharacterTitle.NONE;
returnfalse;
}catch(Exceptione){
player.isBoxed=false;
InterestManager.setObjectDirty(player);
returnfalse;
}
}
@ -5554,6 +5565,14 @@ public class PlayerCharacter extends AbstractCharacter {
@@ -5554,6 +5565,14 @@ public class PlayerCharacter extends AbstractCharacter {
// ChatManager.chatGuildError(player, "Failed to deposit " + ib.getName() +".");
// Logger.debug("OpenWindow", player.getName() + " Failed to deposit Item with ID " + resource.getObjectUUID() + " from Warehouse With ID = " + warehouseBuilding.getObjectUUID());
//check if a valid claimer exists to close the window and claim the mine since the tower was destroyed
if(mine.lastClaimer!=null){
mineWindowClose(mine);
ChatManager.chatSystemChannel("The fight for "+mine.getParentZone().getName()+" "+mine.getMineType()+" MINE has concluded. "+mine.lastClaimer.getName()+" has seized it in the name of "+mine.lastClaimer.getGuild().getNation());
}else{
ChatManager.chatSystemChannel("The "+mine.getParentZone().getName()+" "+mine.getMineType()+" MINE is still unclaimed. The battle continues.");
}
}else{
//tower was not destroyed, mine window closes
mineWindowClose(mine);
ChatManager.chatSystemChannel(tower.getGuild().getNation().getName()+" has successfully defended the "+mine.getParentZone().getName()+" "+mine.getMineType()+" MINE, and retains their claim.");
@ -43,79 +30,49 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();
@@ -43,79 +30,49 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();
@Override
publicvoidrun(){
if(mine!=null)
RunMineMechanic();
if(bane!=null)
RunBaneMechanic();
}
publicvoidRunMineMechanic(){
while(mine.isActive){
HashSet<AbstractWorldObject>currentPlayers;
PlayerCharacterplayer;
// Gather current list of players within the zone bounds
@ -124,28 +81,21 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();
@@ -124,28 +81,21 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();
@ -158,46 +108,32 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();
@@ -158,46 +108,32 @@ public ArrayList<PlayerCharacter> affectedPlayers = new ArrayList<>();