Added/fixed primitives from NEC set, added new keyword "modified" to target creatures that are enchanted or geared or with counters, updated missing card by set list.

This commit is contained in:
Vittorio Alfieri
2023-06-09 22:45:08 +02:00
parent 2831ac12ae
commit 0f607b2cbe
9 changed files with 131 additions and 111 deletions

View File

@@ -89,6 +89,11 @@ void CardDescriptor::unsecureSetHasBackSide(int k)
hasBackSide = k;
}
void CardDescriptor::unsecureSetModified(int k)
{
modified = k;
}
void CardDescriptor::unsecureSetHasPartner(int k)
{
hasPartner = k;
@@ -341,6 +346,11 @@ MTGCardInstance * CardDescriptor::match(MTGCardInstance * card)
}
}
if ((modified == -1 && ((card->enchanted) || (card->equipment > 0) || (card->counters->mCount))) || (modified == 1 && !((card->enchanted) || (card->equipment > 0) || (card->counters->mCount))))
{
match = NULL;
}
if ((hasKickerCost == -1 && ((card->getManaCost()->getKicker() && !card->basicAbilities[Constants::HASNOKICKER]) || (!card->getManaCost()->getKicker() && card->basicAbilities[Constants::HASOTHERKICKER]))) || (hasKickerCost == 1 && !((card->getManaCost()->getKicker() && !card->basicAbilities[Constants::HASNOKICKER]) || (!card->getManaCost()->getKicker() && card->basicAbilities[Constants::HASOTHERKICKER]))))
{
match = NULL; //Some kicker costs are not a real kicker (e.g. Fuse cost).