From 45774f4b75114de122f739cb00a96b48b2e3b170 Mon Sep 17 00:00:00 2001 From: doitux Date: Sat, 29 Sep 2007 16:08:48 +0000 Subject: [PATCH] adds activePlayerList and runningPlayerList (XXIV) - bugfixes --- src/engine/local_engine/localberopreflop.cpp | 3 ++- src/engine/local_engine/localplayer.cpp | 24 ++++++++++---------- src/game.cpp | 2 +- src/game_defs.h | 4 ++-- src/gui/qt/mainwindow/mainwindowimpl.cpp | 2 +- 5 files changed, 18 insertions(+), 17 deletions(-) diff --git a/src/engine/local_engine/localberopreflop.cpp b/src/engine/local_engine/localberopreflop.cpp index b823f847..50cc5465 100644 --- a/src/engine/local_engine/localberopreflop.cpp +++ b/src/engine/local_engine/localberopreflop.cpp @@ -131,8 +131,9 @@ void LocalBeRoPreflop::run() { } + } else { + setFirstRoundLastPlayersTurnId( getBigBlindPositionId() ); } - setFirstRoundLastPlayersTurnId( getBigBlindPositionId() ); } setCurrentPlayersTurnId( getFirstRoundLastPlayersTurnId() ); diff --git a/src/engine/local_engine/localplayer.cpp b/src/engine/local_engine/localplayer.cpp index 0ae4e61d..b554ceca 100755 --- a/src/engine/local_engine/localplayer.cpp +++ b/src/engine/local_engine/localplayer.cpp @@ -863,19 +863,19 @@ LocalPlayer::LocalPlayer(ConfigFile *c, BoardInterface *b, int id, unsigned uniq myCash=0; } break; case 2: { - myCash=180; - } break; - case 3: { - myCash=3930; - } break; - case 4: { myCash=0; } break; + case 3: { + myCash=0; + } break; + case 4: { + myCash=10040; + } break; case 5: { - myCash=13590; + myCash=0; } break; case 6: { - myCash=3300; + myCash=10960; } break; default: { } @@ -1246,7 +1246,7 @@ void LocalPlayer::preflopEngine() { case 3: { switch(actualHand->getMyID()) { case 1: { - myAction = PLAYER_ACTION_FOLD; +// myAction = PLAYER_ACTION_FOLD; // raise = 20; // if(mySet >= 40) { // myAction = PLAYER_ACTION_CALL; @@ -1269,7 +1269,7 @@ void LocalPlayer::preflopEngine() { case 4: { switch(actualHand->getMyID()) { case 1: { - myAction = PLAYER_ACTION_FOLD; +// myAction = PLAYER_ACTION_FOLD; // raise = 20; // if(mySet > 0) { // myAction = PLAYER_ACTION_FOLD; @@ -1291,13 +1291,13 @@ void LocalPlayer::preflopEngine() { break; case 5: { if(mySet == 0) { - myAction = PLAYER_ACTION_CALL; +// myAction = PLAYER_ACTION_CALL; } } break; case 6: { if(mySet == 160) { - myAction = PLAYER_ACTION_CALL; +// myAction = PLAYER_ACTION_CALL; } } break; diff --git a/src/game.cpp b/src/game.cpp index 1d16fdf6..0b3edede 100755 --- a/src/game.cpp +++ b/src/game.cpp @@ -37,7 +37,7 @@ Game::Game(GuiInterface* gui, boost::shared_ptr factory, myGameID(gameId), actualSmallBlind(gameData.smallBlind), actualHandID(0), dealerPosition(0), lastHandBlindsRaised(1), lastTimeBlindsRaised(0), myGameData(gameData) { if(DEBUG_MODE) { - startSmallBlind = 160; + startSmallBlind = 5120; actualSmallBlind = startSmallBlind; } diff --git a/src/game_defs.h b/src/game_defs.h index 68a42f5f..c2773dc9 100644 --- a/src/game_defs.h +++ b/src/game_defs.h @@ -23,8 +23,8 @@ #define MIN_NUMBER_OF_PLAYERS 2 #define MAX_NUMBER_OF_PLAYERS 7 -#define MIN_GUI_SPEED 1 -#define MAX_GUI_SPEED 11 +#define MIN_GUI_SPEED 1 +#define MAX_GUI_SPEED 11 #define DEBUG_MODE 0 diff --git a/src/gui/qt/mainwindow/mainwindowimpl.cpp b/src/gui/qt/mainwindow/mainwindowimpl.cpp index ebccdfb7..8c64ed02 100755 --- a/src/gui/qt/mainwindow/mainwindowimpl.cpp +++ b/src/gui/qt/mainwindow/mainwindowimpl.cpp @@ -805,7 +805,7 @@ void mainWindowImpl::startNewLocalGame(newGameDialogImpl *v) { startData.numberOfPlayers = gameData.maxNumberOfPlayers; Tools::getRandNumber(0, startData.numberOfPlayers-1, 1, &tmpDealerPos, 0); if(DEBUG_MODE) { - tmpDealerPos = 5; + tmpDealerPos = 6; } startData.startDealerPlayerId = static_cast(tmpDealerPos);