|
|
|
@ -973,20 +973,7 @@ public class MobAI {
@@ -973,20 +973,7 @@ public class MobAI {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private static void hamletGuardAggro(Mob mob) { |
|
|
|
|
City city = ZoneManager.getCityAtLocation(mob.bindLoc); |
|
|
|
|
if(city != null && city.isNoobIsle == 1){ |
|
|
|
|
//noob island guards only aggro to mobs
|
|
|
|
|
HashSet<AbstractWorldObject> loadedMobs = WorldGrid.getObjectsInRangePartial(mob.loc, MobAIThread.AI_BASE_AGGRO_RANGE, MBServerStatics.MASK_MOB); |
|
|
|
|
for (AbstractWorldObject awo : loadedMobs) { |
|
|
|
|
Mob targetMob = (Mob) awo; |
|
|
|
|
if (!targetMob.isAlive() || targetMob.despawned) |
|
|
|
|
continue; |
|
|
|
|
if (targetMob.isPet()) |
|
|
|
|
continue; |
|
|
|
|
mob.combatTarget = targetMob; |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
} else { |
|
|
|
|
|
|
|
|
|
HashSet<AbstractWorldObject> loadedPlayers = WorldGrid.getObjectsInRangePartial(mob.loc, MobAIThread.AI_BASE_AGGRO_RANGE, MBServerStatics.MASK_PLAYER); |
|
|
|
|
for (AbstractWorldObject awo : loadedPlayers) { |
|
|
|
|
PlayerCharacter pc = (PlayerCharacter) awo; |
|
|
|
@ -1001,7 +988,6 @@ public class MobAI {
@@ -1001,7 +988,6 @@ public class MobAI {
|
|
|
|
|
mob.combatTarget = pc; |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
private static void defaultLogic(Mob mob) { |
|
|
|
|