If one side of the skirmish is missing, no more phase actions can be played

This commit is contained in:
marcins78@gmail.com
2011-09-16 20:01:31 +00:00
parent 3759afb322
commit c8bf487c4d

View File

@@ -2,6 +2,7 @@ package com.gempukku.lotro.logic.timing.processes.turn.general;
import com.gempukku.lotro.common.Phase;
import com.gempukku.lotro.game.state.LotroGame;
import com.gempukku.lotro.game.state.Skirmish;
import com.gempukku.lotro.logic.PlayOrder;
import com.gempukku.lotro.logic.decisions.CardActionSelectionDecision;
import com.gempukku.lotro.logic.decisions.DecisionResultInvalidException;
@@ -29,9 +30,12 @@ public class PlayersPlayPhaseActionsInOrderGameProcess implements GameProcess {
@Override
public void process() {
if (_game.getGameState().getCurrentPhase() == Phase.SKIRMISH
&& _game.getGameState().getSkirmish().isCancelled()) {
_nextProcess = _followingGameProcess;
if (_game.getGameState().getCurrentPhase() == Phase.SKIRMISH) {
Skirmish skirmish = _game.getGameState().getSkirmish();
// If the skirmish is cancelled or one side of the skirmish is missing, no more phase actions can be played
if (_game.getGameState().getSkirmish().isCancelled()
|| skirmish.getFellowshipCharacter() == null || skirmish.getShadowCharacters().size() == 0)
_nextProcess = _followingGameProcess;
} else {
String playerId = _playOrder.getNextPlayer();
GatherPlayableActionsVisitor visitor = new GatherPlayableActionsVisitor(_game, playerId);