public void Initialise() { _trackEnabler = new VehicleTokenStatus[2]; // TODO:: do this for each car, store in a more convenient 2D array or something _trackEnabler[0] = new VehicleTokenStatus(0, CountSliderOne); _trackEnabler[1] = new VehicleTokenStatus(1, CountSliderTwo); _trackEnabler[0].ColourChange = GameObject.FindWithTag("BarFillOne").GetComponent <Image>(); _trackEnabler[1].ColourChange = GameObject.FindWithTag("BarFillTwo").GetComponent <Image>(); string[] ids = VehicleManager.GetVehicleIds(); if (_vehicleDictionary == null) { _vehicleDictionary = new Dictionary <string, VehicleTokenStatus[]>(); } foreach (string id in ids) { VehicleTokenStatus[] _vehicleStatus = new VehicleTokenStatus[2]; _vehicleStatus[0] = new VehicleTokenStatus(0); _vehicleStatus[1] = new VehicleTokenStatus(1); _vehicleDictionary.Add(id, _vehicleStatus); } }