mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 11:48:02 +00:00
- Further tweaks to surprise pump experimental feature.
This commit is contained in:
@@ -1126,7 +1126,9 @@ public class AiAttackController {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (canKillAllDangerous && !hasAttackEffect && !hasCombatEffect && this.attackers.size() <= defenders.size()) {
|
if (canKillAllDangerous
|
||||||
|
&& !hasAttackEffect && !hasCombatEffect
|
||||||
|
&& (this.attackers.size() <= defenders.size() || attacker.getNetPower() <= 0)) {
|
||||||
if (ai.getController().isAI()) {
|
if (ai.getController().isAI()) {
|
||||||
if (((PlayerControllerAi)ai.getController()).getAi().getBooleanProperty(AiProps.TRY_TO_AVOID_ATTACKING_INTO_CERTAIN_BLOCK)) {
|
if (((PlayerControllerAi)ai.getController()).getAi().getBooleanProperty(AiProps.TRY_TO_AVOID_ATTACKING_INTO_CERTAIN_BLOCK)) {
|
||||||
// We can't kill a blocker, there is no reason to attack unless we can cripple a
|
// We can't kill a blocker, there is no reason to attack unless we can cripple a
|
||||||
|
|||||||
@@ -1242,7 +1242,10 @@ public class ComputerUtilCard {
|
|||||||
// cast it during Declare Blockers, thus ruining its attacker
|
// cast it during Declare Blockers, thus ruining its attacker
|
||||||
if (holdCombatTricks && sa.getApi() == ApiType.Pump
|
if (holdCombatTricks && sa.getApi() == ApiType.Pump
|
||||||
&& sa.hasParam("NumAtt") && sa.getHostCard() != null
|
&& sa.hasParam("NumAtt") && sa.getHostCard() != null
|
||||||
&& sa.getHostCard().getZone() != null && sa.getHostCard().getZone().is(ZoneType.Hand)) {
|
&& sa.getHostCard().getZone() != null && sa.getHostCard().getZone().is(ZoneType.Hand)
|
||||||
|
&& c.getNetPower() > 0 // too obvious if attacking with a 0-power creature
|
||||||
|
&& sa.getHostCard().isInstant() // only do it for instant speed spells in hand
|
||||||
|
&& ComputerUtilMana.hasEnoughManaSourcesToCast(sa, ai)) {
|
||||||
combatTrick = true;
|
combatTrick = true;
|
||||||
|
|
||||||
final List<String> kws = sa.hasParam("KW") ? Arrays.asList(sa.getParam("KW").split(" & "))
|
final List<String> kws = sa.hasParam("KW") ? Arrays.asList(sa.getParam("KW").split(" & "))
|
||||||
|
|||||||
Reference in New Issue
Block a user