simplified mob aI
This commit is contained in:
@@ -106,8 +106,8 @@ public class StandardMob {
|
|||||||
if(Mob.discDroppers.contains(mob))
|
if(Mob.discDroppers.contains(mob))
|
||||||
return;
|
return;
|
||||||
float baseRespawnTimer = mob.spawnTime;
|
float baseRespawnTimer = mob.spawnTime;
|
||||||
float reduction = ((100-mob.level) * 0.01f);
|
float reduction = (100-mob.level) * 0.01f;
|
||||||
float reducedRespawnTime = baseRespawnTimer * reduction;
|
float reducedRespawnTime = baseRespawnTimer * (1.0f - reduction);
|
||||||
float respawnTimer = reducedRespawnTime * 1000f;
|
float respawnTimer = reducedRespawnTime * 1000f;
|
||||||
if (System.currentTimeMillis() > (mob.deathTime + respawnTimer)) {
|
if (System.currentTimeMillis() > (mob.deathTime + respawnTimer)) {
|
||||||
Zone.respawnQue.add(mob);
|
Zone.respawnQue.add(mob);
|
||||||
@@ -219,9 +219,6 @@ public class StandardMob {
|
|||||||
if(mob.getLastAttackTime() > System.currentTimeMillis())
|
if(mob.getLastAttackTime() > System.currentTimeMillis())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
mob.updateLocation();
|
|
||||||
InterestManager.forceLoad(mob);
|
|
||||||
|
|
||||||
if (mob.BehaviourType.callsForHelp)
|
if (mob.BehaviourType.callsForHelp)
|
||||||
MobCallForHelp(mob);
|
MobCallForHelp(mob);
|
||||||
|
|
||||||
@@ -231,6 +228,10 @@ public class StandardMob {
|
|||||||
if(!CombatUtilities.inRange2D(mob,mob.combatTarget,mob.getRange()))
|
if(!CombatUtilities.inRange2D(mob,mob.combatTarget,mob.getRange()))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
mob.updateLocation();
|
||||||
|
//InterestManager.forceLoad(mob);
|
||||||
|
InterestManager.setObjectDirty(mob);
|
||||||
|
|
||||||
if (mainHand == null && offHand == null) {
|
if (mainHand == null && offHand == null) {
|
||||||
CombatUtilities.combatCycle(mob, mob.combatTarget, true, null);
|
CombatUtilities.combatCycle(mob, mob.combatTarget, true, null);
|
||||||
int delay = 3000;
|
int delay = 3000;
|
||||||
|
|||||||
Reference in New Issue
Block a user