Whenever CARDNAME becomes tapped
The new code based on the City of Brass caught my attention.
I added the following card:
and it works. The code above places this ability on the stack along with the message and we have to click OK to continue. It is not automatic.
I reduced the code to this:
and this version no longer includes the stack. Hmm, how does this card play in real life? Before I add this card I would like to know which of the two code versions above are rules compliant.
I added the following card:- Code: Select all
Fallowsage
3 U
Creature Merfolk Wizard
Whenever Fallowsage becomes tapped, you may draw a card.
2/2
- Code: Select all
if (c.getName().equals("Fallowsage")) {
final String player = c.getController();
Ability ability = new Ability(c, "0") {
@Override
public void resolve() {
AllZone.GameAction.drawCard(player);
}
};// Ability
ability.setStackDescription("Fallowsage - draw a card");
AllZone.Stack.add(ability);
}//end Fallowsage
and it works. The code above places this ability on the stack along with the message and we have to click OK to continue. It is not automatic.
I reduced the code to this:
- Code: Select all
if (c.getName().equals("Fallowsage")) {
final String player = c.getController();
AllZone.GameAction.drawCard(player);
}//end Fallowsage
and this version no longer includes the stack. Hmm, how does this card play in real life? Before I add this card I would like to know which of the two code versions above are rules compliant.