add some cards

also added countb() - countedbamount..
This commit is contained in:
Anthony Calosa
2017-03-19 21:57:59 +08:00
parent fa69686f0a
commit eb8370b86b
9 changed files with 91 additions and 23 deletions

View File

@@ -5209,6 +5209,30 @@ AACountObject * AACountObject::clone() const
{
return NEW AACountObject(*this);
}
//count objects on field before doing an effect
AACountObjectB::AACountObjectB(GameObserver* observer, int id, MTGCardInstance * card, MTGCardInstance *, ManaCost * _cost, string value) :
ActivatedAbility(observer, id, card, _cost, 0), value(value)
{
}
int AACountObjectB::resolve()
{
if (source)
{
int amount = 0;
WParsedInt * use = NEW WParsedInt(value, NULL, source);
amount = use->getValue();
source->CountedObjectsB = amount;
SAFE_DELETE(use);
}
return 1;
}
AACountObjectB * AACountObjectB::clone() const
{
return NEW AACountObjectB(*this);
}
// Win Game
AAWinGame::AAWinGame(GameObserver* observer, int _id, MTGCardInstance * card, Targetable * _target, ManaCost * _cost, int who) :