Пример #1
0
        private void LoadWordGuess()
        {
            GuessLbl.Text = "";
            bool complete = true;

            foreach (char letter in Word)
            {
                if (Guesses.Contains(letter))
                {
                    GuessLbl.Text += letter;
                }
                else
                {
                    GuessLbl.Text += '_';
                    complete       = false;
                }
                GuessLbl.Text += ' ';
            }
            if (complete)
            {
                SeqNo++;
                TotalScore += SeqNo <= 4 ? 5 : SeqNo <= 8 ? 10 : 20;
                Score.Text  = "Score: " + TotalScore;
                if (TotalScore > Hiscore)
                {
                    Hiscore        = TotalScore;
                    HighScore.Text = "High Score : " + Hiscore;
                }
                TextToSpeech();
                TimeKeeper.Stop();
                RemoveControls(ControlList);
                ShowElements(new Control[] { Listen, Continue });
                Continue.Focus();
            }
        }
Пример #2
0
 private void OnLoaded(object sender, RoutedEventArgs routedEventArgs)
 {
     Continue.Focus();
 }