Skip to content

Commit

Permalink
XEEN: Further simplification in checkMoveDirection
Browse files Browse the repository at this point in the history
  • Loading branch information
dreammaster committed Apr 28, 2018
1 parent b9e8320 commit d5acefa
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions engines/xeen/interface.cpp
Expand Up @@ -921,16 +921,18 @@ bool Interface::checkMoveDirection(int key) {
break;
}

// Get next facing tile information, and then reset back to the old direction (if changed)
map.getCell(7);
party._mazeDirection = dir;


int startSurfaceId = map._currentSurfaceId;
int surfaceId;

if (debugger._intangible)
return true;

if (map._isOutdoors) {
party._mazeDirection = dir;

switch (map._currentWall) {
case 5:
if (_vm->_files->_ccNum)
Expand Down Expand Up @@ -976,12 +978,9 @@ bool Interface::checkMoveDirection(int key) {
} else {
surfaceId = map.getCell(2);
if (surfaceId >= map.mazeData()._difficulties._wallNoPass) {
party._mazeDirection = dir;
sound.playFX(46);
return false;
} else {
party._mazeDirection = dir;

if (startSurfaceId != SURFTYPE_SWAMP || party.checkSkill(SWIMMING) ||
party._walkOnWaterActive) {
if (_buttonValue == Common::KEYCODE_UP && _wo[107]) {
Expand Down

0 comments on commit d5acefa

Please sign in to comment.