mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 20:28:00 +00:00
1) implement X in Drawback$MakeToken
2) add AEther Mutation (from Apocalypse) using Drawback$MakeToken X functionality
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -57,6 +57,7 @@ res/cardsfolder/aesthir_glider.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_adept.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_flash.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_membrane.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_mutation.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_spellbomb.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_vial.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/aether_web.txt -text svneol=native#text/plain
|
||||
|
||||
10
res/cardsfolder/aether_mutation.txt
Normal file
10
res/cardsfolder/aether_mutation.txt
Normal file
@@ -0,0 +1,10 @@
|
||||
Name:AEther Mutation
|
||||
ManaCost:3 G U
|
||||
Types:Sorcery
|
||||
Text:Return target creature to its owner's hand. Put X 1/1 green Saproling creature tokens onto the battlefield, where X is that creature's converted mana cost.
|
||||
K:spBounceTgt:Creature:Hand:Drawback$MakeToken<>X<>Saproling<>G 1 1 Saproling<>Controller<>G<>Creature;Saproling<>1<>1<>None
|
||||
#X will be the Converted Mana Cost of the target of AEther Mutation
|
||||
SVar:X:Count$CardManaCost
|
||||
SVar:Rarity:Uncommon
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/aether_mutation.jpg
|
||||
End
|
||||
@@ -3933,9 +3933,9 @@ public class CardFactoryUtil {
|
||||
|
||||
if(d[0].contains("MakeToken")) {
|
||||
final String[] k = d[0].split("<>");
|
||||
//final String numString = k[1].equals("X") ? Src.getSVar("X") : k[1];
|
||||
final String numString = k[1];
|
||||
//final boolean xString = k[1].equals("X") ? true : false;
|
||||
final String numString = k[1].equals("X") ? Src.getSVar("X") : k[1];
|
||||
//final String numString = k[1];
|
||||
final boolean xString = k[1].equals("X") ? true : false;
|
||||
final String name = k[2];
|
||||
final String imageName = k[3];
|
||||
final String controllerString = k[4];
|
||||
@@ -3945,17 +3945,14 @@ public class CardFactoryUtil {
|
||||
final int defense = Integer.valueOf(k[8]);
|
||||
final String[] keywords = k[9].split(";");
|
||||
|
||||
//String controller = (controllerString.equals("Controller") ? Src.getController() : AllZone.GameAction.getOpponent(card.getController()));
|
||||
String controller = controllerString.equals("Controller") ? cardController : Opp;
|
||||
if(keywords[0].equals("None")) keywords[0] = "";
|
||||
|
||||
if(keywords[0].equals("None")) keywords[0] = "";
|
||||
|
||||
//int num = xString ? CardFactoryUtil.xCount(card, numString) : Integer.valueOf(numString);
|
||||
int num = Integer.valueOf(numString);
|
||||
int num = xString ? CardFactoryUtil.xCount(TgtC, numString) : Integer.valueOf(numString);
|
||||
for(int i = 0; i < num; i ++ ){
|
||||
CardFactoryUtil.makeToken(name, imageName, controller, manaCost, types, attack, defense, keywords);
|
||||
}
|
||||
}
|
||||
}//end MakeToken drawback
|
||||
|
||||
|
||||
if(d[0].contains("ReturnFromYard")) // placeholder for effect
|
||||
|
||||
Reference in New Issue
Block a user