- Added support for restrictions in alternate costs (same as those of AbilityFactory).

- Added Lashknife.
This commit is contained in:
Sloth
2011-08-27 10:11:38 +00:00
parent 5664e1ba2c
commit d4dc60d8c9
3 changed files with 17 additions and 0 deletions

1
.gitattributes vendored
View File

@@ -4226,6 +4226,7 @@ res/cardsfolder/l/lapse_of_certainty.txt svneol=native#text/plain
res/cardsfolder/l/laquatuss_champion.txt svneol=native#text/plain
res/cardsfolder/l/larceny.txt svneol=native#text/plain
res/cardsfolder/l/lash_out.txt svneol=native#text/plain
res/cardsfolder/l/lashknife.txt -text
res/cardsfolder/l/lashknife_barrier.txt svneol=native#text/plain
res/cardsfolder/l/lashwrithe.txt svneol=native#text/plain
res/cardsfolder/l/last_breath.txt svneol=native#text/plain

View File

@@ -0,0 +1,11 @@
Name:Lashknife
ManaCost:1 W
Types:Enchantment Aura
Text:no text
K:Enchant creature
A:SP$ Attach | Cost$ 1 W | ValidTgts$ Creature | AILogic$ Pump
S:Mode$ Continuous | Affected$ Creature.EnchantedBy | AddKeyword$ First Strike | Description$ Enchanted creature has first strike.
SVar:AltCost:Cost$ tapXType<1/Creature> | IsPresent$ Plains.YouCtrl | Description$ If you control a Plains, you may tap an untapped creature you control rather than pay Lashknife's mana cost.
SVar:Rarity:Common
SVar:Picture:http://www.wizards.com/global/images/magic/general/lashknife.jpg
End

View File

@@ -4490,6 +4490,11 @@ public class CardFactoryUtil {
sb.append(" rather than pay ").append(card.getName()).append("'s mana cost.");
}
SpellAbility_Restriction restriction = new SpellAbility_Restriction();
restriction.setRestrictions(mapParams);
restriction.setZone(Constant.Zone.Hand);
altCostSA.setRestrictions(restriction);
altCostSA.setDescription(sb.toString());
card.addSpellAbility(altCostSA);