|
|
@ -678,7 +678,9 @@ public class MobileFSM { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER_WITH_LOOT) { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER_WITH_LOOT) { |
|
|
|
aiAgent.despawn(); |
|
|
|
aiAgent.despawn(); |
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
|
|
|
|
if(aiAgent.deathTime != 0) { |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
|
|
|
|
} |
|
|
|
respawn(aiAgent); |
|
|
|
respawn(aiAgent); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -689,7 +691,9 @@ public class MobileFSM { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER_ONCE_LOOTED) { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER_ONCE_LOOTED) { |
|
|
|
aiAgent.despawn(); |
|
|
|
aiAgent.despawn(); |
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
|
|
|
|
if(aiAgent.deathTime != 0) { |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
|
|
|
|
} |
|
|
|
respawn(aiAgent); |
|
|
|
respawn(aiAgent); |
|
|
|
} |
|
|
|
} |
|
|
|
//Mob never had Loot.
|
|
|
|
//Mob never had Loot.
|
|
|
@ -697,7 +701,9 @@ public class MobileFSM { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER) { |
|
|
|
if (System.currentTimeMillis() > aiAgent.deathTime + MBServerStatics.DESPAWN_TIMER) { |
|
|
|
aiAgent.despawn(); |
|
|
|
aiAgent.despawn(); |
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
//update time of death after mob despawns so respawn time happens after mob despawns.
|
|
|
|
|
|
|
|
if(aiAgent.deathTime != 0) { |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
aiAgent.setDeathTime(System.currentTimeMillis()); |
|
|
|
|
|
|
|
} |
|
|
|
respawn(aiAgent); |
|
|
|
respawn(aiAgent); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|