private void testDirectionChange (float biasTan, Vector3 low, Vector3 middle, Vector3 high) { float smallTan = Mathf.Tan (22.5f); float largeTan = Mathf.Tan (67.5f); if (biasTan < smallTan) setNPCDirection (low); else if (biasTan < largeTan) setNPCDirection (middle); else setNPCDirection (high); }