Пример #1
0
        private void AddObject_Click(object sender, EventArgs e)
        {
            timer1.Stop();
            ObjectEditor obj_edit = new ObjectEditor(map.Cam.Scale);

            obj_edit.ShowDialog();
            if (obj_edit.editor_status == "Confirm")
            {
                map.CreateNewObject(obj_edit.map.Objects[0], map.Cam.Pos);
            }

            obj_edit.Dispose();
            timer1.Start();
        }
Пример #2
0
 private void editButton_Click(object sender, EventArgs e)
 {
     if (map.ActiveCircle.Activity != "None Active")
     {
         timer1.Stop();
         ObjectEditor obj_edit = new ObjectEditor(map.Cam.Scale, map.Objects[int.Parse(map.ActiveCircle.Activity.Split(' ')[1])]);
         obj_edit.ShowDialog();
         if (obj_edit.editor_status == "Confirm")
         {
             map.Objects[int.Parse(map.ActiveCircle.Activity.Split(' ')[1])] = new Object(map.ActiveCircle.Pos, obj_edit.map.Objects[0], obj_edit.obj_num);
             map.ActiveCircle.InitCircle(map.Objects[int.Parse(map.ActiveCircle.Activity.Split(' ')[1])]);
         }
         obj_edit.Dispose();
         timer1.Start();
     }
 }