mirror of
https://github.com/magefree/mage.git
synced 2026-01-25 04:39:18 -08:00
Cleaned up unneeded imports for Goblin Wizard.
Added Magewright's Stone.
Modified AbilityPredicate to allow for Magewright's stone to search specifically for creatures containing {T} in their mana cost.
This commit is contained in:
parent
f16bd0bd0b
commit
0189d64361
3 changed files with 91 additions and 17 deletions
|
|
@ -30,6 +30,10 @@ package mage.filter.predicate.mageobject;
|
|||
import mage.MageObject;
|
||||
import mage.abilities.Abilities;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.Cost;
|
||||
import mage.abilities.costs.common.DiscardCardCost;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.cards.Card;
|
||||
import mage.filter.predicate.Predicate;
|
||||
import mage.game.Game;
|
||||
|
|
@ -57,7 +61,18 @@ public class AbilityPredicate implements Predicate<MageObject> {
|
|||
|
||||
for (Ability ability : abilities) {
|
||||
if (abilityClass.equals(ability.getClass())) {
|
||||
return true;
|
||||
//Burseg Hack: Magewright's Stone [DIS] specifically looks for activated ability containing {T}
|
||||
//As of 9/13/2015, no other AbilityPredicate is filtering for SimpleActivatedAbility
|
||||
if (abilityClass.equals(SimpleActivatedAbility.class) && ability.getCosts().size() > 0){
|
||||
for (Cost cost : ability.getCosts()) {
|
||||
if (cost instanceof TapSourceCost) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue