mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 04:38:00 +00:00
- Fixed March of the Machines.
This commit is contained in:
@@ -2,9 +2,9 @@ Name:March of the Machines
|
||||
ManaCost:3 U
|
||||
Types:Enchantment
|
||||
Text:no text
|
||||
S:Mode$ Continuous | Affected$ Artifact.nonCreature | SetPower$ MarchoftheMachinesX | SetToughness$ MarchoftheMachinesX | AddType$ Creature | AddSVar$ MarchoftheMachinesX | Description$ Each noncreature artifact is an artifact creature with power and toughness each equal to its converted mana cost. (Equipment that's a creature can't equip a creature.)
|
||||
S:Mode$ Continuous | Affected$ Artifact.nonCreature | SetPower$ AffectedX | SetToughness$ AffectedX | AddType$ Creature | Description$ Each noncreature artifact is an artifact creature with power and toughness each equal to its converted mana cost. (Equipment that's a creature can't equip a creature.)
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:MarchoftheMachinesX:Count$CardManaCost
|
||||
SVar:AffectedX:Count$CardManaCost
|
||||
SVar:Rarity:Rare
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/march_of_the_machines.jpg
|
||||
SetInfo:MRD|Rare|http://magiccards.info/scans/en/mi/42.jpg
|
||||
|
||||
@@ -40,7 +40,9 @@ public class StaticAbility_Continuous {
|
||||
|
||||
int powerBonus = 0;
|
||||
int toughnessBonus = 0;
|
||||
String setP = "";
|
||||
int setPower = -1;
|
||||
String setT = "";
|
||||
int setToughness = -1;
|
||||
String[] addKeywords = null;
|
||||
String[] addHiddenKeywords = null;
|
||||
@@ -58,13 +60,13 @@ public class StaticAbility_Continuous {
|
||||
boolean removeCreatureTypes = false;
|
||||
|
||||
if (params.containsKey("SetPower")) {
|
||||
String setP = params.get("SetPower");
|
||||
setP = params.get("SetPower");
|
||||
setPower = setP.matches("[0-9][0-9]?") ? Integer.parseInt(setP)
|
||||
: CardFactoryUtil.xCount(hostCard, hostCard.getSVar(setP));
|
||||
}
|
||||
|
||||
if (params.containsKey("SetToughness")) {
|
||||
String setT = params.get("SetToughness");
|
||||
setT = params.get("SetToughness");
|
||||
setToughness = setT.matches("[0-9][0-9]?") ? Integer.parseInt(setT)
|
||||
: CardFactoryUtil.xCount(hostCard, hostCard.getSVar(setT));
|
||||
}
|
||||
@@ -202,6 +204,12 @@ public class StaticAbility_Continuous {
|
||||
}
|
||||
else //non CharacteristicDefining
|
||||
if (setPower != -1 || setToughness != -1) {
|
||||
if (setP.startsWith("AffectedX")) {
|
||||
setPower = CardFactoryUtil.xCount(affectedCard, hostCard.getSVar(setP));
|
||||
}
|
||||
if (setT.startsWith("AffectedX")) {
|
||||
setToughness = CardFactoryUtil.xCount(affectedCard, hostCard.getSVar(setT));
|
||||
}
|
||||
affectedCard.addNewPT(setPower, setToughness, hostCard.getTimestamp());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user