@Override public CantAttackYouUnlessPayManaAllEffect copy() { return new CantAttackYouUnlessPayManaAllEffect(this); } }
public BairdStewardOfArgive(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}{W}"); this.addSuperType(SuperType.LEGENDARY); this.subtype.add(SubType.HUMAN, SubType.SOLDIER); this.power = new MageInt(2); this.toughness = new MageInt(4); //Vigilance this.addAbility(VigilanceAbility.getInstance()); // Creatures can't attack you or a planeswalker you control unless their controller pays {1} for each of those creatures. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl("{1}"), true) .setText("Creatures can't attack you or a planeswalker you control unless their controller pays {1} for each of those creatures"))); }
@Override public boolean applies(GameEvent event, Ability source, Game game) { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent.isTapped()) { return false; } return super.applies(event, source, game); }
public NornsAnnex(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{3}{W/P}{W/P}"); // {W/P} ({W/P} can be paid with either or 2 life.) // Creatures can't attack you or a planeswalker you control unless their controller pays {W/P} for each of those creatures. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl<>("{W/P}"), true))); }
public GhostlyPrison(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{W}"); // Creatures can't attack you unless their controller pays {2} for each creature he or she controls that's attacking you this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl("{2}")))); }
public Propaganda(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{U}"); // Creatures can't attack you unless their controller pays {2} for each creature he or she controls that's attacking you. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl("{2}")))); }
public WindbornMuse(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{W}"); this.subtype.add(SubType.SPIRIT); this.power = new MageInt(2); this.toughness = new MageInt(3); // Flying this.addAbility(FlyingAbility.getInstance()); // Creatures can't attack you unless their controller pays {2} for each creature he or she controls that's attacking you. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl("{2}")))); }
public ElephantGrass(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{G}"); // Cumulative upkeep {1} this.addAbility(new CumulativeUpkeepAbility(new ManaCostsImpl("{1}"))); // Black creatures can't attack you. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouAllEffect(Duration.WhileOnBattlefield, filterBlack))); // Nonblack creatures can't attack you unless their controller pays {2} for each creature he or she controls that's attacking you. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl<>("{2"), false, filter))); }
public KoskunFalls(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{2}{B}{B}"); addSuperType(SuperType.WORLD); // At the beginning of your upkeep, sacrifice Koskun Falls unless you tap an untapped creature you control. Effect effect = new SacrificeSourceUnlessPaysEffect(new TapTargetCost(new TargetControlledCreaturePermanent(1, 1, filterCreature, true))); effect.setText("sacrifice Koskun Falls unless you tap an untapped creature you control"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // Creatures can't attack you unless their controller pays {2} for each creature he or she controls that's attacking you. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackYouUnlessPayManaAllEffect(new ManaCostsImpl("{2}")))); }
public ForbiddingSpirit(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{W}{W}"); this.subtype.add(SubType.SPIRIT); this.subtype.add(SubType.CLERIC); this.power = new MageInt(3); this.toughness = new MageInt(3); // When Forbidding Spirit enters the battlefield, until your next turn, creatures can't attack you or a planeswalker you control unless their controller pays {2} for each of those creatures. ContinuousEffect effect = new CantAttackYouUnlessPayManaAllEffect( new ManaCostsImpl("{2}"), true ); effect.setDuration(Duration.UntilYourNextTurn); effect.setText("until your next turn, creatures can't attack you or a planeswalker you control " + "unless their controller pays {2} for each of those creatures."); this.addAbility(new EntersBattlefieldTriggeredAbility(effect)); }