Fortify use :

This commit is contained in:
Hanmac
2018-08-17 15:19:09 +02:00
parent 22766f9942
commit a72dfcacea
2 changed files with 3 additions and 12 deletions

View File

@@ -3819,24 +3819,15 @@ public class CardFactoryUtil {
} else if (keyword.startsWith("Fortify")) {
final String equipString = keyword.substring(7);
final String[] equipExtras = equipString.contains("|") ? equipString.split("\\|", 2) : null;
String[] k = keyword.split(":");
// Get cost string
String equipCost = "";
if (equipExtras != null) {
equipCost = equipExtras[0].trim();
} else {
equipCost = equipString.trim();
}
String equipCost = k[1];
// Create attach ability string
final StringBuilder abilityStr = new StringBuilder();
abilityStr.append("AB$ Attach | Cost$ ");
abilityStr.append(equipCost);
abilityStr.append(" | ValidTgts$ Land.YouCtrl | TgtPrompt$ Select target land you control ");
abilityStr.append("| SorcerySpeed$ True | AILogic$ Pump | IsPresent$ Fortification.Self+nonCreature ");
if (equipExtras != null) {
abilityStr.append("| ").append(equipExtras[1]).append(" ");
}
abilityStr.append("| PrecostDesc$ Fortify");
Cost cost = new Cost(equipCost, true);
abilityStr.append(cost.isOnlyManaCost() ? " " : "");

View File

@@ -1,7 +1,7 @@
Name:Darksteel Garrison
ManaCost:2
Types:Artifact Fortification
K:Fortify 3
K:Fortify:3
S:Mode$ Continuous | Affected$ Land.FortifiedBy | AddKeyword$ Indestructible | Description$ Fortified land has indestructible.
T:Mode$ Taps | ValidCard$ Land.FortifiedBy | Execute$ TrigPump | TriggerDescription$ Whenever fortified land becomes tapped, target creature gets +1/+1 until end of turn.
SVar:TrigPump:DB$ Pump | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ 1 | NumDef$ 1