private void chooseTilemap_Click(object sender, EventArgs e) { OpenFileDialog openFileDialog1 = new OpenFileDialog(); openFileDialog1.Title = "Select file"; openFileDialog1.CheckFileExists = true; openFileDialog1.CheckPathExists = true; openFileDialog1.Filter = "1PP tilemap binary (*.mpb)|*.mpb"; if (openFileDialog1.ShowDialog() == DialogResult.OK) { activeMpb = new mpbfile(); activeMpb.form1 = form1; activeMpb.filepath = openFileDialog1.FileName; activeMpb.Load(); } }
private void chooseTilemap_Click(object sender, EventArgs e) { OpenFileDialog openFileDialog1 = new OpenFileDialog(); openFileDialog1.Title = "Select file"; openFileDialog1.CheckFileExists = true; openFileDialog1.CheckPathExists = true; openFileDialog1.Filter = "Nitro Tilemap (*.nbfs)|*.nbfs"; if (openFileDialog1.ShowDialog() == DialogResult.OK) { activeNbfs = new mpbfile(); activeNbfs.form1 = form1; //activeNbfs.editorForm = this; activeNbfs.filepath = openFileDialog1.FileName; activeNbfs.filebytes = File.ReadAllBytes(activeNbfs.filepath); activeNbfs.Load(); } }