private void automaton_Click(object sender, System.EventArgs e) { this.btnCurrentAuto.Enabled = false; this.StartStop.Enabled = false; this.StartStop.Text = "Start"; this.automaton.Enabled = false; this.btnSave.Enabled = false; this.btnLoad.Enabled = false; modeling.RequestPause(); panel1.Paint += new PaintEventHandler(panel1_PaintCenter); panel1.Invalidate(); //this.btnClear_Click(sender,e); foreach (Cell cell in cells) { modeling.RequestUpdate( new Position(cell.X / cellSize, cell.Y / cellSize), false); } modeling.RequestActivateNeighbors( new Position( cells[cellsWide / 2, cellsHigh / 2].X / cellSize, cells[cellsWide / 2, cellsHigh / 2].Y / cellSize ) ); this.btnDone.Enabled = true; }