[Scummvm-cvs-logs] SF.net SVN: scummvm:[44938] scummvm/trunk/engines/sci/engine/kgraphics.cpp

thebluegr at users.sourceforge.net thebluegr at users.sourceforge.net
Sun Oct 11 20:42:53 CEST 2009


Revision: 44938
          http://scummvm.svn.sourceforge.net/scummvm/?rev=44938&view=rev
Author:   thebluegr
Date:     2009-10-11 18:42:52 +0000 (Sun, 11 Oct 2009)

Log Message:
-----------
Added kSetPort case with 4 parameters (used in the ending of LSL6)

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kgraphics.cpp

Modified: scummvm/trunk/engines/sci/engine/kgraphics.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-10-11 18:41:13 UTC (rev 44937)
+++ scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-10-11 18:42:52 UTC (rev 44938)
@@ -1253,22 +1253,23 @@
 	int16 picTop, picLeft;
 
 	switch (argc) {
-		case 1:
+	case 1:
 		portPtr = argv[0].toSint16();
 		s->_gui->setPort(portPtr);
 		break;
 
-		case 6:
+	case 4:
+	case 6:
 		picRect.top = argv[0].toSint16();
 		picRect.left = argv[1].toSint16();
 		picRect.bottom = argv[2].toSint16();
 		picRect.right = argv[3].toSint16();
-		picTop = argv[4].toSint16();
-		picLeft = argv[5].toSint16();
+		picTop = (argc == 6) ? argv[4].toSint16() : 0;
+		picLeft = (argc == 6) ? argv[5].toSint16() : 0;
 		s->_gui->setPortPic(picRect, picTop, picLeft);
 		break;
 
-		default:
+	default:
 		error("SetPort was called with %d parameters", argc);
 		break;
 	}


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