[Scummvm-cvs-logs] SF.net SVN: scummvm: [25266] scummvm/trunk/engines/scumm/string.cpp
fingolfin at users.sourceforge.net
fingolfin at users.sourceforge.net
Mon Jan 29 22:06:40 CET 2007
Revision: 25266
http://scummvm.svn.sourceforge.net/scummvm/?rev=25266&view=rev
Author: fingolfin
Date: 2007-01-29 13:06:39 -0800 (Mon, 29 Jan 2007)
Log Message:
-----------
cleanup
Modified Paths:
--------------
scummvm/trunk/engines/scumm/string.cpp
Modified: scummvm/trunk/engines/scumm/string.cpp
===================================================================
--- scummvm/trunk/engines/scumm/string.cpp 2007-01-29 20:58:57 UTC (rev 25265)
+++ scummvm/trunk/engines/scumm/string.cpp 2007-01-29 21:06:39 UTC (rev 25266)
@@ -400,7 +400,7 @@
void ScummEngine::CHARSET_1() {
Actor *a;
- int t, c = 0;
+ int c = 0;
#ifndef DISABLE_SCUMM_7_8
byte subtitleBuffer[200];
byte *subtitleLine = subtitleBuffer;
@@ -514,16 +514,17 @@
}
}
- t = _charset->_right - _string[0].xpos - 1;
- if (_charset->_center) {
- if (t > _nextLeft)
- t = _nextLeft;
- t *= 2;
+ if (_game.version > 3) {
+ int maxwidth = _charset->_right - _string[0].xpos - 1;
+ if (_charset->_center) {
+ if (maxwidth > _nextLeft)
+ maxwidth = _nextLeft;
+ maxwidth *= 2;
+ }
+
+ _charset->addLinebreaks(0, _charsetBuffer + _charsetBufPos, 0, maxwidth);
}
- if (_game.version > 3)
- _charset->addLinebreaks(0, _charsetBuffer + _charsetBufPos, 0, t);
-
if (_charset->_center) {
_nextLeft -= _charset->getStringWidth(0, _charsetBuffer + _charsetBufPos) / 2;
if (_nextLeft < 0)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list