mirror of
https://github.com/correl/mage.git
synced 2024-11-15 03:00:16 +00:00
implement Chaos Maw
This commit is contained in:
parent
e302e5f302
commit
7028f8ee3d
3 changed files with 65 additions and 0 deletions
36
Mage.Sets/src/mage/cards/c/ChaosMaw.java
Normal file
36
Mage.Sets/src/mage/cards/c/ChaosMaw.java
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
package mage.cards.c;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||||
|
import mage.abilities.effects.common.DamageAllEffect;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.filter.common.FilterCreaturePermanent;
|
||||||
|
import mage.filter.predicate.permanent.AnotherPredicate;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
public class ChaosMaw extends CardImpl {
|
||||||
|
private static FilterCreaturePermanent filter = new FilterCreaturePermanent("other creature");
|
||||||
|
static {
|
||||||
|
filter.add(new AnotherPredicate());
|
||||||
|
}
|
||||||
|
public ChaosMaw(UUID ownerId, CardSetInfo cardSetInfo){
|
||||||
|
super(ownerId, cardSetInfo, new CardType[]{CardType.CREATURE}, "{5}{R}{R}");
|
||||||
|
subtype.add("Hellion");
|
||||||
|
power = new MageInt(6);
|
||||||
|
toughness = new MageInt(6);
|
||||||
|
|
||||||
|
// When Chaos Maw enters the battlefield, it deals 3 damage to each other creature
|
||||||
|
addAbility(new EntersBattlefieldTriggeredAbility(new DamageAllEffect(3, filter)));
|
||||||
|
}
|
||||||
|
|
||||||
|
public ChaosMaw(final ChaosMaw chaosMaw){
|
||||||
|
super(chaosMaw);
|
||||||
|
}
|
||||||
|
|
||||||
|
public ChaosMaw copy(){
|
||||||
|
return new ChaosMaw(this);
|
||||||
|
}
|
||||||
|
}
|
|
@ -76,6 +76,7 @@ public class HourOfDevastation extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Carrion Screecher", 61, Rarity.COMMON, mage.cards.c.CarrionScreecher.class));
|
cards.add(new SetCardInfo("Carrion Screecher", 61, Rarity.COMMON, mage.cards.c.CarrionScreecher.class));
|
||||||
cards.add(new SetCardInfo("Champion of Wits", 31, Rarity.RARE, mage.cards.c.ChampionOfWits.class));
|
cards.add(new SetCardInfo("Champion of Wits", 31, Rarity.RARE, mage.cards.c.ChampionOfWits.class));
|
||||||
cards.add(new SetCardInfo("Chandra's Defeat", 86, Rarity.UNCOMMON, mage.cards.c.ChandrasDefeat.class));
|
cards.add(new SetCardInfo("Chandra's Defeat", 86, Rarity.UNCOMMON, mage.cards.c.ChandrasDefeat.class));
|
||||||
|
cards.add(new SetCardInfo("Chaos Maw", 87, Rarity.RARE, mage.cards.c.ChaosMaw.class));
|
||||||
cards.add(new SetCardInfo("Cinder Barrens", 209, Rarity.COMMON, mage.cards.c.CinderBarrens.class));
|
cards.add(new SetCardInfo("Cinder Barrens", 209, Rarity.COMMON, mage.cards.c.CinderBarrens.class));
|
||||||
cards.add(new SetCardInfo("Claim // Fame", 150, Rarity.UNCOMMON, mage.cards.c.ClaimFame.class));
|
cards.add(new SetCardInfo("Claim // Fame", 150, Rarity.UNCOMMON, mage.cards.c.ClaimFame.class));
|
||||||
cards.add(new SetCardInfo("Crook of Condemnation", 159, Rarity.UNCOMMON, mage.cards.c.CrookOfCondemnation.class));
|
cards.add(new SetCardInfo("Crook of Condemnation", 159, Rarity.UNCOMMON, mage.cards.c.CrookOfCondemnation.class));
|
||||||
|
|
|
@ -0,0 +1,28 @@
|
||||||
|
package org.mage.test.cards.single.hou;
|
||||||
|
|
||||||
|
import mage.constants.PhaseStep;
|
||||||
|
import mage.constants.Zone;
|
||||||
|
import org.junit.Test;
|
||||||
|
import org.mage.test.serverside.base.CardTestPlayerBase;
|
||||||
|
|
||||||
|
public class ChaosMawTest extends CardTestPlayerBase {
|
||||||
|
|
||||||
|
private String chaosMaw = "Chaos Maw";
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testChaosMaw(){
|
||||||
|
addCard(Zone.HAND, playerA, chaosMaw, 1);
|
||||||
|
addCard(Zone.BATTLEFIELD, playerA, "Mountain", 10);
|
||||||
|
addCard(Zone.BATTLEFIELD, playerA, "Grizzly Bears", 1);
|
||||||
|
addCard(Zone.BATTLEFIELD, playerB, "Savannah Lions", 1);
|
||||||
|
|
||||||
|
castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, chaosMaw );
|
||||||
|
|
||||||
|
setStopAt(1, PhaseStep.POSTCOMBAT_MAIN);
|
||||||
|
|
||||||
|
execute();
|
||||||
|
|
||||||
|
assertGraveyardCount(playerA, "Grizzly Bears", 1);
|
||||||
|
assertGraveyardCount(playerB, "Savannah Lions", 1);
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue