/// <summary> /// Called by the clien when a player wins/loses. /// </summary> /// <param name="player">The player which won/lost</param> /// <param name="isWinner">True - the player won. False - The player lost. /// </param> public void NotifyPlayerStatus(PokerEngine.Player player, bool isWinner) { }
/// <summary> /// Called by the client to get the current player betting action. Derived classes must implement it and respond with a /// proper action /// </summary> /// <param name="player">The player which needs to bet</param> /// <param name="action">The action to use to pass the player response</param> public void WaitPlayerBettingAction(PokerEngine.Player player, PokerEngine.Engine.PlayerBettingAction action) { }
/// <summary> /// Called by the client when a player performs an action. /// </summary> /// <param name="player">The player which performed the action</param> /// <param name="betAction">The action performed</param> /// <param name="callAmount">The call amount if any, can be 0</param> /// <param name="raiseAmount">The raise amount if any, can be 0</param> public void NotifyPlayerAction(PokerEngine.Player player, PokerEngine.Engine.BetAction betAction, int callAmount, int raiseAmount) { }
/// <summary> /// Called when a player is thinking of a move /// </summary> /// <param name="thinkingPlayer">The player which is thinking</param> public void NotifyPlayerIsThinking(PokerEngine.Player thinkingPlayer) { }
/// <summary> /// Called by the client to get the current player betting action. Derived classes must implement it and respond with a /// proper action /// </summary> /// <param name="player">The player which needs to bet</param> /// <param name="action">The action to use to pass the player response</param> public override void WaitPlayerBettingAction(PokerEngine.Player player, PokerEngine.Engine.PlayerBettingAction action) { currentStrategy.Bet(player, action); }
/// <summary> /// Called when the game round starts and the blind raise is made /// </summary> /// <param name="raiser">The blind raiser</param> /// <param name="raiseAmount">The raise amount, can be 0</param> public void NotifyBlindRaise(PokerEngine.Player raiser, int raiseAmount) { concreteHelper.NotifyBlindRaise(raiser, raiseAmount); }
/// <summary> /// A method which is used to get the player drawing action. Derived classes must override this method to perform the action. /// </summary> /// <param name="player">The player which may draw new cards</param> /// <param name="action">The drawing action which must be updated with the player drawing selection</param> public void WaitPlayerDrawingAction(PokerEngine.Player player, PlayerDrawingAction action) { concreteHelper.WaitPlayerDrawingAction(player, action); }
/// <summary> /// Called by the client when a round starts. /// </summary> /// <param name="dealer">The current round dealer</param> /// <param name="potAmount">The starting amount of money in the pot</param> public void NotifyDealerAndPotAmount(PokerEngine.Player dealer, int potAmount) { }
/// <summary> /// Get a safe copy of the player. /// </summary> /// <param name="player">A non null value of a player</param> /// <returns> /// A copy of the player which is safe to send to other players. /// </returns> /// <remarks> /// Since the point of poker is hiding your hand from the other players, this method creates a copy which can be sent /// to other players. (It may remove/set as empty, some or all of the player cards) /// </remarks> public PokerEngine.Player GetSafePlayer(PokerEngine.Player player) { return(concreteHelper.GetSafePlayer(player)); }
/// <summary> /// Called after each player performs an action /// </summary> /// <param name="player">The player which performed the action </param> /// <param name="betAction">The action performed</param> /// <param name="callAmount">The amount which the player had to call</param> /// <param name="raiseAmount">The amount which the player raised (if any)</param> public void NotifyPlayerAction(PokerEngine.Player player, BetAction betAction, int callAmount, int raiseAmount) { concreteHelper.NotifyPlayerAction(player, betAction, callAmount, raiseAmount); }
/// <summary> /// Called by the engine when the game is over and there is a single player standing. /// Override this method to add logic for game over. /// </summary> /// <param name="winner"> /// The winnig player /// </param> /// <remarks> /// On each round end, either this method or <see cref="WaitForAnotherRound"/> will be called. /// </remarks> public void WaitGameOver(PokerEngine.Player winner) { concreteHelper.WaitGameOver(winner); }
/// <summary> /// Called when a player wins a round. There can be more than one winner per round. /// </summary> /// <param name="player">The winning player</param> /// <param name="result">The winning player hand</param> public void OnDeclareWinner(PokerEngine.Player player, PokerRules.Games.GameResult result) { concreteHelper.OnDeclareWinner(player, result); }
/// <summary> /// Called when a player loses the game. The player has lost all of the money and can't continue in the game. /// </summary> /// <param name="player">The losing player</param> public void OnDeclareLoser(PokerEngine.Player player) { concreteHelper.OnDeclareLoser(player); }
/// <summary> /// Called by the client when the blind open is made. /// </summary> /// <param name="opened">The player which blind opens</param> /// <param name="openAmount">The player open amount, may be 0</param> public void NotifyBlindOpen(PokerEngine.Player opened, int openAmount) { }
/// <summary> /// Called by the engine to notify the player with the new cards /// </summary> /// <param name="curPlayer">The player with the new drawn cards</param> public void NotifyPlayerNewCards(PokerEngine.Player curPlayer) { concreteHelper.NotifyPlayerNewCards(curPlayer); }
/// <summary> /// Called by the client when the blind raise is made. /// </summary> /// <param name="raiser">The player which blind raises</param> /// <param name="raiseAmount">The raise amound, may be 0</param> public void NotifyBlindRaise(PokerEngine.Player raiser, int raiseAmount) { }
/// <summary> /// Called when the game round starts. /// </summary> /// <param name="potAmount">The initial pot amount</param> /// <param name="dealer">The current round dealer</param> public void NotifyAntesAndDealer(int potAmount, PokerEngine.Player dealer) { concreteHelper.NotifyAntesAndDealer(potAmount, dealer); }
/// <summary> /// Called by the client when each round ends. /// </summary> /// <param name="gameOver">A flag which indicates the game is over.</param> /// <param name="winner">The winning player (if any), may be null</param> public override void WaitOnRoundEnd(bool gameOver, PokerEngine.Player winner) { }
/// <summary> /// Called by the client when a new player is connected. /// </summary> /// <param name="player">The new player which was connected</param> public void NotifyNewUserConnected(PokerEngine.Player player) { }
/// <summary> /// Called by the client when a round starts. /// </summary> /// <param name="dealer">The current round dealer</param> /// <param name="potAmount">The starting amount of money in the pot</param> public override void NotifyDealerAndPotAmount(PokerEngine.Player dealer, int potAmount) { chooseStrategy(); base.NotifyDealerAndPotAmount(dealer, potAmount); }
/// <summary> /// Called when the game round starts and the blind open is made /// </summary> /// <param name="opener">The blind opener</param> /// <param name="openAmount">The open amount, can be 0</param> public void NotifyBlindOpen(PokerEngine.Player opener, int openAmount) { concreteHelper.NotifyBlindOpen(opener, openAmount); }