[refactor] removed generic parameter from SplitCard

This commit is contained in:
North 2014-06-02 21:43:59 +03:00
parent 59126eef87
commit 1cc42a7cbb
27 changed files with 27 additions and 29 deletions

View file

@ -45,7 +45,7 @@ import mage.target.common.TargetCreatureOrPlayerAmount;
*/ */
public class FireIce extends SplitCard<FireIce> { public class FireIce extends SplitCard {
public FireIce(UUID ownerId) { public FireIce(UUID ownerId) {
super(ownerId, 128, "Fire", "Ice", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{R}", "{1}{U}", false); super(ownerId, 128, "Fire", "Ice", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{R}", "{1}{U}", false);

View file

@ -45,7 +45,7 @@ import mage.target.common.TargetSpellOrPermanent;
* @author LevelX2 * @author LevelX2
*/ */
public class IllusionReality extends SplitCard<IllusionReality> { public class IllusionReality extends SplitCard {
public IllusionReality(UUID ownerId) { public IllusionReality(UUID ownerId) {
super(ownerId, 129, "Illusion", "Reality", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{U}", "{2}{G}", false); super(ownerId, 129, "Illusion", "Reality", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{U}", "{2}{G}", false);

View file

@ -53,7 +53,7 @@ import mage.target.common.TargetCardInYourGraveyard;
* @author LevelX2 * @author LevelX2
*/ */
public class LifeDeath extends SplitCard<LifeDeath> { public class LifeDeath extends SplitCard {
public LifeDeath(UUID ownerId) { public LifeDeath(UUID ownerId) {
super(ownerId, 130, "Life", "Death", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{G}", "{1}{B}", false); super(ownerId, 130, "Life", "Death", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{G}", "{1}{B}", false);

View file

@ -51,7 +51,7 @@ import mage.target.common.TargetCreaturePermanent;
* @author LevelX2 * @author LevelX2
*/ */
public class NightDay extends SplitCard<NightDay> { public class NightDay extends SplitCard {
public NightDay(UUID ownerId) { public NightDay(UUID ownerId) {
super(ownerId, 131, "Night", "Day", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{B}", "{2}{W}", false); super(ownerId, 131, "Night", "Day", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{B}", "{2}{W}", false);

View file

@ -45,7 +45,7 @@ import mage.target.common.TargetAttackingCreature;
*/ */
public class OrderChaos extends SplitCard<OrderChaos> { public class OrderChaos extends SplitCard {
public OrderChaos(UUID ownerId) { public OrderChaos(UUID ownerId) {
super(ownerId, 132, "Order", "Chaos", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{W}", "{2}{R}", false); super(ownerId, 132, "Order", "Chaos", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{W}", "{2}{R}", false);

View file

@ -42,7 +42,7 @@ import mage.filter.predicate.mageobject.AbilityPredicate;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class RoughTumble extends SplitCard<RoughTumble> { public class RoughTumble extends SplitCard {
private static final FilterCreaturePermanent filterFlying = new FilterCreaturePermanent("creature with flying"); private static final FilterCreaturePermanent filterFlying = new FilterCreaturePermanent("creature with flying");
private static final FilterCreaturePermanent filterWithoutFlying = new FilterCreaturePermanent("creature without flying"); private static final FilterCreaturePermanent filterWithoutFlying = new FilterCreaturePermanent("creature without flying");

View file

@ -52,7 +52,7 @@ import mage.target.common.TargetOpponent;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class HideSeek extends SplitCard<HideSeek> { public class HideSeek extends SplitCard {
private static final FilterPermanent filter = new FilterPermanent("artifact or enchantment"); private static final FilterPermanent filter = new FilterPermanent("artifact or enchantment");

View file

@ -52,7 +52,7 @@ import mage.target.TargetSpell;
*/ */
public class OddsEnds extends SplitCard<OddsEnds> { public class OddsEnds extends SplitCard {
private static final FilterSpell filter = new FilterSpell("instant or sorcery spell"); private static final FilterSpell filter = new FilterSpell("instant or sorcery spell");
static { static {

View file

@ -44,7 +44,7 @@ import mage.players.Player;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class AliveWell extends SplitCard<AliveWell> { public class AliveWell extends SplitCard {
public AliveWell(UUID ownerId) { public AliveWell(UUID ownerId) {
super(ownerId, 121, "Alive", "Well", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{G}","{W}", true); super(ownerId, 121, "Alive", "Well", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{G}","{W}", true);

View file

@ -45,7 +45,7 @@ import mage.target.common.TargetCreaturePermanent;
*/ */
public class ArmedDangerous extends SplitCard<ArmedDangerous> { public class ArmedDangerous extends SplitCard {
public ArmedDangerous(UUID ownerId) { public ArmedDangerous(UUID ownerId) {
super(ownerId, 122, "Armed", "Dangerous", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{R}", "{3}{G}", true); super(ownerId, 122, "Armed", "Dangerous", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{R}", "{3}{G}", true);

View file

@ -49,7 +49,7 @@ import mage.game.permanent.Permanent;
*/ */
public class BeckCall extends SplitCard<BeckCall> { public class BeckCall extends SplitCard {
public BeckCall(UUID ownerId) { public BeckCall(UUID ownerId) {
super(ownerId, 123, "Beck", "Call", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{G}{U}", "{4}{W}{U}", true); super(ownerId, 123, "Beck", "Call", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{G}{U}", "{4}{W}{U}", true);

View file

@ -57,7 +57,7 @@ import mage.target.targetpointer.FixedTarget;
*/ */
public class BreakingEntering extends SplitCard<BreakingEntering> { public class BreakingEntering extends SplitCard {
public BreakingEntering(UUID ownerId) { public BreakingEntering(UUID ownerId) {
super(ownerId, 124, "Breaking", "Entering", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{U}{B}", "{4}{B}{R}", true); super(ownerId, 124, "Breaking", "Entering", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{U}{B}", "{4}{B}{R}", true);

View file

@ -64,7 +64,7 @@ import mage.target.common.TargetControlledPermanent;
*/ */
public class CatchRelease extends SplitCard<CatchRelease> { public class CatchRelease extends SplitCard {
public CatchRelease(UUID ownerId) { public CatchRelease(UUID ownerId) {
super(ownerId, 125, "Catch", "Release", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{1}{U}{R}", "{4}{R}{W}",true); super(ownerId, 125, "Catch", "Release", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{1}{U}{R}", "{4}{R}{W}",true);

View file

@ -43,7 +43,7 @@ import mage.target.common.TargetCardInYourGraveyard;
*/ */
public class DownDirty extends SplitCard<DownDirty> { public class DownDirty extends SplitCard {
public DownDirty(UUID ownerId) { public DownDirty(UUID ownerId) {
super(ownerId, 126, "Down", "Dirty", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{B}", "{2}{G}", true); super(ownerId, 126, "Down", "Dirty", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{B}", "{2}{G}", true);

View file

@ -44,7 +44,7 @@ import mage.target.common.TargetCreaturePermanent;
*/ */
public class FarAway extends SplitCard<FarAway> { public class FarAway extends SplitCard {
public FarAway(UUID ownerId) { public FarAway(UUID ownerId) {
super(ownerId, 127, "Far", "Away", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{U}", "{2}{B}", true); super(ownerId, 127, "Far", "Away", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{U}", "{2}{B}", true);

View file

@ -54,7 +54,7 @@ import mage.target.common.TargetCreaturePermanent;
*/ */
public class FleshBlood extends SplitCard<FleshBlood> { public class FleshBlood extends SplitCard {
public FleshBlood(UUID ownerId) { public FleshBlood(UUID ownerId) {
super(ownerId, 128, "Flesh", "Blood", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{3}{B}{G}", "{R}{G}",true); super(ownerId, 128, "Flesh", "Blood", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{3}{B}{G}", "{R}{G}",true);

View file

@ -46,7 +46,7 @@ import mage.target.common.TargetCreaturePermanent;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class GiveTake extends SplitCard<GiveTake> { public class GiveTake extends SplitCard {
public GiveTake(UUID ownerId) { public GiveTake(UUID ownerId) {
super(ownerId, 129, "Give", "Take", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{G}","{2}{U}", true); super(ownerId, 129, "Give", "Take", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{G}","{2}{U}", true);

View file

@ -46,7 +46,7 @@ import mage.filter.predicate.permanent.ControllerPredicate;
*/ */
public class ProfitLoss extends SplitCard<ProfitLoss> { public class ProfitLoss extends SplitCard {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures your opponents control"); private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures your opponents control");
static { static {

View file

@ -42,7 +42,7 @@ import mage.target.common.TargetCreaturePermanent;
*/ */
public class ProtectServe extends SplitCard<ProtectServe> { public class ProtectServe extends SplitCard {
public ProtectServe(UUID ownerId) { public ProtectServe(UUID ownerId) {
super(ownerId, 131, "Protect", "Serve", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}", "{1}{U}", true); super(ownerId, 131, "Protect", "Serve", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}", "{1}{U}", true);

View file

@ -47,7 +47,7 @@ import mage.filter.common.FilterCreaturePermanent;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class ReadyWilling extends SplitCard<ReadyWilling> { public class ReadyWilling extends SplitCard {
public ReadyWilling(UUID ownerId) { public ReadyWilling(UUID ownerId) {
super(ownerId, 132, "Ready", "Willing", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{G}{W}", "{1}{W}{B}", true); super(ownerId, 132, "Ready", "Willing", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{G}{W}", "{1}{W}{B}", true);

View file

@ -48,7 +48,7 @@ import mage.target.TargetPlayer;
*/ */
public class ToilTrouble extends SplitCard<ToilTrouble> { public class ToilTrouble extends SplitCard {
public ToilTrouble(UUID ownerId) { public ToilTrouble(UUID ownerId) {
super(ownerId, 133, "Toil", "Trouble", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{B}", "{2}{R}",true); super(ownerId, 133, "Toil", "Trouble", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{B}", "{2}{R}",true);

View file

@ -47,7 +47,7 @@ import mage.target.common.TargetCreaturePermanent;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class TurnBurn extends SplitCard<TurnBurn> { public class TurnBurn extends SplitCard {
public TurnBurn(UUID ownerId) { public TurnBurn(UUID ownerId) {
super(ownerId, 134, "Turn", "Burn", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{U}", "{1}{R}", true); super(ownerId, 134, "Turn", "Burn", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{U}", "{1}{R}", true);

View file

@ -41,7 +41,7 @@ import mage.target.common.TargetArtifactPermanent;
* *
* @author LevelX2 * @author LevelX2
*/ */
public class WearTear extends SplitCard<WearTear> { public class WearTear extends SplitCard {
public WearTear(UUID ownerId) { public WearTear(UUID ownerId) {
super(ownerId, 135, "Wear", "Tear", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{R}", "{W}", true); super(ownerId, 135, "Wear", "Tear", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{R}", "{W}", true);

View file

@ -44,7 +44,7 @@ import mage.target.common.TargetCreatureOrPlayer;
*/ */
public class AssaultBattery extends SplitCard<AssaultBattery> { public class AssaultBattery extends SplitCard {
public AssaultBattery(UUID ownerId) { public AssaultBattery(UUID ownerId) {
super(ownerId, 295, "Assault", "Battery", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{R}", "{3}{G}", false); super(ownerId, 295, "Assault", "Battery", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{R}", "{3}{G}", false);

View file

@ -47,7 +47,7 @@ import mage.target.TargetPermanent;
*/ */
public class BoomBust extends SplitCard<BoomBust> { public class BoomBust extends SplitCard {
private static final FilterLandPermanent filter1 = new FilterLandPermanent("land you control"); private static final FilterLandPermanent filter1 = new FilterLandPermanent("land you control");
private static final FilterLandPermanent filter2 = new FilterLandPermanent("land you don't control"); private static final FilterLandPermanent filter2 = new FilterLandPermanent("land you don't control");

View file

@ -46,10 +46,8 @@ import mage.watchers.Watcher;
/** /**
* *
* @author LevelX2 * @author LevelX2
* @param <T>
*/ */
public abstract class SplitCard extends CardImpl {
public abstract class SplitCard<T extends SplitCard<T>> extends CardImpl {
protected Card leftHalfCard; protected Card leftHalfCard;
protected Card rightHalfCard; protected Card rightHalfCard;

View file

@ -12,7 +12,7 @@ import mage.constants.CardType;
* *
* @author North * @author North
*/ */
public class MockSplitCard extends SplitCard<MockSplitCard> { public class MockSplitCard extends SplitCard {
public MockSplitCard(CardInfo card) { public MockSplitCard(CardInfo card) {
super(null, super(null,