[Scummvm-cvs-logs] SF.net SVN: scummvm: [23812] scummvm/branches/branch-0-9-0
eriktorbjorn at users.sourceforge.net
eriktorbjorn at users.sourceforge.net
Thu Aug 31 19:29:46 CEST 2006
Revision: 23812
http://svn.sourceforge.net/scummvm/?rev=23812&view=rev
Author: eriktorbjorn
Date: 2006-08-31 10:29:26 -0700 (Thu, 31 Aug 2006)
Log Message:
-----------
Backported patch #1549054, fixes to the Kyra 1 intro scrolling.
Modified Paths:
--------------
scummvm/branches/branch-0-9-0/NEWS
scummvm/branches/branch-0-9-0/engines/kyra/sequences_v1.cpp
Modified: scummvm/branches/branch-0-9-0/NEWS
===================================================================
--- scummvm/branches/branch-0-9-0/NEWS 2006-08-31 17:17:31 UTC (rev 23811)
+++ scummvm/branches/branch-0-9-0/NEWS 2006-08-31 17:29:26 UTC (rev 23812)
@@ -25,6 +25,11 @@
Broken Sword 2:
- More robust handling of the optional startup.inf file.
+ Kyrandia:
+ - Scrolling in the Kyrandia intro is less CPU intensive, at the cost of
+ not being as smooth as before.
+ - Fixed a tiny graphics glitch in the Kyrandia intro.
+
PSP Port:
- Fixed crashes during scrolling scenes in certain SCUMM games.
- Added saving of thumbnail in SCUMM savegames.
Modified: scummvm/branches/branch-0-9-0/engines/kyra/sequences_v1.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/kyra/sequences_v1.cpp 2006-08-31 17:17:31 UTC (rev 23811)
+++ scummvm/branches/branch-0-9-0/engines/kyra/sequences_v1.cpp 2006-08-31 17:29:26 UTC (rev 23812)
@@ -151,34 +151,39 @@
if (_quitFlag)
return;
- int y1 = 8;
- int h1 = 175;
- int y2 = 176;
- int h2 = 0;
- int32 start, now;
- int wait;
- _screen->copyRegion(0, 91, 0, 8, 320, 103, 6, 2);
- _screen->copyRegion(0, 0, 0, 111, 320, 64, 6, 2);
+ _screen->copyRegion(0, 91, 0, 8, 320, 104, 6, 2);
+ _screen->copyRegion(0, 0, 0, 112, 320, 64, 6, 2);
+
+ uint32 start = _system->getMillis();
+ bool doneFlag = false;
+ int oldDistance = 0;
+
do {
- start = (int32)_system->getMillis();
- if (h1 > 0) {
+ uint32 now = _system->getMillis();
+
+ // The smallest y2 we ever draw the screen for is 65.
+ int distance = (now - start) / _tickLength;
+ if (distance > 112) {
+ distance = 112;
+ doneFlag = true;
+ }
+
+ if (distance > oldDistance) {
+ int y1 = 8 + distance;
+ int h1 = 168 - distance;
+ int y2 = 176 - distance;
+ int h2 = distance;
+
_screen->copyRegion(0, y1, 0, 8, 320, h1, 2, 0);
+ if (h2 > 0)
+ _screen->copyRegion(0, 64, 0, y2, 320, h2, 4, 0);
+ _screen->updateScreen();
}
- ++y1;
- --h1;
- if (h2 > 0) {
- _screen->copyRegion(0, 64, 0, y2, 320, h2, 4, 0);
- }
- --y2;
- ++h2;
- _screen->updateScreen();
- now = (int32)_system->getMillis();
- wait = _tickLength - (now - start);
- if (wait > 0) {
- delay(wait);
- }
- } while (y2 >= 64 && !_quitFlag && !_abortIntroFlag);
+ oldDistance = distance;
+ delay(10);
+ } while (!doneFlag && !_quitFlag && !_abortIntroFlag);
+
if (_quitFlag)
return;
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