Beispiel #1
0
        /// <summary>
        /// Asks the player whether or not they'd like to play again
        /// </summary>
        void PlayAgain()
        {
            MessageBoxResult playAgain = MessageBox.Show("Would you like to play again?", "Hunt the Wumpus", MessageBoxButton.YesNo);

            if (playAgain == MessageBoxResult.Yes)
            {
                frmWumpus frmWumpus = new frmWumpus();
                frmWumpus.Show();
                this.Close();
            }
            else
            {
                this.Close();
            }
        }
Beispiel #2
0
 public Room(frmWumpus frm)
 {
     neighbors = new Room[3];
     frmWumpus = frm;
     Reset();
 }
Beispiel #3
0
        private void btnWumpus_Click(object sender, RoutedEventArgs e)
        {
            frmWumpus frmWumpus = new frmWumpus();

            frmWumpus.Show();
        }