Using correct CantBeBlockedTargetEffect to implement Touch of Invisibility.

This commit is contained in:
LevelX2 2014-01-02 12:55:41 +01:00
parent 383bc47ffd
commit dc8380ce44

View file

@ -29,8 +29,7 @@ package mage.sets.odyssey;
import java.util.UUID; import java.util.UUID;
import mage.abilities.effects.common.DrawCardControllerEffect; import mage.abilities.effects.common.DrawCardControllerEffect;
import mage.abilities.effects.common.continious.GainAbilityTargetEffect; import mage.abilities.effects.common.combat.CantBeBlockedTargetEffect;
import mage.abilities.keyword.UnblockableAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Duration; import mage.constants.Duration;
@ -50,10 +49,9 @@ public class TouchOfInvisibility extends CardImpl<TouchOfInvisibility> {
this.color.setBlue(true); this.color.setBlue(true);
// Target creature is unblockable this turn. // Target creature is unblockable this turn.
this.getSpellAbility().addEffect(new GainAbilityTargetEffect(new UnblockableAbility(), Duration.EndOfTurn)); this.getSpellAbility().addEffect(new CantBeBlockedTargetEffect(Duration.EndOfTurn));
this.getSpellAbility().addTarget(new TargetCreaturePermanent(true)); this.getSpellAbility().addTarget(new TargetCreaturePermanent(true));
//
// Draw a card. // Draw a card.
this.getSpellAbility().addEffect(new DrawCardControllerEffect(1)); this.getSpellAbility().addEffect(new DrawCardControllerEffect(1));
} }