added functionality to may and choice ability so that it can check a "restriction{}" like a activated ability with cost, that can keep a menu option from appearing if the restriction is not met

auto=choice damage:1 target(creature) restriction{type(creature[blue])~morethan~1}

this choice menu will only appear is there is more than one blue creature inplay
This commit is contained in:
omegablast2002@yahoo.com
2013-01-28 03:49:24 +00:00
parent a32a58f621
commit 2b9cae8950
3 changed files with 20 additions and 4 deletions

View File

@@ -1074,11 +1074,12 @@ class MayAbility: public MTGAbility, public NestedAbility
public:
int triggered;
bool must;
string Cond;
Player * previousInterrupter;
MTGAbility * mClone;
ManaCost * optionalCost;
MayAbility(GameObserver* observer, int _id, MTGAbility * _ability, MTGCardInstance * _source, bool must = false);
MayAbility(GameObserver* observer, int _id, MTGAbility * _ability, MTGCardInstance * _source, bool must = false, string restriction = "");
void Update(float dt);