private int EvalutePointsOnRemaining( Card targetCard )
{
// 1.1
const int POINTS_TO_ADD = 20;
int points = POINTS_TO_ADD;
Card maxCard = GetCurrentMaxCardInColor( targetCard.CardColor );
int distance = GetDistance( targetCard, maxCard, _playingManager.CurrentAnnouncement );
int remainingCards = 0;
foreach ( Card card in this.Cards )
{
if ( card.CardColor == targetCard.CardColor && card != targetCard )
{
remainingCards++;
}
}
int passedCards = 0;
foreach ( Card card in _playingManager.PlayedCards )
{
if ( card.CardColor == targetCard.CardColor )
{
passedCards++;
}
}
if ( remainingCards >= distance )
{
points += ( remainingCards - distance ) * POINTS_TO_ADD - distance - passedCards;
}
else
{
points = 0;
}
return points;
}