forked from External/mage
58 lines
2.2 KiB
Java
58 lines
2.2 KiB
Java
package mage.cards.a;
|
|
|
|
import mage.MageInt;
|
|
import mage.abilities.common.DiesSourceTriggeredAbility;
|
|
import mage.abilities.common.GainLifeControllerTriggeredAbility;
|
|
import mage.abilities.dynamicvalue.DynamicValue;
|
|
import mage.abilities.dynamicvalue.common.CountersSourceCount;
|
|
import mage.abilities.effects.common.counter.AddCountersAllEffect;
|
|
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
|
import mage.abilities.keyword.LifelinkAbility;
|
|
import mage.cards.CardImpl;
|
|
import mage.cards.CardSetInfo;
|
|
import mage.constants.CardType;
|
|
import mage.constants.SubType;
|
|
import mage.constants.SuperType;
|
|
import mage.counters.CounterType;
|
|
import mage.filter.StaticFilters;
|
|
|
|
import java.util.UUID;
|
|
|
|
/**
|
|
* @author TheElk801
|
|
*/
|
|
public final class AerithGainsborough extends CardImpl {
|
|
|
|
private static final DynamicValue xValue = new CountersSourceCount(CounterType.P1P1);
|
|
|
|
public AerithGainsborough(UUID ownerId, CardSetInfo setInfo) {
|
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
|
|
|
|
this.supertype.add(SuperType.LEGENDARY);
|
|
this.subtype.add(SubType.HUMAN);
|
|
this.subtype.add(SubType.CLERIC);
|
|
this.power = new MageInt(2);
|
|
this.toughness = new MageInt(2);
|
|
|
|
// Lifelink
|
|
this.addAbility(LifelinkAbility.getInstance());
|
|
|
|
// Whenever you gain life, put a +1/+1 counter on Aerith Gainsborough.
|
|
this.addAbility(new GainLifeControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance())));
|
|
|
|
// When Aerith Gainsborough dies, put X +1/+1 counters on each legendary creature you control, where X is the number of +1/+1 counters on Aerith Gainsborough.
|
|
this.addAbility(new DiesSourceTriggeredAbility(new AddCountersAllEffect(
|
|
CounterType.P1P1.createInstance(), xValue, StaticFilters.FILTER_CONTROLLED_CREATURE_LEGENDARY
|
|
).setText("put X +1/+1 counters on each legendary creature you control, " +
|
|
"where X is the number of +1/+1 counters on {this}")));
|
|
}
|
|
|
|
private AerithGainsborough(final AerithGainsborough card) {
|
|
super(card);
|
|
}
|
|
|
|
@Override
|
|
public AerithGainsborough copy() {
|
|
return new AerithGainsborough(this);
|
|
}
|
|
}
|