diff options
author | Travis Howell | 2006-04-09 22:41:52 +0000 |
---|---|---|
committer | Travis Howell | 2006-04-09 22:41:52 +0000 |
commit | 774476ee21ebb29302c671ec28ce59a224837efe (patch) | |
tree | add0b04e9c400bead89885a8038c1e68e756e4c9 | |
parent | 7b7eb1f331f4bcc49a4f0e9c3e1a523e095e5ecf (diff) | |
download | scummvm-rg350-774476ee21ebb29302c671ec28ce59a224837efe.tar.gz scummvm-rg350-774476ee21ebb29302c671ec28ce59a224837efe.tar.bz2 scummvm-rg350-774476ee21ebb29302c671ec28ce59a224837efe.zip |
Adjust line breaks, to prevent regression.
svn-id: r21737
-rw-r--r-- | engines/simon/charset.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/engines/simon/charset.cpp b/engines/simon/charset.cpp index 9eb032005d..09f6b482b0 100644 --- a/engines/simon/charset.cpp +++ b/engines/simon/charset.cpp @@ -317,9 +317,9 @@ void SimonEngine::showmessage_print_char(byte chr) { print_char_helper_1(&chr, 1); print_char_helper_5(_textWindow); } else if (chr == 0 || chr == ' ' || chr == 10) { - uint count = (getGameType() == GType_FF) ? _printCharPixelCount : _numLettersToPrint; - if (_printCharMaxPos - _printCharCurPos > count) { - _printCharCurPos += count; + uint count = (getGameType() == GType_FF) ? _printCharPixelCount + 1: _numLettersToPrint; + if (_printCharMaxPos - _printCharCurPos >= count) { + _printCharCurPos += _printCharPixelCount; print_char_helper_1(_lettersToPrintBuf, _numLettersToPrint); if (_printCharCurPos == _printCharMaxPos) { @@ -330,11 +330,11 @@ void SimonEngine::showmessage_print_char(byte chr) { if (chr == 10) _printCharCurPos = 0; else if (chr != 0) - _printCharCurPos += (getGameType() == GType_FF) ? feebleFontSize[chr - 32] : 1; + _printCharCurPos += _printCharPixelCount; } } else { const byte newline_character = 10; - _printCharCurPos = (getGameType() == GType_FF) ? _printCharPixelCount : _numLettersToPrint; + _printCharCurPos = _printCharPixelCount; print_char_helper_1(&newline_character, 1); print_char_helper_1(_lettersToPrintBuf, _numLettersToPrint); if (chr == ' ') { @@ -349,8 +349,7 @@ void SimonEngine::showmessage_print_char(byte chr) { _printCharPixelCount = 0; } else { _lettersToPrintBuf[_numLettersToPrint++] = chr; - if (getGameType() == GType_FF) - _printCharPixelCount += feebleFontSize[chr - 32]; + _printCharPixelCount += (getGameType() == GType_FF) ? feebleFontSize[chr - 32] : 1; } } |