private void DestroyPartySlotObjects() { if (this.UnitSlots != null) { GameUtility.DestroyGameObjects <GenericSlot>(this.UnitSlots); } GameUtility.DestroyGameObject((Component)this.FriendSlot); this.mSlotData.Clear(); }
protected virtual void OnDestroy() { CameraHook.RemovePreCullEventListener(new CameraHook.PreCullEvent(this.PreCull)); if (!this.AutoDestroyUIObject) { return; } GameUtility.DestroyGameObject((Component)this.UIObject); }
public void SetBackgroundTemplate(GameObject backgroundTemplate) { GameUtility.DestroyGameObject((Component)this.mBackground); this.mBackground = (Transform)null; Transform transform = backgroundTemplate.get_transform(); this.mBackground = (Object.Instantiate((Object)backgroundTemplate, transform.get_position(), transform.get_rotation()) as GameObject).get_transform(); this.mBackground.SetParent(((Component)this).get_transform(), false); GameUtility.SetLayer((Component)this.mBackground, GameUtility.LayerHidden, true); }
private void InitRebirthStar() { using (List <GameObject> .Enumerator enumerator = this.mRebirthStars.GetEnumerator()) { while (enumerator.MoveNext()) { GameUtility.DestroyGameObject(enumerator.Current); } } this.mRebirthStars.Clear(); }
private void OnDestroy() { if (UnityEngine.Object.op_Inequality((UnityEngine.Object) this.mCurrentPreview, (UnityEngine.Object)null)) { GameUtility.DestroyGameObject((Component)this.mCurrentPreview); this.mCurrentPreview = (UnitPreview)null; } GameUtility.DestroyGameObjects <UnitPreview>(this.mPreviewControllers); if (UnityEngine.Object.op_Inequality((UnityEngine.Object) this.mLeaderSkillDetail, (UnityEngine.Object)null)) { UnityEngine.Object.Destroy((UnityEngine.Object) this.mLeaderSkillDetail.get_gameObject()); } GameUtility.DestroyGameObjects(this.mAbilits); }
public static void DestroyChildGameObjects <T>(GameObject go_parent, List <GameObject> go_ignore_lists = null) { if (!UnityEngine.Object.op_Implicit((UnityEngine.Object)go_parent)) { return; } for (int index = go_parent.get_transform().get_childCount() - 1; index >= 0; --index) { Transform child = go_parent.get_transform().GetChild(index); if (UnityEngine.Object.op_Implicit((UnityEngine.Object)child) && (object)((Component)child).GetComponent <T>() != null && (go_ignore_lists == null || !go_ignore_lists.Contains(((Component)child).get_gameObject()))) { GameUtility.DestroyGameObject(((Component)child).get_gameObject()); } } }
private void OnDestroy() { GameUtility.DestroyGameObject((Component)this.mCurrentPreview); this.mCurrentPreview = (UnitPreview)null; if (UnityEngine.Object.op_Inequality((UnityEngine.Object) this.mPreviewUnitRT, (UnityEngine.Object)null)) { RenderTexture.ReleaseTemporary(this.mPreviewUnitRT); this.mPreviewUnitRT = (RenderTexture)null; } if (!UnityEngine.Object.op_Inequality((UnityEngine.Object) this.mMessageWindow, (UnityEngine.Object)null)) { return; } UnityEngine.Object.Destroy((UnityEngine.Object)((Component)this.mMessageWindow).get_gameObject()); this.mMessageWindow = (LoginBonusWindow)null; }
private void LateUpdate() { Animator component = (Animator)((Component)this).GetComponent <Animator>(); if (!Object.op_Inequality((Object)component, (Object)null)) { return; } if (this.IsTapSplash) { if (!GameUtility.CompareAnimatorStateName((Component)component, "close")) { return; } AnimatorStateInfo animatorStateInfo = component.GetCurrentAnimatorStateInfo(0); // ISSUE: explicit reference operation if ((double)((AnimatorStateInfo)@animatorStateInfo).get_normalizedTime() < 1.0) { return; } UIUtility.PopCanvas(true); GameUtility.DestroyGameObject((Component)((Component)this).GetComponentInParent <Canvas>()); } else { if (!GameUtility.CompareAnimatorStateName((Component)component, "open")) { return; } AnimatorStateInfo animatorStateInfo = component.GetCurrentAnimatorStateInfo(0); // ISSUE: explicit reference operation if ((double)((AnimatorStateInfo)@animatorStateInfo).get_normalizedTime() < 1.0) { return; } GameUtility.SetGameObjectActive(((Component)this).get_gameObject(), false); GameUtility.DestroyGameObject(((Component)this).get_gameObject()); } }
private void OnDestroy() { GameUtility.DestroyGameObject(this.mMasterAbilityPopup); this.mMasterAbilityPopup = (GameObject)null; }
private void OnDestroy() { GameUtility.DestroyGameObject((Component)this.mDropItem); GameUtility.DestroyGameObject((Component)this.mDropGold); }