Only owner of the card with muster can use it.
This commit is contained in:
@@ -32,13 +32,15 @@ public class MusterRule {
|
||||
&& game.getGameState().getHand(playerId).size() > 0) {
|
||||
List<OptionalTriggerAction> actions = new LinkedList<OptionalTriggerAction>();
|
||||
for (PhysicalCard musterCard : Filters.filterActive(game.getGameState(), game.getModifiersQuerying(), Keyword.MUSTER)) {
|
||||
OptionalTriggerAction action = new OptionalTriggerAction("muster" + musterCard.getCardId(), musterCard);
|
||||
action.setText("Use Muster");
|
||||
action.appendCost(
|
||||
new ChooseAndDiscardCardsFromHandEffect(action, playerId, false, 1));
|
||||
action.appendEffect(
|
||||
new DrawCardsEffect(playerId, 1));
|
||||
actions.add(action);
|
||||
if (playerId.equals(musterCard.getOwner())) {
|
||||
OptionalTriggerAction action = new OptionalTriggerAction("muster" + musterCard.getCardId(), musterCard);
|
||||
action.setText("Use Muster");
|
||||
action.appendCost(
|
||||
new ChooseAndDiscardCardsFromHandEffect(action, playerId, false, 1));
|
||||
action.appendEffect(
|
||||
new DrawCardsEffect(playerId, 1));
|
||||
actions.add(action);
|
||||
}
|
||||
}
|
||||
|
||||
return actions;
|
||||
|
||||
Reference in New Issue
Block a user