public void CloseItemList() { foreach (Button btn in ExistingButtons) { GameObjectUtility.CustomDestroy(btn.gameObject); //Debug.Log("Clearing Existing buttons"); } //Debug.Log("-------------------item list closed-------------------"); itemListPanel.SetActive(false); }
private void ClearRuneChoices(List <GameObject> gameObjects) { if (gameObjects != null) { foreach (GameObject go in gameObjects) { GameObjectUtility.CustomDestroy(go); } } }
public void Clear() { if (runeStones != null) { foreach (GameObject rs in runeStones) { rs.GetComponent <IndividualRune>().Clear(); GameObjectUtility.CustomDestroy(rs); } } }
private void UpdateDisplay() { foreach (GameObject text in displayedTexts) { GameObjectUtility.CustomDestroy(text); } displayedTexts = new List <GameObject>(); foreach (SpellListItem item in spellList) { GameObject displayText = GameObjectUtility.CustomInstantiate(displayTextPrefab, spellListDisplay.transform); displayText.GetComponent <Text>().text = item.strSpell; displayedTexts.Add(displayText); } }
public void RemoveSpell(SpellListItem spell) { GameObject spellToBeRemoved; if (newSpellBtns.TryGetValue(spell.strSpell, out spellToBeRemoved)) { newSpellBtns.Remove(spell.strSpell); GameObjectUtility.CustomDestroy(spellToBeRemoved); BackSpace(spell); } else { Debug.Log("No spell removed"); } }
private void Close() { foreach (AdvancedSettingEditor editor in editors) { if (!isConfirmed) { Debug.Log("Reverting Modification"); editor.RESET(); } GameObjectUtility.CustomDestroy(editor.gameObject); } editors.Clear(); Debug.Log("Closing Advanced Setting Tab"); gameObject.SetActive(false); }
private void DestroySecondaryPathSelections() { if (secPathSelections == null) { return; } foreach (GameObject gO in secPathSelections) { if (gO == null) { Debug.Log("null gameObject"); } GameObjectUtility.CustomDestroy(gO); } }