mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 03:08:02 +00:00
fix AiAttack with CHOSEN_FOG_EFFECT
This commit is contained in:
@@ -267,9 +267,15 @@ public class AiAttackController {
|
|||||||
// no need to block (already holding mana to cast fog next turn)
|
// no need to block (already holding mana to cast fog next turn)
|
||||||
if (!AiCardMemory.isMemorySetEmpty(ai, AiCardMemory.MemorySet.CHOSEN_FOG_EFFECT)) {
|
if (!AiCardMemory.isMemorySetEmpty(ai, AiCardMemory.MemorySet.CHOSEN_FOG_EFFECT)) {
|
||||||
// Don't send the card that'll do the fog effect to attack, it's unsafe!
|
// Don't send the card that'll do the fog effect to attack, it's unsafe!
|
||||||
if (attackers.contains(AiCardMemory.MemorySet.CHOSEN_FOG_EFFECT)) {
|
|
||||||
attackers.remove(AiCardMemory.MemorySet.CHOSEN_FOG_EFFECT);
|
List<Card> toRemove = Lists.newArrayList();
|
||||||
|
for(Card c : attackers) {
|
||||||
|
if (AiCardMemory.isRememberedCard(ai, c, AiCardMemory.MemorySet.CHOSEN_FOG_EFFECT)) {
|
||||||
|
toRemove.add(c);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
attackers.removeAll(toRemove);
|
||||||
|
|
||||||
return attackers;
|
return attackers;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user