forked from External/mage
Fixed some bugs in table handling. Fixed that matches were not set to finished yet, if players left match during sideboarding phase.
This commit is contained in:
parent
df9c200753
commit
40c25fae34
25 changed files with 274 additions and 140 deletions
|
|
@ -33,6 +33,7 @@ import org.apache.log4j.Logger;
|
|||
|
||||
import java.util.UUID;
|
||||
import java.util.concurrent.Callable;
|
||||
import mage.MageException;
|
||||
|
||||
/**
|
||||
*
|
||||
|
|
@ -42,9 +43,9 @@ public class GameWorker implements Callable {
|
|||
|
||||
private static final Logger logger = Logger.getLogger(GameWorker.class);
|
||||
|
||||
private GameCallback result;
|
||||
private Game game;
|
||||
private UUID choosingPlayerId;
|
||||
private final GameCallback result;
|
||||
private final Game game;
|
||||
private final UUID choosingPlayerId;
|
||||
|
||||
public GameWorker(Game game, UUID choosingPlayerId, GameCallback result) {
|
||||
this.game = game;
|
||||
|
|
@ -58,7 +59,7 @@ public class GameWorker implements Callable {
|
|||
game.start(choosingPlayerId);
|
||||
game.fireUpdatePlayersEvent();
|
||||
result.gameResult(game.getWinner());
|
||||
} catch (Exception ex) {
|
||||
} catch (MageException ex) {
|
||||
logger.fatal("GameWorker error ", ex);
|
||||
}
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue