#5615 closed defect (fixed)
SCI32: KQ7 coordinates bug
Reported by: | SF/vakons | Owned by: | SF/mthreepwood |
---|---|---|---|
Priority: | normal | Component: | Engine: SCI |
Version: | Keywords: | ||
Cc: | Game: | King's Quest 7 |
Description
Bug appeared in SVN revision 55744. ( http://scummvm.svn.sourceforge.net/viewvc/scummvm?view=revision&revision=55744 )
Logic was changed (in 5 places) in engines\sci\graphics\frameout.cpp, view.cpp and compare.cpp.
If I got it right, check for SCI_VERSION_2 was removed before checking "view->isSci2Hires()".
was: 2.0.hi UpscaledCoordinates 2.0 - 2.1.hi screen / script 2.1 screen / script x.x.hi - x.x -
now: 2.0.hi UpscaledCoordinates 2.0 - 2.1.hi UpscaledCoordinates 2.1 screen / script x.x.hi UpscaledCoordinates x.x -
In King's Quest VII (SCI v2.1) this causes incorrect coordinates handling (from SCI v2.0?), because some of game objects returns view->isSci2Hires() == true.
(For example, "Corn Kernel" and "Ear of Corn", when they are being examined in 3D window, or "Ripped Petticoat", when it's taken from cactus).
As a result, objects are placed with wrong coordinates, in addition their hotspots are somewhere outside.
By the way, that patch affects everything but 2.0 games, which Gabriel Knight 1 should be, according to http://wiki.scummvm.org/index.php/Sierra_Game_Versions#SCI_Games . And it tries to handle v2.1 as v2.0. So maybe Mac version is incorrectly detected as v2.1?
Sorry if I messed something up, I don't know much about SCI interpreters yet. :)
Ticket imported from: #3253208. Ticket imported from: bugs/5615.
Attachments (3)
Change History (12)
comment:1 by , 14 years ago
comment:2 by , 14 years ago
Owner: | set to |
---|
comment:3 by , 14 years ago
I put it incorrectly probably. My KQ is not for Macintosh, it's for Windows, version 1.4, English, the one from 2 CD collection.
What I did is placed a warning message to frameout.cpp:
if (view->isSci2Hires()) { int16 dummyX = 0; _screen->adjustToUpscaledCoordinates(itemEntry->y, itemEntry->x); _screen->adjustToUpscaledCoordinates(itemEntry->z, dummyX);
warning("ver x.x, hires");
} else if (getSciVersion() == SCI_VERSION_2_1) { itemEntry->y = (itemEntry->y * _screen->getHeight()) / scriptsRunningHeight; itemEntry->x = (itemEntry->x * _screen->getWidth()) / scriptsRunningWidth; itemEntry->z = (itemEntry->z * _screen->getHeight()) / scriptsRunningHeight; }
And compiled ScummVM for Windows (with text console turned on).
Message appears with some objects - corn or petticoat (as I mentioned above) and probably some others. And those objects are shifted like this:
http://i54.tinypic.com/2vxf88w.jpg http://i55.tinypic.com/kas51h.jpg
But it doesn't appear with other objects - stick, for example. And they are shown normally.
comment:4 by , 14 years ago
The first place when message appears is the chapter title. I have attached the screenshots.
comment:5 by , 14 years ago
No, you put it correctly. All I needed was the VERSION file contents. The bitflag check is incorrect here and we should also check for screen size. I will fix later.
comment:8 by , 14 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:9 by , 6 years ago
Component: | → Engine: SCI |
---|---|
Game: | → King's Quest 7 |
The problem is that KQ7 (which is SCI2.1) incorrectly reports that flag, or its meaning was changed at one point. What version of KQ7 do you have? (In the VERSION file). It might have had its meaning changed at one point.
The Mac version is SCI2.1, not SCI2. It's like that on purpose. That Sierra Game Versions page is mostly for DOS/Windows versions only.