public GrafRats(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{B}"); this.subtype.add(SubType.RAT); this.power = new MageInt(2); this.toughness = new MageInt(1); // At the beginning of combat on your turn, if you both own and control Graf Rats and a creature named Midnight Scavengers, exile them, then meld them into Chittering Host. this.addAbility(new ConditionalInterveningIfTriggeredAbility( new BeginningOfCombatTriggeredAbility(new MeldEffect("Midnight Scavengers", new mage.cards.c.ChitteringHost(ownerId, new CardSetInfo("Chittering Host", "EMN", "96", Rarity.COMMON))), TargetController.YOU, false), new MeldCondition("Midnight Scavengers"), "At the beginning of combat on your turn, if you both own and control {this} and a creature named Midnight Scavengers, exile them, then meld them into Chittering Host.")); }
public SplitCard(UUID ownerId, CardSetInfo setInfo, CardType[] typesLeft, CardType[] typesRight, String costsLeft, String costsRight, SpellAbilityType spellAbilityType) { super(ownerId, setInfo, CardType.mergeTypes(typesLeft, typesRight), costsLeft + costsRight, spellAbilityType); String[] names = setInfo.getName().split(" // "); leftHalfCard = new SplitCardHalfImpl(this.getOwnerId(), new CardSetInfo(names[0], setInfo.getExpansionSetCode(), setInfo.getCardNumber(), setInfo.getRarity(), setInfo.getGraphicInfo()), typesLeft, costsLeft, this, SpellAbilityType.SPLIT_LEFT); rightHalfCard = new SplitCardHalfImpl(this.getOwnerId(), new CardSetInfo(names[1], setInfo.getExpansionSetCode(), setInfo.getCardNumber(), setInfo.getRarity(), setInfo.getGraphicInfo()), typesRight, costsRight, this, SpellAbilityType.SPLIT_RIGHT); this.splitCard = true; }
public DefaultCommander(UUID ownerId, String commanderName, String manaString) { super(ownerId, new CardSetInfo(commanderName, "", "999", Rarity.RARE), new CardType[]{CardType.CREATURE}, manaString); this.addSuperType(SuperType.LEGENDARY); if (manaString.contains("{G}")) { this.color.setGreen(true); } if (manaString.contains("{W}")) { this.color.setWhite(true); } if (manaString.contains("{U}")) { this.color.setBlue(true); } if (manaString.contains("{B}")) { this.color.setBlack(true); } if (manaString.contains("{R}")) { this.color.setRed(true); } this.power = new MageInt(3); this.toughness = new MageInt(3); }
@Override public final Card getSecondCardFace() { if (secondSideCardClazz == null && secondSideCard == null) { return null; } if (secondSideCard != null) { return secondSideCard; } List<ExpansionSet.SetCardInfo> cardInfo = Sets.findSet(expansionSetCode).findCardInfoByClass(secondSideCardClazz); assert cardInfo.size() == 1; // should find 1 second side card if (cardInfo.isEmpty()) { return null; } ExpansionSet.SetCardInfo info = cardInfo.get(0); return secondSideCard = createCard(secondSideCardClazz, new CardSetInfo(info.getName(), expansionSetCode, info.getCardNumber(), info.getRarity(), info.getGraphicInfo())); }
public Card getCard() { return CardImpl.createCard(className, new CardSetInfo(name, setCode, cardNumber, rarity, new CardGraphicInfo(FrameStyle.valueOf(frameStyle), variousArt))); }
public GiselaTheBrokenBlade(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}{W}"); addSuperType(SuperType.LEGENDARY); this.subtype.add(SubType.ANGEL); this.subtype.add(SubType.HORROR); this.power = new MageInt(4); this.toughness = new MageInt(3); // Flying this.addAbility(FlyingAbility.getInstance()); // First strike this.addAbility(FirstStrikeAbility.getInstance()); // Lifelink this.addAbility(LifelinkAbility.getInstance()); // At the beginning of your end step, if you both own and control Gisela, the Broken Blade and a creature named Bruna, the Fading Light, exile them, then meld them into Brisela, Voice of Nightmares. this.addAbility(new ConditionalInterveningIfTriggeredAbility( new BeginningOfEndStepTriggeredAbility( new MeldEffect("Bruna, the Fading Light", new mage.cards.b.BriselaVoiceOfNightmares(ownerId, new CardSetInfo("Brisela, Voice of Nightmares", "EMN", "15", Rarity.MYTHIC))), TargetController.YOU, false), new MeldCondition("Bruna, the Fading Light"), "At the beginning of your end step, if you both own and control {this} and a creature named Bruna, the Fading Light, exile them, " + "then meld them into Brisela, Voice of Nightmares.")); }
public HanweirBattlements(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.LAND},""); // {T}: Add {C}. this.addAbility(new ColorlessManaAbility()); // {R},{T}: Target creature gains haste until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{R}")); ability.addCost(new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); // {3}{R}{R},{T}: If you both own and control Hanweir Battlements and a creature named Hanweir Garrison, exile them, then meld them into Hanweir, the Writhing Township. ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, new MeldEffect("Hanweir Garrison", new HanweirTheWrithingTownship(ownerId, new CardSetInfo("Hanweir, the Writhing Township", "EMN", "130", Rarity.RARE))), new ManaCostsImpl("{3}{R}{R}"), new MeldCondition("Hanweir Garrison"), "{3}{R}{R}, {T}: If you both own and control {this} and a creature named Hanweir Garrison, exile them, then meld them into Hanweir, the Writhing Township."); ability.addCost(new TapSourceCost()); this.addAbility(ability); }
new CardSetInfo(setInfo.getName(), set.getCode(), setInfo.getCardNumber(), setInfo.getRarity(), setInfo.getGraphicInfo()), errorsList); if (card != null) {
public MockSplitCard(CardInfo card) { super(null, new CardSetInfo(card.getName(), card.getSetCode(), card.getCardNumber(), card.getRarity()), card.getTypes().toArray(new CardType[0]), join(card.getManaCosts()),