aboutsummaryrefslogtreecommitdiff
path: root/engines/gob/video_v2.cpp
diff options
context:
space:
mode:
authorSven Hesse2007-02-01 10:42:27 +0000
committerSven Hesse2007-02-01 10:42:27 +0000
commitd2b8787dd5621f57fa4daab93157f4bb59608238 (patch)
tree8386951bd9f46ade712211f7f557f98a3bc2072c /engines/gob/video_v2.cpp
parentedb61e5b0146cbd896f3137a6b859f3fa3589bef (diff)
downloadscummvm-rg350-d2b8787dd5621f57fa4daab93157f4bb59608238.tar.gz
scummvm-rg350-d2b8787dd5621f57fa4daab93157f4bb59608238.tar.bz2
scummvm-rg350-d2b8787dd5621f57fa4daab93157f4bb59608238.zip
- Fixed the palette animations
- Changed waitRetrace() to take some time, because the scrolling speed is tuned to the retrace delays svn-id: r25319
Diffstat (limited to 'engines/gob/video_v2.cpp')
-rw-r--r--engines/gob/video_v2.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/engines/gob/video_v2.cpp b/engines/gob/video_v2.cpp
index ce5cfa938e..2f71412b69 100644
--- a/engines/gob/video_v2.cpp
+++ b/engines/gob/video_v2.cpp
@@ -29,6 +29,7 @@
#include "gob/global.h"
#include "gob/video.h"
#include "gob/draw.h"
+#include "gob/util.h"
namespace Gob {
@@ -37,12 +38,17 @@ Video_v2::Video_v2(GobEngine *vm) : Video_v1(vm) {
//XXX: Use this function to update the screen for now.
// This should be moved to a better location later on.
-void Video_v2::waitRetrace(int16) {
- CursorMan.showMouse((_vm->_draw->_showCursor & 2) != 0);
+void Video_v2::waitRetrace(int16, bool mouse) {
+ uint32 time;
+
+ if (mouse)
+ CursorMan.showMouse((_vm->_draw->_showCursor & 2) != 0);
if (_vm->_draw->_frontSurface) {
+ time = _vm->_util->getTimeKey();
g_system->copyRectToScreen(_vm->_draw->_frontSurface->vidPtr + _scrollOffset,
_surfWidth, 0, 0, 320, 200);
g_system->updateScreen();
+ _vm->_util->delay(MAX(1, 10 - (int)(_vm->_util->getTimeKey() - time)));
}
}