mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
- Fixed AI not using the first ability of Vraska the Unseen.
This commit is contained in:
@@ -87,8 +87,9 @@ public abstract class SpellAbilityAi extends SaTargetRoutines {
|
|||||||
* @return a boolean.
|
* @return a boolean.
|
||||||
*/
|
*/
|
||||||
protected static boolean isSorcerySpeed(final SpellAbility sa) {
|
protected static boolean isSorcerySpeed(final SpellAbility sa) {
|
||||||
return ( sa.isSpell() && sa.getHostCard().isSorcery() )
|
return (sa.isSpell() && sa.getHostCard().isSorcery())
|
||||||
|| ( sa.isAbility() && sa.getRestrictions().isSorcerySpeed() );
|
|| (sa.isAbility() && sa.getRestrictions().isSorcerySpeed())
|
||||||
|
|| (sa.getRestrictions().isPwAbility() && !sa.getHostCard().hasKeyword("CARDNAME's loyalty abilities can be activated at instant speed."));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ public class AnimateAi extends SpellAbilityAi {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// don't use instant speed animate abilities outside computers
|
// don't use instant speed animate abilities outside computers
|
||||||
// Combat_Begin step
|
// Combat_Begin step
|
||||||
if (!ph.is(PhaseType.COMBAT_BEGIN)
|
if (!ph.is(PhaseType.COMBAT_BEGIN)
|
||||||
@@ -100,7 +100,8 @@ public class AnimateAi extends SpellAbilityAi {
|
|||||||
if (ph.isPlayerTurn(aiPlayer)
|
if (ph.isPlayerTurn(aiPlayer)
|
||||||
&& aiPlayer.getLife() < 6
|
&& aiPlayer.getLife() < 6
|
||||||
&& opponent.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;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user