private void ClearStateMachine()
{
if (this.m_Animator != null)
{
AnimatorController.SetAnimatorController(this.m_Animator, null);
}
if (this.m_Controller != null)
{
this.m_Controller.OnAnimatorControllerDirty = (Action) Delegate.Remove(this.m_Controller.OnAnimatorControllerDirty, new Action(this, (IntPtr) this.ControllerDirty));
}
Object.DestroyImmediate(this.m_Controller);
Object.DestroyImmediate(this.m_State);
this.m_StateMachine = null;
this.m_Controller = null;
this.m_State = null;
}