SLD: the_fourteenth_doctor.txt + support

This commit is contained in:
Klisz
2023-12-05 14:02:12 -07:00
parent e48ab034e8
commit efd69b8153
2 changed files with 35 additions and 0 deletions

View File

@@ -152,6 +152,7 @@ public class CloneEffect extends SpellAbilityEffect {
if (!pumpKeywords.isEmpty()) { if (!pumpKeywords.isEmpty()) {
tgtCard.addChangedCardKeywords(pumpKeywords, Lists.newArrayList(), false, ts, 0); tgtCard.addChangedCardKeywords(pumpKeywords, Lists.newArrayList(), false, ts, 0);
addPumpUntil(sa, tgtCard, ts);
} }
tgtCard.updateStateForView(); tgtCard.updateStateForView();
@@ -202,4 +203,27 @@ public class CloneEffect extends SpellAbilityEffect {
} }
} }
protected void addPumpUntil(SpellAbility sa, final Card c, long timestamp) {
if (!sa.hasParam("PumpDuration")) {
return;
}
final String duration = sa.getParam("PumpDuration");
final Card host = sa.getHostCard();
final Game game = host.getGame();
final GameCommand untilEOT = new GameCommand() {
private static final long serialVersionUID = -42244224L;
@Override
public void run() {
c.removeChangedCardKeywords(timestamp, 0);
game.fireEvent(new GameEventCardStatsChanged(c));
}
};
if ("UntilYourNextTurn".equals(duration)) {
game.getCleanup().addUntil(sa.getActivatingPlayer(), untilEOT);
} else {
game.getEndOfTurn().addUntil(untilEOT);
}
}
} }

View File

@@ -0,0 +1,11 @@
Name:The Fourteenth Doctor
ManaCost:RG W U
Types:Legendary Creature Time Lord Doctor
PT:3/4
T:Mode$ SpellCast | ValidCard$ Card.Self | Execute$ TrigDig | TriggerDescription$ When you cast this spell, reveal the top fourteen cards of your library. Put all Doctor cards revealed this way into your graveyard and the rest on the bottom of your library in a random order.
SVar:TrigDig:DB$ Dig | DigNum$ 14 | Reveal$ True | ChangeNum$ All | ChangeValid$ Doctor | DestinationZone$ Graveyard | RestRandomOrder$ True
K:ETBReplacement:Copy:DBCopy:Optional
SVar:DBCopy:DB$ Clone | Choices$ Doctor.YouOwn+ThisTurnEnteredFrom_Library | ChoiceZone$ Graveyard | PumpKeywords$ Haste | PumpDuration$ EOT | SpellDescription$ You may have CARDNAME enter the battlefield as a copy of a Doctor card in your graveyard that was put there from your library this turn. If you do, it gains haste until end of turn.
DeckHas:Ability$Graveyard
DeckNeeds:Type$Doctor
Oracle:When you cast this spell, reveal the top fourteen cards of your library. Put all Doctor cards revealed this way into your graveyard and the rest on the bottom of your library in a random order.\nYou may have The Fourteenth Doctor enter the battlefield as a copy of a Doctor card in your graveyard that was put there from your library this turn. If you do, it gains haste until end of turn.