コード例 #1
0
        void FinishGame(int winnerPlayerNum)
        {
            Player2Timer.Stop();
            Player1Timer.Stop();

            MessageBox.Show("Winner: " + winnerPlayerNum.ToString() + ".Player", "End Game Window", MessageBoxButtons.OK, MessageBoxIcon.Information);

            this.Close();
        }
コード例 #2
0
        private void TimeRecorder()
        {
            if (Player1Timer.Enabled)
            {
                Player1Timer.Stop();
                Player2Timer.Start();
            }

            else
            {
                Player1Timer.Start();
                Player2Timer.Stop();
            }
        }