mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
- Renamed PlayCards in ComputerUtil to playAbilities.
This commit is contained in:
@@ -71,7 +71,7 @@ public class ComputerAIGeneral implements Computer {
|
||||
private void playCards(final String phase) {
|
||||
SpellAbility[] sp = phase.equals(Constant.Phase.MAIN1) ? getMain1() : getMain2();
|
||||
|
||||
boolean nextPhase = ComputerUtil.playCards(sp);
|
||||
boolean nextPhase = ComputerUtil.playAbilities(sp);
|
||||
|
||||
if (nextPhase) {
|
||||
AllZone.getPhase().passPriority();
|
||||
@@ -501,7 +501,7 @@ public class ComputerAIGeneral implements Computer {
|
||||
boolean pass = (sas.length == 0)
|
||||
|| AllZone.getPhase().is(Constant.Phase.END_OF_TURN, AllZone.getComputerPlayer());
|
||||
if (!pass) { // Each AF should check the phase individually
|
||||
pass = ComputerUtil.playCards(sas);
|
||||
pass = ComputerUtil.playAbilities(sas);
|
||||
}
|
||||
|
||||
if (pass) {
|
||||
@@ -530,7 +530,7 @@ public class ComputerAIGeneral implements Computer {
|
||||
|
||||
possibleCounters.clear();
|
||||
possibleCounters = getPossibleETBCounters();
|
||||
if (possibleCounters.size() > 0 && !ComputerUtil.playCards(possibleCounters)) {
|
||||
if (possibleCounters.size() > 0 && !ComputerUtil.playAbilities(possibleCounters)) {
|
||||
// Responding Permanent w/ ETB Counter is on the Stack
|
||||
// AllZone.getPhase().passPriority();
|
||||
return;
|
||||
@@ -538,7 +538,7 @@ public class ComputerAIGeneral implements Computer {
|
||||
|
||||
if (sas.length > 0) {
|
||||
// Spell not Countered
|
||||
if (!ComputerUtil.playCards(sas)) {
|
||||
if (!ComputerUtil.playAbilities(sas)) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ public class ComputerUtil {
|
||||
* objects.
|
||||
* @return a boolean.
|
||||
*/
|
||||
public static boolean playCards(final SpellAbility[] all) {
|
||||
public static boolean playAbilities(final SpellAbility[] all) {
|
||||
// not sure "playing biggest spell" matters?
|
||||
sortSpellAbilityByCost(all);
|
||||
// MyRandom.shuffle(all);
|
||||
@@ -95,12 +95,12 @@ public class ComputerUtil {
|
||||
* a {@link java.util.ArrayList} object.
|
||||
* @return a boolean.
|
||||
*/
|
||||
public static boolean playCards(final ArrayList<SpellAbility> all) {
|
||||
public static boolean playAbilities(final ArrayList<SpellAbility> all) {
|
||||
SpellAbility[] sas = new SpellAbility[all.size()];
|
||||
for (int i = 0; i < sas.length; i++) {
|
||||
sas[i] = all.get(i);
|
||||
}
|
||||
return playCards(sas);
|
||||
return playAbilities(sas);
|
||||
} // playCards()
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user