private bool InAttackRangeOfPlayer()
{
float DistanceToPlayer = Vector3.Distance(player.transform.position, transform.position);
return DistanceToPlayer < chaseDistance;
}
How come it’s DistanceToPlayer < chaseDistance
? Can’t we just return DistanceToPlayer
? It doesn’t calculate value for if it’s lower?