protected virtual void Start() { this.root = CRootTask.GetInstance(); this.m_UIManager = CUIManager.GetInstance(); this.m_SongData = CTaskUtil.REFERENCES [CTaskUtil.SELECTED_SONG] as CSongData; this.m_AudioName = m_SongData.songName; var currentTask = this.root.GetCurrentTask(); if (string.IsNullOrEmpty(this.m_AudioName) == false) { StartCoroutine(LoadAssetsAsyn(this.m_AudioName, () => { this.StartGame(); }, () => { this.EndGame(); throw new Exception("ERROR: Can not load assets."); })); } }
public void SelectSong(CSongData song) { CTaskUtil.REFERENCES [CTaskUtil.SELECTED_SONG] = song; this.m_RootTask.GetCurrentTask().OnTaskCompleted(); }