Skip to content
Permalink
Browse files

FIx last commit, fixes #36

  • Loading branch information...
mcmonkey4eva committed Jun 27, 2016
1 parent 05fe5f5 commit 3289f746cece8cd2b389fbef5e816cb0f38d9b84
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/main/java/org/mcmonkey/sentinel/SentinelTrait.java
@@ -568,8 +568,8 @@ public void chase(LivingEntity entity) {
}
chasing = entity;
npc.getNavigator().getDefaultParameters().stuckAction(null);
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
npc.getNavigator().setTarget(entity.getLocation());
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
}

public ItemStack getArrow() {
@@ -1058,17 +1058,17 @@ public void runUpdate() {
if (dist > 7 * 7) {
npc.getNavigator().getDefaultParameters().range(100);
npc.getNavigator().getDefaultParameters().stuckAction(TeleportStuckAction.INSTANCE);
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
npc.getNavigator().setTarget(player.getLocation());
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
}
}
}
else if (chaseRange > 0) {
Location near = nearestPathPoint();
if (near != null && near.distanceSquared(getLivingEntity().getLocation()) > chaseRange * chaseRange) {
npc.getNavigator().getDefaultParameters().stuckAction(TeleportStuckAction.INSTANCE);
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
npc.getNavigator().setTarget(near);
npc.getNavigator().getLocalParameters().speedModifier((float)speed);
}
}
}

0 comments on commit 3289f74

Please sign in to comment.
You can’t perform that action at this time.