mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
[STX] fixed Double Major targeting spells not controlled by its controller (fixes #7824)
This commit is contained in:
parent
6ede79aa1f
commit
e9189f1d9d
1 changed files with 10 additions and 2 deletions
|
@ -7,7 +7,9 @@ import mage.cards.CardSetInfo;
|
|||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SuperType;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.constants.TargetController;
|
||||
import mage.filter.FilterSpell;
|
||||
import mage.filter.common.FilterCreatureSpell;
|
||||
import mage.filter.predicate.mageobject.MageObjectReferencePredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.stack.Spell;
|
||||
|
@ -22,12 +24,18 @@ import java.util.UUID;
|
|||
*/
|
||||
public final class DoubleMajor extends CardImpl {
|
||||
|
||||
private static final FilterSpell filter = new FilterCreatureSpell("creature spell you control");
|
||||
|
||||
static {
|
||||
filter.add(TargetController.YOU.getControllerPredicate());
|
||||
}
|
||||
|
||||
public DoubleMajor(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{G}{U}");
|
||||
|
||||
// Copy target creature spell you control, except it isn't legendary if the spell is legendary.
|
||||
this.getSpellAbility().addEffect(new DoubleMajorEffect());
|
||||
this.getSpellAbility().addTarget(new TargetSpell(StaticFilters.FILTER_SPELL_CREATURE));
|
||||
this.getSpellAbility().addTarget(new TargetSpell(filter));
|
||||
}
|
||||
|
||||
private DoubleMajor(final DoubleMajor card) {
|
||||
|
|
Loading…
Reference in a new issue