mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-09-29 09:22:18 -07:00
Adjust to rebase.
Took 28 minutes Took 7 seconds Took 2 minutes Took 8 minutes Took 13 seconds
This commit is contained in:
parent
6ea68c3f58
commit
0b7a323adf
16 changed files with 48 additions and 45 deletions
|
|
@ -7,7 +7,6 @@
|
|||
#include "../../game_graphics/zones/table_zone.h"
|
||||
#include "../../interface/widgets/tabs/tab_game.h"
|
||||
#include "../../interface/widgets/utility/get_text_with_max.h"
|
||||
|
||||
#include "../zones/view_zone_logic.h"
|
||||
|
||||
#include <libcockatrice/card/database/card_database_manager.h>
|
||||
|
|
@ -1635,14 +1634,13 @@ static bool isUnwritableRevealZone(CardZoneLogic *zone)
|
|||
|
||||
void PlayerActions::playSelectedCards(QList<CardItem *> selectedCards, const bool faceDown)
|
||||
{
|
||||
playSelectedCardsImpl(faceDown, nullptr);
|
||||
playSelectedCardsImpl(selectedCards, faceDown, nullptr);
|
||||
}
|
||||
|
||||
void PlayerActions::playSelectedCardsImpl(bool faceDown,
|
||||
void PlayerActions::playSelectedCardsImpl(QList<CardItem *> selectedCards,
|
||||
bool faceDown,
|
||||
const std::function<void(CardItem *, const QString &)> &postPlayCallback)
|
||||
{
|
||||
QList<CardItem *> selectedCards = player->getGameScene()->selectedCards();
|
||||
|
||||
// CardIds will get shuffled downwards when cards leave the deck.
|
||||
// We need to iterate through the cards in reverse order so cardIds don't get changed out from under us as we play
|
||||
// out the cards one-by-one.
|
||||
|
|
@ -1660,9 +1658,9 @@ void PlayerActions::playSelectedCardsImpl(bool faceDown,
|
|||
}
|
||||
}
|
||||
|
||||
void PlayerActions::actPlayAndIncreaseTax()
|
||||
void PlayerActions::actPlayAndIncreaseTax(QList<CardItem *> selectedCards)
|
||||
{
|
||||
playSelectedCardsImpl(false, [this](CardItem * /*card*/, const QString &originalZone) {
|
||||
playSelectedCardsImpl(selectedCards, false, [this](CardItem * /*card*/, const QString &originalZone) {
|
||||
if (originalZone == ZoneNames::COMMAND) {
|
||||
AbstractCounter *ctr = player->getCounterWidget(CounterIds::CommanderTax);
|
||||
if (ctr && ctr->isActive()) {
|
||||
|
|
@ -1672,9 +1670,9 @@ void PlayerActions::actPlayAndIncreaseTax()
|
|||
});
|
||||
}
|
||||
|
||||
void PlayerActions::actPlayAndIncreasePartnerTax()
|
||||
void PlayerActions::actPlayAndIncreasePartnerTax(QList<CardItem *> selectedCards)
|
||||
{
|
||||
playSelectedCardsImpl(false, [this](CardItem * /*card*/, const QString &originalZone) {
|
||||
playSelectedCardsImpl(selectedCards, false, [this](CardItem * /*card*/, const QString &originalZone) {
|
||||
if (originalZone == ZoneNames::COMMAND) {
|
||||
AbstractCounter *ctr = player->getCounterWidget(CounterIds::PartnerTax);
|
||||
if (ctr && ctr->isActive()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue