mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
- Added Fetchlands to randomly generated decks.
- Updated some SVars.
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -9753,6 +9753,7 @@ src/main/java/forge/deck/generate/Generate3ColorDeck.java svneol=native#text/pla
|
||||
src/main/java/forge/deck/generate/Generate5ColorDeck.java svneol=native#text/plain
|
||||
src/main/java/forge/deck/generate/GenerateConstructedDeck.java svneol=native#text/plain
|
||||
src/main/java/forge/deck/generate/GenerateConstructedMultiColorDeck.java svneol=native#text/plain
|
||||
src/main/java/forge/deck/generate/GenerateDeckUtil.java -text
|
||||
src/main/java/forge/deck/generate/GenerateThemeDeck.java svneol=native#text/plain
|
||||
src/main/java/forge/deck/generate/package-info.java svneol=native#text/plain
|
||||
src/main/java/forge/deck/package-info.java svneol=native#text/plain
|
||||
|
||||
@@ -4,6 +4,7 @@ Types:Artifact
|
||||
Text:no text
|
||||
A:AB$ Draw | Cost$ 1 Sac<1/CARDNAME> | NumCards$ 1 | SpellDescription$ Draw a card.
|
||||
A:AB$ ChangeZone | Cost$ U Sac<1/CARDNAME> | ValidTgts$ Creature | TgtPrompt$ Select target creature | Origin$ Battlefield | Destination$ Hand | SpellDescription$ Return target creature to its owner's hand.
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/aether_spellbomb.jpg
|
||||
SetInfo:MRD|Common|http://magiccards.info/scans/en/mi/141.jpg
|
||||
|
||||
@@ -4,6 +4,7 @@ Types:Artifact
|
||||
Text:no text
|
||||
A:AB$ Animate | Cost$ G Sac<1/CARDNAME> | ValidTgts$ Land | TgtPrompt$ Select target land | Power$ 3 | Toughness$ 3 | Types$ Creature | SpellDescription$ Until end of turn, target land becomes a 3/3 creature that's still a land.
|
||||
A:AB$ Draw | Cost$ 1 Sac<1/CARDNAME> | NumCards$ 1 | SpellDescription$ Draw a card.
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/lifespark_spellbomb.jpg
|
||||
SetInfo:MRD|Common|http://magiccards.info/scans/en/mi/197.jpg
|
||||
|
||||
@@ -4,6 +4,7 @@ Types:Artifact
|
||||
Text:no text
|
||||
A:AB$ Discard | Cost$ B Sac<1/CARDNAME> | ValidTgts$ Player | NumCards$ 1 | Mode$ TgtChoose | SpellDescription$ Target player discards a card.
|
||||
A:AB$ Draw | Cost$ 1 Sac<1/CARDNAME> | NumCards$ 1 | SpellDescription$ Draw a card.
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/necrogen_spellbomb.jpg
|
||||
SetInfo:MRD|Common|http://magiccards.info/scans/en/mi/216.jpg
|
||||
|
||||
@@ -4,6 +4,7 @@ Types:Artifact
|
||||
Text:no text
|
||||
A:AB$ Draw | Cost$ 1 Sac<1/CARDNAME> | NumCards$ 1 | SpellDescription$ Draw a card.
|
||||
A:AB$ DealDamage | Cost$ R Sac<1/CARDNAME> | Tgt$ TgtCP | NumDmg$ 2 | SpellDescription$ CARDNAME deals 2 damage to target creature or player.
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/pyrite_spellbomb.jpg
|
||||
SetInfo:MRD|Common|http://magiccards.info/scans/en/mi/232.jpg
|
||||
|
||||
@@ -4,6 +4,7 @@ Types:Artifact
|
||||
Text:no text
|
||||
A:AB$ Draw | Cost$ 1 Sac<1/CARDNAME> | NumCards$ 1 | SpellDescription$ Draw a card.
|
||||
A:AB$ GainLife | Cost$ W Sac<1/CARDNAME> | LifeAmount$ 5 | SpellDescription$ You gain 5 life.
|
||||
SVar:RemRandomDeck:True
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/sunbeam_spellbomb.jpg
|
||||
SetInfo:MRD|Common|http://magiccards.info/scans/en/mi/250.jpg
|
||||
|
||||
@@ -21,7 +21,6 @@ public class Generate2ColorDeck {
|
||||
private Random r = null;
|
||||
private Map<String, String> ClrMap = null;
|
||||
private ArrayList<String> notColors = null;
|
||||
private ArrayList<DLnd> DualLands = null;
|
||||
private ArrayList<String> DL = null;
|
||||
private Map<String, Integer> CardCounts = null;
|
||||
|
||||
@@ -50,28 +49,6 @@ public class Generate2ColorDeck {
|
||||
notColors.add("red");
|
||||
notColors.add("green");
|
||||
|
||||
DualLands = new ArrayList<DLnd>();
|
||||
DualLands.add(new DLnd("Tundra", "WU"));
|
||||
DualLands.add(new DLnd("Hallowed Fountain", "WU"));
|
||||
DualLands.add(new DLnd("Underground Sea", "UB"));
|
||||
DualLands.add(new DLnd("Watery Grave", "UB"));
|
||||
DualLands.add(new DLnd("Badlands", "BR"));
|
||||
DualLands.add(new DLnd("Blood Crypt", "BR"));
|
||||
DualLands.add(new DLnd("Taiga", "RG"));
|
||||
DualLands.add(new DLnd("Stomping Ground", "RG"));
|
||||
DualLands.add(new DLnd("Savannah", "GW"));
|
||||
DualLands.add(new DLnd("Temple Garden", "GW"));
|
||||
DualLands.add(new DLnd("Scrubland", "WB"));
|
||||
DualLands.add(new DLnd("Godless Shrine", "WB"));
|
||||
DualLands.add(new DLnd("Volcanic Island", "UR"));
|
||||
DualLands.add(new DLnd("Steam Vents", "UR"));
|
||||
DualLands.add(new DLnd("Bayou", "BG"));
|
||||
DualLands.add(new DLnd("Overgrown Tomb", "BG"));
|
||||
DualLands.add(new DLnd("Plateau", "RW"));
|
||||
DualLands.add(new DLnd("Sacred Foundry", "RW"));
|
||||
DualLands.add(new DLnd("Tropical Island", "GU"));
|
||||
DualLands.add(new DLnd("Breeding Pool", "GU"));
|
||||
|
||||
if (Clr1.equals("AI")) {
|
||||
// choose first color
|
||||
color1 = notColors.get(r.nextInt(5));
|
||||
@@ -89,13 +66,10 @@ public class Generate2ColorDeck {
|
||||
notColors.remove(color1);
|
||||
notColors.remove(color2);
|
||||
|
||||
DL = new ArrayList<String>();
|
||||
for (int i = 0; i < DualLands.size(); i++) {
|
||||
DLnd d = DualLands.get(i);
|
||||
if (d.Mana.contains(ClrMap.get(color1)) && d.Mana.contains(ClrMap.get(color2))) {
|
||||
DL.add(d.Name);
|
||||
CardCounts.put(d.Name, 0);
|
||||
}
|
||||
DL = GenerateDeckUtil.getDualLandList(ClrMap.get(color1) + ClrMap.get(color2));
|
||||
|
||||
for (int i = 0; i < DL.size(); i++) {
|
||||
CardCounts.put(DL.get(i), 0);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -397,14 +371,4 @@ public class Generate2ColorDeck {
|
||||
Count = cnt;
|
||||
}
|
||||
}
|
||||
|
||||
private class DLnd {
|
||||
public String Name;
|
||||
public String Mana;
|
||||
|
||||
public DLnd(String nm, String mn) {
|
||||
Name = nm;
|
||||
Mana = mn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -22,7 +22,6 @@ public class Generate3ColorDeck {
|
||||
private Random r = null;
|
||||
private Map<String, String> ClrMap = null;
|
||||
private ArrayList<String> notColors = null;
|
||||
private ArrayList<DLnd> DualLands = null;
|
||||
private ArrayList<String> DL = null;
|
||||
private Map<String, Integer> CardCounts = null;
|
||||
|
||||
@@ -52,28 +51,6 @@ public class Generate3ColorDeck {
|
||||
notColors.add("red");
|
||||
notColors.add("green");
|
||||
|
||||
DualLands = new ArrayList<DLnd>();
|
||||
DualLands.add(new DLnd("Tundra", "WU"));
|
||||
DualLands.add(new DLnd("Hallowed Fountain", "WU"));
|
||||
DualLands.add(new DLnd("Underground Sea", "UB"));
|
||||
DualLands.add(new DLnd("Watery Grave", "UB"));
|
||||
DualLands.add(new DLnd("Badlands", "BR"));
|
||||
DualLands.add(new DLnd("Blood Crypt", "BR"));
|
||||
DualLands.add(new DLnd("Taiga", "RG"));
|
||||
DualLands.add(new DLnd("Stomping Ground", "RG"));
|
||||
DualLands.add(new DLnd("Savannah", "GW"));
|
||||
DualLands.add(new DLnd("Temple Garden", "GW"));
|
||||
DualLands.add(new DLnd("Scrubland", "WB"));
|
||||
DualLands.add(new DLnd("Godless Shrine", "WB"));
|
||||
DualLands.add(new DLnd("Volcanic Island", "UR"));
|
||||
DualLands.add(new DLnd("Steam Vents", "UR"));
|
||||
DualLands.add(new DLnd("Bayou", "BG"));
|
||||
DualLands.add(new DLnd("Overgrown Tomb", "BG"));
|
||||
DualLands.add(new DLnd("Plateau", "RW"));
|
||||
DualLands.add(new DLnd("Sacred Foundry", "RW"));
|
||||
DualLands.add(new DLnd("Tropical Island", "GU"));
|
||||
DualLands.add(new DLnd("Breeding Pool", "GU"));
|
||||
|
||||
if (Clr1.equals("AI")) {
|
||||
// choose first color
|
||||
color1 = notColors.get(r.nextInt(5));
|
||||
@@ -98,15 +75,10 @@ public class Generate3ColorDeck {
|
||||
notColors.remove(color2);
|
||||
notColors.remove(color3);
|
||||
|
||||
DL = new ArrayList<String>();
|
||||
for (int i = 0; i < DualLands.size(); i++) {
|
||||
DLnd d = DualLands.get(i);
|
||||
if ((d.Mana.contains(ClrMap.get(color1)) && d.Mana.contains(ClrMap.get(color2))) ||
|
||||
(d.Mana.contains(ClrMap.get(color1)) && d.Mana.contains(ClrMap.get(color3))) ||
|
||||
(d.Mana.contains(ClrMap.get(color2)) && d.Mana.contains(ClrMap.get(color3)))) {
|
||||
DL.add(d.Name);
|
||||
CardCounts.put(d.Name, 0);
|
||||
}
|
||||
DL = GenerateDeckUtil.getDualLandList(ClrMap.get(color1) + ClrMap.get(color2) + ClrMap.get(color3));
|
||||
|
||||
for (int i = 0; i < DL.size(); i++) {
|
||||
CardCounts.put(DL.get(i), 0);
|
||||
}
|
||||
|
||||
}
|
||||
@@ -408,14 +380,4 @@ public class Generate3ColorDeck {
|
||||
Count = cnt;
|
||||
}
|
||||
}
|
||||
|
||||
private class DLnd {
|
||||
public String Name;
|
||||
public String Mana;
|
||||
|
||||
public DLnd(String nm, String mn) {
|
||||
Name = nm;
|
||||
Mana = mn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,7 +31,6 @@ public class Generate5ColorDeck {
|
||||
private Random r = null;
|
||||
private Map<String, String> clrMap = null;
|
||||
private ArrayList<String> notColors = null;
|
||||
private ArrayList<DLnd> dualLands = null;
|
||||
private ArrayList<String> dl = null;
|
||||
private Map<String, Integer> cardCounts = null;
|
||||
|
||||
@@ -72,28 +71,6 @@ public class Generate5ColorDeck {
|
||||
notColors.add("red");
|
||||
notColors.add("green");
|
||||
|
||||
dualLands = new ArrayList<DLnd>();
|
||||
dualLands.add(new DLnd("Tundra", "WU"));
|
||||
dualLands.add(new DLnd("Hallowed Fountain", "WU"));
|
||||
dualLands.add(new DLnd("Underground Sea", "UB"));
|
||||
dualLands.add(new DLnd("Watery Grave", "UB"));
|
||||
dualLands.add(new DLnd("Badlands", "BR"));
|
||||
dualLands.add(new DLnd("Blood Crypt", "BR"));
|
||||
dualLands.add(new DLnd("Taiga", "RG"));
|
||||
dualLands.add(new DLnd("Stomping Ground", "RG"));
|
||||
dualLands.add(new DLnd("Savannah", "GW"));
|
||||
dualLands.add(new DLnd("Temple Garden", "GW"));
|
||||
dualLands.add(new DLnd("Scrubland", "WB"));
|
||||
dualLands.add(new DLnd("Godless Shrine", "WB"));
|
||||
dualLands.add(new DLnd("Volcanic Island", "UR"));
|
||||
dualLands.add(new DLnd("Steam Vents", "UR"));
|
||||
dualLands.add(new DLnd("Bayou", "BG"));
|
||||
dualLands.add(new DLnd("Overgrown Tomb", "BG"));
|
||||
dualLands.add(new DLnd("Plateau", "RW"));
|
||||
dualLands.add(new DLnd("Sacred Foundry", "RW"));
|
||||
dualLands.add(new DLnd("Tropical Island", "GU"));
|
||||
dualLands.add(new DLnd("Breeding Pool", "GU"));
|
||||
|
||||
color1 = clr1;
|
||||
color2 = clr2;
|
||||
color3 = clr3;
|
||||
@@ -106,11 +83,10 @@ public class Generate5ColorDeck {
|
||||
notColors.remove(color4);
|
||||
notColors.remove(color5);
|
||||
|
||||
dl = new ArrayList<String>();
|
||||
for (int i = 0; i < dualLands.size(); i++) {
|
||||
DLnd d = dualLands.get(i);
|
||||
dl.add(d.getName());
|
||||
cardCounts.put(d.getName(), 0);
|
||||
dl = GenerateDeckUtil.getDualLandList("WUBRG");
|
||||
|
||||
for (int i = 0; i < dl.size(); i++) {
|
||||
cardCounts.put(dl.get(i), 0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -478,22 +454,4 @@ public class Generate5ColorDeck {
|
||||
this.count = count;
|
||||
}
|
||||
}
|
||||
|
||||
private class DLnd {
|
||||
private String name;
|
||||
//public String Mana;
|
||||
|
||||
/**
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
public String getName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
public DLnd(final String nm, final String mn) {
|
||||
this.name = nm;
|
||||
//Mana = mn;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
87
src/main/java/forge/deck/generate/GenerateDeckUtil.java
Normal file
87
src/main/java/forge/deck/generate/GenerateDeckUtil.java
Normal file
@@ -0,0 +1,87 @@
|
||||
package forge.deck.generate;
|
||||
|
||||
import forge.*;
|
||||
import forge.error.ErrorViewer;
|
||||
import forge.properties.ForgeProps;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
import java.util.Random;
|
||||
|
||||
/**
|
||||
* <p>Generate2ColorDeck class.</p>
|
||||
*
|
||||
* @author Forge
|
||||
* @version $Id: Generate2ColorDeck.java 10011 2011-08-28 12:20:52Z Sloth $
|
||||
*/
|
||||
public class GenerateDeckUtil {
|
||||
|
||||
|
||||
public static ArrayList<String> getDualLandList(String colors) {
|
||||
|
||||
ArrayList<String> DLands = new ArrayList<String>();
|
||||
|
||||
if (colors.contains("W") && colors.contains("U")) {
|
||||
DLands.add("Tundra");
|
||||
DLands.add("Hallowed Fountain");
|
||||
DLands.add("Flooded Strand");
|
||||
}
|
||||
|
||||
if (colors.contains("U") && colors.contains("B")) {
|
||||
DLands.add("Underground Sea");
|
||||
DLands.add("Watery Grave");
|
||||
DLands.add("Polluted Delta");
|
||||
}
|
||||
|
||||
if (colors.contains("B") && colors.contains("R")) {
|
||||
DLands.add("Badlands");
|
||||
DLands.add("Blood Crypt");
|
||||
DLands.add("Bloodstained Mire");
|
||||
}
|
||||
|
||||
if (colors.contains("R") && colors.contains("G")) {
|
||||
DLands.add("Taiga");
|
||||
DLands.add("Stomping Ground");
|
||||
DLands.add("Wooded Foothills");
|
||||
}
|
||||
|
||||
if (colors.contains("G") && colors.contains("W")) {
|
||||
DLands.add("Savannah");
|
||||
DLands.add("Temple Garden");
|
||||
DLands.add("Windswept Heath");
|
||||
}
|
||||
|
||||
if (colors.contains("W") && colors.contains("B")) {
|
||||
DLands.add("Scrubland");
|
||||
DLands.add("Godless Shrine");
|
||||
DLands.add("Marsh Flats");
|
||||
}
|
||||
|
||||
if (colors.contains("U") && colors.contains("R")) {
|
||||
DLands.add("Volcanic Island");
|
||||
DLands.add("Steam Vents");
|
||||
DLands.add("Scalding Tarn");
|
||||
}
|
||||
|
||||
if (colors.contains("B") && colors.contains("G")) {
|
||||
DLands.add("Bayou");
|
||||
DLands.add("Overgrown Tomb");
|
||||
DLands.add("Verdant Catacombs");
|
||||
}
|
||||
|
||||
if (colors.contains("R") && colors.contains("W")) {
|
||||
DLands.add("Plateau");
|
||||
DLands.add("Sacred Foundry");
|
||||
DLands.add("Arid Mesa");
|
||||
}
|
||||
|
||||
if (colors.contains("G") && colors.contains("U")) {
|
||||
DLands.add("Tropical Island");
|
||||
DLands.add("Breeding Pool");
|
||||
DLands.add("Misty Rainforest");
|
||||
}
|
||||
|
||||
return DLands;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user