mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-10 16:24:45 -07:00
Reveal top x cards
Updated reveal top card to reveal top x cards Sometimes you want to reveal more than only the top 1 card.
This commit is contained in:
parent
9ff22eaf17
commit
59c0834427
3 changed files with 23 additions and 4 deletions
|
|
@ -515,8 +515,19 @@ void Player::playerListActionTriggered()
|
|||
if (menu == mRevealLibrary) {
|
||||
cmd.set_zone_name("deck");
|
||||
} else if (menu == mRevealTopCard) {
|
||||
cmd.set_zone_name("deck");
|
||||
cmd.set_card_id(0);
|
||||
bool ok;
|
||||
int number =
|
||||
#if QT_VERSION < 0x050000
|
||||
QInputDialog::getInteger(
|
||||
#else
|
||||
QInputDialog::getInt(
|
||||
#endif
|
||||
0, tr("Reveal top cards of library"), tr("Number of cards:"), defaultNumberTopCards, 1, 2000000000, 1, &ok);
|
||||
if (ok) {
|
||||
cmd.set_zone_name("deck");
|
||||
cmd.set_top_cards(number);
|
||||
}
|
||||
|
||||
} else if (menu == mRevealHand)
|
||||
cmd.set_zone_name("hand");
|
||||
else if (menu == mRevealRandomHandCard) {
|
||||
|
|
@ -624,7 +635,7 @@ void Player::retranslateUi()
|
|||
aViewLibrary->setText(tr("&View library"));
|
||||
aViewTopCards->setText(tr("View &top cards of library..."));
|
||||
mRevealLibrary->setTitle(tr("Reveal &library to..."));
|
||||
mRevealTopCard->setTitle(tr("Reveal t&op card to..."));
|
||||
mRevealTopCard->setTitle(tr("Reveal t&op cards to..."));
|
||||
aAlwaysRevealTopCard->setText(tr("&Always reveal top card"));
|
||||
aOpenDeckInDeckEditor->setText(tr("O&pen deck in deck editor"));
|
||||
aViewSideboard->setText(tr("&View sideboard"));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue