[Scummvm-cvs-logs] SF.net SVN: scummvm:[55407] scummvm/trunk/engines/gob/videoplayer.cpp
drmccoy at users.sourceforge.net
drmccoy at users.sourceforge.net
Sat Jan 22 05:39:39 CET 2011
Revision: 55407
http://scummvm.svn.sourceforge.net/scummvm/?rev=55407&view=rev
Author: drmccoy
Date: 2011-01-22 04:39:39 +0000 (Sat, 22 Jan 2011)
Log Message:
-----------
GOB: Don't mess with the break key in Urban Runner
To be able ESC videos, you need to switch on ESC in the settings
in the right part of the menu, because the scripts needs to
trigger the drawing of the last frame of the ESC'd video.
Otherwise, the graphics e.g. stops mid-frame during a turn.
Modified Paths:
--------------
scummvm/trunk/engines/gob/videoplayer.cpp
Modified: scummvm/trunk/engines/gob/videoplayer.cpp
===================================================================
--- scummvm/trunk/engines/gob/videoplayer.cpp 2011-01-22 04:14:33 UTC (rev 55406)
+++ scummvm/trunk/engines/gob/videoplayer.cpp 2011-01-22 04:39:39 UTC (rev 55407)
@@ -263,8 +263,10 @@
return true;
}
- // NOTE: For testing (and comfort?) purposes, we enable aborting of all videos)
- properties.breakKey = kShortKeyEscape;
+ if (_vm->getGameType() != kGameTypeUrban)
+ // NOTE: For testing (and comfort?) purposes, we enable aborting of all videos.
+ // Except for Urban Runner, where it leads to glitches
+ properties.breakKey = kShortKeyEscape;
while ((properties.startFrame != properties.lastFrame) &&
(properties.startFrame < (int32)(video->decoder->getFrameCount() - 1))) {
@@ -495,7 +497,21 @@
&_vm->_global->_inter_mouseY, &_vm->_game->_mouseButtons);
_vm->_inter->storeKey(_vm->_util->checkKey());
- if (VAR(0) == (unsigned) properties.breakKey) {
+
+ // Check for that specific key
+ bool pressedBreak = (VAR(0) == (unsigned)properties.breakKey);
+
+ // Mouse buttons
+ if (properties.breakKey < 4)
+ if (_vm->_game->_mouseButtons & properties.breakKey)
+ pressedBreak = true;
+
+ // Any key
+ if (properties.breakKey == 4)
+ if (VAR(0) != 0)
+ pressedBreak = true;
+
+ if (pressedBreak) {
video.decoder->disableSound();
// Seek to the last frame. Some scripts depend on that.
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