- Added Rotting Giant.

This commit is contained in:
Sloth
2012-10-19 21:12:28 +00:00
parent 97245e358f
commit 9ed4b92dc7
6 changed files with 55 additions and 12 deletions

1
.gitattributes vendored
View File

@@ -8090,6 +8090,7 @@ res/cardsfolder/r/roterothopter.txt svneol=native#text/plain
res/cardsfolder/r/rotlung_reanimator.txt svneol=native#text/plain
res/cardsfolder/r/rotted_hystrix.txt svneol=native#text/plain
res/cardsfolder/r/rotting_fensnake.txt -text
res/cardsfolder/r/rotting_giant.txt -text
res/cardsfolder/r/rotting_legion.txt svneol=native#text/plain
res/cardsfolder/r/rotting_rats.txt svneol=native#text/plain
res/cardsfolder/r/roughshod_mentor.txt svneol=native#text/plain

View File

@@ -5,7 +5,7 @@ Text:no text
PT:6/4
T:Mode$ Attacks | ValidCard$ Card.Self | Execute$ TrigSac | TriggerDescription$ Whenever CARDNAME attacks or blocks, sacrifice a land.
T:Mode$ Blocks | ValidCard$ Card.Self | Execute$ TrigSac | Secondary$ True | TriggerDescription$ Whenever CARDNAME attacks or blocks, sacrifice a land.
SVar:TrigSac:AB$Sacrifice | Cost$ 0 | SacValid$ Land | ChangeNum$ 1
SVar:TrigSac:AB$ Sacrifice | Cost$ 0 | SacValid$ Land
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/lesser_gargadon.jpg
SetInfo:PCY|Uncommon|http://magiccards.info/scans/en/pr/97.jpg

View File

@@ -0,0 +1,14 @@
Name:Rotting Giant
ManaCost:1 B
Types:Creature Zombie Giant
Text:no text
PT:3/3
T:Mode$ Attacks | ValidCard$ Card.Self | Execute$ TrigSac | TriggerDescription$ Whenever CARDNAME attacks or blocks, sacrifice it unless you exile a card from your graveyard.
T:Mode$ Blocks | ValidCard$ Card.Self | Execute$ TrigSac | Secondary$ True | TriggerDescription$ Whenever CARDNAME attacks or blocks, sacrifice it unless you exile a card from your graveyard.
SVar:TrigSac:AB$ Sacrifice | Cost$ 0 | Defined$ Self | UnlessCost$ ExileFromGrave<1/Card> | UnlessPayer$ You
SVar:RemAIDeck:True
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/rotting_giant.jpg
SetInfo:ODY|Uncommon|http://magiccards.info/scans/en/od/158.jpg
Oracle:Whenever Rotting Giant attacks or blocks, sacrifice it unless you exile a card from your graveyard.
End

View File

@@ -4,7 +4,7 @@ Types:Artifact Creature Golem
Text:no text
PT:2/3
T:Mode$ SpellCast | ValidCard$ Creature | ValidActivatingPlayer$ Opponent | TriggerZones$ Battlefield | Execute$ TrigSacrifice | TriggerDescription$ When an opponent casts a creature spell, sacrifice CARDNAME.
SVar:TrigSacrifice:AB$Sacrifice | Cost$ 0 | Defined$ Self
SVar:TrigSacrifice:AB$ Sacrifice | Cost$ 0 | Defined$ Self
SVar:AntiBuffedBy:Creature
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/straw_golem.jpg

View File

@@ -397,6 +397,7 @@ public final class GameActionUtil {
p.payLife(amount, null);
} else {
hasPaid = false;
break;
}
remainingParts.remove(part);
}
@@ -410,6 +411,7 @@ public final class GameActionUtil {
p.addDamage(amount, source);
} else {
hasPaid = false;
break;
}
remainingParts.remove(part);
}
@@ -428,22 +430,50 @@ public final class GameActionUtil {
hasPaid = false;
Singletons.getModel().getGameState().getGameLog().add("ResolveStack", "Trying to pay upkeep for " + source + " but it can't have "
+ counterType.getName() + " counters put on it.", 2);
break;
}
} else {
hasPaid = false;
break;
}
remainingParts.remove(part);
}
if (part instanceof CostExile && "All".equals(part.getType())) {
else if (part instanceof CostExile) {
Player p = Singletons.getControl().getPlayer();
if (showYesNoDialog(source, "Do you want to exile all cards in your graveyard?")) {
for (final Card card : p.getCardsIn(ZoneType.Graveyard)) {
Singletons.getModel().getGameAction().exile(card);
if ("All".equals(part.getType())) {
if (showYesNoDialog(source, "Do you want to exile all cards in your graveyard?")) {
for (final Card card : p.getCardsIn(ZoneType.Graveyard)) {
Singletons.getModel().getGameAction().exile(card);
}
} else {
hasPaid = false;
break;
}
remainingParts.remove(part);
} else {
hasPaid = false;
CostExile costExile = (CostExile) part;
ZoneType from = costExile.getFrom();
List<Card> list = p.getCardsIn(from);
list = CardLists.getValidCards(list, part.getType().split(";"), p, source);
final int nNeeded = AbilityFactory.calculateAmount(source, part.getAmount(), ability);
if (list.size() >= nNeeded) {
for (int i = 0; i < nNeeded; i++) {
final Card c = GuiChoose.oneOrNone("Exile from " + from, list);
if (c != null) {
list.remove(c);
Singletons.getModel().getGameAction().exile(c);
} else {
hasPaid = false;
break;
}
}
} else {
hasPaid = false;
break;
}
}
remainingParts.remove(part);
}
}
if (!hasPaid) {

View File

@@ -360,11 +360,9 @@ public class CostExile extends CostPartWithList {
this.cancel();
}
final Card o = GuiChoose
.oneOrNone("Exile from " + part.getFrom(), this.typeList);
final Card c = GuiChoose.oneOrNone("Exile from " + part.getFrom(), this.typeList);
if (o != null) {
final Card c = o;
if (c != null) {
this.typeList.remove(c);
part.addToList(c);
Singletons.getModel().getGameAction().exile(c);