GOB: skip '\r' or '\n' bytes when printing text

CRLF is sometimes found at the end of resource strings, but uselessly (the "printText" opcode has no is no "newline" capacity)

Fixes garbage characters in Adibou2 diploma text.
This commit is contained in:
Simon Delamarre 2022-10-29 00:43:41 +02:00 committed by Eugene Sandulenko
parent 4ae76a7812
commit 912f61c904
No known key found for this signature in database
GPG Key ID: 014D387312D34F08

View File

@ -96,6 +96,9 @@ void Font::drawLetter(Surface &surf, uint8 c, uint16 x, uint16 y,
uint16 data;
if (c == '\r' || c == '\n')
return;
const byte *src = getCharData(c);
if (!src) {
warning("Font::drawLetter(): getCharData() == 0");