forked from MagicBane/Server
update lastChase timestamp for mobs
This commit is contained in:
@@ -901,6 +901,8 @@ public class MobAI {
|
|||||||
else if(System.currentTimeMillis() < mob.getTimestamps().get("lastChase").longValue() + 1000)
|
else if(System.currentTimeMillis() < mob.getTimestamps().get("lastChase").longValue() + 1000)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
mob.getTimestamps().put("lastChase",System.currentTimeMillis());
|
||||||
|
|
||||||
if (CombatUtilities.inRange2D(mob, mob.getCombatTarget(), mob.getRange()) == false) {
|
if (CombatUtilities.inRange2D(mob, mob.getCombatTarget(), mob.getRange()) == false) {
|
||||||
if (mob.getRange() > 15) {
|
if (mob.getRange() > 15) {
|
||||||
mob.destination = mob.getCombatTarget().getLoc();
|
mob.destination = mob.getCombatTarget().getLoc();
|
||||||
|
|||||||
Reference in New Issue
Block a user