forked from MagicBane/Server
respawnQue and corpse loading
This commit is contained in:
@@ -453,8 +453,9 @@ public enum InterestManager implements Runnable {
|
|||||||
if (!awonpc.isAlive() && (awonpc.isPet() || awonpc.isSiege() || awonpc.isNecroPet() || awonpc.isPlayerGuard()))
|
if (!awonpc.isAlive() && (awonpc.isPet() || awonpc.isSiege() || awonpc.isNecroPet() || awonpc.isPlayerGuard()))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (awonpc.isAlive() == false)
|
//removed, interest manager should still load mob corpses
|
||||||
continue;
|
//if (awonpc.isAlive() == false)
|
||||||
|
// continue;
|
||||||
|
|
||||||
awonpc.playerAgroMap.put(player.getObjectUUID(), false);
|
awonpc.playerAgroMap.put(player.getObjectUUID(), false);
|
||||||
//MobileFSM.setAwake(awonpc, false);
|
//MobileFSM.setAwake(awonpc, false);
|
||||||
|
|||||||
@@ -342,7 +342,7 @@ public class MobileFSM {
|
|||||||
|
|
||||||
public static void DetermineAction(Mob mob) {
|
public static void DetermineAction(Mob mob) {
|
||||||
//always check the respawn que, respawn 1 mob max per second to not flood the client
|
//always check the respawn que, respawn 1 mob max per second to not flood the client
|
||||||
if(respawnQue.size() > 0 && lastRespawn + 1000 > System.currentTimeMillis()){
|
if(respawnQue.size() > 0 && lastRespawn + 100 < System.currentTimeMillis()){
|
||||||
respawnQue.get(0).respawn();
|
respawnQue.get(0).respawn();
|
||||||
respawnQue.remove(0);
|
respawnQue.remove(0);
|
||||||
lastRespawn = System.currentTimeMillis();
|
lastRespawn = System.currentTimeMillis();
|
||||||
|
|||||||
Reference in New Issue
Block a user