void Awake() { if (apiaryOrg == null) { apiaryOrg = this; } else if (apiaryOrg != this) { Destroy(gameObject); } }
void Start() { journal = this.gameObject; j = this; tabs = journal.GetComponentsInChildren <Toggle>(); apiary = GameObject.Find("Canvas").GetComponentInChildren <ScenarioManager>().apiary.GetComponentInChildren <ApiaryOrganiser>(); foreach (Toggle tab in tabs) { ChangeActiveState(tab); } foreach (GameObject obj in rumours) { obj.SetActive(false); } journal.SetActive(false); rumoursHad = new List <string>(); }