Tunnel Ignus added

This commit is contained in:
Maxmtg
2013-05-08 08:12:14 +00:00
parent 37797e4562
commit d1b415e39f
4 changed files with 20 additions and 8 deletions

1
.gitattributes vendored
View File

@@ -11545,6 +11545,7 @@ res/cardsfolder/t/tundra.txt svneol=native#text/plain
res/cardsfolder/t/tundra_kavu.txt -text
res/cardsfolder/t/tundra_wolves.txt svneol=native#text/plain
res/cardsfolder/t/tunnel.txt svneol=native#text/plain
res/cardsfolder/t/tunnel_ignus.txt -text
res/cardsfolder/t/tunneler_wurm.txt svneol=native#text/plain
res/cardsfolder/t/turbulent_dreams.txt -text
res/cardsfolder/t/turf_wound.txt -text

View File

@@ -0,0 +1,10 @@
Name:Tunnel Ignus
ManaCost:1 R
Types:Creature Elemental
PT:2/1
T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Land.OppCtrl | CheckOnTriggeredCard$ X GT1 | TriggerZones$ Battlefield | Execute$ TrigPump | TriggerDescription$ Whenever a land enters the battlefield under an opponent's control, if that player had another land enter the battlefield under his or her control this turn, CARDNAME deals 3 damage to that player.
SVar:TrigPump:AB$DealDamage | Cost$ 0 | Defined$ TriggeredCardController | NumDmg$ 3
SVar:X:ThisTurnEntered_Battlefield_Land.YouCtrl
SVar:Picture:http://www.wizards.com/global/images/magic/general/tunner_ignus.jpg
Oracle:Whenever a land enters the battlefield under an opponent's control, if that player had another land enter the battlefield under his or her control this turn, Tunnel Ignus deals 3 damage to that player.
SetInfo:SOM Rare

View File

@@ -1124,13 +1124,17 @@ public class CardFactoryUtil {
return doXMath(xCount(c, c.getSVar(l[0].substring(5))), m, c);
}
if (l[0].startsWith("Controller$"))
return playerXProperty(cc, l[0].substring(11), c);
// Manapool
if (l[0].startsWith("ManaPool")) {
final String color = l[0].split(":")[1];
if (color.equals("All")) {
return c.getController().getManaPool().totalMana();
return cc.getManaPool().totalMana();
} else {
return c.getController().getManaPool().getAmountOfColor(color);
return cc.getManaPool().getAmountOfColor(color);
}
}
@@ -1140,8 +1144,8 @@ public class CardFactoryUtil {
final String[] rest = lparts[1].split(",");
final List<Card> cardsInZones = lparts[0].length() > 5
? cc.getGame().getCardsIn(ZoneType.listValueOf(lparts[0].substring(5)))
: cc.getGame().getCardsIn(ZoneType.Battlefield);
? game.getCardsIn(ZoneType.listValueOf(lparts[0].substring(5)))
: game.getCardsIn(ZoneType.Battlefield);
List<Card> cards = CardLists.getValidCards(cardsInZones, rest, cc, c);
return doXMath(cards.size(), m, c);

View File

@@ -88,10 +88,7 @@ public class TriggerChangesZone extends Trigger {
final Card host = hostCard.getGame().getCardState(hostCard);
final String comparator = condition.length < 2 ? "GE1" : condition[1];
final int referenceValue = AbilityUtils.calculateAmount(host, comparator.substring(2), null);
final Object triggered = runParams2.get("Card");
if(!(triggered instanceof Card))
throw new IllegalArgumentException( host + " - CheckOnTriggeredCard being checked for a trigger that has no card!");
final Card triggered = (Card)runParams2.get("Card");
final int actualValue = CardFactoryUtil.xCount((Card)triggered, host.getSVar(condition[0]));
if (!Expressions.compare(actualValue, comparator.substring(0, 2), referenceValue)) {
return false;