- Little refactor CardsCycledOrDiscardedThisTurnWatcher

This commit is contained in:
Achilles 2017-07-16 12:19:59 -05:00
parent 60951f645b
commit 79be2c4ce8

View file

@ -61,7 +61,9 @@ public class CardsCycledOrDiscardedThisTurnWatcher extends Watcher {
@Override
public void watch(GameEvent event, Game game) {
if (event.getType() == GameEvent.EventType.DISCARDED_CARD && event.getPlayerId() != null) {
if (event.getType() == GameEvent.EventType.DISCARDED_CARD
|| event.getType() == GameEvent.EventType.CYCLED_CARD
&& event.getPlayerId() != null) {
Card card = game.getCard(event.getTargetId());
if (card != null) {
Cards c = getCardsCycledOrDiscardedThisTurn(event.getPlayerId());