mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 20:58:03 +00:00
- Improvements to Phyrexian Dreadnought AI handling.
This commit is contained in:
@@ -378,13 +378,16 @@ public class SpecialCardAi {
|
|||||||
// Phyrexian Dreadnought
|
// Phyrexian Dreadnought
|
||||||
public static class PhyrexianDreadnought {
|
public static class PhyrexianDreadnought {
|
||||||
public static CardCollection reviseCreatureSacList(Player ai, SpellAbility sa, CardCollection choices) {
|
public static CardCollection reviseCreatureSacList(Player ai, SpellAbility sa, CardCollection choices) {
|
||||||
choices.sort(Collections.reverseOrder(CardLists.CmcComparatorInv));
|
choices.sort(Collections.reverseOrder(ComputerUtilCard.EvaluateCreatureComparator));
|
||||||
int power = 0;
|
int power = 0;
|
||||||
List<Card> toKeep = Lists.newArrayList();
|
List<Card> toKeep = Lists.newArrayList();
|
||||||
for (Card c : choices) {
|
for (Card c : choices) {
|
||||||
if (c.getName().equals(sa.getHostCard().getName())) {
|
if (c.getName().equals(sa.getHostCard().getName())) {
|
||||||
continue; // not worth it sac'ing another Dreadnaught
|
continue; // not worth it sac'ing another Dreadnaught
|
||||||
}
|
}
|
||||||
|
if (c.getNetPower() < 1) {
|
||||||
|
continue; // contributes nothing to Dreadnought requirements
|
||||||
|
}
|
||||||
if (power >= 12) {
|
if (power >= 12) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user