IEnumerator OthersPlayerGameOver() { Transform[] list = Logic.NetTopPlate.parent.GetComponentsInChildren <Transform>(); GameObject basePlate = null; List <Transform> childs = new List <Transform>(list); for (int i = 0; i < childs.Count; i++) { //除噪 if (childs[i].name == "Cuffcut" || childs[i].name == "NetBasePlate") { if (childs[i].name == "NetBasePlate") { basePlate = childs[i].gameObject; } childs.Remove(childs[i]); } } //创建特效 yield return(StartCoroutine(_effectManager.WaitForTheBoom(childs, Logic.BoomEffect, () => { Logic.NetTopPlate = basePlate.transform; Logic.NetMoveDir = MoveDir.FrontBack; if (Logic.NetTopPlate == null) { Debug.LogError("NetGameLogic/GameOver Error : the top plate is null"); return; } }))); }
protected IEnumerator GameOver() { //Reset Camera _camera.ResetCamera(); Transform[] list = TopPlate.parent.GetComponentsInChildren <Transform>(); List <Transform> childs = new List <Transform>(list); for (int i = 0; i < childs.Count; i++) { //除噪 if (childs[i].name == "Cuffcut") { childs.Remove(childs[i]); } } Debug.Log(childs.Count); //Create Boom SE StartCoroutine(_effectManager.WaitForTheBoom(childs, BoomEffect, () => { SceneMgr.Instance.CustomLoadScene("01_Main"); })); yield return(null); }