diff -ur ScummVM-cvs20030505/scummvm/scumm/gfx.cpp ScummVM-cvs20030505+hack/scummvm/scumm/gfx.cpp
old
|
new
|
|
1958 | 1958 | clampCameraPos(&camera._cur); |
1959 | 1959 | |
1960 | 1960 | camera._dest = camera._cur; |
| 1961 | _vars[VAR_CAMERA_DEST_X] = camera._dest.x; |
| 1962 | _vars[VAR_CAMERA_DEST_Y] = camera._dest.y; |
1961 | 1963 | |
1962 | 1964 | assert(camera._cur.x >= (_realWidth / 2) && camera._cur.y >= (_realHeight / 2)); |
1963 | 1965 | |
… |
… |
|
1996 | 1998 | int ax, ay; |
1997 | 1999 | |
1998 | 2000 | camera._follows = a->number; |
| 2001 | _vars[VAR_CAMERA_FOLLOWED_ACTOR] = a->number; |
1999 | 2002 | |
2000 | 2003 | if (!a->isInCurrentRoom()) { |
2001 | 2004 | startScene(a->getRoom(), 0, 0); |
… |
… |
|
2072 | 2075 | } |
2073 | 2076 | |
2074 | 2077 | if (camera._movingToActor) { |
2075 | | camera._dest.x = a->x; |
2076 | | camera._dest.y = a->y; |
| 2078 | _vars[VAR_CAMERA_DEST_X] = camera._dest.x = a->x; |
| 2079 | _vars[VAR_CAMERA_DEST_Y] = camera._dest.y = a->y; |
2077 | 2080 | } |
2078 | 2081 | |
2079 | 2082 | assert(camera._cur.x >= (_realWidth / 2) && camera._cur.y >= (_realHeight / 2)); |
… |
… |
|
2131 | 2134 | _vars[VAR_CAMERA_POS_X] = camera._cur.x; |
2132 | 2135 | _vars[VAR_CAMERA_POS_Y] = camera._cur.y; |
2133 | 2136 | |
2134 | | _vars[VAR_CAMERA_DEST_X] = camera._dest.x; |
2135 | | |
2136 | | _vars[VAR_CAMERA_DEST_Y] = camera._dest.y; |
2137 | | |
2138 | | _vars[VAR_CAMERA_FOLLOWED_ACTOR] = camera._follows; |
2139 | | |
2140 | 2137 | if (_vars[VAR_SCROLL_SCRIPT]) |
2141 | 2138 | runScript(_vars[VAR_SCROLL_SCRIPT], 0, 0, 0); |
2142 | 2139 | } |
… |
… |
|
2252 | 2249 | void Scumm::panCameraTo(int x, int y) { |
2253 | 2250 | if (_features & GF_AFTER_V7) { |
2254 | 2251 | |
2255 | | camera._follows = 0; |
2256 | | camera._dest.x = x; |
2257 | | camera._dest.y = y; |
| 2252 | _vars[VAR_CAMERA_FOLLOWED_ACTOR] = camera._follows = 0; |
| 2253 | _vars[VAR_CAMERA_DEST_X] = camera._dest.x = x; |
| 2254 | _vars[VAR_CAMERA_DEST_Y] = camera._dest.y = y; |
2258 | 2255 | } else { |
2259 | 2256 | |
2260 | 2257 | camera._dest.x = x; |
diff -ur ScummVM-cvs20030505/scummvm/scumm/script_v5.cpp ScummVM-cvs20030505+hack/scummvm/scumm/script_v5.cpp
old
|
new
|
|
1348 | 1348 | startScene(a->room, a, obj); |
1349 | 1349 | _vars[VAR_WALKTO_OBJ] = 0; |
1350 | 1350 | |
1351 | | camera._dest.x = camera._cur.x = a->x; |
| 1351 | // FIXME: Can this be removed? |
| 1352 | camera._cur.x = a->x; |
| 1353 | |
1352 | 1354 | setCameraAt(a->x, a->y); |
1353 | 1355 | setCameraFollows(a); |
1354 | 1356 | |
diff -ur ScummVM-cvs20030505/scummvm/scumm/script_v6.cpp ScummVM-cvs20030505+hack/scummvm/scumm/script_v6.cpp
old
|
new
|
|
953 | 953 | int x, y; |
954 | 954 | |
955 | 955 | camera._follows = 0; |
| 956 | _vars[VAR_CAMERA_FOLLOWED_ACTOR] = 0; |
956 | 957 | |
957 | 958 | y = pop(); |
958 | 959 | x = pop(); |