public void ToWanderState() { critter.navMeshAgent.avoidancePriority = Random.Range(50, 100); critter.currentState = critter.wanderState; }