forked from External/mage
Convert SpellAbility keywords to costs tag system
This commit is contained in:
parent
f3d5faf199
commit
ad873863fa
6 changed files with 9 additions and 62 deletions
|
|
@ -19,9 +19,6 @@ import mage.constants.TimingRule;
|
|||
import mage.game.Game;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
|
|
@ -80,15 +77,7 @@ public class BlitzAbility extends SpellAbility {
|
|||
if (!super.activate(game, noMana)) {
|
||||
return false;
|
||||
}
|
||||
Object obj = game.getState().getValue(BLITZ_ACTIVATION_VALUE_KEY + getSourceId());
|
||||
List<Integer> blitzActivations;
|
||||
if (obj != null) {
|
||||
blitzActivations = (List<Integer>) obj;
|
||||
} else {
|
||||
blitzActivations = new ArrayList<>();
|
||||
game.getState().setValue(BLITZ_ACTIVATION_VALUE_KEY + getSourceId(), blitzActivations);
|
||||
}
|
||||
blitzActivations.add(game.getState().getZoneChangeCounter(getSourceId()));
|
||||
this.setCostsTag(BLITZ_ACTIVATION_VALUE_KEY, null);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue