Ejemplo n.º 1
0
        public override void PostUpdate(GameTime gameTime)
        {
            int hearts   = deckManager.CardsInPlay["Hearts"].Length - 1;
            int spades   = deckManager.CardsInPlay["Spades"].Length - 1;
            int diamonds = deckManager.CardsInPlay["Diamonds"].Length - 1;
            int clubs    = deckManager.CardsInPlay["Clubs"].Length - 1;

            if (MouseInput.CheckForDoubleClick(pmState, gameTime, clickTimer))
            {
                clickTimer = 0;
            }
            else if (MouseInput.CheckForSingleClick(pmState))
            {
                clickTimer = gameTime.TotalGameTime.TotalMilliseconds;
            }
            if (smiPlayed &&
                playAgainDist > Layout.ButtonRadius &&
                exitDist > Layout.ButtonRadius)
            {
                smiPlayed = false;
            }
            score  = hearts + spades + diamonds + clubs;
            score *= 10;
            if (hearts > 12)
            {
                score += 120;
            }
            if (spades > 12)
            {
                score += 120;
            }
            if (diamonds > 12)
            {
                score += 120;
            }
            if (clubs > 12)
            {
                score += 120;
            }

            pmState = mState;
        }