[ONE] Implement Vat of Rebirth

This commit is contained in:
theelk801 2023-01-29 15:42:07 -05:00
parent 33610d8017
commit 8d33fe02a7
2 changed files with 53 additions and 0 deletions

View file

@ -0,0 +1,52 @@
package mage.cards.v;
import mage.abilities.Ability;
import mage.abilities.common.ActivateAsSorceryActivatedAbility;
import mage.abilities.common.PutIntoGraveFromBattlefieldAllTriggeredAbility;
import mage.abilities.costs.common.RemoveCountersSourceCost;
import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect;
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.counters.CounterType;
import mage.filter.StaticFilters;
import mage.target.common.TargetCardInYourGraveyard;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class VatOfRebirth extends CardImpl {
public VatOfRebirth(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{B}");
// Whenever another artifact or creature you control is put into a graveyard from the battlefield, put an oil counter on Vat of Rebirth.
this.addAbility(new PutIntoGraveFromBattlefieldAllTriggeredAbility(
new AddCountersSourceEffect(CounterType.OIL.createInstance()), false,
StaticFilters.FILTER_CONTROLLED_ANOTHER_ARTIFACT_OR_CREATURE, false
));
// {2}{B}, {T}, Remove four oil counters from Vat of Rebirth: Return target creature card from your graveyard to the battlefield. Activate only as a sorcery.
Ability ability = new ActivateAsSorceryActivatedAbility(
new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl<>("{2}{B}")
);
ability.addCost(new TapSourceCost());
ability.addCost(new RemoveCountersSourceCost(CounterType.OIL.createInstance(4)));
ability.addTarget(new TargetCardInYourGraveyard(StaticFilters.FILTER_CARD_CREATURE_YOUR_GRAVEYARD));
this.addAbility(ability);
}
private VatOfRebirth(final VatOfRebirth card) {
super(card);
}
@Override
public VatOfRebirth copy() {
return new VatOfRebirth(this);
}
}

View file

@ -216,6 +216,7 @@ public final class PhyrexiaAllWillBeOne extends ExpansionSet {
cards.add(new SetCardInfo("Urabrask's Forge", 153, Rarity.RARE, mage.cards.u.UrabrasksForge.class));
cards.add(new SetCardInfo("Vanish into Eternity", 36, Rarity.COMMON, mage.cards.v.VanishIntoEternity.class));
cards.add(new SetCardInfo("Vat Emergence", 112, Rarity.UNCOMMON, mage.cards.v.VatEmergence.class));
cards.add(new SetCardInfo("Vat of Rebirth", 113, Rarity.UNCOMMON, mage.cards.v.VatOfRebirth.class));
cards.add(new SetCardInfo("Veil of Assimilation", 37, Rarity.UNCOMMON, mage.cards.v.VeilOfAssimilation.class));
cards.add(new SetCardInfo("Venerated Rotpriest", 192, Rarity.RARE, mage.cards.v.VeneratedRotpriest.class));
cards.add(new SetCardInfo("Venomous Brutalizer", 193, Rarity.UNCOMMON, mage.cards.v.VenomousBrutalizer.class));