- Minor AI updates.

This commit is contained in:
Sloth
2014-04-04 15:18:00 +00:00
parent 60eee41d72
commit b8825ceb8b
3 changed files with 7 additions and 2 deletions

View File

@@ -1180,7 +1180,7 @@ public class AttachAi extends SpellAbilityAi {
if (keyword.endsWith("CARDNAME can't attack.") || keyword.equals("Defender") if (keyword.endsWith("CARDNAME can't attack.") || keyword.equals("Defender")
|| keyword.endsWith("CARDNAME can't attack or block.")) { || keyword.endsWith("CARDNAME can't attack or block.")) {
if (!CombatUtil.canAttackNextTurn(card)) { if (!CombatUtil.canAttackNextTurn(card) || card.getNetCombatDamage() < 1) {
return false; return false;
} }
} else if (keyword.endsWith("CARDNAME attacks each turn if able.")) { } else if (keyword.endsWith("CARDNAME attacks each turn if able.")) {

View File

@@ -42,6 +42,11 @@ public class DigAi extends SpellAbilityAi {
return false; return false;
} }
// return false if nothing to dig into
if ("Never".equals(sa.getParam("AILogic"))) {
return false;
}
// don't deck yourself // don't deck yourself
if (sa.hasParam("DestinationZone2") && !"Library".equals(sa.getParam("DestinationZone2"))) { if (sa.hasParam("DestinationZone2") && !"Library".equals(sa.getParam("DestinationZone2"))) {
int numToDig = AbilityUtils.calculateAmount(host, sa.getParam("DigNum"), sa); int numToDig = AbilityUtils.calculateAmount(host, sa.getParam("DigNum"), sa);

View File

@@ -2,6 +2,6 @@ Name:Orcish Spy
ManaCost:R ManaCost:R
Types:Creature Orc Rogue Types:Creature Orc Rogue
PT:1/1 PT:1/1
A:AB$ Dig | Cost$ T | ValidTgts$ Player | TgtPrompt$ Select target player | DigNum$ 3 | NoMove$ True | SpellDescription$ Look at the top three cards of target player's library. A:AB$ Dig | Cost$ T | ValidTgts$ Player | TgtPrompt$ Select target player | DigNum$ 3 | NoMove$ True | AILogic$ Never | SpellDescription$ Look at the top three cards of target player's library.
SVar:Picture:http://www.wizards.com/global/images/magic/general/orcish_spy.jpg SVar:Picture:http://www.wizards.com/global/images/magic/general/orcish_spy.jpg
Oracle:{T}: Look at the top three cards of target player's library. Oracle:{T}: Look at the top three cards of target player's library.