mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 02:38:02 +00:00
- Fixed a NPE in ComputerUtilCost, part 2.
This commit is contained in:
@@ -92,7 +92,7 @@ public class ComputerUtilCost {
|
|||||||
|
|
||||||
// Remove X counters - set ChosenX to max possible value here, the SAs should correct that
|
// Remove X counters - set ChosenX to max possible value here, the SAs should correct that
|
||||||
// value later as the AI decides what to do (in checkApiLogic / checkAiLogic)
|
// value later as the AI decides what to do (in checkApiLogic / checkAiLogic)
|
||||||
if (sa.hasSVar(remCounter.getAmount())) {
|
if (sa != null && sa.hasSVar(remCounter.getAmount())) {
|
||||||
final String sVar = sa.getSVar(remCounter.getAmount());
|
final String sVar = sa.getSVar(remCounter.getAmount());
|
||||||
if (sVar.equals("XChoice")) {
|
if (sVar.equals("XChoice")) {
|
||||||
sa.setSVar("ChosenX", String.valueOf(source.getCounters(type)));
|
sa.setSVar("ChosenX", String.valueOf(source.getCounters(type)));
|
||||||
|
|||||||
Reference in New Issue
Block a user