예제 #1
0
 private void delAdvBox_Click(object sender, EventArgs e)
 {
     Main.currentFile.adventures.Remove(Main.currentFile.adventures[advList.SelectedIndex]);
     tilesetUpDown.Value = 0;
     tilesetUpDown.Enabled = false;
     List<string> adventures = new List<string>();
     string label;
     for (int i = 0; i < Main.currentFile.adventures.Count; i++)
     {
         if (Main.currentFile.adventures[i].name != "")
             label = Main.currentFile.adventures[i].name;
         else
             label = string.Concat("Adventure #", i);
         adventures.Add(label);
     }
     advList.DataSource = adventures;
     currentAdventure = null;
     roomX = -1; roomY = -1;
     ClearMap();
 }
예제 #2
0
 private void advList_SelectedIndexChanged(object sender, EventArgs e)
 {
     currentAdventure = Main.currentFile.adventures[advList.SelectedIndex];
     tilesetUpDown.Value = currentAdventure.tileset;
     tilesetUpDown.Enabled = true;
     advMusicList.SelectedIndex = currentAdventure.music + 1;
     roomX = -1; roomY = -1;
     ClearMap();
     DrawRoomGrid();
     DisassembleTileset();
 }