public void Init() { colourController = ColourController.instance; colourOneSwitchables = new List <SwitchableObject>(); colourTwoSwitchables = new List <SwitchableObject>(); foreach (GameObject switchable in GameObject.FindGameObjectsWithTag("Switchable")) { SwitchableObject s = switchable.GetComponent <SwitchableObject>(); s.Init(); if (s.colour == SwitchableColour.colourOne) { colourOneSwitchables.Add(s); } else { colourTwoSwitchables.Add(s); } } Switch(); }