mirror of
https://github.com/magefree/mage.git
synced 2025-12-22 11:32:00 -08:00
Implement Chamber Sentry
This commit is contained in:
parent
958752d8e9
commit
66c152a2e7
1 changed files with 57 additions and 0 deletions
57
Mage.Sets/src/mage/cards/c/ChamberSentry.java
Normal file
57
Mage.Sets/src/mage/cards/c/ChamberSentry.java
Normal file
|
|
@ -0,0 +1,57 @@
|
||||||
|
package mage.cards.c;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.common.SimpleActivatedAbility;
|
||||||
|
import mage.abilities.costs.common.TapSourceCost;
|
||||||
|
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||||
|
import mage.abilities.dynamicvalue.common.ManacostVariableValue;
|
||||||
|
import mage.abilities.effects.Effect;
|
||||||
|
import mage.abilities.effects.common.DamageTargetEffect;
|
||||||
|
import mage.abilities.effects.common.ReturnSourceFromGraveyardToHandEffect;
|
||||||
|
import mage.abilities.keyword.SunburstAbility;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.SubType;
|
||||||
|
import mage.constants.Zone;
|
||||||
|
import mage.target.common.TargetAnyTarget;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author jmharmon
|
||||||
|
*/
|
||||||
|
|
||||||
|
public final class ChamberSentry extends CardImpl {
|
||||||
|
|
||||||
|
public ChamberSentry(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT,CardType.CREATURE}, "{X}");
|
||||||
|
|
||||||
|
this.subtype.add(SubType.CONSTRUCT);
|
||||||
|
this.power = new MageInt(0);
|
||||||
|
this.toughness = new MageInt(0);
|
||||||
|
|
||||||
|
// Chamber Sentry enters the battlefield with a +1/+1 counter on it for each color of mana spent to cast it.
|
||||||
|
this.addAbility(new SunburstAbility(this));
|
||||||
|
|
||||||
|
// {X}, {T}, Remove X +1/+1 counters from Chamber Sentry: It deals X damage to any target.
|
||||||
|
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new ManacostVariableValue()), new ManaCostsImpl("{X}"));
|
||||||
|
ability.addCost(new TapSourceCost());
|
||||||
|
ability.addTarget(new TargetAnyTarget());
|
||||||
|
this.addAbility(ability);
|
||||||
|
|
||||||
|
// {W}{U}{B}{R}{G}: Return Chamber Sentry from your graveyard to your hand.
|
||||||
|
this.addAbility(new SimpleActivatedAbility(Zone.GRAVEYARD, new ReturnSourceFromGraveyardToHandEffect(), new ManaCostsImpl("{W}{U}{B}{R}{G}")));
|
||||||
|
}
|
||||||
|
|
||||||
|
public ChamberSentry(final ChamberSentry card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ChamberSentry copy() {
|
||||||
|
return new ChamberSentry(this);
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue