public override void ExitState() { GameEventModuel eventModuel = GameStart.GetInstance().EventModuel; eventModuel.UnRegisterEventListener(GameEventID.TRIGGER_GAME_EVENT, OnTriggerEffectStart); eventModuel.UnRegisterEventListener(GameEventID.END_GAME_EVENT, OnTriggerEffectEnd); if (m_ground != null) { GameObject.Destroy(m_ground.gameObject); m_ground = null; } if (m_player != null) { m_player.Destroy(); m_player = null; } if (m_playerController != null) { m_playerController.DestroyController(); m_playerController = null; } if (m_bombBall != null) { m_bombBall.Destory(); m_bombBall = null; } if (m_ai != null) { m_ai.Destroy(); m_ai = null; } if (m_aiController != null) { m_aiController.DestroyController(); m_aiController = null; } if (m_effect != null) { m_effect.Destory(); } GameStart.GetInstance().UIModuel.UnLoadResUI(m_bombUI.gameObject); }