Beispiel #1
0
 private void LoopGame()
 {
     while (_thread_is_running)
     {
         _game.Step();
         DrawDeskPanel.Refresh();
         Thread.Sleep(200);
     }
 }
Beispiel #2
0
        private void Slider_Scroll(object sender, System.EventArgs e)
        {
            ShutDownThread();
            Slider slider = sender as Slider;

            slider.Counter.Text = (sender as Slider).Value.ToString();
            _game.ControlPopulation(slider.Value, slider.TypeId);
            _game.Reset();
            UpdatePopulationSliders();
            DrawDeskPanel.Refresh();
        }
Beispiel #3
0
 private void ResetButton_Click(object sender, EventArgs e)
 {
     ShutDownThread();
     _game.Reset();
     DrawDeskPanel.Refresh();
 }