void on_save_sm3_activate(object o, EventArgs e) { if (Terrain.GetInstance().Sm3Filename == "") { on_save_sm3_as1_activate(o, e); return; } Sm3Persistence.GetInstance().SaveSm3(Terrain.GetInstance().Sm3Filename); }
/* * void on_open_heightmap1_activate(object o, EventArgs e) * { * string filepath = GetFilePath("Heightmap open path", "heightmap.bmp"); * if (filepath != "") * { * commandqueue.Enqueue(new CmdOpenHeightMap(filepath)); * } * } */ void on_open_sm3_activate(object o, EventArgs e) { string filepath = GetFilePath("Open SM3", "*.sm3"); if (filepath != "") { Sm3Persistence.GetInstance().LoadSm3(filepath); } }
void on_save_sm3_as1_activate(object o, EventArgs e) { string filepath = GetFilePath("Save SM3 as", "*.sm3"); if (filepath != "") { Sm3Persistence.GetInstance().SaveSm3(filepath); } }
/* * void on_new_heightmap1_activate(object o, EventArgs e) * { * MapSizeDialog sizedialog = new MapSizeDialog(new MapSizeDialog.DoneCallback(on_new_heightmap1_activate_2)); * } */ void on_new_sm3_activate(object o, EventArgs e) { Sm3Persistence.GetInstance().NewSm3(); }