[Scummvm-cvs-logs] SF.net SVN: scummvm: [22375] scummvm/trunk/engines/scumm/string.cpp

fingolfin at users.sourceforge.net fingolfin at users.sourceforge.net
Sun May 7 04:48:03 CEST 2006


Revision: 22375
Author:   fingolfin
Date:     2006-05-07 04:47:17 -0700 (Sun, 07 May 2006)
ViewCVS:  http://svn.sourceforge.net/scummvm/?rev=22375&view=rev

Log Message:
-----------
Handle line breaks/overflow for V1-V3 games *after* processing newline codes, to avoid double breaks (which result in spurious empty lines)

Modified Paths:
--------------
    scummvm/trunk/engines/scumm/string.cpp
Modified: scummvm/trunk/engines/scumm/string.cpp
===================================================================
--- scummvm/trunk/engines/scumm/string.cpp	2006-05-07 11:45:55 UTC (rev 22374)
+++ scummvm/trunk/engines/scumm/string.cpp	2006-05-07 11:47:17 UTC (rev 22375)
@@ -567,6 +567,15 @@
 			continue;
 		}
 
+		// Handle line overflow for V3. See also bug #1306269.
+		if (_game.version == 3 && _charset->_nextLeft >= _screenWidth) {
+			_charset->_nextLeft = _screenWidth;
+		}
+		// Handle line breaks for V1-V2
+		if (_game.version <= 2 && _charset->_nextLeft >= _screenWidth) {
+			goto newLine;
+		}
+
 		_charset->_left = _charset->_nextLeft;
 		_charset->_top = _charset->_nextTop;
 
@@ -615,14 +624,6 @@
 		} else {
 			_talkDelay += (int)VAR(VAR_CHARINC);
 		}
-		// Handle line overflow for V3
-		if (_game.version == 3 && _charset->_nextLeft >= _screenWidth) {
-			_charset->_nextLeft = _screenWidth;
-		}
-		// Handle line breaks for V1-V2
-		if (_game.version <= 2 && _charset->_nextLeft >= _screenWidth) {
-			goto newLine;
-		}
 	}
 
 #ifndef DISABLE_SCUMM_7_8


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