EvaluateCard() public static method

Evaluates points for a card in a game
public static EvaluateCard ( AnnouncementTypeEnum gameType, Card card ) : int
gameType AnnouncementTypeEnum curent game
card Card card to be evaluated
return int
Esempio n. 1
0
        private void CalculatePoints(Hand lastHand)
        {
            PlayerPosition pos = lastHand.Winner.Position;

            if (pos == PlayerPosition.East || pos == PlayerPosition.West)
            {
                foreach (Card card in lastHand)
                {
                    _eastWestPoints += CardPointEvaluator.EvaluateCard(this._currentAnnouncement.Type, card);
                }
            }
            else
            {
                foreach (Card card in lastHand)
                {
                    _northSouthPoints += CardPointEvaluator.EvaluateCard(this._currentAnnouncement.Type, card);
                }
            }
        }