- Converted Callous Giant to script.

This commit is contained in:
Sloth
2011-10-04 20:19:33 +00:00
parent b683634c4d
commit 9958652fcf
3 changed files with 6 additions and 5 deletions

View File

@@ -1,8 +1,9 @@
Name:Callous Giant
ManaCost:4 R R
Types:Creature Giant
Text:If a source would deal 3 or less damage to Callous Giant, prevent that damage.
Text:
PT:4/4
S:Mode$ PreventDamage | Target$ Card.Self | MaxDamage$ 3 | Description$ If a source would deal 3 or less damage to Callous Giant, prevent that damage.
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/callous_giant.jpg
SetInfo:INV|Rare|http://magiccards.info/scans/en/in/139.jpg

View File

@@ -5797,10 +5797,6 @@ public class Card extends GameEntity implements Comparable<Card> {
if ((source.isCreature() && AllZoneUtil.isCardInPlay("Well-Laid Plans") && source.sharesColorWith(this))) {
return 0;
}
if (getName().equals("Callous Giant") && restDamage <= 3) {
return 0;
}
} //Creature end
if (restDamage > 0) {

View File

@@ -34,6 +34,10 @@ public class StaticAbility_PreventDamage {
return restDamage;
}
if(params.containsKey("MaxDamage") && Integer.parseInt(params.get("MaxDamage")) < damage) {
return restDamage;
}
// no amount means all
if(!params.containsKey("Amount") || params.get("Amount").equals("All")) {
return 0;