C# Class TexasHoldem.Logic.Helpers.Helpers

Class containing helper methods for evaluating and comparing player's hands.
Mostra file Open project: NikolayIT/TexasHoldemGameEngine

Public Methods

Method Description
CompareCards ( IEnumerable firstPlayerCards, IEnumerable secondPlayerCards ) : int

Compares the cards of two opponents to see which one can make the strongest hand with the community cards. At least 5 cards are needed. Can be used during and after the Flop round.

GetHandRank ( ICollection cards ) : HandRankType

Finds the best possible hand given a player's cards and all revealed comunity cards.

Method Details

CompareCards() public static method

Compares the cards of two opponents to see which one can make the strongest hand with the community cards. At least 5 cards are needed. Can be used during and after the Flop round.
public static CompareCards ( IEnumerable firstPlayerCards, IEnumerable secondPlayerCards ) : int
firstPlayerCards IEnumerable First player cards + all revealed comunity cards
secondPlayerCards IEnumerable Second player cards + all revealed comunity cards
return int

GetHandRank() public static method

Finds the best possible hand given a player's cards and all revealed comunity cards.
public static GetHandRank ( ICollection cards ) : HandRankType
cards ICollection A player's cards + all revealed comunity cards
return HandRankType