bugfix: allin-bug

This commit is contained in:
floty
2007-08-31 13:09:07 +00:00
parent a84f164b8a
commit a0e78485df
6 changed files with 18 additions and 13 deletions
+2 -2
View File
@@ -3,8 +3,8 @@
TEMPLATE = app
CODECFORSRC = UTF-8
CONFIG += qt thread embed_manifest_exe release
#CONFIG += qt thread embed_manifest_exe warn_on debug
#CONFIG += qt thread embed_manifest_exe release
CONFIG += qt thread embed_manifest_exe warn_on debug
UI_DIR = uics
MOC_DIR = mocs
OBJECTS_DIR = obj
+2 -2
View File
@@ -178,8 +178,8 @@ mac{
INCLUDEPATH += /Library/Frameworks/SDL_mixer.framework/Headers
}
CONFIG += staticlib qt thread release
#CONFIG += staticlib qt thread warn_on debug
#CONFIG += staticlib qt thread release
CONFIG += staticlib qt thread warn_on debug
UI_DIR = uics
TARGET = lib/pokerth_lib
MOC_DIR = mocs
+2 -2
View File
@@ -128,8 +128,8 @@ unix:!mac{
#LIBS += -lcrypto
}
CONFIG += qt thread console embed_manifest_exe release
#CONFIG += qt thread console embed_manifest_exe warn_on debug
#CONFIG += qt thread console embed_manifest_exe release
CONFIG += qt thread console embed_manifest_exe warn_on debug
UI_DIR = uics
TARGET = bin/pokerth_server
MOC_DIR = mocs
+7 -1
View File
@@ -63,6 +63,7 @@ void LocalBeRo::run() {
break;
case GAME_STATE_RIVER: myHand->getGuiInterface()->logDealBoardCardsMsg(myBeRoID, tempBoardCardsArray[0], tempBoardCardsArray[1], tempBoardCardsArray[2], tempBoardCardsArray[3], tempBoardCardsArray[4]);
break;
default: { cout << "ERROR in localbero.cpp - wrong myBeRoID" << endl;}
}
logBoardCardsDone = 1;
@@ -107,7 +108,9 @@ void LocalBeRo::run() {
myHand->setBettingRoundsPlayed(myBeRoID);
}
if( !(myHand->getActualQuantityPlayers() < 3 && firstHeadsUpRound == 1) ) {
//// !!!!!!!!!!!!! very buggy, rule breaking -> TODO !!!!!!!!!!!!!!!! //////////////
if( !(myHand->getActualQuantityPlayers() < 3 && firstHeadsUpRound == 1) || myHand->getPlayerArray()[playersTurn]->getMyActiveStatus() == 0 ) {
// not first round in heads up (for headsup dealer is smallblind so it is dealers turn)
// naechsten Spieler ermitteln
@@ -115,9 +118,12 @@ void LocalBeRo::run() {
for(i=0; (i<MAX_NUMBER_OF_PLAYERS && !(myHand->getPlayerArray()[playersTurn]->getMyActiveStatus()) || (myHand->getPlayerArray()[playersTurn]->getMyAction())==1 || (myHand->getPlayerArray()[playersTurn]->getMyAction())==6) || i==0; i++) {
playersTurn = (playersTurn+1)%(MAX_NUMBER_OF_PLAYERS);
}
firstHeadsUpRound = 0;
}
else { firstHeadsUpRound = 0; }
////// !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ////////////////
//Spieler-Position vor SmallBlind-Position ermitteln
int activePlayerBeforeSmallBlind = smallBlindPosition;
-4
View File
@@ -37,7 +37,6 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
myBoard->setHand(this);
for(i=0; i<startQuantityPlayers; i++) {
playerArray[i]->setHand(this);
// myFlipCards auf 0 setzen
@@ -173,9 +172,6 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
// for(i=0; i<4; i++) {
// cout << i << ": " << playerArray[i]->getMyCardsValueInt() << endl;
// }
dealerPosition = 2;
}
+5 -2
View File
@@ -742,6 +742,9 @@ void mainWindowImpl::startNewLocalGame(newGameDialogImpl *v) {
int tmpDealerPos = 0;
startData.numberOfPlayers = gameData.maxNumberOfPlayers;
Tools::getRandNumber(0, startData.numberOfPlayers-1, 1, &tmpDealerPos, 0);
if(DEBUG_MODE) {
tmpDealerPos = 2;
}
startData.startDealerPlayerId = static_cast<unsigned>(tmpDealerPos);
//some gui modifications
@@ -1407,7 +1410,7 @@ void mainWindowImpl::dealBeRoCards(int myBeRoID) {
break;
case 3: { dealRiverCards0(); }
break;
default: { cout << "dealBeRoCards Error" << endl; }
default: { cout << "dealBeRoCards() Error" << endl; }
}
}
@@ -1897,7 +1900,7 @@ void mainWindowImpl::beRoAnimation2(int myBeRoID) {
break;
case 3: { riverAnimation2(); }
break;
default: { cout << "beRoAnimation2 Error" << endl; }
default: { cout << "beRoAnimation2() Error" << endl; }
}
}