Browse Source

mob respawn issue resolved

lakebane
FatBoy-DOTC 7 days ago
parent
commit
4f08d7286e
  1. 4
      src/engine/mobileAI/MobAI.java
  2. 2
      src/engine/objects/Mob.java

4
src/engine/mobileAI/MobAI.java

@ -884,6 +884,8 @@ public class MobAI { @@ -884,6 +884,8 @@ public class MobAI {
return;
}
}
aiAgent.despawn();
return;
}
if(Mob.discDroppers.contains(aiAgent))
@ -892,7 +894,7 @@ public class MobAI { @@ -892,7 +894,7 @@ public class MobAI {
if(aiAgent.StrongholdGuardian || aiAgent.StrongholdEpic || aiAgent.StrongholdCommander)
return;
if (System.currentTimeMillis() > (aiAgent.deathTime + (aiAgent.spawnTime * 1000L))) {
if (aiAgent.despawned && System.currentTimeMillis() > (aiAgent.deathTime + (aiAgent.spawnTime * 1000L))) {
if (!Zone.respawnQue.contains(aiAgent)) {
Zone.respawnQue.add(aiAgent);
}

2
src/engine/objects/Mob.java

@ -1442,6 +1442,8 @@ public class Mob extends AbstractIntelligenceAgent { @@ -1442,6 +1442,8 @@ public class Mob extends AbstractIntelligenceAgent {
loadInventory();
this.updateLocation();
this.stopPatrolTime = 0;
this.lastPatrolPointIndex = 0;
}
public void despawn() {

Loading…
Cancel
Save