This commit is contained in:
Max-Wilhelm Bruker 2009-04-04 01:54:20 +02:00
parent 16631712c7
commit 46f91f69c4
4 changed files with 17 additions and 12 deletions

View file

@ -250,7 +250,8 @@ void Game::actSetLife()
{
bool ok;
int life = QInputDialog::getInteger(0, tr("Set life"), tr("New life total:"), localPlayer->getCounters()->findCounter("life")->getValue(), 0, 2000000000, 1, &ok);
client->setCounter("life", life);
if (ok)
client->setCounter("life", life);
}
void Game::actShuffle()
@ -281,10 +282,7 @@ void Game::actDrawCards()
void Game::actCreateToken()
{
QString cardname = QInputDialog::getText(0, tr("Create token"), tr("Name:"));
if (!db->getCard(cardname))
QMessageBox::critical(0, "Error", "No such card");
else
client->createToken("table", cardname, QString(), 0, 0);
client->createToken("table", cardname, QString(), 0, 0);
}
void Game::showCardMenu(QPoint p)