private void InitializeDriver() { if (_driverSet) { return; } _driverSet = true; if (_driverHierarchyFilename == null) { _driverHierarchyFilename = Path.Combine(_rootDirectory, "driver_base_pos.knh"); _driverHierarchyWatcher = SimpleDirectoryWatcher.WatchFile(_driverHierarchyFilename, () => { _driver?.AlignNodes(Knh.FromFile(_driverHierarchyFilename)); }); } var driver = _carData.GetDriverDescription(); if (driver == null) { return; } var contentDirectory = Path.GetDirectoryName(Path.GetDirectoryName(_rootDirectory)); if (contentDirectory == null) { return; } var driversDirectory = Path.Combine(contentDirectory, "driver"); _driverModelFilename = Path.Combine(driversDirectory, driver.Name + ".kn5"); _driverModelWatcher = SimpleDirectoryWatcher.WatchFile(_driverModelFilename, ReloadDriverModel); LoadDriverModel(); ObjectsChanged?.Invoke(this, EventArgs.Empty); }