mirror of
https://github.com/correl/mage.git
synced 2025-04-01 19:07:57 -09:00
Implemented Blood Aspirant
This commit is contained in:
parent
be068fb9cf
commit
d1839badb2
2 changed files with 105 additions and 0 deletions
Mage.Sets/src/mage
104
Mage.Sets/src/mage/cards/b/BloodAspirant.java
Normal file
104
Mage.Sets/src/mage/cards/b/BloodAspirant.java
Normal file
|
@ -0,0 +1,104 @@
|
|||
package mage.cards.b;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.abilities.effects.common.combat.CantBlockTargetEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.common.FilterControlledPermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.CardTypePredicate;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class BloodAspirant extends CardImpl {
|
||||
|
||||
private static final FilterControlledPermanent filter = new FilterControlledPermanent("a creature or enchantment");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(
|
||||
new CardTypePredicate(CardType.CREATURE),
|
||||
new CardTypePredicate(CardType.ENCHANTMENT)
|
||||
));
|
||||
}
|
||||
|
||||
public BloodAspirant(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{R}");
|
||||
|
||||
this.subtype.add(SubType.SATYR);
|
||||
this.subtype.add(SubType.BERSERKER);
|
||||
this.power = new MageInt(1);
|
||||
this.toughness = new MageInt(1);
|
||||
|
||||
// Whenever you sacrifice a permanent, put a +1/+1 counter on Blood Aspirant.
|
||||
this.addAbility(new BloodAspirantAbility());
|
||||
|
||||
// {1}{R}, {T}, Sacrifice a creature or enchantment: Blood Aspirant deals 1 damage to target creature. That creature can't block this turn.
|
||||
Ability ability = new SimpleActivatedAbility(
|
||||
new DamageTargetEffect(1), new ManaCostsImpl("{1}{R}")
|
||||
);
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter)));
|
||||
ability.addEffect(new CantBlockTargetEffect(Duration.EndOfTurn)
|
||||
.setText("That creature can't block this turn."));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
private BloodAspirant(final BloodAspirant card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BloodAspirant copy() {
|
||||
return new BloodAspirant(this);
|
||||
}
|
||||
}
|
||||
|
||||
class BloodAspirantAbility extends TriggeredAbilityImpl {
|
||||
|
||||
BloodAspirantAbility() {
|
||||
super(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.P1P1.createInstance()));
|
||||
}
|
||||
|
||||
private BloodAspirantAbility(final BloodAspirantAbility ability) {
|
||||
super(ability);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BloodAspirantAbility copy() {
|
||||
return new BloodAspirantAbility(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkEventType(GameEvent event, Game game) {
|
||||
return event.getType() == GameEvent.EventType.SACRIFICED_PERMANENT;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
return event.getPlayerId().equals(this.getControllerId());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "Whenever you sacrifice a permanent, put a +1/+1 counter on {this}.";
|
||||
}
|
||||
}
|
|
@ -36,6 +36,7 @@ public final class TherosBeyondDeath extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Athreos, Shroud-Veiled", 269, Rarity.MYTHIC, mage.cards.a.AthreosShroudVeiled.class));
|
||||
cards.add(new SetCardInfo("Atris, Oracle of Half-Truths", 209, Rarity.RARE, mage.cards.a.AtrisOracleOfHalfTruths.class));
|
||||
cards.add(new SetCardInfo("Banishing Light", 4, Rarity.UNCOMMON, mage.cards.b.BanishingLight.class));
|
||||
cards.add(new SetCardInfo("Blood Aspirant", 128, Rarity.UNCOMMON, mage.cards.b.BloodAspirant.class));
|
||||
cards.add(new SetCardInfo("Brine Giant", 44, Rarity.COMMON, mage.cards.b.BrineGiant.class));
|
||||
cards.add(new SetCardInfo("Chainweb Aracnir", 167, Rarity.UNCOMMON, mage.cards.c.ChainwebAracnir.class));
|
||||
cards.add(new SetCardInfo("Cling to Dust", 87, Rarity.UNCOMMON, mage.cards.c.ClingToDust.class));
|
||||
|
|
Loading…
Add table
Reference in a new issue