Belot.BelotGame.GetPlayer C# (CSharp) Method

GetPlayer() public method

/// Gets the position of a given player on the table. /// Gets the player of a given position on the table.
public GetPlayer ( PlayerPosition position ) : Player
position PlayerPosition
return Player
        public Player GetPlayer( PlayerPosition position )
        {
            switch ( position )
            {
                case PlayerPosition.South:
                    return _southPlayer;
                case PlayerPosition.East:
                    return _eastPlayer;
                case PlayerPosition.North:
                    return _northPlayer;
                case PlayerPosition.West:
                    return _westPlayer;
                default:
                    return _southPlayer;
            }
        }