Revert connectSource changes from TapTargetEffect. Not needed anymore.

This commit is contained in:
LoneFox 2015-09-29 15:25:52 +03:00
parent 705bdabafb
commit ab0e4b0ddc
10 changed files with 10 additions and 28 deletions

View file

@ -68,7 +68,7 @@ public class WhipVine1 extends CardImpl {
// You may choose not to untap Whip Vine during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// {tap}: Tap target creature with flying blocked by Whip Vine. That creature doesn't untap during its controller's untap step for as long as Whip Vine remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying blocked by {this}");
filter.add(new AbilityPredicate(FlyingAbility.class));
filter.add(new BlockedByIdPredicate(this.getId()));

View file

@ -57,7 +57,7 @@ public class PhyrexianGremlins extends CardImpl {
// You may choose not to untap Phyrexian Gremlins during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// {tap}: Tap target artifact. It doesn't untap during its controller's untap step for as long as Phyrexian Gremlins remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
ability.addTarget(new TargetArtifactPermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());
this.addAbility(ability);

View file

@ -57,7 +57,7 @@ public class MoleWorms extends CardImpl {
// You may choose not to untap Mole Worms during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// {tap}: Tap target land. It doesn't untap during its controller's untap step for as long as Mole Worms remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
ability.addTarget(new TargetLandPermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());
this.addAbility(ability);

View file

@ -55,7 +55,7 @@ public class DesertersQuarters extends CardImpl {
this.addAbility(new SkipUntapOptionalAbility());
// {6}, T: Tap target creature. It doesn't untap during its controller's untap step for as long as Deserter's Quarters remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new GenericManaCost(6));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new GenericManaCost(6));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());

View file

@ -61,7 +61,7 @@ public class SandSquid extends CardImpl {
// You may choose not to untap Sand Squid during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// {tap}: Tap target creature. That creature doesn't untap during its controller's untap step for as long as Sand Squid remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());
this.addAbility(ability);

View file

@ -67,7 +67,7 @@ public class AmberPrison extends CardImpl {
this.addAbility(new SkipUntapOptionalAbility());
// {4}, {tap}: Tap target artifact, creature, or land. That permanent doesn't untap during its controller's untap step for as long as Amber Prison remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new GenericManaCost(4));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new GenericManaCost(4));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetPermanent(filter));
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());

View file

@ -59,7 +59,7 @@ public class RustTick extends CardImpl {
this.addAbility(new SkipUntapOptionalAbility());
// {1}, {tap}: Tap target artifact. It doesn't untap during its controller's untap step for as long as Rust Tick remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new GenericManaCost(1));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new GenericManaCost(1));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetArtifactPermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());

View file

@ -59,7 +59,7 @@ public class ThalakosDreamsower extends CardImpl {
// You may choose not to untap Thalakos Dreamsower during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// Whenever Thalakos Dreamsower deals damage to an opponent, tap target creature. That creature doesn't untap during its controller's untap step for as long as Thalakos Dreamsower remains tapped.
Ability ability = new DealsDamageToOpponentTriggeredAbility(new TapTargetEffect(true), false);
Ability ability = new DealsDamageToOpponentTriggeredAbility(new TapTargetEffect(), false);
ability.addTarget(new TargetCreaturePermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());
this.addAbility(ability);

View file

@ -57,7 +57,7 @@ public class ManaLeech extends CardImpl {
// You may choose not to untap Mana Leech during your untap step.
this.addAbility(new SkipUntapOptionalAbility());
// {tap}: Tap target land. It doesn't untap during its controller's untap step for as long as Mana Leech remains tapped.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(true), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new TapSourceCost());
ability.addTarget(new TargetLandPermanent());
ability.addEffect(new DontUntapAsLongAsSourceTappedEffect());
this.addAbility(ability);

View file

@ -43,23 +43,12 @@ import mage.util.CardUtil;
*/
public class TapTargetEffect extends OneShotEffect {
private final boolean connectSource;
public TapTargetEffect() {
this(null, false);
}
public TapTargetEffect(boolean connectSource) {
this(null, connectSource);
super(Outcome.Tap);
}
public TapTargetEffect(String text) {
this(text, false);
}
public TapTargetEffect(String text, boolean connectSource) {
super(Outcome.Tap);
this.connectSource = connectSource;
if(text != null) {
this.staticText = text;
}
@ -67,7 +56,6 @@ public class TapTargetEffect extends OneShotEffect {
public TapTargetEffect(final TapTargetEffect effect) {
super(effect);
this.connectSource = effect.connectSource;
}
@Override
@ -81,12 +69,6 @@ public class TapTargetEffect extends OneShotEffect {
Permanent permanent = game.getPermanent(target);
if (permanent != null) {
permanent.tap(game);
if(connectSource) {
Permanent sourcePermanent = game.getPermanent(source.getSourceId());
if(sourcePermanent != null) {
sourcePermanent.addConnectedCard(sourcePermanent.getName(), permanent.getId());
}
}
}
}
return true;