mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 20:28:00 +00:00
- Fixed a possible NPE if the activator for a cost is not set.
This commit is contained in:
@@ -113,6 +113,11 @@ public class Cost_Payment {
|
||||
Player activator = ability.getActivatingPlayer();
|
||||
final Card card = ability.getSourceCard();
|
||||
|
||||
if(activator == null) {
|
||||
activator = card.getController();
|
||||
}
|
||||
|
||||
|
||||
for(CostPart part : cost.getCostParts()){
|
||||
if (!part.canPay(ability, card, activator, cost))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user