private void btnAdd_Click(object sender, EventArgs e) { if (inputOpenDialog.ShowDialog() == DialogResult.OK) { // Add the list of selected files foreach (string path in inputOpenDialog.FileNames) { if (T3DParser.IsValidMap(path)) { addMap(path); } } } }
private void loadState() { var settings = Properties.Settings.Default; // Source files lvwSourceFiles.Items.Clear(); if (settings.InputFiles != null) { foreach (string path in settings.InputFiles) { if (T3DParser.IsValidMap(path)) { addMap(path); } } } // Intelligence radOrdered.Checked = (settings.Mode == 0); radShuffled.Checked = (settings.Mode == 1); radSmartSubtract.Checked = (settings.Mode == 2); radSmartAdd.Checked = (settings.Mode == 3); // Probabilities numSolid.Value = settings.SolidProb; numSemiSolid.Value = settings.SemiSolidProb; numNonSolid.Value = settings.NonSolidProb; numSubtract.Value = settings.SubtractProb; numMover.Value = settings.MoverProb; numLight.Value = settings.LightProb; numOther.Value = settings.OtherProb; // Excluded actors chkExInvis.Checked = settings.ExcludeInvisible; chkExPortal.Checked = settings.ExcludePortal; chkExZoneInfo.Checked = settings.ExcludeZone; chkExMore.Checked = settings.ExcludeMore; txtExcludeActors.Lines = settings.ExcludedActors?.Cast <string>().ToArray(); }