From ff071e1374c0030403d22888cf8be8f1c2d59f4b Mon Sep 17 00:00:00 2001 From: Hanmac Date: Thu, 6 Jul 2017 18:04:15 +0000 Subject: [PATCH] Card: add Extra Cost into getAbilityText for Permanent --- forge-game/src/main/java/forge/game/card/Card.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/forge-game/src/main/java/forge/game/card/Card.java b/forge-game/src/main/java/forge/game/card/Card.java index a8ac6d2d2c4..23bcb46698d 100644 --- a/forge-game/src/main/java/forge/game/card/Card.java +++ b/forge-game/src/main/java/forge/game/card/Card.java @@ -1752,6 +1752,18 @@ public class Card extends GameEntity implements Comparable { } } + // add As an additional cost to Permanent spells + if (state.getFirstAbility() != null && type.isPermanent()) { + SpellAbility first = state.getFirstAbility(); + if (first.isSpell()) { + Cost cost = first.getPayCosts(); + if (cost != null && !cost.isOnlyManaCost()) { + sb.append(cost.toString()); + sb.append("\r\n"); + } + } + } + if (this.getRules() != null && state.getView().getState().equals(CardStateName.Original)) { // try to look which what card this card can be meld to // only show this info if this card does not has the meld Effect itself