/* Constants */ void Awake() { if (Instance != null && Instance != this) { Destroy(gameObject); return; } Instance = this; _mainMenuManager = GameObject.Find("MainMenuManager").GetComponent <MainMenuManagerScript>(); /* Register for social network events*/ ProfileEvents.OnLoginFinished += LogInFinished; DontDestroyOnLoad(gameObject); }
private void Awake() { Instance = this; }
// Use this for initialization void Start() { _mainMenuManager = GameObject.FindGameObjectWithTag("MainMenuManager").GetComponent <MainMenuManagerScript>(); }