add showCards function to receive cards from players which hit the show-cards-button during postriver. define static ranking game data
This commit is contained in:
@@ -90,7 +90,7 @@ void ServerGuiWrapper::riverAnimation2() {}
|
||||
|
||||
void ServerGuiWrapper::postRiverAnimation1() {}
|
||||
void ServerGuiWrapper::postRiverRunAnimation1() {}
|
||||
|
||||
void ServerGuiWrapper::postRiverShowCards(unsigned /*playerId*/) {}
|
||||
void ServerGuiWrapper::flipHolecardsAllIn() {}
|
||||
|
||||
void ServerGuiWrapper::nextRoundCleanGui() {}
|
||||
|
||||
@@ -78,6 +78,7 @@ public:
|
||||
|
||||
void postRiverAnimation1();
|
||||
void postRiverRunAnimation1();
|
||||
void postRiverShowCards(unsigned playerId);
|
||||
|
||||
void flipHolecardsAllIn();
|
||||
|
||||
|
||||
@@ -84,11 +84,12 @@ public:
|
||||
|
||||
virtual void postRiverAnimation1()=0;
|
||||
virtual void postRiverRunAnimation1()=0;
|
||||
virtual void postRiverShowCards(unsigned playerId)=0;
|
||||
virtual void flipHolecardsAllIn()=0;
|
||||
|
||||
virtual void nextRoundCleanGui()=0;
|
||||
virtual void meInAction()=0;
|
||||
virtual void updateMyButtonsState()=0;
|
||||
virtual void updateMyButtonsState()=0;
|
||||
virtual void disableMyButtons()=0;
|
||||
virtual void startTimeoutAnimation(int playerNum, int timeoutSec) =0;
|
||||
virtual void stopTimeoutAnimation(int playerNum) =0;
|
||||
|
||||
@@ -69,7 +69,7 @@ void ChatTools::receiveMessage(QString playerName, QString message) {
|
||||
|
||||
switch (myChatType) {
|
||||
case INET_LOBBY_CHAT: {
|
||||
tempMsg = QString("<span style=\"font-weight:bold; color:"+myLobby->palette().linkVisited().color().name()+";\">"+message+"</span>");
|
||||
tempMsg = QString("<span style=\"font-weight:bold; color:"+myLobby->palette().link().color().name()+";\">"+message+"</span>");
|
||||
//play beep sound only in INET-lobby-chat
|
||||
// TODO dont play when message is from yourself
|
||||
if(myLobby->isVisible() && myConfig->readConfigInt("PlayLobbyChatNotification")) {
|
||||
@@ -86,7 +86,7 @@ void ChatTools::receiveMessage(QString playerName, QString message) {
|
||||
}
|
||||
else if(playerName == myNick) {
|
||||
switch (myChatType) {
|
||||
case INET_LOBBY_CHAT: tempMsg = QString("<span style=\"font-weight:normal; color:"+myLobby->palette().linkVisited().color().name()+";\">"+message+"</span>");
|
||||
case INET_LOBBY_CHAT: tempMsg = QString("<span style=\"font-weight:normal; color:"+myLobby->palette().link().color().name()+";\">"+message+"</span>");
|
||||
break;
|
||||
case LAN_LOBBY_CHAT: tempMsg = QString("<span style=\"font-weight:normal;\">"+message+"</span>");
|
||||
break;
|
||||
|
||||
@@ -24,6 +24,18 @@
|
||||
#include "changecompleteblindsdialogimpl.h"
|
||||
|
||||
|
||||
#define RANKING_GAME_START_CASH 10000
|
||||
|
||||
#ifdef POKERTH_IS_08BETA
|
||||
#define RANKING_GAME_NUMBER_OF_PLAYERS 5
|
||||
#else
|
||||
#define RANKING_GAME_NUMBER_OF_PLAYERS 10
|
||||
#endif
|
||||
|
||||
#define RANKING_GAME_START_SBLIND 50
|
||||
#define RANKING_GAME_RAISE_EVERY_HAND 11
|
||||
|
||||
|
||||
createInternetGameDialogImpl::createInternetGameDialogImpl(QWidget *parent, ConfigFile *c)
|
||||
: QDialog(parent), myConfig(c), currentGuestMode(false), currentPlayerName("")
|
||||
{
|
||||
@@ -40,8 +52,8 @@ createInternetGameDialogImpl::createInternetGameDialogImpl(QWidget *parent, Conf
|
||||
|
||||
myChangeCompleteBlindsDialog = new changeCompleteBlindsDialogImpl;
|
||||
|
||||
startBlind = new QLabel(tr("<i>Start blind: $25</i>"));
|
||||
raiseMode = new QLabel(tr("<i>Double blinds every 11'th hand</i>"));
|
||||
startBlind = new QLabel(tr("<i>First small blind: $%1</i>").arg(RANKING_GAME_START_SBLIND));
|
||||
raiseMode = new QLabel(tr("<i>Double blinds every %1'th hand</i>").arg(RANKING_GAME_RAISE_EVERY_HAND));
|
||||
startBlind->hide();
|
||||
raiseMode->hide();
|
||||
gridLayout1->addWidget(startBlind, 0, 0, 1, 1);
|
||||
@@ -75,8 +87,6 @@ void createInternetGameDialogImpl::cancel() {
|
||||
void createInternetGameDialogImpl::fillFormular(bool guestMode, QString playerName) {
|
||||
|
||||
//Network Game Settings
|
||||
spinBox_quantityPlayers->setValue(myConfig->readConfigInt("NetNumberOfPlayers"));
|
||||
spinBox_startCash->setValue(myConfig->readConfigInt("NetStartCash"));
|
||||
spinBox_netDelayBetweenHands->setValue(myConfig->readConfigInt("NetDelayBetweenHands"));
|
||||
spinBox_netTimeOutPlayerAction->setValue(myConfig->readConfigInt("NetTimeOutPlayerAction"));
|
||||
checkBox_Password->setChecked(myConfig->readConfigInt("UseInternetGamePassword"));
|
||||
@@ -84,30 +94,6 @@ void createInternetGameDialogImpl::fillFormular(bool guestMode, QString playerNa
|
||||
lineEdit_Password->setText(QString::fromUtf8(myConfig->readConfigString("InternetGamePassword").c_str()));
|
||||
}
|
||||
|
||||
//fill changeCompleteBlindsDialog
|
||||
myChangeCompleteBlindsDialog->spinBox_firstSmallBlind->setValue(myConfig->readConfigInt("NetFirstSmallBlind"));
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtHands->setChecked(myConfig->readConfigInt("NetRaiseBlindsAtHands"));
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtMinutes->setChecked(myConfig->readConfigInt("NetRaiseBlindsAtMinutes"));
|
||||
myChangeCompleteBlindsDialog->spinBox_raiseSmallBlindEveryHands->setValue(myConfig->readConfigInt("NetRaiseSmallBlindEveryHands"));
|
||||
myChangeCompleteBlindsDialog->spinBox_raiseSmallBlindEveryMinutes->setValue(myConfig->readConfigInt("NetRaiseSmallBlindEveryMinutes"));
|
||||
myChangeCompleteBlindsDialog->radioButton_alwaysDoubleBlinds->setChecked(myConfig->readConfigInt("NetAlwaysDoubleBlinds"));
|
||||
myChangeCompleteBlindsDialog->radioButton_manualBlindsOrder->setChecked(myConfig->readConfigInt("NetManualBlindsOrder"));
|
||||
|
||||
myChangeCompleteBlindsDialog->listWidget_blinds->clear();
|
||||
myChangeCompleteBlindsDialog->spinBox_input->setMinimum(myChangeCompleteBlindsDialog->spinBox_firstSmallBlind->value()+1);
|
||||
|
||||
std::list<int> myBlindsList = myConfig->readConfigIntList("NetManualBlindsList");
|
||||
std::list<int>::iterator it1;
|
||||
|
||||
for(it1= myBlindsList.begin(); it1 != myBlindsList.end(); it1++) {
|
||||
myChangeCompleteBlindsDialog->listWidget_blinds->addItem(QString::number(*it1,10));
|
||||
}
|
||||
myChangeCompleteBlindsDialog->sortBlindsList();
|
||||
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisAlwaysDoubleBlinds->setChecked(myConfig->readConfigInt("NetAfterMBAlwaysDoubleBlinds"));
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisAlwaysRaiseAbout->setChecked(myConfig->readConfigInt("NetAfterMBAlwaysRaiseAbout"));
|
||||
myChangeCompleteBlindsDialog->spinBox_afterThisAlwaysRaiseValue->setValue(myConfig->readConfigInt("NetAfterMBAlwaysRaiseValue"));
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisStayAtLastBlind->setChecked(myConfig->readConfigInt("NetAfterMBStayAtLastBlind"));
|
||||
|
||||
if(guestMode) {
|
||||
comboBox_gameType->setCurrentIndex(0);
|
||||
@@ -197,9 +183,9 @@ void createInternetGameDialogImpl::gameTypeChanged() {
|
||||
checkBox_Password->setChecked(FALSE);
|
||||
checkBox_Password->setDisabled(TRUE);
|
||||
|
||||
spinBox_startCash->setValue(10000);
|
||||
spinBox_startCash->setValue(RANKING_GAME_START_CASH);
|
||||
spinBox_startCash->setDisabled(TRUE);
|
||||
spinBox_quantityPlayers->setValue(10);
|
||||
spinBox_quantityPlayers->setValue(RANKING_GAME_NUMBER_OF_PLAYERS);
|
||||
spinBox_quantityPlayers->setDisabled(TRUE);
|
||||
radioButton_useSavedBlindsSettings->hide();
|
||||
radioButton_changeBlindsSettings->hide();
|
||||
@@ -210,4 +196,40 @@ void createInternetGameDialogImpl::gameTypeChanged() {
|
||||
break;
|
||||
}
|
||||
|
||||
if(comboBox_gameType->currentIndex() == GAME_TYPE_RANKING-1) {
|
||||
//set static values
|
||||
myChangeCompleteBlindsDialog->spinBox_firstSmallBlind->setValue(RANKING_GAME_START_SBLIND);
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtHands->setChecked(TRUE);
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtMinutes->setChecked(FALSE);
|
||||
myChangeCompleteBlindsDialog->spinBox_raiseSmallBlindEveryHands->setValue(11);
|
||||
myChangeCompleteBlindsDialog->radioButton_alwaysDoubleBlinds->setChecked(TRUE);
|
||||
myChangeCompleteBlindsDialog->radioButton_manualBlindsOrder->setChecked(FALSE);
|
||||
myChangeCompleteBlindsDialog->listWidget_blinds->clear();
|
||||
}
|
||||
else {
|
||||
//read config values
|
||||
myChangeCompleteBlindsDialog->spinBox_firstSmallBlind->setValue(myConfig->readConfigInt("NetFirstSmallBlind"));
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtHands->setChecked(myConfig->readConfigInt("NetRaiseBlindsAtHands"));
|
||||
myChangeCompleteBlindsDialog->radioButton_raiseBlindsAtMinutes->setChecked(myConfig->readConfigInt("NetRaiseBlindsAtMinutes"));
|
||||
myChangeCompleteBlindsDialog->spinBox_raiseSmallBlindEveryHands->setValue(myConfig->readConfigInt("NetRaiseSmallBlindEveryHands"));
|
||||
myChangeCompleteBlindsDialog->spinBox_raiseSmallBlindEveryMinutes->setValue(myConfig->readConfigInt("NetRaiseSmallBlindEveryMinutes"));
|
||||
myChangeCompleteBlindsDialog->radioButton_alwaysDoubleBlinds->setChecked(myConfig->readConfigInt("NetAlwaysDoubleBlinds"));
|
||||
myChangeCompleteBlindsDialog->radioButton_manualBlindsOrder->setChecked(myConfig->readConfigInt("NetManualBlindsOrder"));
|
||||
|
||||
myChangeCompleteBlindsDialog->listWidget_blinds->clear();
|
||||
myChangeCompleteBlindsDialog->spinBox_input->setMinimum(myChangeCompleteBlindsDialog->spinBox_firstSmallBlind->value()+1);
|
||||
|
||||
std::list<int> myBlindsList = myConfig->readConfigIntList("NetManualBlindsList");
|
||||
std::list<int>::iterator it1;
|
||||
|
||||
for(it1= myBlindsList.begin(); it1 != myBlindsList.end(); it1++) {
|
||||
myChangeCompleteBlindsDialog->listWidget_blinds->addItem(QString::number(*it1,10));
|
||||
}
|
||||
myChangeCompleteBlindsDialog->sortBlindsList();
|
||||
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisAlwaysDoubleBlinds->setChecked(myConfig->readConfigInt("NetAfterMBAlwaysDoubleBlinds"));
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisAlwaysRaiseAbout->setChecked(myConfig->readConfigInt("NetAfterMBAlwaysRaiseAbout"));
|
||||
myChangeCompleteBlindsDialog->spinBox_afterThisAlwaysRaiseValue->setValue(myConfig->readConfigInt("NetAfterMBAlwaysRaiseValue"));
|
||||
myChangeCompleteBlindsDialog->radioButton_afterThisStayAtLastBlind->setChecked(myConfig->readConfigInt("NetAfterMBStayAtLastBlind"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -197,8 +197,6 @@ gameTableImpl::gameTableImpl(ConfigFile *c, QMainWindow *parent)
|
||||
postRiverAnimation1Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation1Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation2Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation2_flipHoleCards1Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation2_flipHoleCards2Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation3Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation5Timer->setSingleShot(TRUE);
|
||||
postRiverRunAnimation6Timer->setSingleShot(TRUE);
|
||||
@@ -427,8 +425,6 @@ gameTableImpl::gameTableImpl(ConfigFile *c, QMainWindow *parent)
|
||||
connect(postRiverAnimation1Timer, SIGNAL(timeout()), this, SLOT( postRiverAnimation1Action() ));
|
||||
connect(postRiverRunAnimation1Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation2() ));
|
||||
connect(postRiverRunAnimation2Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation3() ));
|
||||
connect(postRiverRunAnimation2_flipHoleCards1Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation2_flipHoleCards1() ));
|
||||
connect(postRiverRunAnimation2_flipHoleCards2Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation2_flipHoleCards2() ));
|
||||
connect(postRiverRunAnimation3Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation4() ));
|
||||
connect(potDistributeTimer, SIGNAL(timeout()), this, SLOT(postRiverRunAnimation5()));
|
||||
connect(postRiverRunAnimation5Timer, SIGNAL(timeout()), this, SLOT( postRiverRunAnimation6() ));
|
||||
@@ -506,6 +502,7 @@ gameTableImpl::gameTableImpl(ConfigFile *c, QMainWindow *parent)
|
||||
connect(this, SIGNAL(signalRiverAnimation2()), this, SLOT(riverAnimation2()));
|
||||
connect(this, SIGNAL(signalPostRiverAnimation1()), this, SLOT(postRiverAnimation1()));
|
||||
connect(this, SIGNAL(signalPostRiverRunAnimation1()), this, SLOT(postRiverRunAnimation1()));
|
||||
connect(this, SIGNAL(signalPostRiverShowCards(unsigned)), this, SLOT(postRiverShowCards(unsigned)));
|
||||
connect(this, SIGNAL(signalFlipHolecardsAllIn()), this, SLOT(flipHolecardsAllIn()));
|
||||
connect(this, SIGNAL(signalNextRoundCleanGui()), this, SLOT(nextRoundCleanGui()));
|
||||
connect(this, SIGNAL(signalStartVoteOnKick(unsigned, unsigned, int, int)), this, SLOT(startVoteOnKick(unsigned, unsigned, int, int)));
|
||||
@@ -657,7 +654,7 @@ void gameTableImpl::applySettings(settingsDialogImpl* mySettingsDialog) {
|
||||
}
|
||||
|
||||
refreshGameTableStyle();
|
||||
// qDebug() << "table: " << myGameTableStyle->getStyleDescription() << myGameTableStyle->getState();
|
||||
// qDebug() << "table: " << myGameTableStyle->getStyleDescription() << myGameTableStyle->getState();
|
||||
if(this->isVisible() && myGameTableStyle->getState() != GT_STYLE_OK) myGameTableStyle->showErrorMessage();
|
||||
|
||||
//blind buttons refresh
|
||||
@@ -1505,20 +1502,20 @@ void gameTableImpl::meInAction() {
|
||||
lineEdit_betValue->selectAll();
|
||||
}
|
||||
|
||||
// if(this->isMinimized()){
|
||||
// this->showNormal();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
// }
|
||||
// else if(!this->isActiveWindow()) {
|
||||
// this->showMinimized();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
// this->showNormal();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
//
|
||||
// }
|
||||
// if(this->isMinimized()){
|
||||
// this->showNormal();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
// }
|
||||
// else if(!this->isActiveWindow()) {
|
||||
// this->showMinimized();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
// this->showNormal();
|
||||
// this->activateWindow();
|
||||
// this->raise();
|
||||
//
|
||||
// }
|
||||
|
||||
|
||||
myActionIsRaise = 0;
|
||||
@@ -2023,59 +2020,51 @@ void gameTableImpl::postRiverRunAnimation2() {
|
||||
|
||||
if(!flipHolecardsAllInAlreadyDone) {
|
||||
|
||||
//TODO - Turn cards like in the rules
|
||||
QPixmap onePix = QPixmap::fromImage(QImage(myAppDataPath +"gfx/gui/misc/1px.png"));
|
||||
//TempArrays
|
||||
QPixmap tempCardsPixmapArray[2];
|
||||
int tempCardsIntArray[2];
|
||||
int antiPeekMode = myConfig->readConfigInt("AntiPeekMode");
|
||||
int showFlipcardAnimation = myConfig->readConfigInt("ShowFlipCardsAnimation");
|
||||
|
||||
// postRiverRunAnimation2_flipHoleCards1Timer->start(nextPlayerSpeed2);
|
||||
int j;
|
||||
for (it_c=currentHand->getActivePlayerList()->begin(); it_c!=currentHand->getActivePlayerList()->end(); it_c++) {
|
||||
(*it_c)->getMyCards(tempCardsIntArray);
|
||||
if((*it_c)->getMyAction() != PLAYER_ACTION_FOLD) {
|
||||
|
||||
// //Config? mit oder ohne Eye-Candy?
|
||||
if(myConfig->readConfigInt("ShowFlipCardsAnimation")) {
|
||||
// mit Eye-Candy
|
||||
|
||||
//TempArrays
|
||||
int tempCardsIntArray[2];
|
||||
|
||||
int j;
|
||||
|
||||
for (it_c=currentHand->getActivePlayerList()->begin(); it_c!=currentHand->getActivePlayerList()->end(); it_c++) {
|
||||
(*it_c)->getMyCards(tempCardsIntArray);
|
||||
if((*it_c)->getMyAction() != PLAYER_ACTION_FOLD) {
|
||||
if((*it_c)->getMyID() || ((*it_c)->getMyID()==0 && myConfig->readConfigInt("AntiPeekMode")) ) {
|
||||
for(j=0; j<2; j++) {
|
||||
// TODO
|
||||
//only some players need to show cards directly. if i dont kneed the show i get the button
|
||||
|
||||
|
||||
|
||||
if((*it_c)->getMyID() || ((*it_c)->getMyID()==0 && antiPeekMode) ) {
|
||||
for(j=0; j<2; j++) {
|
||||
|
||||
if(showFlipcardAnimation) { // with Eye-Candy
|
||||
holeCardsArray[(*it_c)->getMyID()][j]->startFlipCards(guiGameSpeed, QPixmap::fromImage(QImage(myCardDeckStyle->getCurrentDir()+QString::number(tempCardsIntArray[j], 10)+".png")), *flipside);
|
||||
}
|
||||
}
|
||||
//set Player value (logging)
|
||||
(*it_c)->setMyCardsFlip(1,1);
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
//without Eye-Candy
|
||||
|
||||
//Karten der aktiven Spieler umdrehen
|
||||
QPixmap onePix = QPixmap::fromImage(QImage(myAppDataPath +"gfx/gui/misc/1px.png"));
|
||||
|
||||
//TempArrays
|
||||
QPixmap tempCardsPixmapArray[2];
|
||||
int tempCardsIntArray[2];
|
||||
|
||||
int j;
|
||||
for (it_c=currentHand->getActivePlayerList()->begin(); it_c!=currentHand->getActivePlayerList()->end(); it_c++) {
|
||||
(*it_c)->getMyCards(tempCardsIntArray);
|
||||
if((*it_c)->getMyAction() != PLAYER_ACTION_FOLD) {
|
||||
if((*it_c)->getMyID() || ((*it_c)->getMyID()==0 && myConfig->readConfigInt("AntiPeekMode")) ) {
|
||||
for(j=0; j<2; j++) {
|
||||
else { //without Eye-Candy
|
||||
tempCardsPixmapArray[j] = QPixmap::fromImage(QImage(myCardDeckStyle->getCurrentDir()+QString::number(tempCardsIntArray[j], 10)+".png"));
|
||||
holeCardsArray[(*it_c)->getMyID()][j]->setPixmap(tempCardsPixmapArray[j], FALSE);
|
||||
|
||||
}
|
||||
}
|
||||
//set Player value (logging)
|
||||
(*it_c)->setMyCardsFlip(1,1);
|
||||
}
|
||||
//set Player value (logging)
|
||||
(*it_c)->setMyCardsFlip(1,1);
|
||||
|
||||
|
||||
|
||||
// TODO
|
||||
// showShowMyCardsButton();
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//Wenn einmal umgedreht dann fertig!!
|
||||
flipHolecardsAllInAlreadyDone = TRUE;
|
||||
}
|
||||
@@ -2097,28 +2086,6 @@ void gameTableImpl::postRiverRunAnimation2() {
|
||||
|
||||
}
|
||||
|
||||
// TODO
|
||||
void gameTableImpl::postRiverRunAnimation2_flipHoleCards1() {
|
||||
|
||||
HandInterface *currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
|
||||
currentHand->getCurrentBeRo()->setPlayersTurn(currentHand->getCurrentBeRo()->getLastActionPlayer());
|
||||
|
||||
postRiverRunAnimation2_flipHoleCards2Timer->start(nextPlayerSpeed2);
|
||||
}
|
||||
|
||||
|
||||
void gameTableImpl::postRiverRunAnimation2_flipHoleCards2() {
|
||||
|
||||
// if() {
|
||||
// postRiverRunAnimation2_flipHoleCards1Timer->start(nextPlayerSpeed2);
|
||||
// }
|
||||
// else {
|
||||
// postRiverRunAnimation2Timer->start(postRiverRunAnimationSpeed);
|
||||
// }
|
||||
}
|
||||
|
||||
|
||||
void gameTableImpl::postRiverRunAnimation3() {
|
||||
|
||||
HandInterface *currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
@@ -2347,6 +2314,36 @@ void gameTableImpl::postRiverRunAnimation6() {
|
||||
postRiverRunAnimation6Timer->start(newRoundSpeed);
|
||||
}
|
||||
|
||||
void gameTableImpl::postRiverShowCards(unsigned playerId)
|
||||
{
|
||||
HandInterface *currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
QPixmap onePix = QPixmap::fromImage(QImage(myAppDataPath +"gfx/gui/misc/1px.png"));
|
||||
//TempArrays
|
||||
QPixmap tempCardsPixmapArray[2];
|
||||
int tempCardsIntArray[2];
|
||||
int showFlipcardAnimation = myConfig->readConfigInt("ShowFlipCardsAnimation");
|
||||
int j;
|
||||
PlayerListConstIterator it_c;
|
||||
for (it_c=currentHand->getActivePlayerList()->begin(); it_c!=currentHand->getActivePlayerList()->end(); it_c++) {
|
||||
if((*it_c)->getMyUniqueID() == playerId) {
|
||||
|
||||
(*it_c)->getMyCards(tempCardsIntArray);
|
||||
for(j=0; j<2; j++) {
|
||||
|
||||
if(showFlipcardAnimation) { // with Eye-Candy
|
||||
holeCardsArray[(*it_c)->getMyID()][j]->startFlipCards(guiGameSpeed, QPixmap::fromImage(QImage(myCardDeckStyle->getCurrentDir()+QString::number(tempCardsIntArray[j], 10)+".png")), *flipside);
|
||||
}
|
||||
else { //without Eye-Candy
|
||||
tempCardsPixmapArray[j] = QPixmap::fromImage(QImage(myCardDeckStyle->getCurrentDir()+QString::number(tempCardsIntArray[j], 10)+".png"));
|
||||
holeCardsArray[(*it_c)->getMyID()][j]->setPixmap(tempCardsPixmapArray[j], FALSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
//set Player value (logging)
|
||||
(*it_c)->setMyCardsFlip(1,1);
|
||||
}
|
||||
}
|
||||
|
||||
void gameTableImpl::flipHolecardsAllIn() {
|
||||
|
||||
HandInterface *currentHand = myStartWindow->getSession()->getCurrentGame()->getCurrentHand();
|
||||
@@ -3008,7 +3005,7 @@ void gameTableImpl::showMaximized () {
|
||||
|
||||
void gameTableImpl::closeGameTable() {
|
||||
|
||||
if (myStartWindow->getMyServerGuiInterface() && myStartWindow->getMyServerGuiInterface()->getSession()->isNetworkServerRunning()) {
|
||||
if (myStartWindow->getMyServerGuiInterface() && myStartWindow->getMyServerGuiInterface()->getSession()->isNetworkServerRunning()) {
|
||||
|
||||
QMessageBox msgBox(QMessageBox::Warning, tr("Closing PokerTH during network game"),
|
||||
tr("You are the hosting server. Do you want to close PokerTH anyway?"), QMessageBox::Yes | QMessageBox::No, this);
|
||||
@@ -3016,7 +3013,7 @@ void gameTableImpl::closeGameTable() {
|
||||
if (msgBox.exec() == QMessageBox::Yes ) {
|
||||
myStartWindow->getSession()->terminateNetworkClient();
|
||||
stopTimer();
|
||||
if (myStartWindow->getMyServerGuiInterface()) myStartWindow->getMyServerGuiInterface()->getSession()->terminateNetworkServer();
|
||||
if (myStartWindow->getMyServerGuiInterface()) myStartWindow->getMyServerGuiInterface()->getSession()->terminateNetworkServer();
|
||||
saveGameTableGeometry();
|
||||
myStartWindow->show();
|
||||
this->hide();
|
||||
@@ -3442,7 +3439,7 @@ void gameTableImpl::registeredUserMode()
|
||||
|
||||
void gameTableImpl::guestUserMode()
|
||||
{
|
||||
lineEdit_ChatInput->setText(tr("Chat is only available to registered players."));
|
||||
lineEdit_ChatInput->setText(tr("Chat is only available to registered players."));
|
||||
lineEdit_ChatInput->setDisabled(true);
|
||||
guestMode = true;
|
||||
}
|
||||
|
||||
@@ -116,6 +116,7 @@ signals:
|
||||
void signalRiverAnimation2();
|
||||
void signalPostRiverAnimation1();
|
||||
void signalPostRiverRunAnimation1();
|
||||
void signalPostRiverShowCards(unsigned playerId);
|
||||
|
||||
void signalFlipHolecardsAllIn();
|
||||
|
||||
@@ -229,12 +230,11 @@ public slots:
|
||||
|
||||
void postRiverRunAnimation1();
|
||||
void postRiverRunAnimation2();
|
||||
void postRiverRunAnimation2_flipHoleCards1();
|
||||
void postRiverRunAnimation2_flipHoleCards2();
|
||||
void postRiverRunAnimation3();
|
||||
void postRiverRunAnimation4();
|
||||
void postRiverRunAnimation5();
|
||||
void postRiverRunAnimation6();
|
||||
void postRiverShowCards(unsigned playerId);
|
||||
|
||||
void refreshCardsChance(GameState);
|
||||
|
||||
|
||||
@@ -97,6 +97,7 @@ void GuiWrapper::riverAnimation2() { myW->signalRiverAnimation2(); }
|
||||
|
||||
void GuiWrapper::postRiverAnimation1() { myW->signalPostRiverAnimation1(); }
|
||||
void GuiWrapper::postRiverRunAnimation1() { myW->signalPostRiverRunAnimation1(); }
|
||||
void GuiWrapper::postRiverShowCards(unsigned playerId) { myW->signalPostRiverShowCards(playerId); }
|
||||
|
||||
void GuiWrapper::flipHolecardsAllIn() { myW->signalFlipHolecardsAllIn(); }
|
||||
|
||||
|
||||
@@ -85,6 +85,7 @@ public:
|
||||
|
||||
void postRiverAnimation1();
|
||||
void postRiverRunAnimation1();
|
||||
void postRiverShowCards(unsigned playerId);
|
||||
|
||||
void flipHolecardsAllIn();
|
||||
|
||||
|
||||
@@ -102,7 +102,7 @@
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="http://login.pokerth.biz/register.php"><span style=" text-decoration: underline; color:#0057ae;">Create new user account ...</span></a></p></body></html></string>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><a href="http://login.pokerth.biz"><span style=" text-decoration: underline; color:#0057ae;">Create new user account ...</span></a></p></body></html></string>
|
||||
</property>
|
||||
<property name="openExternalLinks">
|
||||
<bool>true</bool>
|
||||
|
||||
+2
-4
@@ -38,8 +38,6 @@
|
||||
|
||||
#define NET_DEFAULT_GAME "default"
|
||||
|
||||
//uncomment for 0.7 beta
|
||||
//#define POKERTH_IS_07BETA
|
||||
|
||||
using namespace std;
|
||||
|
||||
@@ -167,8 +165,8 @@ void Session::startInternetClient()
|
||||
|
||||
myNetClient->Init(
|
||||
myConfig->readConfigString("InternetServerAddress"),
|
||||
#ifdef POKERTH_IS_07BETA
|
||||
"pokerth.net/serverlist07.xml.z", 1,
|
||||
#ifdef POKERTH_IS_08BETA
|
||||
"pokerth.net/serverlist_testing.xml.z", 1,
|
||||
#else
|
||||
myConfig->readConfigString("InternetServerListAddress"),
|
||||
myConfig->readConfigInt("InternetServerConfigMode") == 0,
|
||||
|
||||
@@ -29,6 +29,10 @@
|
||||
#include "game_defs.h"
|
||||
#include <core/crypthelper.h>
|
||||
|
||||
//uncomment for 0.8 beta
|
||||
#define POKERTH_IS_08BETA
|
||||
|
||||
|
||||
class GuiInterface;
|
||||
class Game;
|
||||
class ConfigFile;
|
||||
|
||||
Reference in New Issue
Block a user