- Fixed AI not using the first ability of Vraska the Unseen.

This commit is contained in:
Sloth
2014-08-06 09:18:47 +00:00
parent 1a25c88287
commit 2d12c8faac
2 changed files with 6 additions and 4 deletions

View File

@@ -87,8 +87,9 @@ public abstract class SpellAbilityAi extends SaTargetRoutines {
* @return a boolean.
*/
protected static boolean isSorcerySpeed(final SpellAbility sa) {
return ( sa.isSpell() && sa.getHostCard().isSorcery() )
|| ( sa.isAbility() && sa.getRestrictions().isSorcerySpeed() );
return (sa.isSpell() && sa.getHostCard().isSorcery())
|| (sa.isAbility() && sa.getRestrictions().isSorcerySpeed())
|| (sa.getRestrictions().isPwAbility() && !sa.getHostCard().hasKeyword("CARDNAME's loyalty abilities can be activated at instant speed."));
}
/**

View File

@@ -85,7 +85,7 @@ public class AnimateAi extends SpellAbilityAi {
}
}
}
// don't use instant speed animate abilities outside computers
// Combat_Begin step
if (!ph.is(PhaseType.COMBAT_BEGIN)
@@ -100,7 +100,8 @@ public class AnimateAi extends SpellAbilityAi {
if (ph.isPlayerTurn(aiPlayer)
&& aiPlayer.getLife() < 6
&& opponent.getLife() > 6
&& Iterables.any(opponent.getCardsIn(ZoneType.Battlefield), CardPredicates.Presets.CREATURES)) {
&& Iterables.any(opponent.getCardsIn(ZoneType.Battlefield), CardPredicates.Presets.CREATURES)
&& !sa.hasParam("AILogic")) {
return false;
}