[Refactor] Retype card containers and zone logic onto CardState

This commit is contained in:
Lukas Brübach 2026-10-07 09:27:34 +02:00 • committed by GitHub
parent 893aeb7bae
commit f321132cce
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
32 changed files with 184 additions and 158 deletions

View file

@ -45,7 +45,7 @@ public:
static int tableRowToGridY(int tableRow);
protected:
void addCardImpl(CardItem *card, int x, int y) override;
void addCardImpl(CardState *card, int x, int y) override;
/**
* @brief Removes a card from view.
@ -53,9 +53,9 @@ protected:
* @param position card position
* @param cardId id of card to take
* @param toNewZone Whether the destination of the card is not the same as the starting zone. Defaults to true
* @return CardItem that has been removed
* @return CardState that has been removed
*/
CardItem *takeCard(int position, int cardId, bool toNewZone = true) override;
CardState *takeCard(int position, int cardId, bool toNewZone = true) override;
};
#endif // COCKATRICE_TABLE_ZONE_LOGIC_H