Added support for Ripple (Up to 10, but this can be easily changed). Added Thrumming Stone, Surging AEther, Surging Dementia, Surging Flame, Surging Might and Surging Sentinels

This commit is contained in:
jendave
2011-08-06 05:00:56 +00:00
parent 401fa2f768
commit 310cc0c034
4 changed files with 145 additions and 1 deletions

View File

@@ -38,6 +38,12 @@ snow_covered_mountain.jpg http://www.wizards.com/global/images/magic/gene
snow_covered_mountain1.jpg http://www.wizards.com/global/images/magic/general/snow_covered_mountain.jpg snow_covered_mountain1.jpg http://www.wizards.com/global/images/magic/general/snow_covered_mountain.jpg
snow_covered_mountain2.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg snow_covered_mountain2.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg
snow_covered_mountain3.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg snow_covered_mountain3.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg
thrumming_stone.jpg http://www.wizards.com/global/images/magic/general/thrumming_stone.jpg
surging_aether.jpg http://www.wizards.com/global/images/magic/general/surging_aether.jpg
surging_dementia.jpg http://www.wizards.com/global/images/magic/general/surging_dementia.jpg
surging_flame.jpg http://www.wizards.com/global/images/magic/general/surging_flame.jpg
surging_might.jpg http://www.wizards.com/global/images/magic/general/surging_might.jpg
surging_sentinels.jpg http://www.wizards.com/global/images/magic/general/surging_sentinels.jpg
glory.jpg http://www.wizards.com/global/images/magic/general/glory.jpg glory.jpg http://www.wizards.com/global/images/magic/general/glory.jpg
filth.jpg http://www.wizards.com/global/images/magic/general/filth.jpg filth.jpg http://www.wizards.com/global/images/magic/general/filth.jpg
abyssal_specter.jpg http://www.wizards.com/global/images/magic/general/abyssal_specter.jpg abyssal_specter.jpg http://www.wizards.com/global/images/magic/general/abyssal_specter.jpg

View File

@@ -1,3 +1,44 @@
Thrumming Stone
5
Legendary Artifact
Spells you cast have ripple 4.
Surging AEther
3 U
Instant
Return target permanent to its owner's hand.
Ripple:4
Surging Dementia
1 B
Sorcery
no text
spDamageTgtP:0:Drawback$TgtDiscard/1:Target player discards a card.:Surging Dementia - Target player discards a card.
Ripple:4
Surging Flame
1 R
Instant
no text
spDamageTgtCP:2
Ripple:4
Surging Might
2 G
Enchantment Aura
Enchanted creature gets +2/+2.
Enchant creature
enPump:+2/+2
Ripple:4
Surging Sentinels
2 W
Creature Human Soldier
no text
2/1
First strike
Ripple:4
Glory Glory
3 W W 3 W W
Creature Incarnation Creature Incarnation

View File

@@ -13735,7 +13735,7 @@ public class CardFactory implements NewConstants {
//*************** START *********** START ************************** //*************** START *********** START **************************
else if(cardName.equals("Boomerang") || cardName.equals("Eye of Nowhere")) { else if(cardName.equals("Boomerang") || cardName.equals("Eye of Nowhere") || cardName.equals("Surging AEther")) {
final SpellAbility spell = new Spell(card) { final SpellAbility spell = new Spell(card) {
private static final long serialVersionUID = 5383879224433456795L; private static final long serialVersionUID = 5383879224433456795L;

View File

@@ -277,6 +277,7 @@ public class GameActionUtil {
playCard_Artisan_of_Kozilek(c); playCard_Artisan_of_Kozilek(c);
playCard_Cascade(c); playCard_Cascade(c);
playCard_Ripple(c);
playCard_Storm(c); playCard_Storm(c);
playCard_Dovescape(c); //keep this one top playCard_Dovescape(c); //keep this one top
@@ -545,6 +546,102 @@ public class GameActionUtil {
Cascade.execute(); Cascade.execute();
} }
public static void playCard_Ripple(final Card c) {
Command Ripple = new Command() {
private static final long serialVersionUID = -845154812215847505L;
public void execute() {
final PlayerZone play = AllZone.getZone(Constant.Zone.Play,
Constant.Player.Human);
final PlayerZone comp = AllZone.getZone(Constant.Zone.Play,
Constant.Player.Computer);
CardList Human_ThrummingStone = new CardList();
CardList Computer_ThrummingStone = new CardList();
Human_ThrummingStone.addAll(play.getCards());
Computer_ThrummingStone.addAll(comp.getCards());
Human_ThrummingStone = Human_ThrummingStone.getName("Thrumming Stone");
Computer_ThrummingStone = Computer_ThrummingStone.getName("Thrumming Stone");
for (int i=0;i<Human_ThrummingStone.size();i++)
{
if(c.getController().equals(Constant.Player.Human)) c.addExtrinsicKeyword("Ripple:4");
}
for (int i=0;i<Computer_ThrummingStone.size();i++)
{
if(c.getController().equals(Constant.Player.Computer)) c.addExtrinsicKeyword("Ripple:4");
}
ArrayList<String> a = c.getKeyword();
for(int x = 0; x < a.size(); x++)
if(a.get(x).toString().startsWith("Ripple")) {
String parse = c.getKeyword().get(x).toString();
String k[] = parse.split(":");
DoRipple(c,Integer.valueOf(k[1]));
}
}// execute()
void DoRipple(Card c, final int RippleCount) {
final String controller = c.getController();
final PlayerZone lib = AllZone.getZone(Constant.Zone.Library, controller);
final Card RippleCard = c;
final Ability ability = new Ability(c, "0") {
@Override
public void resolve() {
CardList topOfLibrary = new CardList(lib.getCards());
CardList revealed = new CardList();
int RippleNumber = RippleCount;
if(topOfLibrary.size() == 0) return;
int RippleMax = 10; // Shouldn't Have more than Ripple 10, seeing as no cards exist with a ripple greater than 4
Card[] RippledCards = new Card[RippleMax];
Card crd;
if(topOfLibrary.size() < RippleNumber) RippleNumber = topOfLibrary.size();
for(int i = 0; i < RippleNumber; i++){
crd = topOfLibrary.get(i);
revealed.add(crd);
lib.remove(crd);
if(crd.getName().equals(RippleCard.getName())) RippledCards[i] = crd;
}//For
AllZone.Display.getChoiceOptional("Revealed cards:", revealed.toArray());
for(int i = 0; i < RippleMax; i++) {
if(RippledCards[i] != null && !RippledCards[i].isUnCastable()) {
if(RippledCards[i].getController().equals(Constant.Player.Human)) {
Object[] possibleValues = {"Yes", "No"};
Object q = JOptionPane.showOptionDialog(null, "Cast " + RippledCards[i].getName() + "?", "Ripple",
JOptionPane.DEFAULT_OPTION, JOptionPane.INFORMATION_MESSAGE,
null, possibleValues, possibleValues[0]);
if(q.equals(0)) {
AllZone.GameAction.playCardNoCost(RippledCards[i]);
revealed.remove(RippledCards[i]);
}
} else //computer
{
ArrayList<SpellAbility> choices = RippledCards[i].getBasicSpells();
for(SpellAbility sa:choices) {
if(sa.canPlayAI() && !sa.getSourceCard().getType().contains("Legendary")) {
ComputerUtil.playStackFree(sa);
revealed.remove(RippledCards[i]);
break;
}
}
}
}
}
revealed.shuffle();
for(Card bottom:revealed) {
lib.add(bottom);
}
}
};
ability.setStackDescription(c + " - Ripple.");
AllZone.Stack.add(ability);
}
};
Ripple.execute();
}
public static void playCard_Storm(Card c) { public static void playCard_Storm(Card c) {
if(c.getKeyword().contains("Storm")) if(c.getKeyword().contains("Storm"))
{ {