| | |
| | | for (int i = 0; i < waveData.Count; ++i) |
| | | { |
| | | int tunel = waveData[i].Config.tunel; |
| | | TunelList[tunel - 1].material = Resources.Load<Material>($"{tunelMaterialPath}{tunel}"); |
| | | GameObject obj = Resources.Load<GameObject>($"{faZhenPath}{tunel}"); |
| | | int tunelBgId = waveData[i].Config.tunel_bg; |
| | | |
| | | TunelList[tunel - 1].material = Resources.Load<Material>($"{tunelMaterialPath}{tunelBgId}"); |
| | | GameObject obj = Resources.Load<GameObject>($"{faZhenPath}{tunelBgId}"); |
| | | GameObject faZhen = Instantiate(obj); |
| | | faZhen.transform.SetParent(TunelList[tunel - 1].gameObject.transform); |
| | | faZhen.transform.localPosition = new Vector3(0, 1, 0); |
| | |
| | | TunelList[tunel - 1].gameObject.SetActive(true); |
| | | ParticleSystem ps = faZhen.transform.GetChild(0).GetComponent<ParticleSystem>(); |
| | | ps.Play(); |
| | | Destroy(ps.gameObject, ps.main.duration * 3); |
| | | Destroy(faZhen, ps.main.duration * 3); |
| | | } |
| | | |
| | | RefreshBoss(); |