mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-26 05:51:20 +00:00
- do not calculate translations for empty fonts.
FONTDEFS will create some due to lack of game filtering.
This commit is contained in:
parent
2ca2076a3f
commit
36e84a3669
1 changed files with 11 additions and 0 deletions
|
@ -141,6 +141,17 @@ void FSpecialFont::LoadTranslations()
|
||||||
{
|
{
|
||||||
FFont::LoadTranslations();
|
FFont::LoadTranslations();
|
||||||
|
|
||||||
|
bool empty = true;
|
||||||
|
for (auto& c : Chars)
|
||||||
|
{
|
||||||
|
if (c.OriginalPic != nullptr)
|
||||||
|
{
|
||||||
|
empty = false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (empty) return; // Font has no characters.
|
||||||
|
|
||||||
bool needsnotrans = false;
|
bool needsnotrans = false;
|
||||||
// exclude the non-translated colors from the translation calculation
|
// exclude the non-translated colors from the translation calculation
|
||||||
for (int i = 0; i < 256; i++)
|
for (int i = 0; i < 256; i++)
|
||||||
|
|
Loading…
Reference in a new issue