private static void PopRefCheck() { if (popRef == null) { popRef = FindObjectOfType <PopRef>(); } }
private void OnEnable() { if (popRef == null) { popRef = FindObjectOfType <PopRef>(); } previousFlexibleUIData = allFlexibleUIData.ToList(); }
private void OnEnable() { if (popRef == null) { popRef = FindObjectOfType <PopRef>(); //fails to find during start up } if (popRef != null && !popRef.allThemes.Contains(this)) { popRef.allThemes.Add(this); } }
private void OnEnable() { if (popRef == null) { popRef = FindObjectOfType <PopRef>(); } if (allUIObjects == null) { allUIObjects = popRef.themeSwap.allFlexibleUIData[popRef.themeSwap.activeIndex].allUIObjects; } allUIObjects.Add(this); }
private void OnEnable() { if (popRef == null) { popRef = FindObjectOfType <PopRef>(); } if (flexibleUIData == null) { flexibleUIData = popRef.themeSwap.allFlexibleUIData[popRef.themeSwap.activeIndex]; } OnSkinUI(); }
private void Awake() { //Singleton code if (Instance != null && Instance != this) { Debug.LogError("Trying to instantiate a second singleton", gameObject); } else { Instance = this; } }