forked from External/mage
Improved sceduled logic to remove bugged tables. Reactivated logic to show the list of the last finished 50 matches (no replay possible).
This commit is contained in:
parent
30b738b3ad
commit
7014b28797
4 changed files with 44 additions and 17 deletions
|
|
@ -420,8 +420,10 @@ public class TableController {
|
|||
UUID choosingPlayerId = match.getChooser();
|
||||
match.endGame();
|
||||
table.endGame();
|
||||
//if (!match.getGame().isSimulation())
|
||||
//GameManager.getInstance().saveGame(match.getGame().getId());
|
||||
// Saving of games caused memory leaks - so save is deactivated
|
||||
// if (!match.getGame().isSimulation()) {
|
||||
// GameManager.getInstance().saveGame(match.getGame().getId());
|
||||
// }
|
||||
GameManager.getInstance().removeGame(match.getGame().getId());
|
||||
try {
|
||||
if (!match.isMatchOver()) {
|
||||
|
|
@ -432,10 +434,7 @@ public class TableController {
|
|||
startGame(choosingPlayerId);
|
||||
}
|
||||
else {
|
||||
GamesRoomManager.getInstance().removeTable(table.getId());
|
||||
match.getGames().clear();
|
||||
match = null;
|
||||
table = null;
|
||||
}
|
||||
} catch (GameException ex) {
|
||||
logger.fatal(null, ex);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue