public Rathtar(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}{G}"); this.subtype.add(SubType.BEAST); this.power = new MageInt(4); this.toughness = new MageInt(4); // {5}{G}{G}: Monstrosity 2. this.addAbility(new MonstrosityAbility("{5}{G}{G}", 2)); // When Rathtar becomes monstrous, any number of target creatures must block it this turn if able. Ability ability = new BecomesMonstrousSourceTriggeredAbility( new BlocksIfAbleTargetEffect(Duration.EndOfTurn).setText("any number of target creatures must block it this turn if able")); ability.addTarget(new TargetCreaturePermanent(0, Integer.MAX_VALUE)); this.addAbility(ability); }
public Resistance(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{R}{W}"); // Whenever a creature enters the battlefield under your control, Resistance deals 1 damage to each opponent. this.addAbility(new EntersBattlefieldControlledTriggeredAbility(Zone.BATTLEFIELD, new DamagePlayersEffect(1, TargetController.OPPONENT), StaticFilters.FILTER_PERMANENT_CREATURE, false)); // {R}{W}: Target creature gains haste until end of turn and must attack or block this turn if able. Ability ability = new SimpleActivatedAbility( new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn) .setText("Target creature gains haste until end of turn"), new ManaCostsImpl("{R}{W}")); ability.addEffect(new AttacksIfAbleTargetEffect(Duration.EndOfTurn).setText("and must attack")); //ability.addEffect(new GainAbilityTargetEffect(AttacksThisTurnMarkerAbility.getInstance(), Duration.EndOfTurn, "").setText("")); ability.addEffect(new BlocksIfAbleTargetEffect(Duration.EndOfTurn).setText("or block this turn if able")); //ability.addEffect(new GainAbilityTargetEffect(BlocksThisTurnMarkerAbility.getInstance(), Duration.EndOfTurn, "").setText("")); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); }