private int EvalutePointsOnPartnerAnnounce( Card targetCard )
{
// 1.2
int points = 0;
const int POINTS_TO_ADD = 10;
foreach ( KeyValuePair< Announcement, Player> kv in _allAnnounces )
{
Announcement announce = kv.Key;
if ( announce.Type == AnnouncementTypeEnum.Spades ||
announce.Type == AnnouncementTypeEnum.Hearts ||
announce.Type == AnnouncementTypeEnum.Diamonds ||
announce.Type == AnnouncementTypeEnum.Clubs )
{
if ( targetCard.CardColor == GetCardColor( announce.Type ) )
{
Player player = kv.Value;
if ( player == _playingManager.GetPartner( this ) )
{
points += POINTS_TO_ADD;
}
if ( player != this && player != _playingManager.GetPartner( this ) )
{
points -= POINTS_TO_ADD;
}
}
}
}
return points;
}