protected override bool UnInit() { if (this._prodTorpedoCutIn != null) { this._prodTorpedoCutIn.get_gameObject().Discard(); } this._prodTorpedoCutIn = null; if (this._prodTorpedoSalvoPhase2 != null) { Object.Destroy(this._prodTorpedoSalvoPhase2.transform.get_gameObject()); } this._prodTorpedoSalvoPhase2 = null; if (this._prodTorpedoSalvoPhase3 != null) { Object.Destroy(this._prodTorpedoSalvoPhase3.transform.get_gameObject()); } this._prodTorpedoSalvoPhase3 = null; if (this.prefabProdTorpedoStraight != null) { Object.Destroy(this.prefabProdTorpedoStraight.get_gameObject()); } this.prefabProdTorpedoStraight = null; base.UnInit(); if (this._clsRaigeki != null) { this._clsRaigeki = null; } this.TorpedoParticle = null; return(true); }
protected override bool UnInit() { if (_prodTorpedoCutIn != null) { _prodTorpedoCutIn.gameObject.Discard(); } _prodTorpedoCutIn = null; if (_prodTorpedoSalvoPhase2 != null) { UnityEngine.Object.Destroy(_prodTorpedoSalvoPhase2.transform.gameObject); } _prodTorpedoSalvoPhase2 = null; if (_prodTorpedoSalvoPhase3 != null) { UnityEngine.Object.Destroy(_prodTorpedoSalvoPhase3.transform.gameObject); } _prodTorpedoSalvoPhase3 = null; base.UnInit(); if (_clsRaigeki != null) { _clsRaigeki = null; } TorpedoParticle = null; return(true); }
public void Dispose() { if (this._clsState != null) { this._clsState.Clear(); } Mem.Del <StatementMachine>(ref this._clsState); if (this._prodTorpedoCutIn != null) { this._prodTorpedoCutIn.get_gameObject().Discard(); } this._prodTorpedoCutIn = null; if (this._prodTorpedoSalvoPhase2 != null) { Object.Destroy(this._prodTorpedoSalvoPhase2.transform.get_gameObject()); } this._prodTorpedoSalvoPhase2 = null; if (this._prodTorpedoSalvoPhase3 != null) { Object.Destroy(this._prodTorpedoSalvoPhase3.transform.get_gameObject()); } this._prodTorpedoSalvoPhase3 = null; if (this.prefabProdTorpedoStraight != null) { Object.Destroy(this.prefabProdTorpedoStraight.get_gameObject()); } this.prefabProdTorpedoStraight = null; if (this._clsRaigeki != null) { this._clsRaigeki = null; } this.TorpedoParticle = null; }
private IEnumerator CreateTorpedoCutIn(UniRx.IObserver <bool> observer) { BattleCutInEffectCamera cam = BattleTaskManager.GetBattleCameras().cutInEffectCamera; UITexture centerLine = ((Component)cam.transform.FindChild("TorpedoLine/OverlayLine")).GetComponent <UITexture>(); if (centerLine != null) { centerLine.alpha = 0f; } _prodTorpedoCutIn = ProdTorpedoCutIn.Instantiate(((Component)BattleTaskManager.GetPrefabFile().prefabProdTorpedoCutIn).GetComponent <ProdTorpedoCutIn>(), _clsRaigeki, cam.transform); BattleTaskManager.GetBattleCameras().enemyFieldCamera.cullingMask = BattleTaskManager.GetBattleCameras().GetDefaultLayers(); yield return(new WaitForEndOfFrame()); prefabProdTorpedoStraight = (UnityEngine.Object.Instantiate(BattleTaskManager.GetPrefabFile().prefabTorpedoStraightController, Vector3.zero, Quaternion.identity) as Transform); Transform transP4 = new GameObject().transform; transP4.name = "ProdTorpedoSalvoPhase2"; _prodTorpedoSalvoPhase2 = new ProdTorpedoSalvoPhase2(transP4, ((Component)prefabProdTorpedoStraight).GetComponent <TorpedoStraightController>()); _prodTorpedoSalvoPhase2.Initialize(_clsRaigeki, TorpedoParticle, centerLine); yield return(new WaitForEndOfFrame()); Transform transP3 = new GameObject().transform; transP3.name = "ProdTorpedoSalvoPhase3"; _prodTorpedoSalvoPhase3 = new ProdTorpedoSalvoPhase3(transP3); _prodTorpedoSalvoPhase3.Initialize(_clsRaigeki, TorpedoParticle); yield return(new WaitForEndOfFrame()); _prodTorpedoSalvoPhase3.SetHpGauge(); yield return(new WaitForEndOfFrame()); observer.OnNext(value: true); observer.OnCompleted(); }