mob resync position on death and while moving

This commit is contained in:
2023-07-21 20:01:39 -05:00
parent 413e782af1
commit a34386ae51
2 changed files with 8 additions and 9 deletions
+4 -4
View File
@@ -1375,7 +1375,8 @@ public class Mob extends AbstractIntelligenceAgent {
this.combat = false;
this.walkMode = true;
this.combatTarget = null;
//resync corpses
this.setLoc(this.loc);
this.hasLoot = this.charItemManager.getInventoryCount() > 0;
} catch (Exception e) {
Logger.error(e);
@@ -1384,8 +1385,7 @@ public class Mob extends AbstractIntelligenceAgent {
public void respawn() {
//Commenting out Mob ID rotation.
this.despawned = false;
//this.playerAgroMap.clear();
this.playerAgroMap.clear();
this.setCombatTarget(null);
this.setHealth(this.healthMax);
this.stamina.set(this.staminaMax);
@@ -1410,7 +1410,7 @@ public class Mob extends AbstractIntelligenceAgent {
//MovementManager.translocate(this, this.bindLoc, this.region);
if (!this.isSiege && !this.isPlayerGuard && contract == null)
loadInventory();
this.despawned = false;
}
public void despawn() {