mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 03:08:02 +00:00
Fix minor card render problems (#8478)
* Missing space * Unescape line breaks in card descriptions
This commit is contained in:
@@ -3219,6 +3219,10 @@ public class Card extends GameEntity implements Comparable<Card>, IHasSVars, ITr
|
||||
desc = TextUtil.fastReplace(desc, "EFFECTSOURCE", getEffectSource().getName());
|
||||
}
|
||||
|
||||
// Ensure no more escaped linebreak are present
|
||||
desc = desc.replace("\\r", "\r")
|
||||
.replace("\\n", "\n");
|
||||
|
||||
return desc.trim();
|
||||
}
|
||||
|
||||
|
||||
@@ -938,7 +938,9 @@ public class CardView extends GameEntityView {
|
||||
sb.append("\r\n\r\nMerged Cards: ").append(mergedCards);
|
||||
}
|
||||
|
||||
return sb.toString().trim();
|
||||
return sb.toString().trim()
|
||||
.replace("\\r", "\r")
|
||||
.replace("\\n", "\n");
|
||||
}
|
||||
|
||||
public CardStateView getCurrentState() {
|
||||
|
||||
@@ -252,7 +252,9 @@ public class VStack extends FDropDown {
|
||||
stackInstance = stackInstance0;
|
||||
CardView card = stackInstance.getSourceCard();
|
||||
|
||||
text = stackInstance.getText();
|
||||
text = stackInstance.getText()
|
||||
.replace("\\r", "\r")
|
||||
.replace("\\n", "\n");
|
||||
if (stackInstance.isOptionalTrigger() &&
|
||||
stackInstance0.getActivatingPlayer().equals(MatchController.instance.getCurrentPlayer())) {
|
||||
text = "(OPTIONAL) " + text;
|
||||
|
||||
Reference in New Issue
Block a user