private void InitializeSingleton() { // if the singleton hasn't been initialized yet if (instance != null && instance != this) { Destroy(this.gameObject); } instance = this; DontDestroyOnLoad(this.gameObject); }
private void Awake() { updateObj = GameObject.FindObjectOfType <UpdateObjective>(); bigfoot = GameObject.FindObjectOfType <Bigfoot>(); disguiseManager = GameObject.FindObjectOfType <DisguiseManager>(); }