edit hints of cppcheck
This commit is contained in:
@@ -396,7 +396,6 @@ int CardsValue::cardsValue(int cards[4], int bestHand[4])
|
|||||||
}
|
}
|
||||||
|
|
||||||
int color_2_idx, color_3_idx;
|
int color_2_idx, color_3_idx;
|
||||||
int temp2;
|
|
||||||
|
|
||||||
// Full House, Three of a Kind
|
// Full House, Three of a Kind
|
||||||
temp1 = 0;
|
temp1 = 0;
|
||||||
@@ -413,7 +412,7 @@ int CardsValue::cardsValue(int cards[4], int bestHand[4])
|
|||||||
if(bestHand) {
|
if(bestHand) {
|
||||||
kickerValue1 = determineKickerValue(temp1,0,0);
|
kickerValue1 = determineKickerValue(temp1,0,0);
|
||||||
kickerValue2 = determineKickerValue(kickerValue1.remain,1,1);
|
kickerValue2 = determineKickerValue(kickerValue1.remain,1,1);
|
||||||
temp2 = 0;
|
int temp2 = 0;
|
||||||
for(color_1_idx=3; color_1_idx>=0; color_1_idx--) {
|
for(color_1_idx=3; color_1_idx>=0; color_1_idx--) {
|
||||||
if(temp2<2) bestHand[color_1_idx] += (cards[color_1_idx] & (kickerValue1.select | kickerValue2.select));
|
if(temp2<2) bestHand[color_1_idx] += (cards[color_1_idx] & (kickerValue1.select | kickerValue2.select));
|
||||||
else bestHand[color_1_idx] += (cards[color_1_idx] & kickerValue1.select);
|
else bestHand[color_1_idx] += (cards[color_1_idx] & kickerValue1.select);
|
||||||
@@ -423,7 +422,7 @@ int CardsValue::cardsValue(int cards[4], int bestHand[4])
|
|||||||
return 600000000 + determineKickerValue(temp1,0,1).factorValue;
|
return 600000000 + determineKickerValue(temp1,0,1).factorValue;
|
||||||
} else {
|
} else {
|
||||||
// one times Three of a Kind
|
// one times Three of a Kind
|
||||||
temp2 = temp1;
|
int temp2 = temp1;
|
||||||
temp1 = 0;
|
temp1 = 0;
|
||||||
// check for additional pair
|
// check for additional pair
|
||||||
for(color_1_idx=0; color_1_idx<3; color_1_idx++) {
|
for(color_1_idx=0; color_1_idx<3; color_1_idx++) {
|
||||||
@@ -899,8 +898,6 @@ int CardsValue::cardsValueOld(int cards[7], int position[5])
|
|||||||
|
|
||||||
std::vector< std::vector<int> > CardsValue::calcCardsChance(GameState beRoID, int playerCards[2], int boardCards[5])
|
std::vector< std::vector<int> > CardsValue::calcCardsChance(GameState beRoID, int playerCards[2], int boardCards[5])
|
||||||
{
|
{
|
||||||
int card_idx_1, card_idx_2;
|
|
||||||
|
|
||||||
std::vector< std::vector<int> > chance(2);
|
std::vector< std::vector<int> > chance(2);
|
||||||
chance[0].assign(10,0);
|
chance[0].assign(10,0);
|
||||||
chance[1].assign(10,0);
|
chance[1].assign(10,0);
|
||||||
@@ -908,6 +905,7 @@ std::vector< std::vector<int> > CardsValue::calcCardsChance(GameState beRoID, in
|
|||||||
int cards[4] = { 0,0,0,0 };
|
int cards[4] = { 0,0,0,0 };
|
||||||
int sum = 0;
|
int sum = 0;
|
||||||
|
|
||||||
|
int card_idx_1;
|
||||||
for(card_idx_1=0; card_idx_1<2; card_idx_1++) cards[playerCards[card_idx_1]/13] |= (1 << (playerCards[card_idx_1]%13));
|
for(card_idx_1=0; card_idx_1<2; card_idx_1++) cards[playerCards[card_idx_1]/13] |= (1 << (playerCards[card_idx_1]%13));
|
||||||
|
|
||||||
switch(beRoID) {
|
switch(beRoID) {
|
||||||
@@ -924,7 +922,7 @@ std::vector< std::vector<int> > CardsValue::calcCardsChance(GameState beRoID, in
|
|||||||
for(card_idx_1=0; card_idx_1<51; card_idx_1++) {
|
for(card_idx_1=0; card_idx_1<51; card_idx_1++) {
|
||||||
if((cards[card_idx_1/13] & (1 << (card_idx_1%13))) == 0) {
|
if((cards[card_idx_1/13] & (1 << (card_idx_1%13))) == 0) {
|
||||||
cards[card_idx_1/13] |= (1 << (card_idx_1%13));
|
cards[card_idx_1/13] |= (1 << (card_idx_1%13));
|
||||||
for(card_idx_2=card_idx_1+1; card_idx_2<52; card_idx_2++) {
|
for(int card_idx_2=card_idx_1+1; card_idx_2<52; card_idx_2++) {
|
||||||
if((cards[card_idx_2/13] & (1 << (card_idx_2%13))) == 0) {
|
if((cards[card_idx_2/13] & (1 << (card_idx_2%13))) == 0) {
|
||||||
cards[card_idx_2/13] |= (1 << (card_idx_2%13));
|
cards[card_idx_2/13] |= (1 << (card_idx_2%13));
|
||||||
(chance[0][cardsValueShort(cards)])++;
|
(chance[0][cardsValueShort(cards)])++;
|
||||||
|
|||||||
@@ -158,20 +158,19 @@ void LocalHand::start()
|
|||||||
void LocalHand::assignButtons()
|
void LocalHand::assignButtons()
|
||||||
{
|
{
|
||||||
|
|
||||||
size_t i;
|
PlayerListIterator seatIt;
|
||||||
PlayerListIterator it;
|
|
||||||
|
|
||||||
// delete all buttons
|
// delete all buttons
|
||||||
for (it=seatsList->begin(); it!=seatsList->end(); ++it) {
|
for (seatIt=seatsList->begin(); seatIt!=seatsList->end(); ++seatIt) {
|
||||||
(*it)->setMyButton(BUTTON_NONE);
|
(*seatIt)->setMyButton(BUTTON_NONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
// assign dealer button
|
// assign dealer button
|
||||||
it = getSeatIt(dealerPosition);
|
seatIt = getSeatIt(dealerPosition);
|
||||||
if(it == seatsList->end()) {
|
if(seatIt == seatsList->end()) {
|
||||||
throw LocalException(__FILE__, __LINE__, ERR_SEAT_NOT_FOUND);
|
throw LocalException(__FILE__, __LINE__, ERR_SEAT_NOT_FOUND);
|
||||||
}
|
}
|
||||||
(*it)->setMyButton(BUTTON_DEALER);
|
(*seatIt)->setMyButton(BUTTON_DEALER);
|
||||||
|
|
||||||
|
|
||||||
// assign Small Blind next to dealer. ATTENTION: in heads up it is big blind
|
// assign Small Blind next to dealer. ATTENTION: in heads up it is big blind
|
||||||
@@ -182,40 +181,40 @@ void LocalHand::assignButtons()
|
|||||||
throw LocalException(__FILE__, __LINE__, ERR_SEAT_NOT_FOUND);
|
throw LocalException(__FILE__, __LINE__, ERR_SEAT_NOT_FOUND);
|
||||||
}
|
}
|
||||||
|
|
||||||
for(i=0; i<seatsList->size(); i++) {
|
for(size_t i=0; i<seatsList->size(); i++) {
|
||||||
|
|
||||||
++dealerPositionIt;
|
++dealerPositionIt;
|
||||||
if(dealerPositionIt == seatsList->end()) dealerPositionIt = seatsList->begin();
|
if(dealerPositionIt == seatsList->end()) dealerPositionIt = seatsList->begin();
|
||||||
|
|
||||||
it = getActivePlayerIt( (*dealerPositionIt)->getMyUniqueID() );
|
PlayerListIterator activePlayerIt = getActivePlayerIt( (*dealerPositionIt)->getMyUniqueID() );
|
||||||
if(it != activePlayerList->end() ) {
|
if(activePlayerIt != activePlayerList->end() ) {
|
||||||
nextActivePlayerFound = true;
|
nextActivePlayerFound = true;
|
||||||
if(activePlayerList->size() > 2) {
|
if(activePlayerList->size() > 2) {
|
||||||
//small blind normal
|
//small blind normal
|
||||||
(*it)->setMyButton(2);
|
(*activePlayerIt)->setMyButton(2);
|
||||||
smallBlindPosition = (*it)->getMyUniqueID();
|
smallBlindPosition = (*activePlayerIt)->getMyUniqueID();
|
||||||
} else {
|
} else {
|
||||||
//big blind in heads up
|
//big blind in heads up
|
||||||
(*it)->setMyButton(3);
|
(*activePlayerIt)->setMyButton(3);
|
||||||
bigBlindPosition = (*it)->getMyUniqueID();
|
bigBlindPosition = (*activePlayerIt)->getMyUniqueID();
|
||||||
// lastPlayerAction for showing cards
|
// lastPlayerAction for showing cards
|
||||||
}
|
}
|
||||||
|
|
||||||
// first player after dealer have to show his cards first (in showdown)
|
// first player after dealer have to show his cards first (in showdown)
|
||||||
lastActionPlayerID = (*it)->getMyUniqueID();
|
lastActionPlayerID = (*activePlayerIt)->getMyUniqueID();
|
||||||
myBoard->setLastActionPlayerID(lastActionPlayerID);
|
myBoard->setLastActionPlayerID(lastActionPlayerID);
|
||||||
|
|
||||||
++it;
|
++activePlayerIt;
|
||||||
if(it == activePlayerList->end()) it = activePlayerList->begin();
|
if(activePlayerIt == activePlayerList->end()) activePlayerIt = activePlayerList->begin();
|
||||||
|
|
||||||
if(activePlayerList->size() > 2) {
|
if(activePlayerList->size() > 2) {
|
||||||
//big blind normal
|
//big blind normal
|
||||||
(*it)->setMyButton(3);
|
(*activePlayerIt)->setMyButton(3);
|
||||||
bigBlindPosition = (*it)->getMyUniqueID();
|
bigBlindPosition = (*activePlayerIt)->getMyUniqueID();
|
||||||
} else {
|
} else {
|
||||||
//small blind in heads up
|
//small blind in heads up
|
||||||
(*it)->setMyButton(2);
|
(*activePlayerIt)->setMyButton(2);
|
||||||
smallBlindPosition = (*it)->getMyUniqueID();
|
smallBlindPosition = (*activePlayerIt)->getMyUniqueID();
|
||||||
}
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -2908,8 +2908,8 @@ void LocalPlayer::calcMyOdds()
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
int myCards[4] = { 0,0,0,0 };
|
// int myCards[4] = { 0,0,0,0 };
|
||||||
int opponentCards[4] = { 0,0,0,0 };
|
// int opponentCards[4] = { 0,0,0,0 };
|
||||||
|
|
||||||
|
|
||||||
int tempMyCardsValue;
|
int tempMyCardsValue;
|
||||||
|
|||||||
@@ -42,6 +42,7 @@ using namespace std;
|
|||||||
|
|
||||||
guiLog::guiLog(gameTableImpl* w, ConfigFile *c) : myW(w), myConfig(c), myLogDir(0), myHtmlLogFile(0), myHtmlLogFile_old(0), myTxtLogFile(0), tb(0)
|
guiLog::guiLog(gameTableImpl* w, ConfigFile *c) : myW(w), myConfig(c), myLogDir(0), myHtmlLogFile(0), myHtmlLogFile_old(0), myTxtLogFile(0), tb(0)
|
||||||
{
|
{
|
||||||
|
newVersion = true;
|
||||||
|
|
||||||
myW->setGuiLog(this);
|
myW->setGuiLog(this);
|
||||||
myStyle = myW->getMyGameTableStyle();
|
myStyle = myW->getMyGameTableStyle();
|
||||||
@@ -470,8 +471,6 @@ void guiLog::showLog(QString fileStringPdb, QTextBrowser *tb_tmp, int uniqueGame
|
|||||||
|
|
||||||
int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
||||||
{
|
{
|
||||||
bool neu = true;
|
|
||||||
|
|
||||||
result_struct results;
|
result_struct results;
|
||||||
results.result_Session = 0;
|
results.result_Session = 0;
|
||||||
results.result_Game = 0;
|
results.result_Game = 0;
|
||||||
@@ -567,7 +566,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
log_string = "<h3><b>" + log_string + "</b></h3>\n";
|
log_string = "<h3><b>" + log_string + "</b></h3>\n";
|
||||||
// if(!neu) log_string = "<img src='logo.png'>\n" + log_string;
|
// if(!newVersion) log_string = "<img src='logo.png'>\n" + log_string;
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
log_string += "";
|
log_string += "";
|
||||||
@@ -658,7 +657,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
log_string = "<table><tr><td width=\"600\" align=\"center\"><hr noshade size=\"3\"><b>" + log_string;
|
log_string = "<table><tr><td width=\"600\" align=\"center\"><hr noshade size=\"3\"><b>" + log_string;
|
||||||
if(!neu) log_string += "</b></td><td></td></tr></table>";
|
if(!newVersion) log_string += "</b></td><td></td></tr></table>";
|
||||||
else log_string += "</b></td></tr></table>";
|
else log_string += "</b></td></tr></table>";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
@@ -720,7 +719,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
|
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) log_string += "</br>";
|
if(!newVersion) log_string += "</br>";
|
||||||
else log_string += "<br />";
|
else log_string += "<br />";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
@@ -758,7 +757,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
log_string += ")";
|
log_string += ")";
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) log_string += "</br>";
|
if(!newVersion) log_string += "</br>";
|
||||||
else log_string += "<br />";
|
else log_string += "<br />";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
@@ -781,7 +780,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(neu) {
|
if(newVersion) {
|
||||||
|
|
||||||
if(modus == 1) log_string += "<br />";
|
if(modus == 1) log_string += "<br />";
|
||||||
|
|
||||||
@@ -903,7 +902,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
if(nRow_Action == 1) {
|
if(nRow_Action == 1) {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) log_string += "</br>";
|
if(!newVersion) log_string += "</br>";
|
||||||
else log_string += "<br />";
|
else log_string += "<br />";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
@@ -921,7 +920,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!neu && modus==1) log_string += "</br>";
|
if(!newVersion && modus==1) log_string += "</br>";
|
||||||
|
|
||||||
writeLog(log_string,modus);
|
writeLog(log_string,modus);
|
||||||
log_string = "";
|
log_string = "";
|
||||||
@@ -949,10 +948,10 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
}
|
}
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) round_string = "</br><b>" + round_string + "</b>";
|
if(!newVersion) round_string = "</br><b>" + round_string + "</b>";
|
||||||
else round_string = "<br /><b>" + round_string + "</b>";
|
else round_string = "<br /><b>" + round_string + "</b>";
|
||||||
if(round_ctr >= GAME_STATE_FLOP) {
|
if(round_ctr >= GAME_STATE_FLOP) {
|
||||||
if(!neu) round_string = "</br>\n" + round_string;
|
if(!newVersion) round_string = "</br>\n" + round_string;
|
||||||
else round_string = "<br />\n" + round_string;
|
else round_string = "<br />\n" + round_string;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -1019,7 +1018,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
for(action_ctr=1; action_ctr<=nRow_Action; action_ctr++) {
|
for(action_ctr=1; action_ctr<=nRow_Action; action_ctr++) {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) {
|
if(!newVersion) {
|
||||||
if(action_ctr>1 && (boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "wins" || boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "sits out" || boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "wins (side pot)"))
|
if(action_ctr>1 && (boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "wins" || boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "sits out" || boost::lexical_cast<std::string>(results.result_Action[3*(action_ctr-1)+1]) == "wins (side pot)"))
|
||||||
log_string += "\n";
|
log_string += "\n";
|
||||||
else
|
else
|
||||||
@@ -1037,7 +1036,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
default:
|
default:
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
if(!neu && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins (side pot)") {
|
if(!newVersion && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins (side pot)") {
|
||||||
action_string += player[boost::lexical_cast<int>(results.result_Action[3*action_ctr])-1];
|
action_string += player[boost::lexical_cast<int>(results.result_Action[3*action_ctr])-1];
|
||||||
action_string += " wins $";
|
action_string += " wins $";
|
||||||
action_string += boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+2]);
|
action_string += boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+2]);
|
||||||
@@ -1057,7 +1056,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins game") {
|
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins game") {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) action_string = "</br></br><i><b>" + action_string + " " + boost::lexical_cast<std::string>(gameID) + "!</i></b></br>";
|
if(!newVersion) action_string = "</br></br><i><b>" + action_string + " " + boost::lexical_cast<std::string>(gameID) + "!</i></b></br>";
|
||||||
else action_string = "</br><i><b>" + action_string + " " + boost::lexical_cast<std::string>(gameID) + "!</b></i>";
|
else action_string = "</br><i><b>" + action_string + " " + boost::lexical_cast<std::string>(gameID) + "!</b></i>";
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
@@ -1075,7 +1074,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins (side pot)") {
|
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "wins (side pot)") {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) action_string = "</br><i>" + action_string + "</i>";
|
if(!newVersion) action_string = "</br><i>" + action_string + "</i>";
|
||||||
else action_string = "<i>" + action_string + "</i>";
|
else action_string = "<i>" + action_string + "</i>";
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
@@ -1090,7 +1089,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has left the game" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "was kicked from the game" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "is game admin now" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has joined the game") {
|
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has left the game" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "was kicked from the game" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "is game admin now" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has joined the game") {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) action_string = "<i>" + action_string + "!</i>";
|
if(!newVersion) action_string = "<i>" + action_string + "!</i>";
|
||||||
else action_string = "<i>" + action_string + "</i>";
|
else action_string = "<i>" + action_string + "</i>";
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
@@ -1105,7 +1104,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "sits out") {
|
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "sits out") {
|
||||||
switch(modus) {
|
switch(modus) {
|
||||||
case 1:
|
case 1:
|
||||||
if(!neu) action_string = "</br><i><span style=\"font-size:smaller;\">" + action_string + "</span></i>";
|
if(!newVersion) action_string = "</br><i><span style=\"font-size:smaller;\">" + action_string + "</span></i>";
|
||||||
else action_string = "<i><span style=\"font-size:smaller;\">" + action_string + "</span></i>";
|
else action_string = "<i><span style=\"font-size:smaller;\">" + action_string + "</span></i>";
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
@@ -1122,7 +1121,7 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
// show cards
|
// show cards
|
||||||
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "shows" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has") {
|
if(boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "shows" || boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) == "has") {
|
||||||
// log cards
|
// log cards
|
||||||
if(!neu && round_ctr == GAME_STATE_POST_RIVER) log_string += " [ ";
|
if(!newVersion && round_ctr == GAME_STATE_POST_RIVER) log_string += " [ ";
|
||||||
else log_string += " [";
|
else log_string += " [";
|
||||||
if(modus == 1 || modus == 3) log_string += "<b>";
|
if(modus == 1 || modus == 3) log_string += "<b>";
|
||||||
|
|
||||||
@@ -1193,10 +1192,10 @@ int guiLog::exportLog(QString fileStringPdb,int modus,int uniqueGameID_req)
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!neu && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "shows" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "sits out" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins (side pot)" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has left the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "was kicked from the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "is game admin now" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has joined the game") {
|
if(!newVersion && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "shows" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "sits out" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins (side pot)" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has left the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "was kicked from the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "is game admin now" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has joined the game") {
|
||||||
log_string += ".";
|
log_string += ".";
|
||||||
}
|
}
|
||||||
if(neu && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has left the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "was kicked from the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "is game admin now" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has joined the game")
|
if(newVersion && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "wins game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has left the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "was kicked from the game" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "is game admin now" && boost::lexical_cast<std::string>(results.result_Action[3*action_ctr+1]) != "has joined the game")
|
||||||
log_string += ".";
|
log_string += ".";
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -137,6 +137,7 @@ private:
|
|||||||
QTextBrowser* tb;
|
QTextBrowser* tb;
|
||||||
GameTableStyleReader *myStyle;
|
GameTableStyleReader *myStyle;
|
||||||
std::string mySqliteLogFileName;
|
std::string mySqliteLogFileName;
|
||||||
|
bool newVersion;
|
||||||
|
|
||||||
friend class GuiWrapper;
|
friend class GuiWrapper;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user