aboutsummaryrefslogtreecommitdiff
path: root/engines/bladerunner
diff options
context:
space:
mode:
authorThanasis Antoniou2019-09-09 18:05:25 +0300
committerThanasis Antoniou2019-09-09 18:07:21 +0300
commit8f4d3654f2b66c21711eccb73df65e797236a9d2 (patch)
tree6ef3f0c1abca0d84aeac98e83f894d9da0809bdc /engines/bladerunner
parent5cc574a6958e932b1e1defc26bad7fc8eef9826b (diff)
downloadscummvm-rg350-8f4d3654f2b66c21711eccb73df65e797236a9d2.tar.gz
scummvm-rg350-8f4d3654f2b66c21711eccb73df65e797236a9d2.tar.bz2
scummvm-rg350-8f4d3654f2b66c21711eccb73df65e797236a9d2.zip
BLADERUNNER: Fix Leon Clerk encounter bug
When McCoy leaves CT09 they should be both gone. They were not This was our bug, a bad translation of an if clause. Also added in this commit is a bit different behavior for the restored content case. In restored content, the player is not allowed to leave until the situation is resolved.
Diffstat (limited to 'engines/bladerunner')
-rw-r--r--engines/bladerunner/script/ai/desk_clerk.cpp2
-rw-r--r--engines/bladerunner/script/ai/leon.cpp5
-rw-r--r--engines/bladerunner/script/scene/ct09.cpp5
3 files changed, 11 insertions, 1 deletions
diff --git a/engines/bladerunner/script/ai/desk_clerk.cpp b/engines/bladerunner/script/ai/desk_clerk.cpp
index 363a7e3d26..8b1e91fd43 100644
--- a/engines/bladerunner/script/ai/desk_clerk.cpp
+++ b/engines/bladerunner/script/ai/desk_clerk.cpp
@@ -118,11 +118,13 @@ int AIScriptDeskClerk::GetFriendlinessModifierIfGetsClue(int otherActorId, int c
bool AIScriptDeskClerk::GoalChanged(int currentGoalNumber, int newGoalNumber) {
switch (newGoalNumber) {
case kGoalDeskClerkDefault:
+ // fall through
case kGoalDeskClerkRecovered:
Actor_Put_In_Set(kActorDeskClerk, kSetCT09);
Actor_Set_At_XYZ(kActorDeskClerk, 282.0f, 360.52f, 743.0f, 513);
break;
case kGoalDeskClerkKnockedOut:
+ // fall through
case kGoalDeskClerkGone:
Actor_Put_In_Set(kActorDeskClerk, kSetFreeSlotH);
Actor_Set_At_Waypoint(kActorDeskClerk, 40, 0);
diff --git a/engines/bladerunner/script/ai/leon.cpp b/engines/bladerunner/script/ai/leon.cpp
index 6a3a1b92da..e6e5c4ccc9 100644
--- a/engines/bladerunner/script/ai/leon.cpp
+++ b/engines/bladerunner/script/ai/leon.cpp
@@ -122,7 +122,7 @@ void AIScriptLeon::OtherAgentEnteredThisScene(int otherActorId) {
void AIScriptLeon::OtherAgentExitedThisScene(int otherActorId) {
if (otherActorId == kActorMcCoy
- && Actor_Query_Which_Set_In(kActorLeon) == kSetCT11
+ && Actor_Query_Which_Set_In(kActorLeon) != kSetCT11
) {
AI_Movement_Track_Flush(kActorLeon);
ADQ_Flush();
@@ -250,6 +250,9 @@ bool AIScriptLeon::GoalChanged(int currentGoalNumber, int newGoalNumber) {
return false;
case kGoalLeonLeave:
+ if (_vm->_cutContent) {
+ Scene_Exits_Enable();
+ }
Actor_Force_Stop_Walking(kActorLeon);
AI_Movement_Track_Flush(kActorLeon);
AI_Movement_Track_Append(kActorLeon, 351, 0);
diff --git a/engines/bladerunner/script/scene/ct09.cpp b/engines/bladerunner/script/scene/ct09.cpp
index 3d4593d8e0..dcf5549244 100644
--- a/engines/bladerunner/script/scene/ct09.cpp
+++ b/engines/bladerunner/script/scene/ct09.cpp
@@ -171,6 +171,11 @@ void SceneScriptCT09::PlayerWalkedIn() {
Game_Flag_Set(kFlagCT09Entered);
Actor_Set_Goal_Number(kActorLeon, kGoalLeonHoldingDeskClerk);
leonScene = true;
+ if (_vm->_cutContent) {
+ // don't allow McCoy to leave until the situation is resolved
+ // (the vanilla game allows him to leave)
+ Scene_Exits_Disable();
+ }
}
if (Game_Flag_Query(kFlagCT10toCT09)) {