|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.ualberta.cs.poker.free.academy25.GameInfoDynamics
public class GameInfoDynamics
Field Summary | |
---|---|
boolean[] |
active
folding (or losing) makes a player inactive |
double[] |
bankroll
The bankroll: decremented before gameStateChanged, incremented before winEvent |
double[] |
bankrollAtStart
The bankroll at the start of the current hand |
int |
button
The button is the player who gives the small blind and acts first on the pre-flop. |
int |
currentPlayerSeat
NOTE: currentPlayerSeat MUST be changed manually: 1. |
long |
gameID
The gameID is the hand number |
boolean |
gameOver
Game is over right before the gameOverEvent is called |
boolean[] |
hasActed
|
double[] |
inPot
The pot: incremented before gameStateChanged, set to zero for a new game |
int[] |
lastAction
lastAction[i] last fold(0), call(1), or raise(2) made by the player in seat i, or -1 otherwise. |
int |
numToAct
Two at the beginning of the stage, (before first bet or check) Zero at end of stage (after last call), one elsewhere |
int |
numUnacted
The number of players that have not folded, checked, called, bet, or raised this round. |
int |
numWinners
One after one person wins, two after two people win |
int |
roundBets
|
static double |
smallBet
|
int |
stage
|
Constructor Summary | |
---|---|
GameInfoDynamics()
|
Method Summary | |
---|---|
void |
addToPot(int seat,
double amount)
|
void |
changeCurrentSeat()
Flipping the currentPlayerSeat. |
void |
doNewGame(long gameID,
int button)
|
void |
doPostBetOrRaise()
Called in-between the action event and the state change Does not change the current seat |
void |
doPostBigBlind()
Called in-between the action event and the state change Does not change the current seat |
void |
doPostCheckOrCall()
Called in-between the action event and the state change Does not change the current seat |
void |
doPostFold()
Called in-between the action event and the state change Does not change the current seat |
void |
doPostSmallBlind()
Called in-between the action event and the state change The round bets is incremented during the small blind. |
void |
doPreGameOver()
Call this before gameOverEvent() |
void |
doPreStageEvent(int stage)
On a new stage, the non-button player begins on all but the first round. |
void |
doPreTieEvent(int seat)
This function is for winning the whole pot |
void |
doPreWinEvent(int seat)
This function is for winning the whole pot |
double |
getAmountToBet()
|
double |
getAmountToCall()
|
double |
getAmountToCall(int seat)
|
int |
getOtherSeat(int seat)
|
void |
setBoard(java.lang.String cards)
On a new stage, the non-button player begins on all but the first round. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public int button
public long gameID
public int stage
public int currentPlayerSeat
public int roundBets
public boolean gameOver
public boolean[] active
public int[] lastAction
public double[] inPot
public double[] bankroll
public double[] bankrollAtStart
public boolean[] hasActed
public int numUnacted
public int numToAct
public int numWinners
public static final double smallBet
Constructor Detail |
---|
public GameInfoDynamics()
Method Detail |
---|
public void doNewGame(long gameID, int button)
public int getOtherSeat(int seat)
public void addToPot(int seat, double amount)
public double getAmountToCall(int seat)
public double getAmountToCall()
public double getAmountToBet()
public void doPostSmallBlind()
public void doPostBigBlind()
public void doPostCheckOrCall()
public void doPostBetOrRaise()
public void doPostFold()
public void doPreWinEvent(int seat)
public void doPreTieEvent(int seat)
public void doPreGameOver()
public void doPreStageEvent(int stage)
public void setBoard(java.lang.String cards)
public void changeCurrentSeat()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |