mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
- Implemented AI for Triskelion
This commit is contained in:
@@ -107,6 +107,25 @@ public class DamageDealAi extends DamageAiBase {
|
||||
// This dummy ability will just deal 0 damage, but holds the logic for the AI for Master of Wild Hunt
|
||||
List<Card> wolves = CardLists.getValidCards(ai.getCardsIn(ZoneType.Battlefield), "Creature.Wolf+untapped+YouCtrl+Other", ai, source);
|
||||
dmg = Aggregates.sum(wolves, CardPredicates.Accessors.fnGetNetPower);
|
||||
} else if ("Triskelion".equals(logic)) {
|
||||
final int n = source.getCounters(CounterType.P1P1);
|
||||
if (n > 0) {
|
||||
if (ComputerUtil.playImmediately(ai, sa)) {
|
||||
/*
|
||||
* Mostly used to ping the player with remaining counters. The issue with
|
||||
* stacked effects might appear here.
|
||||
*/
|
||||
return damageTargetAI(ai, sa, n, true);
|
||||
} else {
|
||||
/*
|
||||
* Only ping when stack is clear to avoid hassle of evaluating stacked effects
|
||||
* like protection/pumps or over-killing target.
|
||||
*/
|
||||
return ai.getGame().getStack().isEmpty() && damageTargetAI(ai, sa, n, false);
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (source.getName().equals("Sorin, Grim Nemesis")) {
|
||||
|
||||
@@ -3,7 +3,6 @@ ManaCost:6
|
||||
Types:Artifact Creature Construct
|
||||
PT:1/1
|
||||
K:etbCounter:P1P1:3
|
||||
A:AB$ DealDamage | Cost$ SubCounter<1/P1P1> | ValidTgts$ Creature,Player | TgtPrompt$ Select target creature or player | NumDmg$ 1 | SpellDescription$ CARDNAME deals 1 damage to target creature or player.
|
||||
SVar:RemAIDeck:True
|
||||
A:AB$ DealDamage | AILogic$ Triskelion | Cost$ SubCounter<1/P1P1> | ValidTgts$ Creature,Player | TgtPrompt$ Select target creature or player | NumDmg$ 1 | SpellDescription$ CARDNAME deals 1 damage to target creature or player.
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/triskelion.jpg
|
||||
Oracle:Triskelion enters the battlefield with three +1/+1 counters on it.\nRemove a +1/+1 counter from Triskelion: Triskelion deals 1 damage to target creature or player.
|
||||
|
||||
Reference in New Issue
Block a user