mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 10:48:00 +00:00
CountersPutEffect Stringbuilder tweak for 0 targets
This commit is contained in:
@@ -49,6 +49,13 @@ public class CountersPutEffect extends SpellAbilityEffect {
|
||||
final boolean dividedAsYouChoose = spellAbility.hasParam("DividedAsYouChoose");
|
||||
|
||||
final int amount = AbilityUtils.calculateAmount(card, spellAbility.getParamOrDefault("CounterNum", "1"), spellAbility);
|
||||
//skip the StringBuilder if no targets are chosen ("up to" scenario)
|
||||
if (spellAbility.usesTargeting()) {
|
||||
final List<Card> targetCards = SpellAbilityEffect.getTargetCards(spellAbility);
|
||||
if (targetCards.size() == 0) {
|
||||
return stringBuilder.toString();
|
||||
}
|
||||
}
|
||||
if (spellAbility.hasParam("Bolster")) {
|
||||
stringBuilder.append("Bolster ").append(amount);
|
||||
return stringBuilder.toString();
|
||||
|
||||
Reference in New Issue
Block a user