* Show playable cards - Fixed that this feature created NPEs because it was already called if no proper game step is set.

This commit is contained in:
LevelX2 2014-08-01 12:21:56 +02:00
parent 95843f6fa3
commit 2c6aaf272f

View file

@ -1982,8 +1982,7 @@ public abstract class PlayerImpl implements Player, Serializable {
@Override
public Set<UUID> getPlayableInHand(Game game) {
Set<UUID> playable = new HashSet<>();
if (!shouldSkipGettingPlayable(game)) {
if (game.getStep() != null && !shouldSkipGettingPlayable(game)) {
// for clean_up phase show all cards
if (game.getPhase() != null && PhaseStep.CLEANUP.equals(game.getPhase().getStep().getType())) {
for (Card card: hand.getCards(game)) {