firstRunGui
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
using namespace std;
|
||||
|
||||
LocalBeRo::LocalBeRo(HandInterface* hi, int id, unsigned dP, int sB, GameState gS)
|
||||
: BeRoInterface(), myHand(hi), myBeRoID(gS), myID(id), dealerPosition(dP), smallBlindPosition(0), dealerPositionId(dP), smallBlindPositionId(0), bigBlindPositionId(0), smallBlind(sB), highestSet(false), minimumRaise(2*sB), firstRun(true), firstRound(true), firstHeadsUpRound(true), currentPlayersTurnId(0), firstRoundLastPlayersTurnId(0), logBoardCardsDone(false)
|
||||
: BeRoInterface(), myHand(hi), myBeRoID(gS), myID(id), dealerPosition(dP), smallBlindPosition(0), dealerPositionId(dP), smallBlindPositionId(0), bigBlindPositionId(0), smallBlind(sB), highestSet(false), minimumRaise(2*sB), firstRun(true), firstRunGui(true), firstRound(true), firstHeadsUpRound(true), currentPlayersTurnId(0), firstRoundLastPlayersTurnId(0), logBoardCardsDone(false)
|
||||
{
|
||||
currentPlayersTurnIt = myHand->getRunningPlayerList()->begin();
|
||||
lastPlayersTurnIt = myHand->getRunningPlayerList()->begin();
|
||||
@@ -92,11 +92,15 @@ void LocalBeRo::nextPlayer() {
|
||||
|
||||
void LocalBeRo::run() {
|
||||
|
||||
if (firstRun) {
|
||||
if (firstRun || firstRunGui) {
|
||||
|
||||
// HACK
|
||||
if(firstRunGui) {
|
||||
firstRunGui = false;
|
||||
myHand->getGuiInterface()->dealBeRoCards(myBeRoID);
|
||||
}
|
||||
|
||||
myHand->getGuiInterface()->dealBeRoCards(myBeRoID);
|
||||
firstRun = false;
|
||||
|
||||
/*
|
||||
|
||||
// determine smallBlindPosition
|
||||
|
||||
@@ -35,7 +35,7 @@ public:
|
||||
void setMinimumRaise ( int theValue ) { minimumRaise = theValue; }
|
||||
int getMinimumRaise() const { return minimumRaise; }
|
||||
|
||||
void resetFirstRun() { firstRun = false; }
|
||||
void skipFirstRunGui() { firstRunGui = false; }
|
||||
|
||||
void nextPlayer();
|
||||
void run();
|
||||
@@ -116,6 +116,7 @@ private:
|
||||
int minimumRaise;
|
||||
|
||||
bool firstRun;
|
||||
bool firstRunGui; // HACK
|
||||
bool firstRound;
|
||||
bool firstHeadsUpRound;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user