Skip to content

Commit

Permalink
Merge pull request #875 from segrax/master
Browse files Browse the repository at this point in the history
SCUMM: V0/V1: Fix two graphical issues
  • Loading branch information
sev- committed Jan 13, 2017
2 parents 1c203ea + c95b6a9 commit 059cfbf
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
5 changes: 3 additions & 2 deletions engines/scumm/actor.cpp
Expand Up @@ -1510,10 +1510,11 @@ void Actor::putActor(int dstX, int dstY, int newRoom) {
((Actor_v0 *)this)->_newWalkBoxEntered = false;
((Actor_v0 *)this)->_CurrentWalkTo = _pos;
((Actor_v0 *)this)->_NewWalkTo = _pos;
}

// V0 always sets the actor to face the camera upon entering a room
// V0-V1 Maniac always sets the actor to face the camera upon entering a room
if (_vm->_game.id == GID_MANIAC && _vm->_game.version <= 1 && _vm->_game.platform != Common::kPlatformNES)
setDirection(oldDirToNewDir(2));
}
}

static bool inBoxQuickReject(const BoxCoords &box, int x, int y, int threshold) {
Expand Down
4 changes: 4 additions & 0 deletions engines/scumm/costume.cpp
Expand Up @@ -114,6 +114,10 @@ byte ClassicCostumeRenderer::mainRoutine(int xmoveCur, int ymoveCur) {
v1.x = _actorX;
v1.y = _actorY;

// V0/V1 games are off by 1
if (_vm->_game.version <= 1)
v1.y += 1;

if (use_scaling) {

/* Scale direction */
Expand Down
3 changes: 0 additions & 3 deletions engines/scumm/script_v2.cpp
Expand Up @@ -1131,9 +1131,6 @@ void ScummEngine_v2::o2_putActor() {
x = getVarOrDirectByte(PARAM_2);
y = getVarOrDirectByte(PARAM_3);

if (_game.id == GID_MANIAC && _game.version <= 1 && _game.platform != Common::kPlatformNES)
a->setFacing(180);

a->putActor(x, y);
}

Expand Down

0 comments on commit 059cfbf

Please sign in to comment.