public menuForm() { InitializeComponent(); this.newAirplaneForm = new newAirplaneForm(); this.editAirplaneForm = new editAirplaneForm(); this.controllerAirplaneForm = new controllerAirplaneForm(); this.statsForm = new statsForm(); }
private void button_airplaneController_Click(object sender, EventArgs e) { if (this.game.getMap().getAirplanes().Count == 0) { MessageBox.Show("No airplanes on the map."); } else { this.controllerAirplaneForm.Dispose(); this.controllerAirplaneForm = new controllerAirplaneForm(this.game); this.controllerAirplaneForm.Show(); } }