Fixed a problem with NPE and match start. Chanes to handling of logging.

This commit is contained in:
LevelX2 2014-09-09 07:45:53 +02:00
parent f670cb3977
commit 9c1f69983b
4 changed files with 18 additions and 15 deletions

View file

@ -61,7 +61,7 @@ public class GameStates implements Serializable {
states.remove(states.size() - 1);
}
// return new Copier<GameState>().uncompressCopy(states.get(index));
logger.debug("Rolling back state: " + index);
logger.trace("Rolling back state: " + index);
return states.get(index);
}
return null;

View file

@ -63,7 +63,7 @@ public abstract class MatchImpl implements Match {
public MatchImpl(MatchOptions options) {
this.options = options;
startTime = null;
this.startTime = new Date(); // to avaoid null pointer exceptions
replayAvailable = false;
draws = 0;
}
@ -133,7 +133,7 @@ public abstract class MatchImpl implements Match {
@Override
public boolean hasStarted() {
return startTime != null;
return startedGames > 0;
}
@Override