refactor: Remove no-argument Squad constructor (#12038)

This commit is contained in:
ssk97 2024-04-01 21:44:23 -07:00 committed by GitHub
parent 168ec1abc6
commit fd83fbb600
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 17 additions and 13 deletions

View file

@ -4,6 +4,7 @@ import mage.MageInt;
import mage.abilities.common.CantBlockAbility;
import mage.abilities.common.SimpleActivatedAbility;
import mage.abilities.costs.common.PayLifeCost;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.continuous.GainAbilitySourceEffect;
import mage.abilities.keyword.IndestructibleAbility;
import mage.abilities.keyword.SquadAbility;
@ -28,7 +29,7 @@ public final class ArcoFlagellant extends CardImpl {
this.toughness = new MageInt(1);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Arco-Flagellant can't block.
this.addAbility(new CantBlockAbility());

View file

@ -2,6 +2,7 @@ package mage.cards.g;
import mage.MageInt;
import mage.abilities.common.AttacksTriggeredAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.continuous.BoostAllEffect;
import mage.abilities.keyword.SquadAbility;
import mage.cards.CardImpl;
@ -37,7 +38,7 @@ public final class GaryClone extends CardImpl {
this.toughness = new MageInt(3);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Whenever Gary Clone attacks, each creature you control named Gary Clone gets +1/+0 until end of turn.
this.addAbility(new AttacksTriggeredAbility(new BoostAllEffect(

View file

@ -3,6 +3,7 @@ package mage.cards.p;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DestroyTargetEffect;
import mage.abilities.keyword.SquadAbility;
import mage.cards.CardImpl;
@ -27,7 +28,7 @@ public final class PowderGanger extends CardImpl {
this.toughness = new MageInt(2);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// When Powder Ganger enters the battlefield, destroy up to one target artifact.
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect());

View file

@ -2,6 +2,7 @@ package mage.cards.s;
import mage.MageInt;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
import mage.abilities.keyword.FlashAbility;
import mage.abilities.keyword.SquadAbility;
@ -29,7 +30,7 @@ public final class SicarianInfiltrator extends CardImpl {
this.addAbility(FlashAbility.getInstance());
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Benediction of Omnissiah -- When Sicarian Infiltrator enters the battlefield, draw a card.
this.addAbility(new EntersBattlefieldTriggeredAbility(

View file

@ -3,6 +3,7 @@ package mage.cards.s;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DestroyTargetEffect;
import mage.abilities.keyword.SquadAbility;
import mage.cards.CardImpl;
@ -28,7 +29,7 @@ public final class SpaceMarineDevastator extends CardImpl {
this.toughness = new MageInt(3);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Grav-cannon -- When Space Marine Devastator enters the battlefield, destroy up to one target artifact or enchantment.
Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect());

View file

@ -2,6 +2,7 @@ package mage.cards.u;
import mage.MageInt;
import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.continuous.BoostControlledEffect;
import mage.abilities.keyword.SquadAbility;
import mage.cards.CardImpl;
@ -26,7 +27,7 @@ public final class UltramarinesHonourGuard extends CardImpl {
this.toughness = new MageInt(2);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Other creatures you control get +1/+1.
this.addAbility(new SimpleStaticAbility(new BoostControlledEffect(

View file

@ -2,6 +2,7 @@ package mage.cards.v;
import mage.MageInt;
import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
import mage.abilities.keyword.FlyingAbility;
import mage.abilities.keyword.SquadAbility;
@ -26,7 +27,7 @@ public final class VanguardSuppressor extends CardImpl {
this.toughness = new MageInt(2);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Flying
this.addAbility(FlyingAbility.getInstance());

View file

@ -1,6 +1,7 @@
package mage.cards.z;
import mage.MageInt;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.keyword.FlyingAbility;
import mage.abilities.keyword.MiracleAbility;
import mage.abilities.keyword.SquadAbility;
@ -26,7 +27,7 @@ public final class Zephyrim extends CardImpl {
this.toughness = new MageInt(3);
// Squad {2}
this.addAbility(new SquadAbility());
this.addAbility(new SquadAbility(new GenericManaCost(2)));
// Flying
this.addAbility(FlyingAbility.getInstance());

View file

@ -5,7 +5,6 @@ import mage.abilities.SpellAbility;
import mage.abilities.StaticAbility;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.costs.*;
import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.CreateTokenCopySourceEffect;
import mage.abilities.effects.OneShotEffect;
@ -25,9 +24,6 @@ public class SquadAbility extends StaticAbility implements OptionalAdditionalSou
protected static final String SQUAD_ACTIVATION_VALUE_KEY = "squadActivationCount";
protected static final String SQUAD_REMINDER = "You may pay an additional "
+ "{cost} any number of times as you cast this spell.";
public SquadAbility() {
this(new GenericManaCost(2));
}
public SquadAbility(Cost cost) {
super(Zone.STACK, null);

View file

@ -116,7 +116,7 @@ Soulshift|number|
Skulk|new|
Spectacle|card, cost|
Spree|card|
Squad|new|
Squad|cost|
Storm|new|
Sunburst|new|
Suspend|number, cost, card|