CardFactoryUtil: add Battle cry as trigger

This commit is contained in:
Hanmac
2018-02-17 12:01:53 +01:00
parent e990c3648e
commit 3f1d6238ff
9 changed files with 20 additions and 15 deletions

View File

@@ -1546,7 +1546,7 @@ public class Card extends GameEntity implements Comparable<Card> {
|| (keyword.startsWith("Split second") && !sb.toString().contains("Split second"))
|| keyword.equals("Suspend") // for the ones without amounnt
|| keyword.equals("Hideaway") || keyword.equals("Ascend")
|| keyword.equals("Totem armor")
|| keyword.equals("Totem armor") || keyword.equals("Battle cry")
|| keyword.equals("Devoid")){
sbLong.append(keyword + " (" + inst.getReminderText() + ")");
} else if (keyword.startsWith("Modular") || keyword.startsWith("Bloodthirst")

View File

@@ -2114,6 +2114,18 @@ public class CardFactoryUtil {
sa.setBlessing(true);
}
}
} else if (keyword.equals("Battle cry")) {
final String trig = "Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Secondary$ True "
+ " | TriggerDescription$ " + keyword + " (" + inst.getReminderText() + ")";
String pumpStr = "DB$ PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1";
SpellAbility sa = AbilityFactory.getAbility(pumpStr, card);
sa.setIntrinsic(intrinsic);
final Trigger trigger = TriggerHandler.parseTrigger(trig, card, intrinsic);
trigger.setOverridingAbility(sa);
inst.addTrigger(trigger);
} else if (keyword.startsWith("Bushido")) {
final String[] k = keyword.split(" ", 2);
final String n = k[1];

View File

@@ -2,7 +2,6 @@ Name:Accorder Paladin
ManaCost:1 W
Types:Creature Human Knight
PT:3/1
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$ PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
K:Battle cry
SVar:Picture:http://www.wizards.com/global/images/magic/general/accorder_paladin.jpg
Oracle:Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)

View File

@@ -2,7 +2,6 @@ Name:Goblin Wardriver
ManaCost:R R
Types:Creature Goblin Warrior
PT:2/2
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
K:Battle cry
SVar:Picture:http://www.wizards.com/global/images/magic/general/goblin_wardriver.jpg
Oracle:Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)

View File

@@ -2,9 +2,8 @@ Name:Hero of Bladehold
ManaCost:2 W W
Types:Creature Human Knight
PT:3/4
K:Battle cry
T:Mode$ Attacks | ValidCard$ Card.Self | Execute$ TrigToken | TriggerDescription$ Whenever CARDNAME attacks, create two 1/1 white Soldier creature tokens that are tapped and attacking.
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$ PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
SVar:TrigToken:DB$ Token | TokenAmount$ 2 | TokenName$ Soldier | TokenTypes$ Creature,Soldier | TokenOwner$ You | TokenColors$ White | TokenPower$ 1 | TokenToughness$ 1 | TokenTapped$ True | TokenAttacking$ True | TokenImage$ w 1 1 soldier SOM
SVar:HasAttackEffect:TRUE
SVar:Picture:http://www.wizards.com/global/images/magic/general/hero_of_bladehold.jpg

View File

@@ -3,9 +3,8 @@ ManaCost:2 R R
Types:Creature Human Knight
PT:4/2
K:Haste
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
K:Battle cry
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigEffect | TriggerDescription$ When CARDNAME attacks, creatures with power 1 or less can't block this turn.
SVar:TrigBattleCry:DB$ PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
SVar:TrigEffect:DB$ Effect | Name$ Hero of Oxid Ridge Effect | StaticAbilities$ KWPump
SVar:KWPump:Mode$ Continuous | EffectZone$ Command | Affected$ Creature.powerLE1 | AddHiddenKeyword$ CARDNAME can't block. | Description$ Creatures with power 1 or less can't block this turn.
SVar:Picture:http://www.wizards.com/global/images/magic/general/hero_of_oxid_ridge.jpg

View File

@@ -2,8 +2,7 @@ Name:Kuldotha Ringleader
ManaCost:4 R
Types:Creature Giant Berserker
PT:4/4
K:Battle cry
K:CARDNAME attacks each combat if able.
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
SVar:Picture:http://www.wizards.com/global/images/magic/general/kuldotha_ringleader.jpg
Oracle:Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)\nKuldotha Ringleader attacks each combat if able.

View File

@@ -2,7 +2,6 @@ Name:Loxodon Partisan
ManaCost:4 W
Types:Creature Elephant Soldier
PT:3/4
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
K:Battle cry
SVar:Picture:http://www.wizards.com/global/images/magic/general/loxodon_partisan.jpg
Oracle:Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)

View File

@@ -2,8 +2,7 @@ Name:Signal Pest
ManaCost:1
Types:Artifact Creature Pest
PT:0/1
K:Battle cry
K:CantBeBlockedBy Creature.withoutFlying+withoutReach
T:Mode$ Attacks | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigBattleCry | TriggerDescription$ Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)
SVar:TrigBattleCry:DB$PumpAll | ValidCards$ Creature.attacking+Other | NumAtt$ 1
SVar:Picture:http://www.wizards.com/global/images/magic/general/signal_pest.jpg
Oracle:Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.)\nSignal Pest can't be blocked except by creatures with flying or reach.