mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 20:28:00 +00:00
Clean up
This commit is contained in:
@@ -2,7 +2,6 @@ package forge.ai.ability;
|
|||||||
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import com.google.common.base.Predicate;
|
|
||||||
import com.google.common.collect.Iterables;
|
import com.google.common.collect.Iterables;
|
||||||
|
|
||||||
import forge.ai.AiAttackController;
|
import forge.ai.AiAttackController;
|
||||||
@@ -152,12 +151,7 @@ public class DigAi extends SpellAbilityAi {
|
|||||||
Card bestChoice = ComputerUtilCard.getBestCreatureAI(valid);
|
Card bestChoice = ComputerUtilCard.getBestCreatureAI(valid);
|
||||||
if (bestChoice == null) {
|
if (bestChoice == null) {
|
||||||
// no creatures, but maybe there's a morphable card that can be played as a creature?
|
// no creatures, but maybe there's a morphable card that can be played as a creature?
|
||||||
CardCollection morphs = CardLists.filter(valid, new Predicate<Card>() {
|
CardCollection morphs = CardLists.getKeyword(valid, Keyword.MORPH);
|
||||||
@Override
|
|
||||||
public boolean apply(Card card) {
|
|
||||||
return card.hasKeyword(Keyword.MORPH);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
if (!morphs.isEmpty()) {
|
if (!morphs.isEmpty()) {
|
||||||
bestChoice = ComputerUtilCard.getBestAI(morphs);
|
bestChoice = ComputerUtilCard.getBestAI(morphs);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user