Workorders cleared with hireling removal.
This commit is contained in:
@@ -154,9 +154,11 @@ public abstract class AbstractIntelligenceAgent extends AbstractCharacter {
|
||||
|
||||
WorldGrid.RemoveWorldObject(this);
|
||||
|
||||
if (this.getObjectType() == GameObjectType.Mob)
|
||||
if (((Mob) this).getParentZone() != null)
|
||||
if (this.getObjectType() == GameObjectType.Mob) {
|
||||
if (((Mob) this).getParentZone() != null) {
|
||||
((Mob) this).getParentZone().zoneMobSet.remove(this);
|
||||
}
|
||||
}
|
||||
|
||||
} else { //revert charmed pet
|
||||
this.agentType = mbEnums.AIAgentType.MOBILE;
|
||||
|
||||
@@ -651,8 +651,9 @@ public class NPC extends AbstractCharacter {
|
||||
Logger.error(e.getMessage());
|
||||
}
|
||||
|
||||
if (minionMob.getParentZone() != null)
|
||||
minionMob.getParentZone().zoneMobSet.remove(minionMob);
|
||||
if (minionMob.parentZone != null) {
|
||||
minionMob.parentZone.zoneMobSet.remove(minionMob);
|
||||
}
|
||||
|
||||
WorldGrid.RemoveWorldObject(minionMob);
|
||||
DbManager.removeFromCache(minionMob);
|
||||
|
||||
@@ -4172,9 +4172,9 @@ public class PlayerCharacter extends AbstractCharacter {
|
||||
|
||||
currentPet.setCombatTarget(null);
|
||||
|
||||
if (currentPet.getParentZone() != null)
|
||||
|
||||
currentPet.getParentZone().zoneMobSet.remove(currentPet);
|
||||
if (currentPet.parentZone != null) {
|
||||
currentPet.parentZone.zoneMobSet.remove(currentPet);
|
||||
}
|
||||
|
||||
try {
|
||||
currentPet.clearEffects();
|
||||
|
||||
Reference in New Issue
Block a user