debugging

This commit is contained in:
floty
2007-08-25 20:09:40 +00:00
parent 149092aecf
commit ccf02a0b8e
2 changed files with 83 additions and 72 deletions
+23 -19
View File
@@ -101,13 +101,15 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
if(DEBUG_MODE) {
if(myID==1) {
int temp5Array[5];
tempBoardArray[0] = 25;
tempBoardArray[1] = 37;
tempBoardArray[2] = 20;
tempBoardArray[3] = 49;
tempBoardArray[4] = 39;
tempBoardArray[0] = 38;
tempBoardArray[1] = 19;
tempBoardArray[2] = 21;
tempBoardArray[3] = 11;
tempBoardArray[4] = 45;
myBoard->setMyCards(tempBoardArray);
@@ -119,8 +121,8 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
// player0
tempPlayerArray[0] = 0;
tempPlayerArray[1] = 7;
tempPlayerArray[0] = 9;
tempPlayerArray[1] = 14;
tempPlayerAndBoardArray[0] = tempPlayerArray[0];
tempPlayerAndBoardArray[1] = tempPlayerArray[1];
@@ -136,8 +138,8 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
// player1
tempPlayerArray[0] = 51;
tempPlayerArray[1] = 24;
tempPlayerArray[0] = 44;
tempPlayerArray[1] = 27;
tempPlayerAndBoardArray[0] = tempPlayerArray[0];
tempPlayerAndBoardArray[1] = tempPlayerArray[1];
@@ -148,8 +150,8 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
// player2
tempPlayerArray[0] = 13;
tempPlayerArray[1] = 43;
tempPlayerArray[0] = 51;
tempPlayerArray[1] = 22;
tempPlayerAndBoardArray[0] = tempPlayerArray[0];
tempPlayerAndBoardArray[1] = tempPlayerArray[1];
@@ -158,15 +160,15 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
playerArray[2]->setMyBestHandPosition(temp5Array);
tempPlayerArray[0] = 19;
tempPlayerArray[1] = 51;
tempPlayerAndBoardArray[0] = tempPlayerArray[0];
tempPlayerAndBoardArray[1] = tempPlayerArray[1];
// tempPlayerArray[0] = 19;
// tempPlayerArray[1] = 51;
// tempPlayerAndBoardArray[0] = tempPlayerArray[0];
// tempPlayerAndBoardArray[1] = tempPlayerArray[1];
playerArray[3]->setMyCards(tempPlayerArray);
playerArray[3]->setMyCardsValueInt(myCardsValue.cardsValue(tempPlayerAndBoardArray,temp5Array));
playerArray[3]->setMyBestHandPosition(temp5Array);
// playerArray[3]->setMyCards(tempPlayerArray);
// playerArray[3]->setMyCardsValueInt(myCardsValue.cardsValue(tempPlayerAndBoardArray,temp5Array));
//
// playerArray[3]->setMyBestHandPosition(temp5Array);
// for(i=0; i<4; i++) {
// cout << i << ": " << playerArray[i]->getMyCardsValueInt() << endl;
@@ -177,6 +179,8 @@ LocalHand::LocalHand(boost::shared_ptr<EngineFactory> f, GuiInterface *g, BoardI
}
}
// ----------------------------------------
// Dealer, SB, BB bestimmen
+12 -5
View File
@@ -347,12 +347,12 @@ void LocalPlayer::preflopEngine() {
switch(actualHand->getMyID()) {
case 1: {
myAction = PLAYER_ACTION_CALL;
myAction = PLAYER_ACTION_FOLD;
}
break;
case 2: {
myAction = PLAYER_ACTION_CALL;
// raise = 120;
myAction = PLAYER_ACTION_RAISE;
raise = 70;
}
break;
default: {
@@ -365,12 +365,19 @@ void LocalPlayer::preflopEngine() {
switch(actualHand->getMyID()) {
case 1: {
myAction = PLAYER_ACTION_FOLD;
myAction = PLAYER_ACTION_RAISE;
raise = 20;
if(mySet >= 40) {
myAction = PLAYER_ACTION_CALL;
}
}
break;
case 2: {
myAction = PLAYER_ACTION_RAISE;
raise = 120;
raise = 50;
if(mySet >= 70) {
myAction = PLAYER_ACTION_CALL;
}
}
break;
default: {