Refactor: fix raw use of parameterized class ManaCostsImpl - 'O' cards (#9080)

This commit is contained in:
DeepCrimson 2022-06-12 10:34:47 -07:00 committed by GitHub
parent 22a64d4f1d
commit 5f744fe89c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
58 changed files with 71 additions and 71 deletions

View file

@ -35,7 +35,7 @@ public final class OashraCultivator extends CardImpl {
// {2}{G}, {T}, Sacrifice Oashra Cultivator: Search your library for a basic land card, put it onto the battlefield tapped, then shuffle your library.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(StaticFilters.FILTER_CARD_BASIC_LAND), true),
new ManaCostsImpl("{2}{G}"));
new ManaCostsImpl<>("{2}{G}"));
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);

View file

@ -37,7 +37,7 @@ public final class OathOfLimDul extends CardImpl {
this.addAbility(new OathOfLimDulTriggeredAbility());
// {B}{B}: Draw a card.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{B}{B}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl<>("{B}{B}")));
}

View file

@ -28,25 +28,25 @@ public final class ObeliskOfAlara extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{6}");
// {1}{W}, {tap}: You gain 5 life.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(5), new ManaCostsImpl("{1}{W}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(5), new ManaCostsImpl<>("{1}{W}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
// {1}{U}, {tap}: Draw a card, then discard a card.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawDiscardControllerEffect(), new ManaCostsImpl("{1}{U}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawDiscardControllerEffect(), new ManaCostsImpl<>("{1}{U}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
// {1}{B}, {tap}: Target creature gets -2/-2 until end of turn.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(-2, -2, Duration.EndOfTurn), new ManaCostsImpl("{1}{B}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(-2, -2, Duration.EndOfTurn), new ManaCostsImpl<>("{1}{B}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
// {1}{R}, {tap}: Obelisk of Alara deals 3 damage to target player.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(3), new ManaCostsImpl("{1}{R}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(3), new ManaCostsImpl<>("{1}{R}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetPlayerOrPlaneswalker());
this.addAbility(ability);
// {1}{G}, {tap}: Target creature gets +4/+4 until end of turn.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(4, 4, Duration.EndOfTurn), new ManaCostsImpl("{1}{G}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(4, 4, Duration.EndOfTurn), new ManaCostsImpl<>("{1}{G}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);

View file

@ -32,7 +32,7 @@ public final class ObeliskOfUndoing extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{1}");
// {6}, {tap}: Return target permanent you both own and control to your hand.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl("{6}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl<>("{6}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetControlledPermanent(filter));
this.addAbility(ability);

View file

@ -36,7 +36,7 @@ public final class ObscuringAether extends CardImpl {
// {1}{G}: Turn Obscuring Aether face down.
Effect effect = new BecomesFaceDownCreatureEffect(Duration.Custom, BecomesFaceDownCreatureEffect.FaceDownType.MANUAL);
effect.setText("Turn {this} face down. <i>(It becomes a 2/2 creature.)</i>");
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{1}{G}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl<>("{1}{G}")));
}

View file

@ -23,7 +23,7 @@ public final class ObsessiveSearch extends CardImpl {
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1));
// Madness {U}
this.addAbility(new MadnessAbility(new ManaCostsImpl("{U}")));
this.addAbility(new MadnessAbility(new ManaCostsImpl<>("{U}")));
}
private ObsessiveSearch(final ObsessiveSearch card) {

View file

@ -35,7 +35,7 @@ public final class ObsessiveStitcher extends CardImpl {
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawDiscardControllerEffect(), new TapSourceCost()));
// {2}{U}{B}, {T}, Sacrifice Obsessive Stitcher: Return target creature card from your graveyard to the battlefield.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl("{2}{U}{B}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl<>("{2}{U}{B}"));
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
ability.addTarget(new TargetCardInYourGraveyard(StaticFilters.FILTER_CARD_CREATURE_YOUR_GRAVEYARD));

View file

@ -34,7 +34,7 @@ public final class ObsidianAcolyte extends CardImpl {
this.addAbility(ProtectionAbility.from(ObjectColor.BLACK));
// {W}: Target creature gains protection from black until end of turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new GainAbilityTargetEffect(ProtectionAbility.from(ObjectColor.BLACK), Duration.EndOfTurn), new ManaCostsImpl("{W}"));
new GainAbilityTargetEffect(ProtectionAbility.from(ObjectColor.BLACK), Duration.EndOfTurn), new ManaCostsImpl<>("{W}"));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);

View file

@ -55,7 +55,7 @@ public final class ObsidianFireheart extends CardImpl {
// after Obsidian Fireheart has left the battlefield.)
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new AddCountersTargetEffect(CounterType.BLAZE.createInstance()),
new ManaCostsImpl("{1}{R}{R}"));
new ManaCostsImpl<>("{1}{R}{R}"));
ability.addTarget(new TargetLandPermanent(filter));
OneShotEffect effect = new ObsidianFireheartOneShotEffect();
effect.setText(rule);

View file

@ -34,7 +34,7 @@ public final class Occupation extends CardImpl {
// {W}{B}: Target creature can't attack or block this turn, and its activated abilities can't be activated until end of turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new OccupationOneShotEffect("Target creature can't attack or block this turn, and its activated abilities can't be activated until end of turn"),
new ManaCostsImpl("{W}{B}"));
new ManaCostsImpl<>("{W}{B}"));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
}

View file

@ -46,7 +46,7 @@ public final class OcularHalo extends CardImpl {
// {W}: Enchanted creature gains vigilance until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(VigilanceAbility.getInstance(),
AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl("{W}")));
AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl<>("{W}")));
}
private OcularHalo(final OcularHalo card) {

View file

@ -25,7 +25,7 @@ public final class OdiousTrow extends CardImpl {
this.power = new MageInt(1);
this.toughness = new MageInt(1);
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{1}{B/G}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl<>("{1}{B/G}")));
}
private OdiousTrow(final OdiousTrow card) {

View file

@ -41,7 +41,7 @@ public final class OdunosRiverTrawler extends CardImpl {
ability.addTarget(new TargetCardInYourGraveyard(filter));
this.addAbility(ability);
// {W}, Sacrifice Odunos River Trawler: Return target enchantment creature card from your graveyard to your hand.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToHandTargetEffect(), new ManaCostsImpl("{W}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToHandTargetEffect(), new ManaCostsImpl<>("{W}"));
ability.addTarget(new TargetCardInYourGraveyard(filter));
this.addAbility(ability);
}

View file

@ -31,7 +31,7 @@ public final class OgreMenial extends CardImpl {
this.addAbility(InfectAbility.getInstance());
// {R}: Ogre Menial gets +1/+0 until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{R}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl<>("{R}")));
}
private OgreMenial(final OgreMenial card) {

View file

@ -37,7 +37,7 @@ public final class OgreSiegebreaker extends CardImpl {
this.toughness = new MageInt(3);
// {2}{B}{R}: Destroy target creature that was dealt damage this turn.
Ability ability = new SimpleActivatedAbility(new DestroyTargetEffect(), new ManaCostsImpl("{2}{B}{R}"));
Ability ability = new SimpleActivatedAbility(new DestroyTargetEffect(), new ManaCostsImpl<>("{2}{B}{R}"));
ability.addTarget(new TargetPermanent(filter));
this.addAbility(ability);
}

View file

@ -39,7 +39,7 @@ public final class OhranYeti extends CardImpl {
// {2}{S}: Target snow creature gains first strike until end of turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(
FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{2}{S}"));
FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{2}{S}"));
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);
}

View file

@ -28,7 +28,7 @@ public final class OjutaiInterceptor extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// Megamorph {3}{U}
this.addAbility(new MorphAbility(new ManaCostsImpl("{3}{U}"), true));
this.addAbility(new MorphAbility(new ManaCostsImpl<>("{3}{U}"), true));
}

View file

@ -32,7 +32,7 @@ public final class OjutaiMonument extends CardImpl {
// {4}{W}{U}: Ojutai Monument becomes a 4/4 white and blue Dragon artifact creature with flying until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesCreatureSourceEffect
(new OjutaiMonumentToken(), "", Duration.EndOfTurn), new ManaCostsImpl("{4}{W}{U}")));
(new OjutaiMonumentToken(), "", Duration.EndOfTurn), new ManaCostsImpl<>("{4}{W}{U}")));
}
private OjutaiMonument(final OjutaiMonument card) {

View file

@ -44,7 +44,7 @@ public final class OketraTheTrue extends CardImpl {
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OketraTheTrueRestrictionEffect()));
// {3}{W}: Create a 1/1 white Warrior creature token with vigilance.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new WarriorVigilantToken()), new ManaCostsImpl("{3}{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new WarriorVigilantToken()), new ManaCostsImpl<>("{3}{W}")));
}
private OketraTheTrue(final OketraTheTrue card) {

View file

@ -30,10 +30,10 @@ public final class OketrasAttendant extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// Cycling {2}
this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}")));
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}")));
// Embalm {3}{W}{W}
this.addAbility(new EmbalmAbility(new ManaCostsImpl("{3}{W}{W}"), this));
this.addAbility(new EmbalmAbility(new ManaCostsImpl<>("{3}{W}{W}"), this));
}

View file

@ -36,7 +36,7 @@ public final class OldFogey extends CardImpl {
// Phasing
this.addAbility(PhasingAbility.getInstance());
// Cumulative upkeep {1}
this.addAbility(new CumulativeUpkeepAbility(new ManaCostsImpl("{1}")));
this.addAbility(new CumulativeUpkeepAbility(new ManaCostsImpl<>("{1}")));
// Echo {G}{G}
this.addAbility(new EchoAbility("{G}{G}"));
// Fading 3

View file

@ -45,7 +45,7 @@ public final class OliviasBloodsworn extends CardImpl {
this.addAbility(new CantBlockAbility());
// {R}: Target Vampire gains haste until end of turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{R}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{R}"));
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);
}

View file

@ -33,7 +33,7 @@ public final class OmenOfTheDead extends CardImpl {
this.addAbility(ability);
// {2}{B}, Sacrifice Omen of the Dead: Scry 2.
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl("{2}{B}"));
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl<>("{2}{B}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
}

View file

@ -34,7 +34,7 @@ public final class OmenOfTheForge extends CardImpl {
this.addAbility(ability);
// {2}{R}, Sacrifice Omen of the Forge: Scry 2.
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl("{2}{R}"));
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl<>("{2}{R}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
}

View file

@ -33,7 +33,7 @@ public final class OmenOfTheHunt extends CardImpl {
), true));
// {2}{G}, Sacrifice Omen of the Hunt: Scry 2.
Ability ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl("{2}{G}"));
Ability ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl<>("{2}{G}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
}

View file

@ -31,7 +31,7 @@ public final class OmenOfTheSea extends CardImpl {
this.addAbility(ability);
// {2}{U}, Sacrifice Omen of the Sea: Scry 2.
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl("{2}{U}"));
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl<>("{2}{U}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
}

View file

@ -35,7 +35,7 @@ public final class OmenOfTheSun extends CardImpl {
this.addAbility(ability);
// {2}{W}, Sacrifice Omen of the Sun: Scry 2.
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl("{2}{W}"));
ability = new SimpleActivatedAbility(new ScryEffect(2), new ManaCostsImpl<>("{2}{W}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
}

View file

@ -35,7 +35,7 @@ public final class OminousSeas extends CardImpl {
));
// Cycling {2}
this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}")));
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}")));
}
private OminousSeas(final OminousSeas card) {

View file

@ -29,7 +29,7 @@ public final class OngoingInvestigation extends CardImpl {
this.addAbility(new DealCombatDamageControlledTriggeredAbility(new InvestigateEffect()));
// {1}{G}, Exile a creature card from your graveyard: Investigate. You gain 2 life.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new InvestigateEffect(), new ManaCostsImpl("{1}{G}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new InvestigateEffect(), new ManaCostsImpl<>("{1}{G}"));
ability.addCost(new ExileFromGraveCost(new TargetCardInYourGraveyard(new FilterCreatureCard("a creature card from your graveyard"))));
ability.addEffect(new GainLifeEffect(2));
this.addAbility(ability);

View file

@ -29,7 +29,7 @@ public final class OnyxMage extends CardImpl {
this.power = new MageInt(2);
this.toughness = new MageInt(1);
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{1}{B}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{1}{B}"));
ability.addTarget(new TargetControlledCreaturePermanent());
this.addAbility(ability);
}

View file

@ -30,7 +30,7 @@ public final class OnyxTalisman extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{2}");
// Whenever a player casts a black spell, you may pay {3}. If you do, untap target permanent.
Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new UntapTargetEffect(), new ManaCostsImpl("{3}")), filter, false);
Ability ability = new SpellCastAllTriggeredAbility(new DoIfCostPaid(new UntapTargetEffect(), new ManaCostsImpl<>("{3}")), filter, false);
ability.addTarget(new TargetPermanent());
this.addAbility(ability);
}

View file

@ -35,7 +35,7 @@ public final class OonaQueenOfTheFae extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// {X}{UB}: Choose a color. Target opponent exiles the top X cards of their library. For each card of the chosen color exiled this way, create a 1/1 blue and black Faerie Rogue creature token with flying.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OonaQueenOfTheFaeEffect(), new ManaCostsImpl("{X}{U/B}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OonaQueenOfTheFaeEffect(), new ManaCostsImpl<>("{X}{U/B}"));
ability.addTarget(new TargetOpponent());
this.addAbility(ability);
}

View file

@ -29,7 +29,7 @@ public final class OozeFlux extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{3}{G}");
// {1}{G}, Remove one or more +1/+1 counters from among creatures you control: Create an X/X green Ooze creature token, where X is the number of +1/+1 counters removed this way.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OozeFluxCreateTokenEffect(new OozeToken()),new ManaCostsImpl("{1}{G}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OozeFluxCreateTokenEffect(new OozeToken()),new ManaCostsImpl<>("{1}{G}"));
ability.addCost(new RemoveVariableCountersTargetCost(StaticFilters.FILTER_CONTROLLED_CREATURES, CounterType.P1P1, "one or more", 1));
this.addAbility(ability);
}

View file

@ -39,7 +39,7 @@ public final class OozeGarden extends CardImpl {
// {1}{G}, Sacrifice a non-Ooze creature: Create an X/X green Ooze creature token, where X is the sacrificed creature's power. Activate this ability only any time you could cast a sorcery.
Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new OozeGardenCreateTokenEffect(), new ManaCostsImpl("{1}{G}"));
Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new OozeGardenCreateTokenEffect(), new ManaCostsImpl<>("{1}{G}"));
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true)));
this.addAbility(ability);
}

View file

@ -42,7 +42,7 @@ public final class OpalAcrolith extends CardImpl {
"Whenever an opponent casts a creature spell, if Opal Acrolith is an enchantment, Opal Acrolith becomes a 2/4 Soldier creature."));
// {0}: Opal Acrolith becomes an enchantment.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesEnchantmentSourceEffect(), new ManaCostsImpl("{0}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesEnchantmentSourceEffect(), new ManaCostsImpl<>("{0}")));
}

View file

@ -46,7 +46,7 @@ public final class OpalEyeKondasYojimbo extends CardImpl {
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new OpalEyeKondasYojimboRedirectionEffect(), new TapSourceCost()));
// {1}{W}: Prevent the next 1 damage that would be dealt to Opal-Eye this turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToSourceEffect(Duration.EndOfTurn, 1), new ManaCostsImpl("{1}{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToSourceEffect(Duration.EndOfTurn, 1), new ManaCostsImpl<>("{1}{W}")));
}

View file

@ -30,7 +30,7 @@ public final class OracleOfNectars extends CardImpl {
this.toughness = new MageInt(2);
// {X}, {tap}: You gain X life.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl<>("{X}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
}

View file

@ -43,19 +43,19 @@ public final class OrcishHealer extends CardImpl {
this.toughness = new MageInt(1);
// {R}{R}, {tap}: Target creature can't be regenerated this turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeRegeneratedTargetEffect(Duration.EndOfTurn), new ManaCostsImpl("{R}{R}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeRegeneratedTargetEffect(Duration.EndOfTurn), new ManaCostsImpl<>("{R}{R}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
// {B}{B}{R}, {tap}: Regenerate target black or green creature.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), new ManaCostsImpl("{B}{B}{R}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), new ManaCostsImpl<>("{B}{B}{R}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);
// {R}{G}{G}, {tap}: Regenerate target black or green creature.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), new ManaCostsImpl("{R}{G}{G}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), new ManaCostsImpl<>("{R}{G}{G}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);

View file

@ -36,7 +36,7 @@ public final class OrcishSettlers extends CardImpl {
this.toughness = new MageInt(1);
// {X}{X}{R}, {tap}, Sacrifice Orcish Settlers: Destroy X target lands.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OrcishSettlersEffect(), new ManaCostsImpl("{X}{X}{R}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OrcishSettlersEffect(), new ManaCostsImpl<>("{X}{X}{R}"));
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);

View file

@ -44,7 +44,7 @@ public final class OrcishVeteran extends CardImpl {
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBlockCreaturesSourceEffect(filter)));
// {R}: Orcish Veteran gains first strike until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{R}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{R}")));
}
private OrcishVeteran(final OrcishVeteran card) {

View file

@ -35,10 +35,10 @@ public final class OrderOfLeitbur extends CardImpl {
this.addAbility(ProtectionAbility.from(ObjectColor.BLACK));
// {W}: Order of Leitbur gains first strike until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{W}")));
// {W}{W}: Order of Leitbur gets +1/+0 until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl("{W}{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl<>("{W}{W}")));
}
private OrderOfLeitbur(final OrderOfLeitbur card) {

View file

@ -34,10 +34,10 @@ public final class OrderOfTheEbonHand extends CardImpl {
this.addAbility(ProtectionAbility.from(ObjectColor.WHITE));
// {B}: Order of the Ebon Hand gains first strike until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{B}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{B}")));
// {B}{B}: Order of the Ebon Hand gets +1/+0 until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl("{B}{B}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl<>("{B}{B}")));
}
private OrderOfTheEbonHand(final OrderOfTheEbonHand card) {

View file

@ -30,7 +30,7 @@ public final class OrderOfTheGoldenCricket extends CardImpl {
// Whenever Order of the Golden Cricket attacks, you may pay {W}. If you do, it gains flying until end of turn.
Ability ability = new AttacksTriggeredAbility(new DoIfCostPaid(
new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")),
new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{W}")),
false,
"Whenever {this} attacks, you may pay {W}. If you do, it gains flying until end of turn.");
this.addAbility(ability);

View file

@ -34,10 +34,10 @@ public final class OrderOfTheWhiteShield extends CardImpl {
this.addAbility(ProtectionAbility.from(ObjectColor.BLACK));
// {W}: Order of the White Shield gains first strike until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl<>("{W}")));
// {W}{W}: Order of the White Shield gets +1/+0 until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl("{W}{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1,0, Duration.EndOfTurn), new ManaCostsImpl<>("{W}{W}")));
}
private OrderOfTheWhiteShield(final OrderOfTheWhiteShield card) {

View file

@ -41,7 +41,7 @@ public final class OrderOfWhiteclay extends CardImpl {
this.toughness = new MageInt(4);
// {1}{W}{W}, {untap}: Return target creature card with converted mana cost 3 or less from your graveyard to the battlefield.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl("{1}{W}{W}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl<>("{1}{W}{W}"));
ability.addCost(new UntapSourceCost());
Target target = new TargetCardInYourGraveyard(filter);
ability.addTarget(target);

View file

@ -27,7 +27,7 @@ public final class OrdruunCommando extends CardImpl {
this.toughness = new MageInt(1);
// {W}: Prevent the next 1 damage that would be dealt to Ordruun Commando this turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToSourceEffect(Duration.EndOfTurn, 1), new ManaCostsImpl("{W}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToSourceEffect(Duration.EndOfTurn, 1), new ManaCostsImpl<>("{W}")));
}
private OrdruunCommando(final OrdruunCommando card) {

View file

@ -27,7 +27,7 @@ public final class OreadOfMountainsBlaze extends CardImpl {
// {2}{R}, Discard a card: Draw a card.
Ability ability = new SimpleActivatedAbility(
new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{2}{R}")
new DrawCardSourceControllerEffect(1), new ManaCostsImpl<>("{2}{R}")
);
ability.addCost(new DiscardCardCost());
this.addAbility(ability);

View file

@ -31,7 +31,7 @@ public final class OriginSpellbomb extends CardImpl {
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
this.addAbility(new DiesSourceTriggeredAbility(new DoIfCostPaid(new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{W}")), false));
this.addAbility(new DiesSourceTriggeredAbility(new DoIfCostPaid(new DrawCardSourceControllerEffect(1), new ManaCostsImpl<>("{W}")), false));
}
public OriginSpellbomb (final OriginSpellbomb card) {

View file

@ -48,7 +48,7 @@ public final class OrmosArchiveKeeper extends CardImpl {
// {1}{U}{U}, Discard three cards with different names: Draw five cards.
Ability ability = new SimpleActivatedAbility(
new DrawCardSourceControllerEffect(5), new ManaCostsImpl("{1}{U}{U}")
new DrawCardSourceControllerEffect(5), new ManaCostsImpl<>("{1}{U}{U}")
);
ability.addCost(new DiscardTargetCost(new OrmosArchiveKeeperTarget()));
this.addAbility(ability);

View file

@ -73,7 +73,7 @@ public final class OrochiEggwatcher extends CardImpl {
// {2}{G}, {T}: Create a 1/1 green Snake creature token. If you control ten or more creatures, flip Orochi Eggwatcher.
Ability ability;
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new SnakeToken()), new ManaCostsImpl("{2}{G}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new SnakeToken()), new ManaCostsImpl<>("{2}{G}"));
ability.addCost(new TapSourceCost());
ability.addEffect(new ConditionalOneShotEffect(new FlipSourceEffect(new ShidakoBroodmistress()),
new PermanentsOnTheBattlefieldCondition(new FilterControlledCreaturePermanent(), ComparisonType.MORE_THAN, 9), "If you control ten or more creatures, flip {this}"));
@ -106,7 +106,7 @@ class ShidakoBroodmistress extends TokenImpl {
ability = new SimpleActivatedAbility(
Zone.BATTLEFIELD,
new BoostTargetEffect(3, 3, Duration.EndOfTurn),
new ManaCostsImpl("{G}"));
new ManaCostsImpl<>("{G}"));
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(FILTER_CONTROLLED_CREATURE_SHORT_TEXT)));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);

View file

@ -42,7 +42,7 @@ public final class OrosTheAvenger extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// Whenever Oros, the Avenger deals combat damage to a player, you may pay {2}{W}. If you do, Oros deals 3 damage to each nonwhite creature.
this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(
new DoIfCostPaid(new DamageAllEffect(3, filter), new ManaCostsImpl("{2}{W}")), false));
new DoIfCostPaid(new DamageAllEffect(3, filter), new ManaCostsImpl<>("{2}{W}")), false));
}
private OrosTheAvenger(final OrosTheAvenger card) {

View file

@ -32,7 +32,7 @@ public final class OrzhovCluestone extends CardImpl {
this.addAbility(new BlackManaAbility());
// {W}{B}, {T}, Sacrifice Orzhov Cluestone: Draw a card.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{W}{B}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl<>("{W}{B}"));
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);

View file

@ -29,12 +29,12 @@ public final class OrzhovGuildmage extends CardImpl {
this.toughness = new MageInt(2);
// {2}{W}: Target player gains 1 life.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeTargetEffect(1), new ManaCostsImpl("{2}{W}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeTargetEffect(1), new ManaCostsImpl<>("{2}{W}"));
ability.addTarget(new TargetPlayer(1));
this.addAbility(ability);
// {2}{B}: Each player loses 1 life.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeAllPlayersEffect(1), new ManaCostsImpl("{2}{B}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeAllPlayersEffect(1), new ManaCostsImpl<>("{2}{B}")));
}
private OrzhovGuildmage(final OrzhovGuildmage card) {

View file

@ -30,7 +30,7 @@ public final class OrzhovKeyrune extends CardImpl {
this.addAbility(new BlackManaAbility());
// {W}{B}: Orzhov Keyrune becomes a 1/4 white and black Thrull artifact creature with lifelink until end of turn.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesCreatureSourceEffect(new OrzhovKeyruneToken(), "", Duration.EndOfTurn), new ManaCostsImpl("{W}{B}")));
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesCreatureSourceEffect(new OrzhovKeyruneToken(), "", Duration.EndOfTurn), new ManaCostsImpl<>("{W}{B}")));
}
private OrzhovKeyrune(final OrzhovKeyrune card) {

View file

@ -24,7 +24,7 @@ public final class OrzhovaTheChurchOfDeals extends CardImpl {
public OrzhovaTheChurchOfDeals(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.LAND},"");
this.addAbility(new ColorlessManaAbility());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(1), new ManaCostsImpl("{3}{W}{B}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(1), new ManaCostsImpl<>("{3}{W}{B}"));
ability.addCost(new TapSourceCost());
ability.addEffect(new GainLifeEffect(1));
ability.addTarget(new TargetPlayer(1));

View file

@ -65,7 +65,7 @@ public final class OsgirTheReconstructor extends CardImpl {
// {X},{T}, Exile an artifact with mana value X from your graveyard: Create two tokens that are copies of the exiled card. Activate only as
Ability copyAbility = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD,
new OsgirTheReconstructorCreateArtifactTokensEffect(),
new ManaCostsImpl("{X}"));
new ManaCostsImpl<>("{X}"));
copyAbility.addCost(new TapSourceCost());
copyAbility.addCost(new ExileFromGraveCost(new TargetCardInYourGraveyard(), "Exile an artifact card with mana value X from your graveyard"));

View file

@ -35,7 +35,7 @@ public final class Overtaker extends CardImpl {
this.toughness = new MageInt(1);
// {3}{U}, {tap}, Discard a card: Untap target creature and gain control of it until end of turn. That creature gains haste until end of turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new ManaCostsImpl("{3}{U}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new ManaCostsImpl<>("{3}{U}"));
ability.addCost(new TapSourceCost());
ability.addCost(new DiscardCardCost());
Effect effect = new GainControlTargetEffect(Duration.EndOfTurn);

View file

@ -33,11 +33,11 @@ public final class OviyaPashiriSageLifecrafter extends CardImpl {
this.toughness = new MageInt(2);
// {2}{G}, {T}: Create a 1/1 colorless Servo artifact creature token.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ServoToken(), 1), new ManaCostsImpl("{2}{G}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ServoToken(), 1), new ManaCostsImpl<>("{2}{G}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
// {4}{G}, {T}: Create an X/X colorless Construct artifact creature token, where X is the number of creatures you control.
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OviyaPashiriSageLifecrafterEffect(), new ManaCostsImpl("{4}{G}"));
ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new OviyaPashiriSageLifecrafterEffect(), new ManaCostsImpl<>("{4}{G}"));
ability.addCost(new TapSourceCost());
ability.addHint(CreaturesYouControlHint.instance);
this.addAbility(ability);