[Scummvm-cvs-logs] SF.net SVN: scummvm:[55788] scummvm/trunk/engines/hugo

strangerke at users.sourceforge.net strangerke at users.sourceforge.net
Sat Feb 5 15:07:30 CET 2011


Revision: 55788
          http://scummvm.svn.sourceforge.net/scummvm/?rev=55788&view=rev
Author:   strangerke
Date:     2011-02-05 14:07:30 +0000 (Sat, 05 Feb 2011)

Log Message:
-----------
HUGO: Fix 2 uninitialized variables

Modified Paths:
--------------
    scummvm/trunk/engines/hugo/display.cpp
    scummvm/trunk/engines/hugo/intro.cpp

Modified: scummvm/trunk/engines/hugo/display.cpp
===================================================================
--- scummvm/trunk/engines/hugo/display.cpp	2011-02-05 13:12:42 UTC (rev 55787)
+++ scummvm/trunk/engines/hugo/display.cpp	2011-02-05 14:07:30 UTC (rev 55788)
@@ -45,6 +45,9 @@
 Screen::Screen(HugoEngine *vm) : _vm(vm) {
 	_mainPalette = 0;
 	_curPalette = 0;
+	_dlAddIndex = 0;
+	_dlRestoreIndex = 0;
+
 	for (int i = 0; i < kNumFonts; i++) {
 		_arrayFont[i] = 0;
 		fontLoadedFl[i] = false;
@@ -56,17 +59,15 @@
 		_dlBlistList[i].dy = 0;
 	}
 	for (int i = 0; i < kRectListSize; i++) {
+		_dlAddList[i].x = 0;
+		_dlAddList[i].y = 0;
+		_dlAddList[i].dx = 0;
+		_dlAddList[i].dy = 0;
 		_dlRestoreList[i].x = 0;
 		_dlRestoreList[i].y = 0;
 		_dlRestoreList[i].dx = 0;
 		_dlRestoreList[i].dy = 0;
 	}
-	for (int i = 0; i < kRectListSize; i++) {
-		_dlAddList[i].x = 0;
-		_dlAddList[i].y = 0;
-		_dlAddList[i].dx = 0;
-		_dlAddList[i].dy = 0;
-	}
 }
 
 Screen::~Screen() {

Modified: scummvm/trunk/engines/hugo/intro.cpp
===================================================================
--- scummvm/trunk/engines/hugo/intro.cpp	2011-02-05 13:12:42 UTC (rev 55787)
+++ scummvm/trunk/engines/hugo/intro.cpp	2011-02-05 14:07:30 UTC (rev 55788)
@@ -64,6 +64,7 @@
 	surf.pixels = _vm->_screen->getFrontBuffer();
 	surf.pitch = 320;
 	surf.bytesPerPixel = 1;
+	_vm->_screen->displayList(kDisplayInit);
 }
 
 bool intro_v1d::introPlay() {
@@ -206,6 +207,7 @@
 }
 
 void intro_v2d::introInit() {
+	_vm->_screen->displayList(kDisplayInit);
 	_vm->_file->readBackground(_vm->_numScreens - 1); // display splash screen
 	surf.w = 320;
 	surf.h = 200;
@@ -251,6 +253,7 @@
 }
 
 void intro_v3d::introInit() {
+	_vm->_screen->displayList(kDisplayInit);
 	_vm->_file->readBackground(_vm->_numScreens - 1); // display splash screen
 	surf.w = 320;
 	surf.h = 200;
@@ -365,9 +368,8 @@
 * Hugo 3 - show map and set up for introPlay()
 */
 void intro_v3w::introInit() {
-
+	_vm->_screen->displayList(kDisplayInit);
 	_vm->_file->readBackground(_vm->_numScreens - 1); // display splash screen
-
 	_vm->_screen->displayBackground();
 	g_system->updateScreen();
 	g_system->delayMillis(3000);


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