Skip to content

Commit

Permalink
STARTREK: "Use" action was bypassing "disableWalk"
Browse files Browse the repository at this point in the history
When objects could be walked to by "using" them, this bypassed the
"disableWalk" variable.
  • Loading branch information
Stewmath authored and sev- committed Aug 9, 2018
1 parent 2f3c4b9 commit 2771797
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion engines/startrek/awaymission.cpp
Expand Up @@ -515,7 +515,8 @@ void StarTrekEngine::handleAwayMissionAction() {
if (action.activeObject() != action.passiveObject()) {
switch (action.activeObject()) {
case OBJECT_KIRK:
if (!_room->handleAction(ACTION_WALK, action.passiveObject(), 0, 0)
// BUGFIX: Don't allow the "use" action to bypass the "disableWalking" variable
if (!(!_awayMission.disableWalking && _room->handleAction(ACTION_WALK, action.passiveObject(), 0, 0))
&& !_room->handleAction(ACTION_GET, action.passiveObject(), 0, 0)) {
showTextbox("Capt. Kirk", getLoadedText(GROUNDTX_KIRK_USE), 20, 20, TEXTCOLOR_YELLOW, 0);
}
Expand Down

0 comments on commit 2771797

Please sign in to comment.