Card.changeCardState ensure card can Specialize before changing state

This commit is contained in:
Northmoc
2022-08-18 09:41:29 -04:00
parent 25cfb3e0df
commit c7404192b3

View File

@@ -663,7 +663,7 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars {
} }
} else if (mode.equals("Meld") && isMeldable()) { } else if (mode.equals("Meld") && isMeldable()) {
return changeToState(CardStateName.Meld); return changeToState(CardStateName.Meld);
} else if (mode.equals("Specialize")) { } else if (mode.equals("Specialize") && canSpecialize()) {
if (customState.equalsIgnoreCase("white")) { if (customState.equalsIgnoreCase("white")) {
return changeToState(CardStateName.SpecializeW); return changeToState(CardStateName.SpecializeW);
} else if (customState.equalsIgnoreCase("blue")) { } else if (customState.equalsIgnoreCase("blue")) {