mirror of
https://github.com/correl/mage.git
synced 2025-01-12 19:25:44 +00:00
- Fixed #6821
This commit is contained in:
parent
bb453de525
commit
4c34210d64
1 changed files with 5 additions and 9 deletions
|
@ -6,7 +6,6 @@ import mage.abilities.Ability;
|
|||
import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility;
|
||||
import mage.abilities.dynamicvalue.common.CardsInControllerGraveyardCount;
|
||||
import mage.abilities.dynamicvalue.common.StaticValue;
|
||||
import mage.abilities.effects.ContinuousEffect;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.SacrificeTargetEffect;
|
||||
|
@ -33,6 +32,10 @@ public class Soulshriek extends CardImpl {
|
|||
|
||||
// Target creature you control gets +X/+0 until end of turn, where X is the number
|
||||
// of creature cards in your graveyard. Sacrifice that creature at the beginning of the next end step.
|
||||
CardsInControllerGraveyardCount count = new CardsInControllerGraveyardCount(StaticFilters.FILTER_CARD_CREATURES_YOUR_GRAVEYARD);
|
||||
Effect effect = new BoostTargetEffect(count, StaticValue.get(0), Duration.EndOfTurn, true);
|
||||
effect.setText("Target creature you control gets +X/+0 until end of turn, where X is the number of creature cards in your graveyard.");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addEffect(new SoulshriekEffect());
|
||||
this.getSpellAbility().addTarget(new TargetControlledCreaturePermanent());
|
||||
}
|
||||
|
@ -51,9 +54,7 @@ class SoulshriekEffect extends OneShotEffect {
|
|||
|
||||
public SoulshriekEffect() {
|
||||
super(Outcome.Detriment);
|
||||
this.staticText = "Target creature you control gets +X/+0 until end of turn, "
|
||||
+ "where X is the number of creature cards in your graveyard. "
|
||||
+ "Sacrifice that creature at the beginning of the next end step";
|
||||
this.staticText = "Sacrifice that creature at the beginning of the next end step";
|
||||
}
|
||||
|
||||
public SoulshriekEffect(final SoulshriekEffect effect) {
|
||||
|
@ -69,11 +70,6 @@ class SoulshriekEffect extends OneShotEffect {
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Permanent permanent = game.getPermanent(source.getFirstTarget());
|
||||
if (permanent != null) {
|
||||
ContinuousEffect boost = new BoostTargetEffect(
|
||||
new CardsInControllerGraveyardCount(StaticFilters.FILTER_CARD_CREATURE),
|
||||
StaticValue.get(0), Duration.EndOfTurn);
|
||||
boost.setTargetPointer(new FixedTarget(permanent, game));
|
||||
game.addEffect(boost, source);
|
||||
Effect sacrifice = new SacrificeTargetEffect("Sacrifice that creature "
|
||||
+ "at the beginning of the next end step", source.getControllerId());
|
||||
sacrifice.setTargetPointer(new FixedTarget(permanent, game));
|
||||
|
|
Loading…
Reference in a new issue