Fixes phase skipping for human

This commit is contained in:
Maxmtg
2013-02-18 08:00:01 +00:00
parent 8a9b839c08
commit add7ab382a
2 changed files with 3 additions and 14 deletions

View File

@@ -49,14 +49,12 @@ public abstract class PlayerController {
public boolean mayAutoPass(PhaseType phase) { public boolean mayAutoPass(PhaseType phase) {
return phase.isBefore(autoPassUntil); return phase.isBefore(autoPassUntil);
} }
public boolean isUiSetToSkipPhase(final Player turn, final PhaseType phase) { public boolean isUiSetToSkipPhase(final Player turn, final PhaseType phase) {
boolean isLocalPlayer = getPlayer().equals(Singletons.getControl().getPlayer()); return false; // human has it's overload
return isLocalPlayer && !CMatchUI.SINGLETON_INSTANCE.stopAtPhase(turn, phase);
} }
/** /**

View File

@@ -34,9 +34,6 @@ import forge.item.CardPrinted;
*/ */
public class PlayerControllerHuman extends PlayerController { public class PlayerControllerHuman extends PlayerController {
private PhaseType autoPassUntil = null;
private final Input defaultInput; private final Input defaultInput;
private final Input blockInput; private final Input blockInput;
private final Input cleanupInput; private final Input cleanupInput;
@@ -55,15 +52,9 @@ public class PlayerControllerHuman extends PlayerController {
cleanupInput = new InputCleanup(game); cleanupInput = new InputCleanup(game);
} }
public boolean mayAutoPass(PhaseType phase) { @Override
return phase.isBefore(autoPassUntil);
}
public boolean isUiSetToSkipPhase(final Player turn, final PhaseType phase) { public boolean isUiSetToSkipPhase(final Player turn, final PhaseType phase) {
boolean isLocalPlayer = getPlayer().equals(Singletons.getControl().getPlayer()); return !CMatchUI.SINGLETON_INSTANCE.stopAtPhase(turn, phase);
return isLocalPlayer && !CMatchUI.SINGLETON_INSTANCE.stopAtPhase(turn, phase);
} }
/** /**