- fixed localization support for intermission texts

https://forum.zdoom.org/viewtopic.php?t=66221
This commit is contained in:
alexey.lysiuk 2019-10-27 10:43:09 +02:00
parent ae2f7dd892
commit 958b52d3aa

View file

@ -332,12 +332,18 @@ bool FIntermissionActionTextscreen::ParseKey(FScanner &sc)
else if (sc.Compare("Text")) else if (sc.Compare("Text"))
{ {
sc.MustGetToken('='); sc.MustGetToken('=');
TArray<FString> lines;
do do
{ {
sc.MustGetToken(TK_StringConst); sc.MustGetToken(TK_StringConst);
mText << sc.String << '\n'; lines.Push(sc.String);
} }
while (sc.CheckToken(',')); while (sc.CheckToken(','));
if (lines.Size() == 1 && lines[0][0] == '$')
mText = lines[0];
else
for (const FString& line : lines)
mText << line << '\n';
return true; return true;
} }
else if (sc.Compare("TextColor")) else if (sc.Compare("TextColor"))