mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 12:18:00 +00:00
- NPE guard.
This commit is contained in:
@@ -850,7 +850,7 @@ public class AiController {
|
||||
int neededMana = 0;
|
||||
boolean dangerousRecurringCost = false;
|
||||
|
||||
Cost costWithBuyback = sa.getPayCosts().copy();
|
||||
Cost costWithBuyback = sa.getPayCosts() != null ? sa.getPayCosts().copy() : Cost.Zero;
|
||||
for (OptionalCostValue opt : GameActionUtil.getOptionalCostValues(sa)) {
|
||||
if (opt.getType() == OptionalCost.Buyback) {
|
||||
costWithBuyback.add(opt.getCost());
|
||||
|
||||
Reference in New Issue
Block a user