Update NPCBase.java

This commit is contained in:
Jitse Boonstra 2020-07-21 16:59:45 +02:00
parent 34b4929bed
commit 47210bb1ce
1 changed files with 5 additions and 5 deletions

View File

@ -208,7 +208,7 @@ public abstract class NPCBase implements NPC, NPCPacketHandler {
public boolean inViewOf(Player player) {
Vector dir = location.toVector().subtract(player.getEyeLocation().toVector()).normalize();
return dir.dot(player.getLocation().getDirection()) >= cosFOV;
return dir.dot(player.getEyeLocation().getDirection()) >= cosFOV;
}
@Override