From 2bee290c725d6da76acd6b95c0c59152fb24a48d Mon Sep 17 00:00:00 2001 From: AdAstra-LD <76622070+AdAstra-LD@users.noreply.github.com> Date: Sun, 3 Oct 2021 18:44:09 +0200 Subject: [PATCH] Fixed file filter of Script Editor --- DS_Map/Main Window.cs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/DS_Map/Main Window.cs b/DS_Map/Main Window.cs index 7f7d78d..3b22dd0 100644 --- a/DS_Map/Main Window.cs +++ b/DS_Map/Main Window.cs @@ -6275,11 +6275,13 @@ namespace DSPRE { MessageBox.Show("Level script correctly cleared.", "Success", MessageBoxButtons.OK, MessageBoxIcon.Information); } private void importScriptFileButton_Click(object sender, EventArgs e) { - /* Prompt user to select .scr file */ - OpenFileDialog of = new OpenFileDialog(); - of.Filter = "Script File (*.scr, *.bin)|*.scr, *.bin"; - if (of.ShowDialog(this) != DialogResult.OK) + /* Prompt user to select .scr or .bin file */ + OpenFileDialog of = new OpenFileDialog { + Filter = "Script File (*.scr, *.bin)|*.scr;*.bin" + }; + if (of.ShowDialog(this) != DialogResult.OK) { return; + } /* Update scriptFile object in memory */ string path = RomInfo.gameDirs[DirNames.scripts].unpackedDir + "\\" + selectScriptFileComboBox.SelectedIndex.ToString("D4");