if(Vector3.Distance(transform.position,target.transform.position)<proximity)//If agent is to close: play death sound, destroy the player, sets the state to "lost"
if(Vector3.Distance(transform.position,target.transform.position)<5)//If agent is to close: play death sound, destroy the player, sets the state to "lost"