- Added a new AI SVar: AmbushAI. Creatures with it will be played when the opponent is attacking.

This commit is contained in:
Sloth
2014-11-01 20:37:38 +00:00
parent b9864a2a23
commit fe770a48ba
11 changed files with 16 additions and 7 deletions

View File

@@ -777,8 +777,8 @@ public class AiController {
&& (player.isUnlimitedHandSize() || player.getCardsIn(ZoneType.Hand).size() <= player.getMaxHandSize())
&& player.getManaPool().totalMana() <= 0
&& (game.getPhaseHandler().isPlayerTurn(player)
|| game.getPhaseHandler().getPhase().isBefore(PhaseType.COMBAT_DECLARE_ATTACKERS)
&& !card.hasETBTrigger())
|| game.getPhaseHandler().getPhase().isBefore(PhaseType.COMBAT_DECLARE_ATTACKERS))
&& (!card.hasETBTrigger() || card.hasSVar("AmbushAI"))
&& !ComputerUtil.castPermanentInMain1(player, sa)) {
return AiPlayDecision.AnotherTime;
}