diff --git a/Mage.Sets/src/mage/cards/o/OgreErrant.java b/Mage.Sets/src/mage/cards/o/OgreErrant.java new file mode 100644 index 0000000000..683342b6b4 --- /dev/null +++ b/Mage.Sets/src/mage/cards/o/OgreErrant.java @@ -0,0 +1,57 @@ +package mage.cards.o; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.MenaceAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.SubType; +import mage.filter.FilterPermanent; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.filter.predicate.permanent.AttackingPredicate; +import mage.target.TargetPermanent; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class OgreErrant extends CardImpl { + + private static final FilterPermanent filter + = new FilterPermanent(SubType.KNIGHT, "another attacking Knight"); + + static { + filter.add(AttackingPredicate.instance); + filter.add(AnotherPredicate.instance); + } + + public OgreErrant(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{R}"); + + this.subtype.add(SubType.OGRE); + this.subtype.add(SubType.KNIGHT); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Whenever Ogre Errant attacks, another target attacking Knight gains menace until end of turn. + Ability ability = new AttacksTriggeredAbility(new GainAbilityTargetEffect( + new MenaceAbility(), Duration.EndOfTurn + ).setText("another target attacking Knight gains menace until end of turn"), false); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + private OgreErrant(final OgreErrant card) { + super(card); + } + + @Override + public OgreErrant copy() { + return new OgreErrant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ThroneOfEldraine.java b/Mage.Sets/src/mage/sets/ThroneOfEldraine.java index f2c4a481c3..0b9e86b177 100644 --- a/Mage.Sets/src/mage/sets/ThroneOfEldraine.java +++ b/Mage.Sets/src/mage/sets/ThroneOfEldraine.java @@ -108,6 +108,7 @@ public final class ThroneOfEldraine extends ExpansionSet { cards.add(new SetCardInfo("Murderous Rider", 97, Rarity.RARE, mage.cards.m.MurderousRider.class)); cards.add(new SetCardInfo("Mystical Dispute", 58, Rarity.UNCOMMON, mage.cards.m.MysticalDispute.class)); cards.add(new SetCardInfo("Oakhame Ranger", 212, Rarity.UNCOMMON, mage.cards.o.OakhameRanger.class)); + cards.add(new SetCardInfo("Ogre Errant", 132, Rarity.COMMON, mage.cards.o.OgreErrant.class)); cards.add(new SetCardInfo("Oko's Accomplices", 310, Rarity.COMMON, mage.cards.o.OkosAccomplices.class)); cards.add(new SetCardInfo("Oko's Hospitality", 312, Rarity.RARE, mage.cards.o.OkosHospitality.class)); cards.add(new SetCardInfo("Oko, Thief of Crowns", 197, Rarity.MYTHIC, mage.cards.o.OkoThiefOfCrowns.class));