Belot.Deal.AddNorthSouthHangingPoints C# (CSharp) Метод

AddNorthSouthHangingPoints() приватный Метод

private AddNorthSouthHangingPoints ( int points ) : void
points int
Результат void
        internal void AddNorthSouthHangingPoints( int points )
        {
            _northSouthPoints += points * 10;
        }

Usage Example

Пример #1
0
        /// <summary>
        /// Raises the DealCompleted event
        /// </summary>
        internal void RaiseDealCompleted( )
        {
            _hangingPoints += _currentDeal.HangingPoints;

            if (_hangingPoints != 0 && _currentDeal.HangingPoints == 0)
            {
                // a previous game was hanging and its time to add the points
                if (_currentDeal.RoundedNorthSouthPoints > _currentDeal.RoundedEastWestPoints)
                {
                    _currentDeal.AddNorthSouthHangingPoints(_hangingPoints);
                }
                else
                {
                    _currentDeal.AddEastWesthHangingPoints(_hangingPoints);
                }

                _hangingPoints = 0;
            }

            _totalNorthSouthPoints += _currentDeal.RoundedNorthSouthPoints;
            _totalEastWestPoints   += _currentDeal.RoundedEastWestPoints;

            _southPlayer.CardPlayed -= new Player.CardPlayedHandler(_currentDeal.PlayerPlayedCard);
            _northPlayer.CardPlayed -= new Player.CardPlayedHandler(_currentDeal.PlayerPlayedCard);
            _eastPlayer.CardPlayed  -= new Player.CardPlayedHandler(_currentDeal.PlayerPlayedCard);
            _westPlayer.CardPlayed  -= new Player.CardPlayedHandler(_currentDeal.PlayerPlayedCard);

            DealCompleted( );

            FinalizeDeal();
        }