Fixed some handling to possible NPEs.

This commit is contained in:
LevelX2 2013-07-15 00:53:30 +02:00
parent e7cb9d567d
commit bc9dca4d8a
3 changed files with 11 additions and 3 deletions

View file

@ -701,7 +701,11 @@ public class HumanPlayer extends PlayerImpl<HumanPlayer> {
updateGameStatePriority("getAmount", game);
game.fireGetAmountEvent(playerId, message, min, max);
waitForIntegerResponse(game);
return response.getInteger();
if (response != null) {
return response.getInteger();
} else {
return 0;
}
}
@Override