//---------------------------// // Finished Singelton set up // // --------------------------// #endregion #region Unity API void Awake() { if (instance) { Debug.Log("Already a GameController - going to die now ....."); DestroyImmediate(gameObject); return; } instance = this; DontDestroyOnLoad(gameObject); // As the GC is a pre-fab ... best make it a "hacky - find" if (FM == null) { FM = FindObjectOfType <FlashProManager>(); } }