public ThornwatchScarecrow(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{6}"); this.subtype.add(SubType.SCARECROW); this.power = new MageInt(4); this.toughness = new MageInt(4); // Thornwatch Scarecrow has wither as long as you control a green creature. ContinuousEffect effect = new GainAbilitySourceEffect(WitherAbility.getInstance(), Duration.WhileOnBattlefield); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(effect, new PermanentsOnTheBattlefieldCondition(filter), rule))); // Thornwatch Scarecrow has vigilance as long as you control a white creature. ContinuousEffect effect2 = new GainAbilitySourceEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(effect2, new PermanentsOnTheBattlefieldCondition(filter2), rule2))); }
private static Condition makeAndCondition(ObjectColor color1, ObjectColor color2) { FilterPermanent filter1 = new FilterPermanent(); filter1.add(new ColorPredicate(color1)); Condition condition1 = new PermanentsOnTheBattlefieldCondition(filter1); FilterPermanent filter2 = new FilterPermanent(); filter2.add(new ColorPredicate(color2)); Condition condition2 = new PermanentsOnTheBattlefieldCondition(filter2); return new CompoundCondition(condition1, condition2); }
public ImperialLancer(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{W}"); this.subtype.add(SubType.HUMAN); this.subtype.add(SubType.KNIGHT); this.power = new MageInt(1); this.toughness = new MageInt(1); // Imperial Lancer has double strike as long as you control a Dinosaur. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(new GainAbilitySourceEffect(DoubleStrikeAbility.getInstance(), Duration.WhileOnBattlefield), new PermanentsOnTheBattlefieldCondition(filter), "{this} has double strike as long as you control a Dinosaur"))); }
public SejiriMerfolk(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{1}{U}"); this.subtype.add(SubType.MERFOLK); this.subtype.add(SubType.SOLDIER); this.color.setBlue(true); this.power = new MageInt(2); this.toughness = new MageInt(1); ConditionalContinuousEffect effect1 = new ConditionalContinuousEffect(new GainAbilitySourceEffect(LifelinkAbility.getInstance()), new PermanentsOnTheBattlefieldCondition(filter), rule1); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect1)); ConditionalContinuousEffect effect2 = new ConditionalContinuousEffect(new GainAbilitySourceEffect(FirstStrikeAbility.getInstance()), new PermanentsOnTheBattlefieldCondition(filter), rule2); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect2)); }
public ReverentSilence(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{3}{G}"); // If you control a Forest, rather than pay Reverent Silence's mana cost, you may have each other player gain 6 life. this.addAbility(new AlternativeCostSourceAbility(new GainLifePlayersCost(6), new PermanentsOnTheBattlefieldCondition(filter))); // Destroy all enchantments. this.getSpellAbility().addEffect(new DestroyAllEffect(new FilterEnchantmentPermanent("enchantments"))); }
public RhoxMeditant(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{W}"); this.subtype.add(SubType.RHINO); this.subtype.add(SubType.MONK); this.power = new MageInt(2); this.toughness = new MageInt(4); // When Rhox Meditant enters the battlefield, if you control a green permanent, draw a card. TriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1), false); this.addAbility(new ConditionalInterveningIfTriggeredAbility(ability, new PermanentsOnTheBattlefieldCondition(filter), rule)); }
public SurgeOfThoughtweft(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.TRIBAL,CardType.INSTANT},"{1}{W}"); this.subtype.add(SubType.KITHKIN); // Creatures you control get +1/+1 until end of turn. this.getSpellAbility().addEffect(new BoostControlledEffect(1, 1, Duration.EndOfTurn)); // If you control a Kithkin, draw a card. this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), new PermanentsOnTheBattlefieldCondition(filter),"If you control a Kithkin, draw a card")); }
public SummitApes(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{G}"); this.subtype.add(SubType.APE); this.color.setGreen(true); this.power = new MageInt(5); this.toughness = new MageInt(2); // As long as you control a Mountain, Summit Apes has menace. (It can't be blocked except by two or more creatures.) this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(new GainAbilitySourceEffect(new MenaceAbility()), new PermanentsOnTheBattlefieldCondition(filter), rule))); }
public Submerge(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{4}{U}"); // If an opponent controls a Forest and you control an Island, you may cast this spell without paying its mana cost. Condition condition = new CompoundCondition("If an opponent controls a Forest and you control an Island", new OpponentControlsPermanentCondition(filterForest), new PermanentsOnTheBattlefieldCondition(filterIsland)); this.addAbility(new AlternativeCostSourceAbility(null, condition)); // Put target creature on top of its owner's library. this.getSpellAbility().addEffect(new PutOnLibraryTargetEffect(true)); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); }
public CopperlineGorge(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.LAND}, null); // Copperline Gorge enters the battlefield tapped unless you control two or fewer other lands. Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(StaticFilters.FILTER_LANDS, ComparisonType.FEWER_THAN, 3)); String abilityText = " tapped unless you control two or fewer other lands"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new RedManaAbility()); this.addAbility(new GreenManaAbility()); }
public AngelicFavor(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{W}"); // If you control a Plains, you may tap an untapped creature you control rather than pay Angelic Favor's mana cost. this.addAbility(new AlternativeCostSourceAbility(new TapTargetCost(new TargetControlledPermanent(untappedCreatureYouControl)), new PermanentsOnTheBattlefieldCondition(filter))); // Cast Angelic Favor only during combat. this.addAbility(new CastOnlyDuringPhaseStepSourceAbility(TurnPhase.COMBAT)); // Put a 4/4 white Angel creature token with flying onto the battlefield. Exile it at the beginning of the next end step. this.getSpellAbility().addEffect(new AngelicFavorEffect()); }
public Rootgrapple(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.TRIBAL,CardType.INSTANT},"{4}{G}"); this.subtype.add(SubType.TREEFOLK); // Destroy target noncreature permanent. this.getSpellAbility().addTarget(new TargetPermanent(filterNoncreature)); this.getSpellAbility().addEffect(new DestroyTargetEffect()); // If you control a Treefolk, draw a card. this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), new PermanentsOnTheBattlefieldCondition(filterTreefolk), "If you control a Treefolk, draw a card")); }
public InspiringVantage(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.LAND}, ""); // Inspiring Vantage enters the battlefield tapped unless you control two or fewer other lands. Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(StaticFilters.FILTER_LANDS, ComparisonType.FEWER_THAN, 3)); String abilityText = " tapped unless you control two or fewer other lands"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); // {T}: Add {R} or {W}. this.addAbility(new RedManaAbility()); this.addAbility(new WhiteManaAbility()); }
public SpirebluffCanal(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.LAND}, ""); // Spirebluff Canal enters the battlefield tapped unless you control two or fewer other lands. Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(StaticFilters.FILTER_LANDS, ComparisonType.FEWER_THAN, 3)); String abilityText = " tapped unless you control two or fewer other lands"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); // {T}: Add {U} or {R}. this.addAbility(new BlueManaAbility()); this.addAbility(new RedManaAbility()); }
public DragonmasterOutcast(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{R}"); this.subtype.add(SubType.HUMAN); this.subtype.add(SubType.SHAMAN); this.power = new MageInt(1); this.toughness = new MageInt(1); // At the beginning of your upkeep, if you control six or more lands, create a 5/5 red Dragon creature token with flying. TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(new CreateTokenEffect(new DragonToken2(), 1), TargetController.YOU, false); this.addAbility(new ConditionalInterveningIfTriggeredAbility(ability, new PermanentsOnTheBattlefieldCondition(filter, ComparisonType.MORE_THAN, 5), "At the beginning of your upkeep, if you control six or more lands, create a 5/5 red Dragon creature token with flying.")); }
public RootboundCrag(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.LAND}, null); Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter)); String abilityText = " tapped unless you control a Mountain or a Forest"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new RedManaAbility()); this.addAbility(new GreenManaAbility()); }
public DarkslickShores(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.LAND}, null); // Darkslick Shores enters the battlefield tapped unless you control two or fewer other lands. Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, ComparisonType.FEWER_THAN, 3)); String abilityText = " tapped unless you control two or fewer other lands"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlueManaAbility()); this.addAbility(new BlackManaAbility()); }
public SunkenHollow(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.LAND},""); this.subtype.add(SubType.ISLAND); this.subtype.add(SubType.SWAMP); // Sunken Hollow enters the battlefield tapped unless you control two or more basic lands. Condition controls = new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, ComparisonType.MORE_THAN, 1)); String abilityText = "tapped unless you control two or more basic lands"; this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlueManaAbility()); this.addAbility(new BlackManaAbility()); }
public SagesDousing(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.TRIBAL,CardType.INSTANT},"{2}{U}"); this.subtype.add(SubType.WIZARD); // Counter target spell unless its controller pays {3}. this.getSpellAbility().addTarget(new TargetSpell()); this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(new GenericManaCost(3))); // If you control a Wizard, draw a card. this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), new PermanentsOnTheBattlefieldCondition(filter),"If you control a Wizard, draw a card")); }
public AshenmoorCohort(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{5}{B}"); this.subtype.add(SubType.ELEMENTAL); this.subtype.add(SubType.WARRIOR); this.power = new MageInt(4); this.toughness = new MageInt(3); // Ashenmoor Cohort gets +1/+1 as long as you control another black creature. Condition condition = new PermanentsOnTheBattlefieldCondition(filter); ConditionalContinuousEffect effect = new ConditionalContinuousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), condition, rule); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); }