diff options
Diffstat (limited to 'engines/bladerunner/script/scene')
93 files changed, 1192 insertions, 1064 deletions
diff --git a/engines/bladerunner/script/scene/ar01.cpp b/engines/bladerunner/script/scene/ar01.cpp index c69dbffcfc..2980209afc 100644 --- a/engines/bladerunner/script/scene/ar01.cpp +++ b/engines/bladerunner/script/scene/ar01.cpp @@ -26,9 +26,9 @@ namespace BladeRunner { void SceneScriptAR01::InitializeScene() { Music_Play(0, 25, 0, 2, -1, 1, 2); - if (Game_Flag_Query(323)) { + if (Game_Flag_Query(kFlagHC01toAR01)) { Setup_Scene_Information(-477.0f, 0.0f, -149.0f, 333); - } else if (Game_Flag_Query(321) == 1) { + } else if (Game_Flag_Query(kFlagAR02toAR01)) { Setup_Scene_Information(-182.0f, 0.0f, -551.0f, 518); } else { Setup_Scene_Information(-152.0f, 0.0f, 332.0f, 545); @@ -67,22 +67,33 @@ void SceneScriptAR01::InitializeScene() { Ambient_Sounds_Add_Sound(375, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(376, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(377, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); - if (Game_Flag_Query(kFlagSpinnerAtAR01) && !Game_Flag_Query(321) && !Game_Flag_Query(323)) { + if ( Game_Flag_Query(kFlagSpinnerAtAR01) + && !Game_Flag_Query(kFlagAR02toAR01) + && !Game_Flag_Query(kFlagHC01toAR01) + ) { Actor_Set_Invisible(kActorMcCoy, true); Game_Flag_Set(273); - Scene_Loop_Start_Special(0, 1, 0); + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 1, false); Scene_Loop_Set_Default(2); - } else if (Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(321)) { - Scene_Loop_Start_Special(0, 0, 0); + } else if (Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagAR02toAR01) + ) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 0, false); Scene_Loop_Set_Default(2); - Game_Flag_Reset(321); - } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(321)) { - Scene_Loop_Start_Special(0, 6, 0); + Game_Flag_Reset(kFlagAR02toAR01); + } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagAR02toAR01) + ) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 6, false); Scene_Loop_Set_Default(7); - Game_Flag_Reset(321); - } else if (Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(323)) { + Game_Flag_Reset(kFlagAR02toAR01); + } else if (Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagHC01toAR01) + ) { Scene_Loop_Set_Default(2); - } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(323)) { + } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagHC01toAR01) + ) { Scene_Loop_Set_Default(7); } else { Scene_Loop_Set_Default(7); @@ -168,33 +179,33 @@ bool SceneScriptAR01::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -358.0, 0.0, -149.0, 0, 1, false, 0)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -477.0, 0.0, -149.0, 0, 0, false, 0); - Game_Flag_Set(322); + Game_Flag_Set(kFlagAR01toHC01); Game_Flag_Set(464); - Game_Flag_Reset(180); + Game_Flag_Reset(kFlagMcCoyAtARxx); Game_Flag_Set(479); - Set_Enter(8, kSceneHC01); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC01); Actor_Set_Goal_Number(kActorFishDealer, 3); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -182.0, 0.0, -551.0, 0, 1, false, 0)) { - Game_Flag_Set(320); + Game_Flag_Set(kFlagAR01toAR02); Async_Actor_Walk_To_XYZ(kActorMcCoy, -222.0, 0.0, -690.0, 0, false); - Set_Enter(0, kSceneAR02); + Set_Enter(kSetAR01_AR02, kSceneAR02); Actor_Set_Goal_Number(kActorFishDealer, 3); } return true; } if (exitId == 2) { if (Game_Flag_Query(486) == 1) { - Spinner_Set_Selectable_Destination_Flag(6, 1); + Spinner_Set_Selectable_Destination_Flag(kSpinnerDestinationDNARow, true); } int v1 = Loop_Actor_Walk_To_XYZ(kActorMcCoy, -164.0f, 0.0f, 332.0f, 0, 1, false, 0); Actor_Face_Heading(kActorMcCoy, 545, false); if (Actor_Query_Goal_Number(kActorIzo) >= 2 && Actor_Query_Goal_Number(kActorIzo) <= 103) { Player_Loses_Control(); - Actor_Put_In_Set(kActorIzo, 0); + Actor_Put_In_Set(kActorIzo, kSetAR01_AR02); Actor_Set_At_XYZ(kActorIzo, -448.0, 0.0, 130.0, 0); Loop_Actor_Walk_To_XYZ(kActorIzo, -323.0f, 0.64f, 101.74f, 48, 0, true, 0); Loop_Actor_Walk_To_Actor(kActorIzo, kActorMcCoy, 48, 0, true); @@ -213,83 +224,83 @@ bool SceneScriptAR01::ClickedOnExit(int exitId) { Actor_Voice_Over(4350, kActorVoiceOver); Game_Flag_Set(660); } - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - Game_Flag_Reset(257); - Game_Flag_Reset(180); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtHFxx); + Game_Flag_Reset(kFlagMcCoyAtARxx); - int spinnerDest = Spinner_Interface_Choose_Dest(4, 0); + int spinnerDest = Spinner_Interface_Choose_Dest(4, false); Actor_Face_Heading(kActorMcCoy, 545, false); switch (spinnerDest) { - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetPS01, kScenePS01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetMA01, kSceneMA01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetRC01, kSceneRC01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetCT01_CT12, kSceneCT01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetTB02_TB03, kSceneTB02); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetBB01, kSceneBB01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetNR01, kSceneNR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; - case 9: - Game_Flag_Set(257); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtAR01); Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); - Scene_Loop_Start_Special(1, 5, 1); + Set_Enter(kSetHF01, kSceneHF01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 5, true); break; default: - Game_Flag_Set(180); + Game_Flag_Set(kFlagMcCoyAtARxx); Actor_Set_Invisible(kActorMcCoy, false); break; } @@ -332,9 +343,9 @@ void SceneScriptAR01::PlayerWalkedIn() { if (!Game_Flag_Query(710)) { Game_Flag_Set(710); } - if (Game_Flag_Query(323) == 1) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -358.0f, 0.0f, -149.0f, 0, 1, false, 0); - Game_Flag_Reset(323); + if (Game_Flag_Query(kFlagHC01toAR01)) { + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -358.0f, 0.0f, -149.0f, 0, true, false, 0); + Game_Flag_Reset(kFlagHC01toAR01); } if (Actor_Query_Goal_Number(kActorPhotographer) < 199) { Actor_Set_Goal_Number(kActorPhotographer, 199); @@ -348,7 +359,9 @@ void SceneScriptAR01::PlayerWalkedOut() { if (!Game_Flag_Query(479)) { Music_Stop(2); } - if (!Game_Flag_Query(322) && !Game_Flag_Query(320)) { + if (!Game_Flag_Query(kFlagAR01toHC01) + && !Game_Flag_Query(kFlagAR01toAR02) + ) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Outtake_Play(kOuttakeTowards3, true, -1); diff --git a/engines/bladerunner/script/scene/ar02.cpp b/engines/bladerunner/script/scene/ar02.cpp index 104ba2ccc4..d0b5bf8bba 100644 --- a/engines/bladerunner/script/scene/ar02.cpp +++ b/engines/bladerunner/script/scene/ar02.cpp @@ -62,14 +62,16 @@ void SceneScriptAR02::InitializeScene() { Ambient_Sounds_Add_Sound(375, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(376, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(377, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); - if (Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(320)) { - Scene_Loop_Start_Special(0, 1, 0); + if (Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagAR01toAR02)) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 1, false); Scene_Loop_Set_Default(2); - Game_Flag_Reset(320); - } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) && Game_Flag_Query(320)) { - Scene_Loop_Start_Special(0, 0, 0); + Game_Flag_Reset(kFlagAR01toAR02); + } else if (!Game_Flag_Query(kFlagSpinnerAtAR01) + && Game_Flag_Query(kFlagAR01toAR02)) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 0, false); Scene_Loop_Set_Default(2); - Game_Flag_Reset(320); + Game_Flag_Reset(kFlagAR01toAR02); } else { Scene_Loop_Set_Default(2); } @@ -81,7 +83,7 @@ void SceneScriptAR02::SceneLoaded() { Item_Add_To_World(106, 976, 0, -442.84f, 36.77f, -1144.51f, 360, 36, 36, false, true, false, true); } if (Global_Variable_Query(kVariableChapter) == 4 && !Game_Flag_Query(374)) { - Game_Flag_Set(0); + Game_Flag_Set(kFlagNotUsed0); Item_Remove_From_World(106); } } @@ -199,7 +201,7 @@ bool SceneScriptAR02::ClickedOnItem(int itemId, bool a2) { bool SceneScriptAR02::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -182.0f, 0.0f, -551.0f, 0, 1, false, 0)) { - Game_Flag_Set(321); + Game_Flag_Set(kFlagAR02toAR01); Async_Actor_Walk_To_XYZ(kActorMcCoy, -182.0f, 0.0f, -407.0f, 0, false); Set_Enter(kSetAR01_AR02, kSceneAR01); } @@ -209,8 +211,8 @@ bool SceneScriptAR02::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -465.0f, 0.0f, -799.0f, 0, 1, false, 0)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -560.0f, 0.0f, -799.0f, 0, 0, false, 0); Game_Flag_Set(kFlagAR02toRC03); - Game_Flag_Reset(180); - Game_Flag_Set(182); + Game_Flag_Reset(kFlagMcCoyAtARxx); + Game_Flag_Set(kFlagMcCoyAtRCxx); Music_Stop(3); Set_Enter(kSetRC03, kSceneRC03); } diff --git a/engines/bladerunner/script/scene/bb01.cpp b/engines/bladerunner/script/scene/bb01.cpp index 9bdae8c9f0..ea1afcf6e9 100644 --- a/engines/bladerunner/script/scene/bb01.cpp +++ b/engines/bladerunner/script/scene/bb01.cpp @@ -25,9 +25,9 @@ namespace BladeRunner { void SceneScriptBB01::InitializeScene() { - if (Game_Flag_Query(265)) { + if (Game_Flag_Query(kFlagDR02toBB01)) { Setup_Scene_Information(-253.0f, 9.0f, 715.0f, 266); - } else if (Game_Flag_Query(263)) { + } else if (Game_Flag_Query(kFlagBB02toBB01)) { Setup_Scene_Information(-128.0f, 9.0f, 342.0f, 266); } else { Setup_Scene_Information(43.0f, 0.0f, 1058.0f, 0); @@ -51,12 +51,19 @@ void SceneScriptBB01::InitializeScene() { Ambient_Sounds_Add_Speech_Sound(60, 20, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1); Ambient_Sounds_Add_Speech_Sound(60, 40, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1); Ambient_Sounds_Add_Speech_Sound(60, 50, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1); - if (Game_Flag_Query(kFlagSpinnerAtBB01) && !Game_Flag_Query(265) && !Game_Flag_Query(263)) { - Scene_Loop_Start_Special(0, 0, 0); + if (Game_Flag_Query(kFlagSpinnerAtBB01) + && !Game_Flag_Query(kFlagDR02toBB01) + && !Game_Flag_Query(kFlagBB02toBB01) + ) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 0, false); Scene_Loop_Set_Default(1); - } else if (Game_Flag_Query(kFlagSpinnerAtBB01) && Game_Flag_Query(265)) { + } else if (Game_Flag_Query(kFlagSpinnerAtBB01) + && Game_Flag_Query(kFlagDR02toBB01) + ) { Scene_Loop_Set_Default(1); - } else if (Game_Flag_Query(kFlagSpinnerAtBB01) && Game_Flag_Query(263)) { + } else if (Game_Flag_Query(kFlagSpinnerAtBB01) + && Game_Flag_Query(kFlagBB02toBB01) + ) { Scene_Loop_Set_Default(1); } else { Scene_Loop_Set_Default(5); @@ -85,97 +92,97 @@ bool SceneScriptBB01::ClickedOnItem(int itemId, bool a2) { bool SceneScriptBB01::ClickedOnExit(int exitId) { if (exitId == 0) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -140.0f, 9.0f, 818.0f, 0, 1, false, 0); - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -233.0f, 9.0f, 846.0f, 0, 1, false, 0)) { - Game_Flag_Set(264); - Game_Flag_Reset(258); - Game_Flag_Set(177); - Set_Enter(7, kSceneDR02); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -140.0f, 9.0f, 818.0f, 0, true, false, 0); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -233.0f, 9.0f, 846.0f, 0, true, false, 0)) { + Game_Flag_Set(kFlagBB01toDR02); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Set(kFlagMcCoyAtDRxx); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR02); } return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -125.39f, 9.0f, 372.45f, 0, 1, false, 0)) { - Game_Flag_Set(262); - Set_Enter(1, kSceneBB02); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -125.39f, 9.0f, 372.45f, 0, true, false, 0)) { + Game_Flag_Set(kFlagBB01toBB02); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB02); } return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.0f, 0.0f, 1062.0f, 0, 1, false, 0)) { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - int spinnerDest = Spinner_Interface_Choose_Dest(3, 0); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.0f, 0.0f, 1062.0f, 0, false, false, 0)) { + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + int spinnerDest = Spinner_Interface_Choose_Dest(3, false); switch (spinnerDest) { - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetPS01, kScenePS01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetMA01, kSceneMA01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetRC01, kSceneRC01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetCT01_CT12, kSceneCT01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtBB01); - Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtBB01); - Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtTB02); + Set_Enter(kSetTB02_TB03, kSceneTB02); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetNR01, kSceneNR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 9: - Game_Flag_Set(257); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtBB01); Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetHF01, kSceneHF01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; default: - Game_Flag_Set(258); - Scene_Loop_Start_Special(2, 3, 1); + Game_Flag_Set(kFlagMcCoyAtBBxx); + Scene_Loop_Start_Special(kSceneLoopModeOnce, 3, true); break; } } @@ -210,13 +217,13 @@ void SceneScriptBB01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptBB01::PlayerWalkedIn() { - Spinner_Set_Selectable_Destination_Flag(7, 1); - if (Game_Flag_Query(265)) { - Game_Flag_Reset(265); - } else if (Game_Flag_Query(263)) { - Game_Flag_Reset(263); + Spinner_Set_Selectable_Destination_Flag(kSpinnerDestinationBradburyBuilding, true); + if (Game_Flag_Query(kFlagDR02toBB01)) { + Game_Flag_Reset(kFlagDR02toBB01); + } else if (Game_Flag_Query(kFlagBB02toBB01)) { + Game_Flag_Reset(kFlagBB02toBB01); } else { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.0f, 0.0f, 954.0f, 0, 0, false, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.0f, 0.0f, 954.0f, 0, false, false, 0); } } diff --git a/engines/bladerunner/script/scene/bb02.cpp b/engines/bladerunner/script/scene/bb02.cpp index fed5ee9c0f..0f0e96324d 100644 --- a/engines/bladerunner/script/scene/bb02.cpp +++ b/engines/bladerunner/script/scene/bb02.cpp @@ -32,7 +32,7 @@ void SceneScriptBB02::InitializeScene() { Scene_Loop_Start_Special(0, 0, 0); } else { Setup_Scene_Information(98.0f, -415.06f, -593.0f, 530); - Game_Flag_Reset(262); + Game_Flag_Reset(kFlagBB01toBB02); } Scene_Exit_Add_2D_Exit(0, 313, 137, 353, 173, 0); Scene_Exit_Add_2D_Exit(1, 207, 291, 275, 443, 3); @@ -91,8 +91,8 @@ bool SceneScriptBB02::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 98.0f, -415.06f, -593.0f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(263); - Set_Enter(20, kSceneBB01); + Game_Flag_Set(kFlagBB02toBB01); + Set_Enter(kSetBB01, kSceneBB01); } return true; } @@ -104,8 +104,8 @@ bool SceneScriptBB02::ClickedOnExit(int exitId) { } Game_Flag_Set(332); Game_Flag_Reset(493); - Set_Enter(1, kSceneBB04); - Scene_Loop_Start_Special(1, 3, false); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB04); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, false); } return true; } @@ -114,7 +114,7 @@ bool SceneScriptBB02::ClickedOnExit(int exitId) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 179.0f, -415.06f, 274.0f, 0, 0, false, 0); Game_Flag_Set(282); Game_Flag_Reset(493); - Set_Enter(21, kSceneBB03); + Set_Enter(kSetBB03, kSceneBB03); } return true; } diff --git a/engines/bladerunner/script/scene/bb03.cpp b/engines/bladerunner/script/scene/bb03.cpp index 0b080f6ae8..c4121a9cee 100644 --- a/engines/bladerunner/script/scene/bb03.cpp +++ b/engines/bladerunner/script/scene/bb03.cpp @@ -89,7 +89,7 @@ bool SceneScriptBB03::ClickedOnExit(int exitId) { Game_Flag_Set(283); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Set_Enter(1, kSceneBB04); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB04); } return true; } @@ -98,7 +98,7 @@ bool SceneScriptBB03::ClickedOnExit(int exitId) { Game_Flag_Set(281); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Set_Enter(1, kSceneBB02); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB02); } return true; } @@ -121,7 +121,7 @@ bool SceneScriptBB03::ClickedOnExit(int exitId) { Game_Flag_Set(285); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Set_Enter(22, kSceneBB05); + Set_Enter(kSetBB05, kSceneBB05); } else { Actor_Says(kActorMcCoy, 8522, 3); } diff --git a/engines/bladerunner/script/scene/bb04.cpp b/engines/bladerunner/script/scene/bb04.cpp index 60aa69b489..6ef7d7db00 100644 --- a/engines/bladerunner/script/scene/bb04.cpp +++ b/engines/bladerunner/script/scene/bb04.cpp @@ -87,7 +87,7 @@ bool SceneScriptBB04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(333); Game_Flag_Set(493); - Set_Enter(1, kSceneBB02); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB02); } return true; } @@ -96,7 +96,7 @@ bool SceneScriptBB04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(284); - Set_Enter(21, kSceneBB03); + Set_Enter(kSetBB03, kSceneBB03); } return true; } diff --git a/engines/bladerunner/script/scene/bb05.cpp b/engines/bladerunner/script/scene/bb05.cpp index e0919ed579..e85b107427 100644 --- a/engines/bladerunner/script/scene/bb05.cpp +++ b/engines/bladerunner/script/scene/bb05.cpp @@ -74,7 +74,7 @@ void SceneScriptBB05::SceneLoaded() { Unclickable_Object("BOX14"); if (Actor_Query_Goal_Number(kActorSebastian) == 200) { Actor_Set_Goal_Number(kActorGeneralDoll, 299); - Actor_Put_In_Set(kActorGeneralDoll, 97); + Actor_Put_In_Set(kActorGeneralDoll, kSetFreeSlotG); Actor_Set_At_Waypoint(kActorGeneralDoll, 39, 0); } } @@ -101,7 +101,7 @@ bool SceneScriptBB05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(286); - Set_Enter(21, kSceneBB03); + Set_Enter(kSetBB03, kSceneBB03); } return true; } @@ -110,7 +110,7 @@ bool SceneScriptBB05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(297); - Set_Enter(2, kSceneBB06); + Set_Enter(kSetBB06_BB07, kSceneBB06); } return true; } @@ -119,7 +119,7 @@ bool SceneScriptBB05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(299); - Set_Enter(3, kSceneBB07); + Set_Enter(kSetBB07, kSceneBB07); } return true; } @@ -128,7 +128,7 @@ bool SceneScriptBB05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(301); - Set_Enter(102, kSceneBB12); + Set_Enter(kSetBB12, kSceneBB12); } return true; } @@ -180,7 +180,7 @@ void SceneScriptBB05::PlayerWalkedIn() { Actor_Says_With_Pause(kActorSebastian, 210, 1.5f, 14); Actor_Says(kActorMcCoy, 7055, 15); } else { - Actor_Put_In_Set(kActorGeneralDoll, 22); + Actor_Put_In_Set(kActorGeneralDoll, kSetBB05); Actor_Set_At_Waypoint(kActorGeneralDoll, 134, 0); Loop_Actor_Walk_To_Waypoint(kActorGeneralDoll, 135, 0, 0, false); Actor_Says(kActorGeneralDoll, 0, 3); diff --git a/engines/bladerunner/script/scene/bb06.cpp b/engines/bladerunner/script/scene/bb06.cpp index cce94c1e6b..015a4dfc1a 100644 --- a/engines/bladerunner/script/scene/bb06.cpp +++ b/engines/bladerunner/script/scene/bb06.cpp @@ -111,7 +111,7 @@ bool SceneScriptBB06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(298); - Set_Enter(22, kSceneBB05); + Set_Enter(kSetBB05, kSceneBB05); } return true; } @@ -120,7 +120,7 @@ bool SceneScriptBB06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(393); - Set_Enter(1, kSceneBB51); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB51); } return true; } @@ -129,7 +129,7 @@ bool SceneScriptBB06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(363); - Set_Enter(2, kSceneBB07); + Set_Enter(kSetBB06_BB07, kSceneBB07); } return true; } diff --git a/engines/bladerunner/script/scene/bb07.cpp b/engines/bladerunner/script/scene/bb07.cpp index 82710928d8..d2c9393829 100644 --- a/engines/bladerunner/script/scene/bb07.cpp +++ b/engines/bladerunner/script/scene/bb07.cpp @@ -111,7 +111,7 @@ bool SceneScriptBB07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Overlay_Remove("BB07OVER"); Game_Flag_Set(300); - Set_Enter(22, kSceneBB05); + Set_Enter(kSetBB05, kSceneBB05); } return true; } @@ -121,7 +121,7 @@ bool SceneScriptBB07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Overlay_Remove("BB07OVER"); Game_Flag_Set(364); - Set_Enter(102, kSceneBB12); + Set_Enter(kSetBB12, kSceneBB12); } return true; } @@ -131,7 +131,7 @@ bool SceneScriptBB07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Overlay_Remove("BB07OVER"); Game_Flag_Set(362); - Set_Enter(2, kSceneBB06); + Set_Enter(kSetBB06_BB07, kSceneBB06); } return true; } diff --git a/engines/bladerunner/script/scene/bb08.cpp b/engines/bladerunner/script/scene/bb08.cpp index 1d85ecabcd..df51f0766a 100644 --- a/engines/bladerunner/script/scene/bb08.cpp +++ b/engines/bladerunner/script/scene/bb08.cpp @@ -25,7 +25,7 @@ namespace BladeRunner { void SceneScriptBB08::InitializeScene() { - if (Game_Flag_Query(219)) { + if (Game_Flag_Query(kFlagBB09toBB08)) { Setup_Scene_Information(204.0f, 0.0f, 92.0f, 875); } else { Setup_Scene_Information(247.0f, 0.0f, 27.0f, 790); @@ -87,8 +87,8 @@ bool SceneScriptBB08::ClickedOnExit(int exitId) { Footstep_Sound_Override_Off(); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(218); - Set_Enter(24, kSceneBB09); + Game_Flag_Set(kFlagBB08toBB09); + Set_Enter(kSetBB09, kSceneBB09); } return true; } @@ -97,7 +97,7 @@ bool SceneScriptBB08::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(506); - Set_Enter(102, kSceneBB12); + Set_Enter(kSetBB12, kSceneBB12); } return true; } @@ -115,13 +115,13 @@ void SceneScriptBB08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptBB08::PlayerWalkedIn() { - if (Game_Flag_Query(219)) { + if (Game_Flag_Query(kFlagBB09toBB08)) { Actor_Set_At_XYZ(kActorMcCoy, 204.0f, 96.1f, 94.0f, 256); Footstep_Sound_Override_On(2); Loop_Actor_Travel_Ladder(kActorMcCoy, 8, 0, 0); Footstep_Sound_Override_Off(); Actor_Face_Heading(kActorMcCoy, 768, false); - Game_Flag_Reset(219); + Game_Flag_Reset(kFlagBB09toBB08); } else { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 188.0f, 0.1f, 28.0f, 0, 0, false, 0); } diff --git a/engines/bladerunner/script/scene/bb09.cpp b/engines/bladerunner/script/scene/bb09.cpp index 3a12551ec3..92a20b6349 100644 --- a/engines/bladerunner/script/scene/bb09.cpp +++ b/engines/bladerunner/script/scene/bb09.cpp @@ -26,11 +26,11 @@ namespace BladeRunner { void SceneScriptBB09::InitializeScene() { Setup_Scene_Information(111.2f, -8.96f, 134.65f, 0); - if (Game_Flag_Query(221)) { - Game_Flag_Reset(221); + if (Game_Flag_Query(kFlagBB10toBB09)) { + Game_Flag_Reset(kFlagBB10toBB09); Setup_Scene_Information(115.45f, -8.96f, 134.0f, 628); - } else if (Game_Flag_Query(218)) { - Game_Flag_Reset(218); + } else if (Game_Flag_Query(kFlagBB08toBB09)) { + Game_Flag_Reset(kFlagBB08toBB09); Setup_Scene_Information(107.45f, -9.14f, 166.0f, 244); } Scene_Exit_Add_2D_Exit(0, 224, 213, 286, 353, 1); @@ -84,9 +84,9 @@ bool SceneScriptBB09::ClickedOnExit(int exitId) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 450.56f, -9.0f, 250.31f, 0, 0, false, 0); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(216); - Game_Flag_Set(220); - Set_Enter(25, kSceneBB10); + Game_Flag_Set(kFlagBB09toBB10a); + Game_Flag_Set(kFlagBB09toBB10b); + Set_Enter(kSetBB10, kSceneBB10); } return true; } @@ -94,8 +94,8 @@ bool SceneScriptBB09::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 71.0f, -9.0f, 136.0f, 72, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(219); - Set_Enter(23, kSceneBB08); + Game_Flag_Set(kFlagBB09toBB08); + Set_Enter(kSetBB08, kSceneBB08); } return true; } diff --git a/engines/bladerunner/script/scene/bb10.cpp b/engines/bladerunner/script/scene/bb10.cpp index c90456abf3..adaab3467d 100644 --- a/engines/bladerunner/script/scene/bb10.cpp +++ b/engines/bladerunner/script/scene/bb10.cpp @@ -25,10 +25,10 @@ namespace BladeRunner { void SceneScriptBB10::InitializeScene() { - if (Game_Flag_Query(223)) { + if (Game_Flag_Query(kFlagBB11toBB10)) { Setup_Scene_Information(255.29f, 90.24f, -103.0f, 830); - } else if (Game_Flag_Query(220)) { - Game_Flag_Reset(220); + } else if (Game_Flag_Query(kFlagBB09toBB10b)) { + Game_Flag_Reset(kFlagBB09toBB10b); Setup_Scene_Information(151.67f, 66.84f, -313.06f, 0); } else { Setup_Scene_Information(199.67f, 67.4f, -169.06f, 628); @@ -110,8 +110,8 @@ bool SceneScriptBB10::ClickedOnExit(int exitId) { Footstep_Sound_Override_Off(); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(222); - Set_Enter(26, kSceneBB11); + Game_Flag_Set(kFlagBB10toBB11); + Set_Enter(kSetBB11, kSceneBB11); } return true; } @@ -119,9 +119,9 @@ bool SceneScriptBB10::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 206.01f, 66.84f, -261.62f, 0, 1, false, 0) && !Loop_Actor_Walk_To_XYZ(kActorMcCoy, 151.67f, 66.84f, -313.06f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Reset(216); - Game_Flag_Set(221); - Set_Enter(24, kSceneBB09); + Game_Flag_Reset(kFlagBB09toBB10a); + Game_Flag_Set(kFlagBB10toBB09); + Set_Enter(kSetBB09, kSceneBB09); } return true; } @@ -177,13 +177,13 @@ void SceneScriptBB10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptBB10::PlayerWalkedIn() { - if (Game_Flag_Query(216)) { + if (Game_Flag_Query(kFlagBB09toBB10a)) { Player_Loses_Control(); Actor_Set_At_XYZ(kActorMcCoy, 214.01f, 66.84f, -349.62f, 462); Loop_Actor_Walk_To_XYZ(kActorMcCoy, 206.01f, 66.84f, -261.62f, 0, 0, false, 0); Player_Gains_Control(); - Game_Flag_Reset(216); - } else if (Game_Flag_Query(223)) { + Game_Flag_Reset(kFlagBB09toBB10a); + } else if (Game_Flag_Query(kFlagBB11toBB10)) { Actor_Set_At_XYZ(kActorMcCoy, 249.58f, 127.2f, -102.1f, 256); Footstep_Sound_Override_On(2); Loop_Actor_Travel_Ladder(kActorMcCoy, 3, 0, 0); @@ -192,7 +192,7 @@ void SceneScriptBB10::PlayerWalkedIn() { Footstep_Sound_Override_On(2); Loop_Actor_Travel_Stairs(kActorMcCoy, 3, 0, 0); Footstep_Sound_Override_Off(); - Game_Flag_Reset(223); + Game_Flag_Reset(kFlagBB11toBB10); } } diff --git a/engines/bladerunner/script/scene/bb11.cpp b/engines/bladerunner/script/scene/bb11.cpp index e18ad1ffbb..8c99c525f9 100644 --- a/engines/bladerunner/script/scene/bb11.cpp +++ b/engines/bladerunner/script/scene/bb11.cpp @@ -83,11 +83,11 @@ bool SceneScriptBB11::ClickedOnItem(int itemId, bool a2) { bool SceneScriptBB11::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.39f, -10.27f, -68.52f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 43.39f, -10.27f, -68.52f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(223); - Set_Enter(25, kSceneBB10); + Game_Flag_Set(kFlagBB11toBB10); + Set_Enter(kSetBB10, kSceneBB10); } return true; } diff --git a/engines/bladerunner/script/scene/bb12.cpp b/engines/bladerunner/script/scene/bb12.cpp index 29795bdea2..d32c7cee5c 100644 --- a/engines/bladerunner/script/scene/bb12.cpp +++ b/engines/bladerunner/script/scene/bb12.cpp @@ -84,7 +84,7 @@ bool SceneScriptBB12::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(507); - Set_Enter(23, kSceneBB08); + Set_Enter(kSetBB08, kSceneBB08); } return true; } @@ -93,7 +93,7 @@ bool SceneScriptBB12::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(365); - Set_Enter(3, kSceneBB07); + Set_Enter(kSetBB07, kSceneBB07); } return true; } @@ -102,7 +102,7 @@ bool SceneScriptBB12::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(302); - Set_Enter(22, kSceneBB05); + Set_Enter(kSetBB05, kSceneBB05); } return true; } diff --git a/engines/bladerunner/script/scene/bb51.cpp b/engines/bladerunner/script/scene/bb51.cpp index 9314b371b5..086eaa49dc 100644 --- a/engines/bladerunner/script/scene/bb51.cpp +++ b/engines/bladerunner/script/scene/bb51.cpp @@ -85,7 +85,7 @@ bool SceneScriptBB51::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(394); - Set_Enter(1, kSceneBB06); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB06); } return true; } @@ -94,7 +94,7 @@ bool SceneScriptBB51::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(395); - Set_Enter(1, kSceneBB06); + Set_Enter(kSetBB02_BB04_BB06_BB51, kSceneBB06); } return true; } diff --git a/engines/bladerunner/script/scene/ct01.cpp b/engines/bladerunner/script/scene/ct01.cpp index 931749f735..91022ff5bd 100644 --- a/engines/bladerunner/script/scene/ct01.cpp +++ b/engines/bladerunner/script/scene/ct01.cpp @@ -143,7 +143,7 @@ bool SceneScriptCT01::ClickedOnActor(int actorId) { Actor_Says(kActorHowieLee, 0, 14); Game_Flag_Set(kFlagCT01McCoyTalkedToHowieLee); Actor_Set_Goal_Number(kActorHowieLee, 0); - } else if (!Game_Flag_Query(30) && Actor_Query_Friendliness_To_Other(kActorHowieLee, kActorMcCoy) >= 40) { + } else if (!Game_Flag_Query(kFlagNotUsed30) && Actor_Query_Friendliness_To_Other(kActorHowieLee, kActorMcCoy) >= 40) { dialogueWithHowieLee(); Actor_Set_Goal_Number(kActorHowieLee, 0); } else { @@ -245,22 +245,22 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { return true; } if (exitId == kCT01ExitSpinner) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -314.0f, -6.5f, 326.0f, 0, 1, false, 0)) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -330.0f, -6.5f, 221.0f, 0, 0, true, 0); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -530.0f, -6.5f, 241.0f, 0, 0, true, 0); - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(180); - Game_Flag_Reset(261); - Game_Flag_Reset(177); - Game_Flag_Reset(258); - int spinnerDest = Spinner_Interface_Choose_Dest(-1, 0); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -314.0f, -6.5f, 326.0f, 0, true, false, 0)) { + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -330.0f, -6.5f, 221.0f, 0, false, true, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -530.0f, -6.5f, 241.0f, 0, false, true, 0); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtARxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + int spinnerDest = Spinner_Interface_Choose_Dest(-1, false); switch (spinnerDest) { case kSpinnerDestinationPoliceStation: - Game_Flag_Set(178); + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtPS01); @@ -268,7 +268,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationMcCoysApartment: - Game_Flag_Set(179); + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtMA01); @@ -276,7 +276,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationRuncitersAnimals: - Game_Flag_Set(182); + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtRC01); @@ -284,7 +284,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationAnimoidRow: - Game_Flag_Set(180); + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtAR01); @@ -292,7 +292,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationTyrellBuilding: - Game_Flag_Set(261); + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Set(kFlagSpinnerAtTB02); @@ -300,7 +300,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationDNARow: - Game_Flag_Set(177); + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtDR01); @@ -308,7 +308,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationBradburyBuilding: - Game_Flag_Set(258); + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtBB01); @@ -316,7 +316,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationNightclubRow: - Game_Flag_Set(181); + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtNR01); @@ -324,7 +324,7 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; case kSpinnerDestinationHysteriaHall: - Game_Flag_Set(257); + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Reset(kFlagSpinnerAtCT01); Game_Flag_Set(kFlagSpinnerAtHF01); @@ -332,11 +332,11 @@ bool SceneScriptCT01::ClickedOnExit(int exitId) { Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kCT01LoopOutshot, true); break; default: - Game_Flag_Set(176); + Game_Flag_Set(kFlagMcCoyAtCTxx); Player_Loses_Control(); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -530.0f, -6.5f, 241.0f, 0, 0, true, 0); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -330.0f, -6.5f, 221.0f, 0, 0, true, 0); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -314.0f, -6.5f, 326.0f, 0, 0, false, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -530.0f, -6.5f, 241.0f, 0, false, true, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -330.0f, -6.5f, 221.0f, 0, false, true, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -314.0f, -6.5f, 326.0f, 0, false, false, 0); Player_Gains_Control(); break; } @@ -414,7 +414,7 @@ void SceneScriptCT01::PlayerWalkedOut() { Ambient_Sounds_Remove_All_Looping_Sounds(1); } Music_Stop(5); - if (!Game_Flag_Query(176) && Global_Variable_Query(kVariableChapter) == 1) { + if (!Game_Flag_Query(kFlagMcCoyAtCTxx) && Global_Variable_Query(kVariableChapter) == 1) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Outtake_Play(kOuttakeTowards3, true, -1); diff --git a/engines/bladerunner/script/scene/ct06.cpp b/engines/bladerunner/script/scene/ct06.cpp index 5a8f0a6d12..dd78e208f6 100644 --- a/engines/bladerunner/script/scene/ct06.cpp +++ b/engines/bladerunner/script/scene/ct06.cpp @@ -35,7 +35,7 @@ void SceneScriptCT06::InitializeScene() { } Scene_Exit_Add_2D_Exit(0, 0, 440, 639, 479, 2); Scene_Exit_Add_2D_Exit(1, 401, 162, 536, 317, 0); - if (Game_Flag_Query(kFlagZubenRetired) && Actor_Query_In_Set(kActorZuben, 30)) { + if (Game_Flag_Query(kFlagZubenRetired) && Actor_Query_In_Set(kActorZuben, kSetCT07)) { Actor_Put_In_Set(kActorZuben, kSetCT06); Actor_Set_At_XYZ(kActorZuben, 58.41f, -58.23f, -24.97f, 240); Actor_Retired_Here(kActorZuben, 72, 36, 1, kActorMcCoy); @@ -88,25 +88,25 @@ bool SceneScriptCT06::ClickedOn3DObject(const char *objectName, bool a2) { bool SceneScriptCT06::ClickedOnActor(int actorId) { if (actorId == kActorZuben) { - Loop_Actor_Walk_To_Actor(kActorMcCoy, kActorZuben, 24, 1, false); + Loop_Actor_Walk_To_Actor(kActorMcCoy, kActorZuben, 24, true, false); Actor_Face_Actor(kActorMcCoy, kActorZuben, true); - if (Game_Flag_Query(145)) { - Actor_Says(kActorMcCoy, 8570, 13); - return false; - } - Actor_Clue_Acquire(kActorMcCoy, kClueZuben, 1, -1); - Item_Pickup_Spin_Effect(984, 340, 369); - Actor_Voice_Over(350, kActorVoiceOver); - Actor_Voice_Over(360, kActorVoiceOver); - Actor_Voice_Over(370, kActorVoiceOver); - if (!Game_Flag_Query(kFlagDirectorsCut)) { - Actor_Voice_Over(380, kActorVoiceOver); - Actor_Voice_Over(390, kActorVoiceOver); - Actor_Voice_Over(400, kActorVoiceOver); - Actor_Voice_Over(410, kActorVoiceOver); + if (!Game_Flag_Query(kFlagZubenPhoto)) { + Actor_Clue_Acquire(kActorMcCoy, kClueZuben, 1, -1); + Item_Pickup_Spin_Effect(984, 340, 369); + Actor_Voice_Over(350, kActorVoiceOver); + Actor_Voice_Over(360, kActorVoiceOver); + Actor_Voice_Over(370, kActorVoiceOver); + if (!Game_Flag_Query(kFlagDirectorsCut)) { + Actor_Voice_Over(380, kActorVoiceOver); + Actor_Voice_Over(390, kActorVoiceOver); + Actor_Voice_Over(400, kActorVoiceOver); + Actor_Voice_Over(410, kActorVoiceOver); + } + Game_Flag_Set(kFlagZubenPhoto); + return true; } - Game_Flag_Set(145); - return true; + Actor_Says(kActorMcCoy, 8570, 13); + return false; } return false; } @@ -122,7 +122,7 @@ bool SceneScriptCT06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(kFlagCT06toCT05); Set_Enter(kSetCT05, kSceneCT05); - Game_Flag_Reset(212); + Game_Flag_Reset(kFlagNotUsed212); } return true; } @@ -135,7 +135,7 @@ bool SceneScriptCT06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_Sound(199, true); Player_Loses_Control(); Actor_Set_Goal_Number(kActorZuben, kGoalZubenCT06JumpDown); - Game_Flag_Reset(212); + Game_Flag_Reset(kFlagNotUsed212); } return true; } @@ -148,7 +148,7 @@ bool SceneScriptCT06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(kFlagCT06toCT08); Set_Enter(kSetCT08_CT51_UG12, kSceneCT08); - Game_Flag_Reset(212); + Game_Flag_Reset(kFlagNotUsed212); } } } diff --git a/engines/bladerunner/script/scene/ct08.cpp b/engines/bladerunner/script/scene/ct08.cpp index a4ba9362b5..e7d7334b18 100644 --- a/engines/bladerunner/script/scene/ct08.cpp +++ b/engines/bladerunner/script/scene/ct08.cpp @@ -126,7 +126,7 @@ bool SceneScriptCT08::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(379); - Set_Enter(6, kSceneCT51); + Set_Enter(kSetCT08_CT51_UG12, kSceneCT51); } return true; } diff --git a/engines/bladerunner/script/scene/ct11.cpp b/engines/bladerunner/script/scene/ct11.cpp index 44a05e1a07..37823fe879 100644 --- a/engines/bladerunner/script/scene/ct11.cpp +++ b/engines/bladerunner/script/scene/ct11.cpp @@ -101,7 +101,7 @@ bool SceneScriptCT11::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 121.0f, 9.68f, -42.0f, 0, 1, false, 0)) { Game_Flag_Set(304); - Set_Enter(31, kSceneCT09); + Set_Enter(kSetCT09, kSceneCT09); } return true; } @@ -116,9 +116,9 @@ bool SceneScriptCT11::ClickedOnExit(int exitId) { if (exitId == 2) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 290.0f, 0.0f, 635.0f, 0, 1, false, 0)) { Game_Flag_Set(531); - Game_Flag_Reset(176); - Game_Flag_Set(177); - Set_Enter(7, kSceneDR01); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Set(kFlagMcCoyAtDRxx); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); } return true; } diff --git a/engines/bladerunner/script/scene/ct12.cpp b/engines/bladerunner/script/scene/ct12.cpp index e3201af272..4a2f05fb44 100644 --- a/engines/bladerunner/script/scene/ct12.cpp +++ b/engines/bladerunner/script/scene/ct12.cpp @@ -27,12 +27,12 @@ namespace BladeRunner { void SceneScriptCT12::InitializeScene() { if (Game_Flag_Query(kFlagCT01toCT12)) { Setup_Scene_Information(-419.0f, -6.5f, 696.0f, 616); - } else if (Game_Flag_Query(432)) { + } else if (Game_Flag_Query(kFlagUG09toCT12)) { Setup_Scene_Information(-292.0f, -6.5f, 990.0f, 827); - if (!Game_Flag_Query(150)) { - Game_Flag_Set(150); + if (!Game_Flag_Query(kFlagNotUsed150)) { + Game_Flag_Set(kFlagNotUsed150); } - Game_Flag_Reset(432); + Game_Flag_Reset(kFlagUG09toCT12); } else if (Game_Flag_Query(kFlagCT11toCT12)) { Setup_Scene_Information(-493.0f, -6.5f, 1174.0f, 990); } else { @@ -60,7 +60,7 @@ void SceneScriptCT12::InitializeScene() { Ambient_Sounds_Add_Sound(376, 50, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(377, 50, 180, 50, 100, 0, 0, -101, -101, 0, 0); if (Global_Variable_Query(kVariableChapter) < 2 && Actor_Query_Goal_Number(kActorGaff) == 1) { - Actor_Put_In_Set(kActorGaff, 4); + Actor_Put_In_Set(kActorGaff, kSetCT01_CT12); Actor_Set_At_XYZ(kActorGaff, -534.0f, -6.5f, 952.0f, 367); Game_Flag_Set(kFlagGaffSpinnerCT12); } @@ -192,7 +192,7 @@ bool SceneScriptCT12::ClickedOn2DRegion(int region) { } void SceneScriptCT12::SceneFrameAdvanced(int frame) { - if (!((frame - 1) % 10)) { + if (((frame - 1) % 10) == 0) { /*int v2 = Random_Query(0, 1); if (v2 <= 1) { @@ -230,9 +230,12 @@ void SceneScriptCT12::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptCT12::PlayerWalkedIn() { - if (Global_Variable_Query(kVariableChapter) < 2 && !Game_Flag_Query(64) && Actor_Query_Goal_Number(kActorGaff) == 1) { + if ( Global_Variable_Query(kVariableChapter) < 2 + && !Game_Flag_Query(kFlagGaffApproachedMcCoyAboutZuben) + && Actor_Query_Goal_Number(kActorGaff) == 1 + ) { Player_Loses_Control(); - Loop_Actor_Walk_To_Actor(kActorGaff, kActorMcCoy, 48, 0, false); + Loop_Actor_Walk_To_Actor(kActorGaff, kActorMcCoy, 48, false, false); Actor_Face_Actor(kActorGaff, kActorMcCoy, true); Actor_Face_Actor(kActorMcCoy, kActorGaff, true); Actor_Says(kActorGaff, 0, 3); @@ -246,35 +249,41 @@ void SceneScriptCT12::PlayerWalkedIn() { Actor_Says(kActorGaff, 40, 3); Actor_Says(kActorMcCoy, 690, 3); Actor_Clue_Acquire(kActorMcCoy, kClueGaffsInformation, 1, kActorGaff); - Game_Flag_Set(64); + Game_Flag_Set(kFlagGaffApproachedMcCoyAboutZuben); CDB_Set_Crime(kClueZuben, kCrimeMoonbusHijacking); - if (Game_Flag_Query(64) && Game_Flag_Query(40)) { + + if (Game_Flag_Query(kFlagGaffApproachedMcCoyAboutZuben) + && Game_Flag_Query(kFlagZubenRetired) + ) { Actor_Says(kActorGaff, 50, 3); Actor_Says(kActorMcCoy, 695, 3); Actor_Says(kActorGaff, 60, 3); Actor_Says(kActorMcCoy, 700, 3); Actor_Says(kActorGaff, 70, 3); Actor_Clue_Acquire(kActorGaff, kClueMcCoyRetiredZuben, 1, -1); - } else if (Game_Flag_Query(64) && Game_Flag_Query(kFlagZubenSpared)) { + } else if (Game_Flag_Query(kFlagGaffApproachedMcCoyAboutZuben) + && Game_Flag_Query(kFlagZubenSpared) + ) { Actor_Says(kActorGaff, 80, 3); Actor_Says(kActorGaff, 90, 3); Actor_Says(kActorMcCoy, 705, 3); Actor_Says(kActorGaff, 100, 3); Actor_Clue_Acquire(kActorGaff, kClueMcCoyLetZubenEscape, 1, -1); } + Actor_Set_Goal_Number(kActorGaff, 2); } if (Game_Flag_Query(kFlagCT11toCT12)) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -520.0f, -6.5f, 1103.0f, 0, 0, false, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -520.0f, -6.5f, 1103.0f, 0, false, false, 0); Game_Flag_Reset(kFlagCT11toCT12); } } void SceneScriptCT12::PlayerWalkedOut() { Game_Flag_Reset(kFlagGenericWalkerWaiting); - if (Game_Flag_Query(433)) { - Game_Flag_Reset(176); - Game_Flag_Set(259); + if (Game_Flag_Query(kFlagCT12ToUG09)) { + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Set(kFlagMcCoyAtUGxx); } } diff --git a/engines/bladerunner/script/scene/ct51.cpp b/engines/bladerunner/script/scene/ct51.cpp index afbb8537da..887ae08f89 100644 --- a/engines/bladerunner/script/scene/ct51.cpp +++ b/engines/bladerunner/script/scene/ct51.cpp @@ -96,7 +96,7 @@ bool SceneScriptCT51::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(380); - Set_Enter(6, kSceneCT08); + Set_Enter(kSetCT08_CT51_UG12, kSceneCT08); } return true; } diff --git a/engines/bladerunner/script/scene/dr01.cpp b/engines/bladerunner/script/scene/dr01.cpp index 2300afc6d4..1284c028b7 100644 --- a/engines/bladerunner/script/scene/dr01.cpp +++ b/engines/bladerunner/script/scene/dr01.cpp @@ -25,7 +25,7 @@ namespace BladeRunner { void SceneScriptDR01::InitializeScene() { - if (Game_Flag_Query(225)) { + if (Game_Flag_Query(kFlagDR02toDR01)) { Setup_Scene_Information(-835.0f, -0.04f, -118.0f, 664); } else if (Game_Flag_Query(kFlagDR04toDR01)) { Setup_Scene_Information(-711.0f, -0.04f, 70.0f, 307); @@ -55,16 +55,20 @@ void SceneScriptDR01::InitializeScene() { Ambient_Sounds_Add_Sound(378, 5, 80, 50, 100, -100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(379, 5, 80, 50, 100, -100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(380, 5, 80, 50, 100, -100, 100, -101, -101, 0, 0); - if (Game_Flag_Query(272) && Game_Flag_Query(kFlagDR04toDR01)) { + if (Game_Flag_Query(272) + && Game_Flag_Query(kFlagDR04toDR01) + ) { Scene_Loop_Start_Special(0, 3, 0); Scene_Loop_Set_Default(4); - } else if (!Game_Flag_Query(272) && Game_Flag_Query(kFlagDR04toDR01)) { + } else if (!Game_Flag_Query(272) + && Game_Flag_Query(kFlagDR04toDR01) + ) { Scene_Loop_Start_Special(0, 2, 0); Scene_Loop_Set_Default(4); - } else if (Game_Flag_Query(225)) { + } else if (Game_Flag_Query(kFlagDR02toDR01)) { Scene_Loop_Start_Special(0, 1, 0); Scene_Loop_Set_Default(4); - } else if (Game_Flag_Query(531) == 1) { + } else if (Game_Flag_Query(531)) { Scene_Loop_Set_Default(4); } else { Scene_Loop_Start_Special(0, 0, 0); @@ -109,7 +113,7 @@ bool SceneScriptDR01::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -835.0f, -0.04f, -118.0f, 0, 1, false, 0)) { Async_Actor_Walk_To_XYZ(kActorMcCoy, -911.0f, -0.04f, -118.0f, 0, false); Ambient_Sounds_Adjust_Looping_Sound(112, 10, -100, 1); - Game_Flag_Set(224); + Game_Flag_Set(kFlagDR01toDR02); Set_Enter(kSetDR01_DR02_DR04, kSceneDR02); } return true; @@ -124,74 +128,74 @@ bool SceneScriptDR01::ClickedOnExit(int exitId) { } if (exitId == 2) { if (Loop_Actor_Walk_To_XYZ(kActorMcCoy, -372.0f, -0.04f, -82.0f, 0, 1, false, 0)) { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(180); - Game_Flag_Reset(261); - Game_Flag_Reset(177); - Game_Flag_Reset(258); - int spinnerDest = Spinner_Interface_Choose_Dest(-1, 0); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtARxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + int spinnerDest = Spinner_Interface_Choose_Dest(-1, false); switch (spinnerDest) { - case 2: - Game_Flag_Set(182); - Game_Flag_Reset(kFlagSpinnerAtDR01); - Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtDR01); - Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); + Game_Flag_Set(kFlagSpinnerAtPS01); + Set_Enter(kSetPS01, kScenePS01); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtDR01); Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); + Set_Enter(kSetMA01, kSceneMA01); break; - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtDR01); - Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); + Game_Flag_Set(kFlagSpinnerAtRC01); + Set_Enter(kSetRC01, kSceneRC01); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtDR01); - Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); + Game_Flag_Set(kFlagSpinnerAtCT01); + Set_Enter(kSetCT01_CT12, kSceneCT01); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtDR01); Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); + break; + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagSpinnerAtDR01); + Game_Flag_Set(kFlagSpinnerAtTB02); + Set_Enter(kSetTB02_TB03, kSceneTB02); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtDR01); Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); + Set_Enter(kSetBB01, kSceneBB01); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtDR01); Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); + Set_Enter(kSetNR01, kSceneNR01); break; - case 9: - Game_Flag_Set(257); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtDR01); Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); + Set_Enter(kSetHF01, kSceneHF01); break; default: Player_Loses_Control(); - Game_Flag_Set(177); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -447.39f, 0.16f, -92.38f, 0, 0, true, 0); + Game_Flag_Set(kFlagMcCoyAtDRxx); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -447.39f, 0.16f, -92.38f, 0, false, true, 0); Player_Gains_Control(); break; } @@ -208,9 +212,9 @@ bool SceneScriptDR01::ClickedOnExit(int exitId) { } if (!v7) { Game_Flag_Set(558); - Game_Flag_Set(176); - Game_Flag_Reset(177); - Set_Enter(33, kSceneCT11); + Game_Flag_Set(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Set_Enter(kSetCT11, kSceneCT11); } return true; } @@ -238,18 +242,23 @@ void SceneScriptDR01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo void SceneScriptDR01::PlayerWalkedIn() { if (Game_Flag_Query(531)) { Async_Actor_Walk_To_XYZ(kActorMcCoy, -757.15f, -0.04f, 24.64f, 0, false); - } else if (!Game_Flag_Query(225) && !Game_Flag_Query(kFlagDR04toDR01)) { + } else if (!Game_Flag_Query(kFlagDR02toDR01) + && !Game_Flag_Query(kFlagDR04toDR01) + ) { Player_Loses_Control(); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, -447.39f, 0.16f, -92.38f, 0, 0, false, 0); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, -447.39f, 0.16f, -92.38f, 0, false, false, 0); Player_Gains_Control(); } - Game_Flag_Reset(225); + Game_Flag_Reset(kFlagDR02toDR01); Game_Flag_Reset(kFlagDR04toDR01); Game_Flag_Reset(531); } void SceneScriptDR01::PlayerWalkedOut() { - if (!Game_Flag_Query(kFlagDR01toDR04) && !Game_Flag_Query(224) && !Game_Flag_Query(558)) { + if (!Game_Flag_Query(kFlagDR01toDR04) + && !Game_Flag_Query(kFlagDR01toDR02) + && !Game_Flag_Query(558) + ) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Outtake_Play(kOuttakeInside2, true, -1); diff --git a/engines/bladerunner/script/scene/dr02.cpp b/engines/bladerunner/script/scene/dr02.cpp index c416fe2ff2..45867c15e8 100644 --- a/engines/bladerunner/script/scene/dr02.cpp +++ b/engines/bladerunner/script/scene/dr02.cpp @@ -25,11 +25,11 @@ namespace BladeRunner { void SceneScriptDR02::InitializeScene() { - if (Game_Flag_Query(227)) { + if (Game_Flag_Query(kFlagDR03toDR02)) { Setup_Scene_Information(-1162.0f, 7.18f, -322.0f, 552); - } else if (Game_Flag_Query(224)) { + } else if (Game_Flag_Query(kFlagDR01toDR02)) { Setup_Scene_Information(-835.0f, -0.04f, -118.0f, 193); - } else if (Game_Flag_Query(264)) { + } else if (Game_Flag_Query(kFlagBB01toDR02)) { Setup_Scene_Information(-1258.0f, 7.18f, -314.0f, 400); } else { Setup_Scene_Information(168.78f, 0.16f, -775.72f, 193); @@ -49,8 +49,8 @@ void SceneScriptDR02::InitializeScene() { Ambient_Sounds_Add_Sound(380, 2, 50, 33, 100, -100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(67, 5, 100, 16, 25, -100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(66, 5, 100, 16, 25, -100, 100, -101, -101, 0, 0); - if (Game_Flag_Query(224)) { - Scene_Loop_Start_Special(0, 0, 0); + if (Game_Flag_Query(kFlagDR01toDR02)) { + Scene_Loop_Start_Special(kSceneLoopModeLoseControl, 0, false); Scene_Loop_Set_Default(1); } else { Scene_Loop_Set_Default(1); @@ -117,32 +117,32 @@ bool SceneScriptDR02::ClickedOnItem(int itemId, bool a2) { bool SceneScriptDR02::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -835.0f, -0.04f, -118.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -835.0f, -0.04f, -118.0f, 0, true, false, 0)) { Async_Actor_Walk_To_XYZ(kActorMcCoy, -727.0f, -0.04f, -118.0f, 0, false); - Game_Flag_Set(225); - Set_Enter(7, kSceneDR01); + Game_Flag_Set(kFlagDR02toDR01); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); } Ambient_Sounds_Adjust_Looping_Sound(219, 12, -101, 1); Ambient_Sounds_Adjust_Looping_Sound(98, 14, -101, 1); return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1162.0f, 7.18f, -322.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1162.0f, 7.18f, -322.0f, 0, true, false, 0)) { if (Global_Variable_Query(kVariableChapter) > 2) { Actor_Says(kActorMcCoy, 8522, 15); } else { - Game_Flag_Set(226); - Set_Enter(34, kSceneDR03); + Game_Flag_Set(kFlagDR02toDR03); + Set_Enter(kSetDR03, kSceneDR03); } } return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1258.0f, 7.18f, -314.0f, 0, 1, false, 0)) { - Game_Flag_Set(265); - Game_Flag_Reset(177); - Game_Flag_Set(258); - Set_Enter(20, kSceneBB01); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1258.0f, 7.18f, -314.0f, 0, true, false, 0)) { + Game_Flag_Set(kFlagDR02toBB01); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Game_Flag_Set(kFlagMcCoyAtBBxx); + Set_Enter(kSetBB01, kSceneBB01); } return true; } @@ -163,14 +163,14 @@ void SceneScriptDR02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptDR02::PlayerWalkedIn() { - if (Game_Flag_Query(227)) { - Game_Flag_Reset(227); + if (Game_Flag_Query(kFlagDR03toDR02)) { + Game_Flag_Reset(kFlagDR03toDR02); } - if (Game_Flag_Query(224)) { - Game_Flag_Reset(224); + if (Game_Flag_Query(kFlagDR01toDR02)) { + Game_Flag_Reset(kFlagDR01toDR02); } - if (Game_Flag_Query(264)) { - Game_Flag_Reset(264); + if (Game_Flag_Query(kFlagBB01toDR02)) { + Game_Flag_Reset(kFlagBB01toDR02); } } diff --git a/engines/bladerunner/script/scene/dr03.cpp b/engines/bladerunner/script/scene/dr03.cpp index d3113ca7f8..2fa1f35974 100644 --- a/engines/bladerunner/script/scene/dr03.cpp +++ b/engines/bladerunner/script/scene/dr03.cpp @@ -25,17 +25,17 @@ namespace BladeRunner { void SceneScriptDR03::InitializeScene() { - if (Game_Flag_Query(226)) { - Game_Flag_Reset(226); + if (Game_Flag_Query(kFlagDR02toDR03)) { + Game_Flag_Reset(kFlagDR02toDR03); Setup_Scene_Information(330.31f, 4.27f, -910.91f, 297); } Setup_Scene_Information(330.31f, 4.27f, -910.91f, 297); Scene_Exit_Add_2D_Exit(0, 377, 122, 445, 266, 0); if (Global_Variable_Query(kVariableChapter) == 3) { - Actor_Put_In_Set(kActorChew, 34); + Actor_Put_In_Set(kActorChew, kSetDR03); Actor_Set_At_XYZ(kActorChew, 431.21f, 4.27f, -776.26f, 0); } else { - Actor_Put_In_Set(kActorChew, 34); + Actor_Put_In_Set(kActorChew, kSetDR03); Actor_Set_At_XYZ(kActorChew, 360.77f, 4.4f, -806.67f, 126); } Ambient_Sounds_Remove_All_Looping_Sounds(1); @@ -127,8 +127,8 @@ bool SceneScriptDR03::ClickedOnItem(int itemId, bool a2) { bool SceneScriptDR03::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 330.31f, 4.27f, -910.91f, 24, 1, false, 0)) { - Game_Flag_Set(227); - Set_Enter(7, kSceneDR02); + Game_Flag_Set(kFlagDR03toDR02); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR02); } return true; } @@ -153,7 +153,7 @@ void SceneScriptDR03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptDR03::PlayerWalkedIn() { - if (!Game_Flag_Query(226)) { + if (!Game_Flag_Query(kFlagDR02toDR03)) { if (Random_Query(1, 2) == 1) { Actor_Says(kActorChew, 660, 14); Actor_Says(kActorChew, 680, 14); diff --git a/engines/bladerunner/script/scene/dr04.cpp b/engines/bladerunner/script/scene/dr04.cpp index e36c696811..0483d191f8 100644 --- a/engines/bladerunner/script/scene/dr04.cpp +++ b/engines/bladerunner/script/scene/dr04.cpp @@ -146,7 +146,7 @@ bool SceneScriptDR04::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1067.0f, 7.18f, 421.0f, 0, 1, false, 0)) { Game_Flag_Set(232); Game_Flag_Set(228); - Set_Enter(35, kSceneDR05); + Set_Enter(kSetDR05, kSceneDR05); } return true; } @@ -162,7 +162,7 @@ bool SceneScriptDR04::ClickedOnExit(int exitId) { Actor_Set_Immunity_To_Obstacles(kActorMcCoy, false); Footstep_Sound_Override_Off(); Game_Flag_Set(230); - Set_Enter(36, kSceneDR06); + Set_Enter(kSetDR06, kSceneDR06); } return true; } diff --git a/engines/bladerunner/script/scene/dr05.cpp b/engines/bladerunner/script/scene/dr05.cpp index ce2a76218a..dfa4b8bbbf 100644 --- a/engines/bladerunner/script/scene/dr05.cpp +++ b/engines/bladerunner/script/scene/dr05.cpp @@ -108,7 +108,7 @@ bool SceneScriptDR05::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -22.0f, 0.3f, 221.0f, 0, 1, false, 0)) { Game_Flag_Reset(232); Game_Flag_Set(229); - Set_Enter(7, kSceneDR04); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR04); } return true; } diff --git a/engines/bladerunner/script/scene/dr06.cpp b/engines/bladerunner/script/scene/dr06.cpp index 393cdc3184..6d8271bec4 100644 --- a/engines/bladerunner/script/scene/dr06.cpp +++ b/engines/bladerunner/script/scene/dr06.cpp @@ -180,14 +180,14 @@ bool SceneScriptDR06::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -733.0f, 136.6f, -980.0f, 0, 1, false, 0)) { Game_Flag_Set(231); - Set_Enter(7, kSceneDR04); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR04); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -707.57f, 136.6f, -1132.64f, 0, 1, false, 0)) { Game_Flag_Set(552); - Set_Enter(19, kSceneUG16); + Set_Enter(kSetUG16, kSceneUG16); } return true; } diff --git a/engines/bladerunner/script/scene/hc01.cpp b/engines/bladerunner/script/scene/hc01.cpp index fbf54e0adc..89ac7d72ca 100644 --- a/engines/bladerunner/script/scene/hc01.cpp +++ b/engines/bladerunner/script/scene/hc01.cpp @@ -67,7 +67,7 @@ void SceneScriptHC01::InitializeScene() { void SceneScriptHC01::SceneLoaded() { Obstacle_Object("PILLAR", true); - if (Game_Flag_Query(322)) { + if (Game_Flag_Query(kFlagAR01toHC01)) { Preload(19); Preload(426); Preload(430); @@ -145,17 +145,17 @@ bool SceneScriptHC01::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 814.0f, 0.14f, 153.0f, 0, 1, false, 0)) { Music_Adjust(12, 0, 2); - Game_Flag_Set(323); - Set_Enter(0, kSceneAR01); + Game_Flag_Set(kFlagHC01toAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); Game_Flag_Reset(479); - Game_Flag_Set(180); + Game_Flag_Set(kFlagMcCoyAtARxx); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 607.0f, 0.14f, 9.0f, 0, 1, false, 0)) { Game_Flag_Set(386); - Set_Enter(8, kSceneHC03); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC03); } return true; } @@ -163,7 +163,7 @@ bool SceneScriptHC01::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 105.0f, 0.14f, 103.0f, 0, 1, false, 0)) { Game_Flag_Set(384); Async_Actor_Walk_To_XYZ(kActorMcCoy, -57.0f, 0.14f, 83.0f, 0, false); - Set_Enter(8, kSceneHC02); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC02); } return true; } @@ -208,8 +208,8 @@ void SceneScriptHC01::PlayerWalkedIn() { if (Game_Flag_Query(387)) { Game_Flag_Reset(387); } - if (Game_Flag_Query(322)) { - Game_Flag_Reset(322); + if (Game_Flag_Query(kFlagAR01toHC01)) { + Game_Flag_Reset(kFlagAR01toHC01); } } diff --git a/engines/bladerunner/script/scene/hc02.cpp b/engines/bladerunner/script/scene/hc02.cpp index 8723186333..f59d350307 100644 --- a/engines/bladerunner/script/scene/hc02.cpp +++ b/engines/bladerunner/script/scene/hc02.cpp @@ -164,7 +164,7 @@ bool SceneScriptHC02::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(385); - Set_Enter(8, kSceneHC01); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC01); } return true; } diff --git a/engines/bladerunner/script/scene/hc03.cpp b/engines/bladerunner/script/scene/hc03.cpp index 7b89fc6652..762a40c170 100644 --- a/engines/bladerunner/script/scene/hc03.cpp +++ b/engines/bladerunner/script/scene/hc03.cpp @@ -25,10 +25,10 @@ namespace BladeRunner { void SceneScriptHC03::InitializeScene() { - if (Game_Flag_Query(318)) { + if (Game_Flag_Query(kFlagUG02toHC03)) { Setup_Scene_Information(656.0f, 1.61f, -95.0f, 497); Game_Flag_Set(388); - Game_Flag_Reset(318); + Game_Flag_Reset(kFlagUG02toHC03); } else { Setup_Scene_Information(607.0f, 0.14f, 13.0f, 57); Game_Flag_Reset(386); @@ -131,19 +131,19 @@ bool SceneScriptHC03::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 607.0f, 0.14f, 9.0f, 0, 1, false, 0)) { Game_Flag_Set(387); - Set_Enter(8, kSceneHC01); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC01); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 628.0f, 2.04f, -123.0f, 0, 1, false, 0)) { if (Game_Flag_Query(388)) { - Game_Flag_Set(319); + Game_Flag_Set(kFlagHC03toUG02); Game_Flag_Reset(479); - Game_Flag_Set(259); + Game_Flag_Set(kFlagMcCoyAtUGxx); Game_Flag_Set(388); Music_Stop(2); - Set_Enter(75, kSceneUG02); + Set_Enter(kSetUG02, kSceneUG02); } else { Scene_Loop_Set_Default(6); Scene_Loop_Start_Special(kSceneLoopModeOnce, 5, true); diff --git a/engines/bladerunner/script/scene/hc04.cpp b/engines/bladerunner/script/scene/hc04.cpp index b264306321..2cf0d8424c 100644 --- a/engines/bladerunner/script/scene/hc04.cpp +++ b/engines/bladerunner/script/scene/hc04.cpp @@ -32,7 +32,7 @@ void SceneScriptHC04::InitializeScene() { Setup_Scene_Information(-88.0f, 0.14f, -463.0f, 1013); } Music_Play(4, 14, -90, 1, -1, 1, 2); - Actor_Put_In_Set(kActorIsabella, 8); + Actor_Put_In_Set(kActorIsabella, kSetHC01_HC02_HC03_HC04); Actor_Set_At_XYZ(kActorIsabella, -210.0f, 0.0f, -445.0f, 250); Scene_Exit_Add_2D_Exit(0, 539, 51, 639, 309, 0); Scene_Exit_Add_2D_Exit(1, 0, 456, 639, 479, 2); @@ -112,7 +112,7 @@ bool SceneScriptHC04::ClickedOnExit(int exitId) { Music_Stop(2); Game_Flag_Set(kFlagHC04toRC03); Game_Flag_Reset(479); - Game_Flag_Set(182); + Game_Flag_Set(kFlagMcCoyAtRCxx); Set_Enter(kSetRC03, kSceneRC03); } return true; diff --git a/engines/bladerunner/script/scene/hf01.cpp b/engines/bladerunner/script/scene/hf01.cpp index ee5a1163fb..adec56fd87 100644 --- a/engines/bladerunner/script/scene/hf01.cpp +++ b/engines/bladerunner/script/scene/hf01.cpp @@ -27,11 +27,11 @@ namespace BladeRunner { void SceneScriptHF01::InitializeScene() { if (Game_Flag_Query(617)) { Setup_Scene_Information(243.94f, 8.0f, -341.9f, 342); - } else if (Game_Flag_Query(313)) { + } else if (Game_Flag_Query(kFlagHF05toHF01)) { Setup_Scene_Information(-202.0f, 0.0f, -619.0f, 407); - } else if (Game_Flag_Query(311)) { + } else if (Game_Flag_Query(kFlagHF03toHF01)) { Setup_Scene_Information(124.0f, 8.0f, -880.0f, 455); - } else if (Game_Flag_Query(309)) { + } else if (Game_Flag_Query(kFlagHF02toHF01)) { Setup_Scene_Information(406.0f, 8.0f, -813.0f, 455); } else { Setup_Scene_Information(100.0f, 0.0f, -260.0f, 0); @@ -62,7 +62,10 @@ void SceneScriptHF01::InitializeScene() { Ambient_Sounds_Add_Sound(376, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(377, 10, 180, 50, 100, 0, 0, -101, -101, 0, 0); if (Game_Flag_Query(kFlagSpinnerAtHF01)) { - if (!Game_Flag_Query(309) && !Game_Flag_Query(311) && !Game_Flag_Query(313)) { + if (!Game_Flag_Query(kFlagHF02toHF01) + && !Game_Flag_Query(kFlagHF03toHF01) + && !Game_Flag_Query(kFlagHF05toHF01) + ) { Scene_Loop_Start_Special(0, 0, 0); } Scene_Loop_Set_Default(1); @@ -131,7 +134,15 @@ bool SceneScriptHF01::ClickedOnActor(int actorId) { Actor_Says(kActorMcCoy, 8630, 13); return true; } - if (Global_Variable_Query(kVariableChapter) == 5 && (Actor_Clue_Query(kActorMcCoy, kCluePhoneCallDektora1) || Actor_Clue_Query(kActorMcCoy, kCluePhoneCallLucy1)) && !Game_Flag_Query(165) && Actor_Query_Goal_Number(kActorCrazylegs) != 2 && Game_Flag_Query(653) && !Game_Flag_Query(662)) { + if (Global_Variable_Query(kVariableChapter) == 5 + && (Actor_Clue_Query(kActorMcCoy, kCluePhoneCallDektora1) + || Actor_Clue_Query(kActorMcCoy, kCluePhoneCallLucy1) + ) + && !Game_Flag_Query(kFlagCrazylegsArrested) + && Actor_Query_Goal_Number(kActorCrazylegs) != 2 + && Game_Flag_Query(653) + && !Game_Flag_Query(662) + ) { Game_Flag_Set(662); Actor_Face_Actor(kActorMcCoy, v1, true); Actor_Face_Actor(v1, kActorMcCoy, true); @@ -142,8 +153,8 @@ bool SceneScriptHF01::ClickedOnActor(int actorId) { } Async_Actor_Walk_To_XYZ(v1, -175.0f, 8.0f, -617.0f, 0, false); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -137.0f, 8.0f, -577.0f, 0, 0, false, 1); - Game_Flag_Set(312); - Set_Enter(41, kSceneHF05); + Game_Flag_Set(kFlagHF01toHF05); + Set_Enter(kSetHF05, kSceneHF05); } } } @@ -156,104 +167,104 @@ bool SceneScriptHF01::ClickedOnItem(int itemId, bool a2) { bool SceneScriptHF01::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -202.0f, 8.0f, -619.0f, 0, 1, false, 0)) { - Game_Flag_Set(312); - Set_Enter(41, kSceneHF05); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -202.0f, 8.0f, -619.0f, 0, true, false, 0)) { + Game_Flag_Set(kFlagHF01toHF05); + Set_Enter(kSetHF05, kSceneHF05); } return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 124.0f, 8.0f, -724.0f, 0, 1, false, 0)) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, 124.0f, 8.0f, -880.0f, 0, 0, false, 0); - Game_Flag_Set(310); - Set_Enter(39, kSceneHF03); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 124.0f, 8.0f, -724.0f, 0, true, false, 0)) { + Loop_Actor_Walk_To_XYZ(kActorMcCoy, 124.0f, 8.0f, -880.0f, 0, false, false, 0); + Game_Flag_Set(kFlagHF01toHF03); + Set_Enter(kSetHF03, kSceneHF03); } return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 406.0f, 8.0f, -717.0f, 0, 1, false, 0)) { - Loop_Actor_Walk_To_XYZ(kActorMcCoy, 406.0f, 8.0f, -813.0f, 0, 0, false, 0); - Game_Flag_Set(308); - Set_Enter(38, kSceneHF02); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 406.0f, 8.0f, -717.0f, 0, true, false, 0)) { + Loop_Actor_Walk_To_XYZ(kActorMcCoy, 406.0f, 8.0f, -813.0f, 0, false, false, 0); + Game_Flag_Set(kFlagHF01toHF02); + Set_Enter(kSetHF02, kSceneHF02); } return true; } if (exitId == 3) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 0.0f, -260.0f, 0, 1, false, 0)) { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - Game_Flag_Reset(257); - int spinnerDest = Spinner_Interface_Choose_Dest(3, 0); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 0.0f, -260.0f, 0, true, false, 0)) { + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtHFxx); + int spinnerDest = Spinner_Interface_Choose_Dest(3, false); switch (spinnerDest) { - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetPS01, kScenePS01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetMA01, kSceneMA01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetRC01, kSceneRC01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetCT01_CT12, kSceneCT01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetTB02_TB03, kSceneTB02); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetAR01_AR02, kSceneAR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtHF01); - Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtDR01); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtHF01); - Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtBB01); + Set_Enter(kSetBB01, kSceneBB01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtHF01); Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetNR01, kSceneNR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; default: - Game_Flag_Set(257); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 0.0f, -300.0f, 0, 1, false, 0); + Game_Flag_Set(kFlagMcCoyAtHFxx); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 0.0f, -300.0f, 0, true, false, 0); break; } } @@ -291,20 +302,20 @@ void SceneScriptHF01::PlayerWalkedIn() { if (Game_Flag_Query(663)) { ADQ_Flush(); ADQ_Add(kActorOfficerGrayford, 280, 3); - Actor_Put_In_Set(kActorOfficerLeary, 37); + Actor_Put_In_Set(kActorOfficerLeary, kSetHF01); Actor_Set_At_XYZ(kActorOfficerLeary, 8.2f, 8.0f, -346.67f, 1021); - Actor_Put_In_Set(kActorOfficerGrayford, 37); + Actor_Put_In_Set(kActorOfficerGrayford, kSetHF01); Actor_Set_At_XYZ(kActorOfficerGrayford, 51.21f, 8.0f, -540.78f, 796); Non_Player_Actor_Combat_Mode_On(kActorOfficerLeary, kActorCombatStateUncover, true, kActorMcCoy, 4, kAnimationModeCombatIdle, kAnimationModeCombatWalk, kAnimationModeCombatRun, 0, 0, 0, 100, 300, false); Non_Player_Actor_Combat_Mode_On(kActorOfficerGrayford, kActorCombatStateUncover, true, kActorMcCoy, 4, kAnimationModeCombatIdle, kAnimationModeCombatWalk, kAnimationModeCombatRun, 0, 0, 0, 100, 300, false); } - if (!Game_Flag_Query(165) && Actor_Query_Goal_Number(kActorCrazylegs) != 2) { + if (!Game_Flag_Query(kFlagCrazylegsArrested) && Actor_Query_Goal_Number(kActorCrazylegs) != 2) { if (Actor_Clue_Query(kActorMcCoy, kCluePhoneCallLucy1) && Global_Variable_Query(kVariableAffectionTowards) == 3 && Actor_Query_Goal_Number(kActorLucy) != 599) { - Actor_Put_In_Set(kActorLucy, 37); + Actor_Put_In_Set(kActorLucy, kSetHF01); Actor_Set_At_XYZ(kActorLucy, -5.0f, 8.0f, -622.0f, 419); Actor_Set_Targetable(kActorLucy, true); } else if (Actor_Clue_Query(kActorMcCoy, kCluePhoneCallDektora1) && Global_Variable_Query(kVariableAffectionTowards) == 2 && Actor_Query_Goal_Number(kActorDektora) != 599) { - Actor_Put_In_Set(kActorDektora, 37); + Actor_Put_In_Set(kActorDektora, kSetHF01); Actor_Set_At_XYZ(kActorDektora, -5.0f, 8.0f, -622.0f, 419); Actor_Set_Targetable(kActorDektora, true); } @@ -334,23 +345,27 @@ void SceneScriptHF01::PlayerWalkedIn() { Actor_Face_Heading(kActorMurray, 271, false); Game_Flag_Set(377); } - if (Game_Flag_Query(311)) { + if (Game_Flag_Query(kFlagHF03toHF01)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 124.0f, 8.0f, -724.0f, 0, 1, false, 0); - } else if (Game_Flag_Query(309)) { + } else if (Game_Flag_Query(kFlagHF02toHF01)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 406.0f, 8.0f, -717.0f, 0, 1, false, 0); - } else if (!Game_Flag_Query(313)) { + } else if (!Game_Flag_Query(kFlagHF05toHF01)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 0.0f, -300.0f, 0, 1, false, 0); } - Game_Flag_Reset(311); - Game_Flag_Reset(309); - Game_Flag_Reset(313); + Game_Flag_Reset(kFlagHF03toHF01); + Game_Flag_Reset(kFlagHF02toHF01); + Game_Flag_Reset(kFlagHF05toHF01); //return false; } void SceneScriptHF01::PlayerWalkedOut() { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - if (!Game_Flag_Query(312) && !Game_Flag_Query(308) && !Game_Flag_Query(310) && !Game_Flag_Query(722)) { + if (!Game_Flag_Query(kFlagHF01toHF05) + && !Game_Flag_Query(kFlagHF01toHF02) + && !Game_Flag_Query(kFlagHF01toHF03) + && !Game_Flag_Query(722) + ) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Outtake_Play(kOuttakeInside2, true, -1); @@ -358,12 +373,12 @@ void SceneScriptHF01::PlayerWalkedOut() { } Game_Flag_Reset(722); if (Actor_Query_Goal_Number(kActorLucy) == 450) { - Actor_Put_In_Set(kActorLucy, 97); + Actor_Put_In_Set(kActorLucy, kSetFreeSlotG); Actor_Set_At_Waypoint(kActorLucy, 39, 0); Actor_Set_Goal_Number(kActorLucy, 599); } if (Actor_Query_Goal_Number(kActorDektora) == 450) { - Actor_Put_In_Set(kActorDektora, 97); + Actor_Put_In_Set(kActorDektora, kSetFreeSlotG); Actor_Set_At_Waypoint(kActorDektora, 39, 0); Actor_Set_Goal_Number(kActorDektora, 599); } diff --git a/engines/bladerunner/script/scene/hf02.cpp b/engines/bladerunner/script/scene/hf02.cpp index 9df62e4d2a..1bc4e9501f 100644 --- a/engines/bladerunner/script/scene/hf02.cpp +++ b/engines/bladerunner/script/scene/hf02.cpp @@ -87,8 +87,8 @@ bool SceneScriptHF02::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 42.0f, 47.76f, -296.0f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(309); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagHF02toHF01); + Set_Enter(kSetHF01, kSceneHF01); } return true; } @@ -97,7 +97,7 @@ bool SceneScriptHF02::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(527); - Set_Enter(39, kSceneHF03); + Set_Enter(kSetHF03, kSceneHF03); } return true; } @@ -122,9 +122,9 @@ void SceneScriptHF02::PlayerWalkedIn() { if (Game_Flag_Query(528)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 470.0f, 47.76f, -444.0f, 0, 0, false, 0); Game_Flag_Reset(528); - } else if (Game_Flag_Query(308)) { + } else if (Game_Flag_Query(kFlagHF01toHF02)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 42.0f, 47.76f, -296.0f, 0, 0, false, 0); - Game_Flag_Reset(308); + Game_Flag_Reset(kFlagHF01toHF02); } if (Actor_Query_Goal_Number(kActorSteele) == 243) { if (Actor_Query_Goal_Number(kActorLucy) == 599) { diff --git a/engines/bladerunner/script/scene/hf03.cpp b/engines/bladerunner/script/scene/hf03.cpp index e3b01df4f8..e24aab74cb 100644 --- a/engines/bladerunner/script/scene/hf03.cpp +++ b/engines/bladerunner/script/scene/hf03.cpp @@ -189,22 +189,22 @@ bool SceneScriptHF03::ClickedOnItem(int itemId, bool a2) { bool SceneScriptHF03::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 179.0f, 46.76f, -824.0f, 0, 1, false, 0)) { - Game_Flag_Set(311); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagHF03toHF01); + Set_Enter(kSetHF01, kSceneHF01); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 479.0f, 47.76f, -524.0f, 0, 1, false, 0)) { Game_Flag_Set(528); - Set_Enter(38, kSceneHF02); + Set_Enter(kSetHF02, kSceneHF02); } return true; } if (exitId == 2) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 942.0f, 47.76f, -847.0f, 0, 1, false, 0)) { Game_Flag_Set(566); - Set_Enter(40, kSceneHF04); + Set_Enter(kSetHF04, kSceneHF04); } return true; } @@ -227,7 +227,7 @@ void SceneScriptHF03::PlayerWalkedIn() { Game_Flag_Reset(527); } else { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 179.0f, 47.76f, -824.0f, 0, 0, false, 0); - Game_Flag_Reset(310); + Game_Flag_Reset(kFlagHF01toHF03); } if (Actor_Query_Goal_Number(kActorLucy) == 250) { Actor_Set_Goal_Number(kActorLucy, 212); diff --git a/engines/bladerunner/script/scene/hf04.cpp b/engines/bladerunner/script/scene/hf04.cpp index 192d0e92a1..11a8479da7 100644 --- a/engines/bladerunner/script/scene/hf04.cpp +++ b/engines/bladerunner/script/scene/hf04.cpp @@ -84,7 +84,7 @@ bool SceneScriptHF04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(567); - Set_Enter(38, kSceneHF02); + Set_Enter(kSetHF02, kSceneHF02); } return true; } diff --git a/engines/bladerunner/script/scene/hf05.cpp b/engines/bladerunner/script/scene/hf05.cpp index 57846f2b73..4022d1952c 100644 --- a/engines/bladerunner/script/scene/hf05.cpp +++ b/engines/bladerunner/script/scene/hf05.cpp @@ -69,10 +69,15 @@ bool SceneScriptHF05::ClickedOn3DObject(const char *objectName, bool a2) { if (Object_Query_Click("TOP CON", objectName) == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 95.0f, 40.63f, 308.0f, 0, 1, false, 0)) { Actor_Face_Object(kActorMcCoy, "TOP CON", true); - if (Actor_Query_In_Set(kActorCrazylegs, 41) && Actor_Query_Goal_Number(kActorCrazylegs) != 1 && Actor_Query_Goal_Number(kActorCrazylegs) != 2) { + if (Actor_Query_In_Set(kActorCrazylegs, kSetHF05) + && Actor_Query_Goal_Number(kActorCrazylegs) != 1 + && Actor_Query_Goal_Number(kActorCrazylegs) != 2 + ) { Actor_Face_Actor(kActorCrazylegs, kActorMcCoy, true); Actor_Says(kActorCrazylegs, 480, 13); - } else if (!Game_Flag_Query(662) || Game_Flag_Query(369)) { + } else if (!Game_Flag_Query(662) + || Game_Flag_Query(369) + ) { Actor_Change_Animation_Mode(kActorMcCoy, 23); Sound_Play(412, 100, 0, 0, 50); } else { @@ -129,7 +134,7 @@ bool SceneScriptHF05::ClickedOn3DObject(const char *objectName, bool a2) { bool SceneScriptHF05::ClickedOnActor(int actorId) { if (actorId == 9) { - if (!Loop_Actor_Walk_To_Actor(kActorMcCoy, kActorCrazylegs, 60, 1, false)) { + if (!Loop_Actor_Walk_To_Actor(kActorMcCoy, kActorCrazylegs, 60, true, false)) { Actor_Face_Actor(kActorMcCoy, kActorCrazylegs, true); Actor_Face_Actor(kActorCrazylegs, kActorMcCoy, true); sub_402AE4(); @@ -145,8 +150,8 @@ bool SceneScriptHF05::ClickedOnItem(int itemId, bool a2) { bool SceneScriptHF05::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 483.0f, 40.63f, -189.0f, 0, 1, false, 0) && !Game_Flag_Query(684)) { - Game_Flag_Set(313); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagHF05toHF01); + Set_Enter(kSetHF01, kSceneHF01); } return true; } @@ -158,14 +163,14 @@ bool SceneScriptHF05::ClickedOnExit(int exitId) { Actor_Says(kActorMcCoy, 1810, 16); } Game_Flag_Set(359); - Set_Enter(43, kSceneHF07); + Set_Enter(kSetHF07, kSceneHF07); } return true; } if (exitId == 2) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 277.0f, 40.63f, 410.0f, 0, 1, false, 0) && !Game_Flag_Query(684)) { Game_Flag_Set(529); - Set_Enter(42, kSceneHF06); + Set_Enter(kSetHF06, kSceneHF06); } return true; } @@ -234,9 +239,9 @@ void SceneScriptHF05::PlayerWalkedIn() { if (Game_Flag_Query(662)) { int v0 = sub_404858(); if (Game_Flag_Query(662) && v0 != -1) { - Actor_Put_In_Set(v0, 41); + Actor_Put_In_Set(v0, kSetHF05); Actor_Force_Stop_Walking(v0); - if (Game_Flag_Query(312)) { + if (Game_Flag_Query(kFlagHF01toHF05)) { Actor_Set_At_XYZ(v0, 506.81f, 40.63f, -140.92f, 0); Async_Actor_Walk_To_Waypoint(v0, 437, 36, 0); } else if (Game_Flag_Query(530)) { @@ -265,13 +270,13 @@ void SceneScriptHF05::PlayerWalkedIn() { } else { sub_403A34(v0); } - } else if (Game_Flag_Query(312) == 1) { + } else if (Game_Flag_Query(kFlagHF01toHF05)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 399.0f, 40.63f, -85.0f, 0, 0, false, 0); } else if (Game_Flag_Query(358)) { Actor_Set_At_XYZ(kActorMcCoy, 346.0f, 4.63f, -151.0f, 603); Loop_Actor_Travel_Stairs(kActorMcCoy, 4, 1, 0); } - if (Actor_Query_In_Set(kActorCrazylegs, 41)) { + if (Actor_Query_In_Set(kActorCrazylegs, kSetHF05)) { if (Game_Flag_Query(562)) { if (!Game_Flag_Query(563) && Global_Variable_Query(kVariableChapter) == 3) { sub_402970(); @@ -282,7 +287,7 @@ void SceneScriptHF05::PlayerWalkedIn() { Game_Flag_Set(562); } } - Game_Flag_Reset(312); + Game_Flag_Reset(kFlagHF01toHF05); Game_Flag_Reset(530); Game_Flag_Reset(358); @@ -463,16 +468,16 @@ void SceneScriptHF05::sub_403738() { Actor_Says(kActorMcCoy, 1990, 17); Actor_Says(kActorCrazylegs, 600, 16); Actor_Says(kActorMcCoy, 1995, 3); - Game_Flag_Set(165); - Actor_Put_In_Set(kActorCrazylegs, 67); + Game_Flag_Set(kFlagCrazylegsArrested); + Actor_Put_In_Set(kActorCrazylegs, kSetPS09); Actor_Set_At_XYZ(kActorCrazylegs, -315.15f, 0.0f, 241.06f, 583); Actor_Set_Goal_Number(kActorCrazylegs, 699); Game_Flag_Set(652); if (Game_Flag_Query(kFlagSpinnerAtNR01)) { - Set_Enter(54, kSceneNR01); + Set_Enter(kSetNR01, kSceneNR01); } else { - Game_Flag_Set(313); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagHF05toHF01); + Set_Enter(kSetHF01, kSceneHF01); } } else if (answer == 1260) { Actor_Says(kActorMcCoy, 1965, 12); @@ -543,7 +548,7 @@ void SceneScriptHF05::sub_40410C() { } void SceneScriptHF05::sub_403A34(int actorId) { - if (actorId != -1 && Actor_Query_In_Set(kActorCrazylegs, 41)) { + if (actorId != -1 && Actor_Query_In_Set(kActorCrazylegs, kSetHF05)) { Async_Actor_Walk_To_Waypoint(actorId, 437, 36, 0); Loop_Actor_Walk_To_Waypoint(kActorMcCoy, 437, 0, 0, false); Actor_Face_Actor(kActorCrazylegs, kActorMcCoy, true); @@ -588,7 +593,7 @@ void SceneScriptHF05::sub_403A34(int actorId) { Async_Actor_Walk_To_XYZ(actorId, 309.0f, 40.63f, 402.0f, 0, false); Loop_Actor_Walk_To_XYZ(kActorMcCoy, 277.0f, 40.63f, 410.0f, 0, 0, false, 0); Game_Flag_Set(529); - Set_Enter(42, kSceneHF06); + Set_Enter(kSetHF06, kSceneHF06); } } @@ -661,10 +666,10 @@ void SceneScriptHF05::sub_404474() { } int SceneScriptHF05::sub_4048C0() { - if (Actor_Query_In_Set(kActorDektora, 41) == 1 && Actor_Query_Goal_Number(kActorDektora) != 599) { + if (Actor_Query_In_Set(kActorDektora, kSetHF05) && Actor_Query_Goal_Number(kActorDektora) != 599) { return kActorDektora; } - if (Actor_Query_In_Set(kActorLucy, 41) == 1 && Actor_Query_Goal_Number(kActorLucy) != 599) { + if (Actor_Query_In_Set(kActorLucy, kSetHF05) && Actor_Query_Goal_Number(kActorLucy) != 599) { return kActorLucy; } return kActorMcCoy; diff --git a/engines/bladerunner/script/scene/hf06.cpp b/engines/bladerunner/script/scene/hf06.cpp index 49ea1d81d2..318e104c14 100644 --- a/engines/bladerunner/script/scene/hf06.cpp +++ b/engines/bladerunner/script/scene/hf06.cpp @@ -64,11 +64,11 @@ bool SceneScriptHF06::ClickedOn3DObject(const char *objectName, bool a2) { if (Object_Query_Click("BOX28", objectName) || Object_Query_Click("BOX29", objectName) || Object_Query_Click("BOX30", objectName) || Object_Query_Click("HOOD BOX", objectName)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 14.33f, 367.93f, 399.0f, 0, 1, false, 0)) { Actor_Face_Heading(kActorMcCoy, 486, true); - if (Actor_Query_In_Set(kActorDektora, 42) && Actor_Query_Goal_Number(kActorDektora) != 599) { + if (Actor_Query_In_Set(kActorDektora, kSetHF06) && Actor_Query_Goal_Number(kActorDektora) != 599) { Actor_Face_Actor(kActorDektora, kActorMcCoy, true); Actor_Says(kActorDektora, 210, 12); Actor_Says(kActorMcCoy, 2125, 12); - } else if (Actor_Query_In_Set(kActorLucy, 42) && Actor_Query_Goal_Number(kActorLucy) != 599) { + } else if (Actor_Query_In_Set(kActorLucy, kSetHF06) && Actor_Query_Goal_Number(kActorLucy) != 599) { Actor_Face_Actor(kActorLucy, kActorMcCoy, true); Actor_Says(kActorLucy, 490, 18); Actor_Says(kActorMcCoy, 2125, 12); @@ -126,7 +126,7 @@ bool SceneScriptHF06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(530); - Set_Enter(41, kSceneHF05); + Set_Enter(kSetHF05, kSceneHF05); } return true; } @@ -148,9 +148,9 @@ void SceneScriptHF06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo Actor_Says(kActorSteele, 260, -1); Actor_Says(kActorSteele, 270, -1); int otherActorId = -1; - if (Actor_Query_In_Set(kActorDektora, 42) && Actor_Query_Goal_Number(kActorDektora) == 599) { + if (Actor_Query_In_Set(kActorDektora, kSetHF06) && Actor_Query_Goal_Number(kActorDektora) == 599) { otherActorId = kActorDektora; - } else if (Actor_Query_In_Set(kActorLucy, 42) && Actor_Query_Goal_Number(kActorLucy) == 599) { + } else if (Actor_Query_In_Set(kActorLucy, kSetHF06) && Actor_Query_Goal_Number(kActorLucy) == 599) { otherActorId = kActorLucy; } if (otherActorId != -1) { @@ -168,10 +168,10 @@ void SceneScriptHF06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo Actor_Voice_Over(1050, kActorVoiceOver); Actor_Clue_Acquire(kActorMcCoy, kClueBomb, 1, -1); } - if (Actor_Query_In_Set(kActorDektora, 42)) { + if (Actor_Query_In_Set(kActorDektora, kSetHF06)) { Actor_Set_Targetable(kActorDektora, false); } - if (Actor_Query_In_Set(kActorLucy, 42)) { + if (Actor_Query_In_Set(kActorLucy, kSetHF06)) { Actor_Set_Targetable(kActorLucy, false); } Scene_Exits_Enable(); @@ -188,7 +188,7 @@ void SceneScriptHF06::PlayerWalkedIn() { } if (actorId != -1) { - Actor_Put_In_Set(actorId, 42); + Actor_Put_In_Set(actorId, kSetHF06); if (Game_Flag_Query(559)) { Actor_Set_At_XYZ(actorId, 173.67f, 367.93f, 446.04f, 229); Async_Actor_Walk_To_XYZ(actorId, 173.67f, 367.93f, 394.04f, 0, false); @@ -216,19 +216,18 @@ void SceneScriptHF06::DialogueQueueFlushed(int a1) { void SceneScriptHF06::sub_401EF4() { int actorId; - if (Actor_Query_In_Set(kActorDektora, 42)) { + if (Actor_Query_In_Set(kActorDektora, kSetHF06)) { actorId = kActorDektora; - } else { - if (!Actor_Query_In_Set(kActorLucy, 42)) { - return; - } + } else if (Actor_Query_In_Set(kActorLucy, kSetHF06)) { actorId = kActorLucy; + } else { + return; } Actor_Set_Targetable(actorId, true); Loop_Actor_Walk_To_XYZ(kActorMcCoy, 14.33f, 367.93f, 399.0f, 0, 0, true, 0); Actor_Face_Heading(kActorMcCoy, 486, true); sub_4023E0(); - Actor_Put_In_Set(kActorSteele, 42); + Actor_Put_In_Set(kActorSteele, kSetHF06); Actor_Set_At_XYZ(kActorSteele, 92.0f, 367.93f, 19.0f, 0); Actor_Set_Targetable(kActorSteele, true); Actor_Face_Actor(actorId, kActorSteele, true); diff --git a/engines/bladerunner/script/scene/hf07.cpp b/engines/bladerunner/script/scene/hf07.cpp index b653cfd08a..318cb93c5e 100644 --- a/engines/bladerunner/script/scene/hf07.cpp +++ b/engines/bladerunner/script/scene/hf07.cpp @@ -68,36 +68,36 @@ bool SceneScriptHF07::ClickedOnItem(int itemId, bool a2) { bool SceneScriptHF07::ClickedOnExit(int exitId) { if (exitId == 0) { - if (Actor_Query_In_Set(3, 43)) { - Async_Actor_Walk_To_XYZ(3, 235.0f, 58.43f, -100.0f, 0, false); - } else if (Actor_Query_In_Set(6, 43)) { - Async_Actor_Walk_To_XYZ(6, 235.0f, 58.43f, -100.0f, 0, false); + if (Actor_Query_In_Set(kActorDektora, kSetHF07)) { + Async_Actor_Walk_To_XYZ(kActorDektora, 235.0f, 58.43f, -100.0f, 0, false); + } else if (Actor_Query_In_Set(kActorLucy, kSetHF07)) { + Async_Actor_Walk_To_XYZ(kActorLucy, 235.0f, 58.43f, -100.0f, 0, false); } - if (!Loop_Actor_Walk_To_XYZ(0, 318.0f, 71.43f, -102.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 318.0f, 71.43f, -102.0f, 0, 1, false, 0)) { Game_Flag_Set(358); if (!Game_Flag_Query(662)) { - Actor_Face_Heading(0, 0, false); + Actor_Face_Heading(kActorMcCoy, 0, false); Footstep_Sound_Override_On(3); - Loop_Actor_Travel_Stairs(0, 30, 1, 0); + Loop_Actor_Travel_Stairs(kActorMcCoy, 30, true, 0); Footstep_Sound_Override_Off(); } Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Set_Enter(41, kSceneHF05); + Set_Enter(kSetHF05, kSceneHF05); } return true; } if (exitId == 1) { - if (Actor_Query_In_Set(3, 43)) { - Async_Actor_Walk_To_XYZ(3, -73.0f, 58.43f, -7.0f, 0, false); - } else if (Actor_Query_In_Set(6, 43)) { - Async_Actor_Walk_To_XYZ(6, -73.0f, 58.43f, -7.0f, 0, false); + if (Actor_Query_In_Set(kActorDektora, kSetHF07)) { + Async_Actor_Walk_To_XYZ(kActorDektora, -73.0f, 58.43f, -7.0f, 0, false); + } else if (Actor_Query_In_Set(kActorLucy, kSetHF07)) { + Async_Actor_Walk_To_XYZ(kActorLucy, -73.0f, 58.43f, -7.0f, 0, false); } - if (!Loop_Actor_Walk_To_XYZ(0, -84.0f, 58.43f, -105.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -84.0f, 58.43f, -105.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(360); - Set_Enter(78, kSceneUG05); + Set_Enter(kSetUG05, kSceneUG05); } return true; } @@ -118,7 +118,7 @@ void SceneScriptHF07::PlayerWalkedIn() { if (Game_Flag_Query(662)) { int actorId = sub_401864(); if (Game_Flag_Query(662) && actorId != -1) { - Actor_Put_In_Set(actorId, 43); + Actor_Put_In_Set(actorId, kSetHF07); if (Game_Flag_Query(361)) { Actor_Set_At_XYZ(actorId, -73.0f, 58.43f, -7.0f, 224); } else { @@ -126,9 +126,9 @@ void SceneScriptHF07::PlayerWalkedIn() { } } } else if (Game_Flag_Query(359)) { - Actor_Set_At_XYZ(0, 267.72f, 329.43f, -86.75f, 940); + Actor_Set_At_XYZ(kActorMcCoy, 267.72f, 329.43f, -86.75f, 940); Footstep_Sound_Override_On(3); - Loop_Actor_Travel_Stairs(0, 30, 0, 0); + Loop_Actor_Travel_Stairs(kActorMcCoy, 30, false, 0); Footstep_Sound_Override_Off(); } Game_Flag_Reset(359); @@ -142,10 +142,10 @@ void SceneScriptHF07::DialogueQueueFlushed(int a1) { } int SceneScriptHF07::sub_401864() { - if (Global_Variable_Query(kVariableAffectionTowards) == 2 && Actor_Query_Goal_Number(3) != 599) { + if (Global_Variable_Query(kVariableAffectionTowards) == 2 && Actor_Query_Goal_Number(kActorDektora) != 599) { return kActorDektora; } - if (Global_Variable_Query(kVariableAffectionTowards) == 3 && Actor_Query_Goal_Number(6) != 599) { + if (Global_Variable_Query(kVariableAffectionTowards) == 3 && Actor_Query_Goal_Number(kActorLucy) != 599) { return kActorLucy; } return -1; diff --git a/engines/bladerunner/script/scene/kp01.cpp b/engines/bladerunner/script/scene/kp01.cpp index 72ab3d5117..b2daa6b101 100644 --- a/engines/bladerunner/script/scene/kp01.cpp +++ b/engines/bladerunner/script/scene/kp01.cpp @@ -83,7 +83,7 @@ bool SceneScriptKP01::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(415); - Set_Enter(47, kSceneKP04); + Set_Enter(kSetKP04, kSceneKP04); } return true; } @@ -92,7 +92,7 @@ bool SceneScriptKP01::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(417); - Set_Enter(46, kSceneKP03); + Set_Enter(kSetKP03, kSceneKP03); } return true; } @@ -101,7 +101,7 @@ bool SceneScriptKP01::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(414); - Set_Enter(45, kSceneKP02); + Set_Enter(kSetKP02, kSceneKP02); } return true; } @@ -136,7 +136,7 @@ void SceneScriptKP01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(417); - Set_Enter(46, kSceneKP03); + Set_Enter(kSetKP03, kSceneKP03); //return true; } } diff --git a/engines/bladerunner/script/scene/kp02.cpp b/engines/bladerunner/script/scene/kp02.cpp index b123160519..4912a88c6f 100644 --- a/engines/bladerunner/script/scene/kp02.cpp +++ b/engines/bladerunner/script/scene/kp02.cpp @@ -84,12 +84,12 @@ bool SceneScriptKP02::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(411); - Set_Enter(84, kSceneUG12); + Set_Enter(kSetUG12, kSceneUG12); } else { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(411); - Set_Enter(84, kSceneUG12); + Set_Enter(kSetUG12, kSceneUG12); } } return true; @@ -104,12 +104,12 @@ bool SceneScriptKP02::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(413); - Set_Enter(44, kSceneKP01); + Set_Enter(kSetKP01, kSceneKP01); } else { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(413); - Set_Enter(44, kSceneKP01); + Set_Enter(kSetKP01, kSceneKP01); } } return true; diff --git a/engines/bladerunner/script/scene/kp03.cpp b/engines/bladerunner/script/scene/kp03.cpp index cb96e8bfe3..1d810f2fd9 100644 --- a/engines/bladerunner/script/scene/kp03.cpp +++ b/engines/bladerunner/script/scene/kp03.cpp @@ -47,7 +47,7 @@ void SceneScriptKP03::InitializeScene() { Game_Flag_Set(421); } if ((Actor_Query_Goal_Number(kActorSteele) != 599 && !Game_Flag_Query(422) && !Game_Flag_Query(484)) && ((Game_Flag_Query(653) && Game_Flag_Query(420)) || (!Game_Flag_Query(653) && Game_Flag_Query(417)))) { - Actor_Put_In_Set(kActorSteele, 46); + Actor_Put_In_Set(kActorSteele, kSetKP03); Actor_Set_At_XYZ(kActorSteele, -300.0f, -36.55f, 26.0f, 350); } } @@ -127,7 +127,7 @@ bool SceneScriptKP03::ClickedOnExit(int exitId) { Game_Flag_Reset(417); Game_Flag_Reset(420); Game_Flag_Set(419); - Set_Enter(9, kSceneKP05); + Set_Enter(kSetKP05_KP06, kSceneKP05); } return true; } @@ -139,7 +139,7 @@ bool SceneScriptKP03::ClickedOnExit(int exitId) { Game_Flag_Reset(417); Game_Flag_Reset(420); Game_Flag_Set(418); - Set_Enter(44, kSceneKP01); + Set_Enter(kSetKP01, kSceneKP01); } return true; } @@ -255,7 +255,7 @@ void SceneScriptKP03::sub_401E54() { Game_Flag_Reset(417); Game_Flag_Reset(420); Game_Flag_Set(419); - Set_Enter(9, kSceneKP05); + Set_Enter(kSetKP05_KP06, kSceneKP05); Player_Gains_Control(); } diff --git a/engines/bladerunner/script/scene/kp04.cpp b/engines/bladerunner/script/scene/kp04.cpp index 97eda1bd24..ae9e4021c5 100644 --- a/engines/bladerunner/script/scene/kp04.cpp +++ b/engines/bladerunner/script/scene/kp04.cpp @@ -74,7 +74,7 @@ bool SceneScriptKP04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(416); - Set_Enter(44, kSceneKP01); + Set_Enter(kSetKP01, kSceneKP01); } return true; } @@ -83,7 +83,7 @@ bool SceneScriptKP04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(574); - Set_Enter(9, kSceneKP05); + Set_Enter(kSetKP05_KP06, kSceneKP05); } return true; } diff --git a/engines/bladerunner/script/scene/kp05.cpp b/engines/bladerunner/script/scene/kp05.cpp index 99fa6c33fa..a3c7d1ee1a 100644 --- a/engines/bladerunner/script/scene/kp05.cpp +++ b/engines/bladerunner/script/scene/kp05.cpp @@ -88,7 +88,7 @@ bool SceneScriptKP05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(420); - Set_Enter(46, kSceneKP03); + Set_Enter(kSetKP03, kSceneKP03); } return true; } @@ -97,7 +97,7 @@ bool SceneScriptKP05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(575); - Set_Enter(47, kSceneKP04); + Set_Enter(kSetKP04, kSceneKP04); } return true; } @@ -107,7 +107,7 @@ bool SceneScriptKP05::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(576); Async_Actor_Walk_To_XYZ(kActorMcCoy, -868.0f, 0.0f, -216.0f, 0, false); - Set_Enter(9, kSceneKP06); + Set_Enter(kSetKP05_KP06, kSceneKP06); } return true; } diff --git a/engines/bladerunner/script/scene/kp06.cpp b/engines/bladerunner/script/scene/kp06.cpp index 462bd83f0c..569ccbb8b6 100644 --- a/engines/bladerunner/script/scene/kp06.cpp +++ b/engines/bladerunner/script/scene/kp06.cpp @@ -101,7 +101,7 @@ bool SceneScriptKP06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(577); - Set_Enter(9, kSceneKP05); + Set_Enter(kSetKP05_KP06, kSceneKP05); } return true; } @@ -120,7 +120,7 @@ bool SceneScriptKP06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(578); - Set_Enter(48, kSceneKP07); + Set_Enter(kSetKP07, kSceneKP07); } } else if (Actor_Clue_Query(kActorMcCoy, kCluePowerSource) ) { Actor_Says(kActorSadik, 280, 3); @@ -131,7 +131,7 @@ bool SceneScriptKP06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(578); - Set_Enter(48, kSceneKP07); + Set_Enter(kSetKP07, kSceneKP07); } else { Actor_Set_Goal_Number(kActorSadik, 417); } diff --git a/engines/bladerunner/script/scene/kp07.cpp b/engines/bladerunner/script/scene/kp07.cpp index c78dcf6f47..7a0c0eb535 100644 --- a/engines/bladerunner/script/scene/kp07.cpp +++ b/engines/bladerunner/script/scene/kp07.cpp @@ -122,7 +122,7 @@ bool SceneScriptKP07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(579); - Set_Enter(9, kSceneKP06); + Set_Enter(kSetKP05_KP06, kSceneKP06); } return true; } @@ -148,7 +148,7 @@ void SceneScriptKP07::PlayerWalkedIn() { Actor_Says(kActorMcCoy, 8500, 3); Actor_Says(kActorClovis, 1250, 3); if (Actor_Query_Goal_Number(kActorSadik) == 416) { - Actor_Put_In_Set(kActorSadik, 48); + Actor_Put_In_Set(kActorSadik, kSetKP07); Global_Variable_Increment(kVariableReplicants, 1); Actor_Set_At_XYZ(kActorSadik, -12.0f, -41.58f, 72.0f, 0); Actor_Face_Actor(kActorSadik, kActorClovis, true); diff --git a/engines/bladerunner/script/scene/ma01.cpp b/engines/bladerunner/script/scene/ma01.cpp index 5acd8c48e2..d48795eb65 100644 --- a/engines/bladerunner/script/scene/ma01.cpp +++ b/engines/bladerunner/script/scene/ma01.cpp @@ -118,74 +118,74 @@ bool SceneScriptMA01::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 381.0f, 0.0f, 54.0f, 0, 1, false, 0)) { Player_Loses_Control(); Actor_Face_Heading(kActorMcCoy, 736, false); - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(180); - Game_Flag_Reset(261); - Game_Flag_Reset(177); - Game_Flag_Reset(258); - Game_Flag_Reset(178); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtARxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); int spinnerDest = Spinner_Interface_Choose_Dest(kMA01LoopOutDoorAnim, false); switch (spinnerDest) { case kSpinnerDestinationPoliceStation: - Game_Flag_Set(178); + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtPS01); Set_Enter(kSetPS01, kScenePS01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationRuncitersAnimals: - Game_Flag_Set(182); + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtRC01); Set_Enter(kSetRC01, kSceneRC01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationChinatown: - Game_Flag_Set(176); + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtCT01); Set_Enter(kSetCT01_CT12, kSceneCT01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationTyrellBuilding: - Game_Flag_Set(261); + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtTB02); Set_Enter(kSetTB02_TB03, kSceneTB02); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationAnimoidRow: - Game_Flag_Set(180); + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtAR01); Set_Enter(kSetAR01_AR02, kSceneAR01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationDNARow: - Game_Flag_Set(177); + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtDR01); Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationBradburyBuilding: - Game_Flag_Set(258); + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtBB01); Set_Enter(kSetBB01, kSceneBB01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationNightclubRow: - Game_Flag_Set(181); + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtNR01); Set_Enter(kSetNR01, kSceneNR01); Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kMA01LoopOutshotRoof, true); break; case kSpinnerDestinationHysteriaHall: - Game_Flag_Set(257); + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtMA01); Game_Flag_Set(kFlagSpinnerAtHF01); Set_Enter(kSetHF01, kSceneHF01); @@ -194,7 +194,7 @@ bool SceneScriptMA01::ClickedOnExit(int exitId) { default: Actor_Set_Invisible(kActorMcCoy, false); Actor_Face_Heading(kActorMcCoy, 736, false); - Game_Flag_Set(179); + Game_Flag_Set(kFlagMcCoyAtMAxx); break; } } diff --git a/engines/bladerunner/script/scene/ma04.cpp b/engines/bladerunner/script/scene/ma04.cpp index 0b2643149b..ed6ee682a9 100644 --- a/engines/bladerunner/script/scene/ma04.cpp +++ b/engines/bladerunner/script/scene/ma04.cpp @@ -291,7 +291,7 @@ void SceneScriptMA04::PlayerWalkedIn() { Item_Remove_From_World(kItemChromeDebris); } Actor_Set_Goal_Number(kActorOfficerLeary, 99); - Actor_Put_In_Set(kActorOfficerLeary, 93); + Actor_Put_In_Set(kActorOfficerLeary, kSetFreeSlotC); Actor_Set_At_Waypoint(kActorOfficerLeary, 35, 0); Autosave_Game(0); } @@ -365,7 +365,7 @@ void SceneScriptMA04::phoneCallWithDektora() { Actor_Says(kActorMcCoy, 2495, 0); Actor_Says(kActorDektora, 340, 3); Actor_Says(kActorDektora, 350, 3); - if (Game_Flag_Query(165) || Actor_Query_Goal_Number(kActorCrazylegs) == 2) { + if (Game_Flag_Query(kFlagCrazylegsArrested) || Actor_Query_Goal_Number(kActorCrazylegs) == 2) { answer = 1170; } else { Dialogue_Menu_Clear_List(); @@ -418,7 +418,7 @@ void SceneScriptMA04::phoneCallWithLucy() { Actor_Says(kActorLucy, 570, 3); Actor_Says(kActorMcCoy, 2560, 17); Actor_Says(kActorLucy, 580, 3); - if (Game_Flag_Query(165) || Actor_Query_Goal_Number(kActorCrazylegs) == 2) { + if (Game_Flag_Query(kFlagCrazylegsArrested) || Actor_Query_Goal_Number(kActorCrazylegs) == 2) { Actor_Says(kActorLucy, 630, 3); Actor_Says_With_Pause(kActorMcCoy, 2575, 0.0f, 15); if (!Game_Flag_Query(kFlagDirectorsCut)) { diff --git a/engines/bladerunner/script/scene/ma07.cpp b/engines/bladerunner/script/scene/ma07.cpp index bb85a82cde..62a5187e77 100644 --- a/engines/bladerunner/script/scene/ma07.cpp +++ b/engines/bladerunner/script/scene/ma07.cpp @@ -79,7 +79,7 @@ bool SceneScriptMA07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(kFlagMA07toMA06); - Set_Enter(52, kSceneMA06); + Set_Enter(kSetMA06, kSceneMA06); } } return true; @@ -89,9 +89,9 @@ bool SceneScriptMA07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(672); - Game_Flag_Reset(179); - Game_Flag_Set(178); - Set_Enter(68, kScenePS14); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Set(kFlagMcCoyAtPSxx); + Set_Enter(kSetPS14, kScenePS14); } return true; } @@ -100,7 +100,7 @@ bool SceneScriptMA07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(357); - Set_Enter(90, kSceneUG19); + Set_Enter(kSetUG19, kSceneUG19); } return true; } diff --git a/engines/bladerunner/script/scene/nr01.cpp b/engines/bladerunner/script/scene/nr01.cpp index 9fc87d8367..528d9d74e0 100644 --- a/engines/bladerunner/script/scene/nr01.cpp +++ b/engines/bladerunner/script/scene/nr01.cpp @@ -109,123 +109,123 @@ bool SceneScriptNR01::ClickedOnItem(int itemId, bool a2) { bool SceneScriptNR01::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -380.0f, 31.93f, -841.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -380.0f, 31.93f, -841.0f, 0, true, false, 0)) { if (Global_Variable_Query(kVariableChapter) > 3) { Actor_Says(kActorMcCoy, 8522, 12); } else { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(535); - Set_Enter(55, kSceneNR03); + Set_Enter(kSetNR03, kSceneNR03); } } return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -281.0f, 31.93f, -1061.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -281.0f, 31.93f, -1061.0f, 0, true, false, 0)) { Actor_Face_Heading(kActorMcCoy, 45, false); Loop_Actor_Travel_Stairs(kActorMcCoy, 3, 0, 0); Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(343); - Set_Enter(79, kSceneUG06); + Set_Enter(kSetUG06, kSceneUG06); } return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 312.0f, 31.66f, -901.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 312.0f, 31.66f, -901.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(532); - Set_Enter(11, kSceneNR02); + Set_Enter(kSetNR02, kSceneNR02); } return true; } if (exitId == 3) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 108.0f, 23.88f, -93.0f, 0, 1, false, 0)) { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - Game_Flag_Reset(257); - Game_Flag_Reset(261); - Game_Flag_Reset(181); - switch (Spinner_Interface_Choose_Dest(-1, 1)) { - case 9: - Game_Flag_Set(257); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 108.0f, 23.88f, -93.0f, 0, true, false, 0)) { + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtHFxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagMcCoyAtNRxx); + switch (Spinner_Interface_Choose_Dest(-1, true)) { + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtNR01); - Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Reset(kFlagArrivedFromSpinner); + Game_Flag_Set(kFlagSpinnerAtPS01); + Set_Enter(kSetPS01, kScenePS01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtMA01); + Set_Enter(kSetMA01, kSceneMA01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtRC01); + Set_Enter(kSetRC01, kSceneRC01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtCT01); + Set_Enter(kSetCT01_CT12, kSceneCT01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); - Scene_Loop_Start_Special(1, 3, 1); + Set_Enter(kSetAR01_AR02, kSceneAR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtTB02); + Set_Enter(kSetTB02_TB03, kSceneTB02); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtDR01); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtNR01); Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtBB01); + Set_Enter(kSetBB01, kSceneBB01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtNR01); - Game_Flag_Reset(kFlagArrivedFromSpinner); - Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); - Scene_Loop_Start_Special(1, 3, 1); + Game_Flag_Set(kFlagSpinnerAtHF01); + Set_Enter(kSetHF01, kSceneHF01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); break; default: Player_Loses_Control(); - Game_Flag_Set(181); + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Set(kFlagArrivedFromSpinner); Player_Gains_Control(); break; @@ -303,7 +303,7 @@ void SceneScriptNR01::PlayerWalkedIn() { } if (Game_Flag_Query(632)) { Delay(3500); - Set_Enter(60, kSceneNR11); + Set_Enter(kSetNR11, kSceneNR11); //return true; return; } @@ -388,7 +388,7 @@ void SceneScriptNR01::PlayerWalkedIn() { } } else if (Game_Flag_Query(545)) { Game_Flag_Reset(545); - Actor_Put_In_Set(kActorHanoi, 54); + Actor_Put_In_Set(kActorHanoi, kSetNR01); Actor_Set_At_XYZ(kActorHanoi, -202.0f, 24.0f, -574.0f, 0); Actor_Face_Heading(kActorHanoi, 256, false); Actor_Set_Goal_Number(kActorHanoi, 204); diff --git a/engines/bladerunner/script/scene/nr02.cpp b/engines/bladerunner/script/scene/nr02.cpp index 93b168b75e..37956e380f 100644 --- a/engines/bladerunner/script/scene/nr02.cpp +++ b/engines/bladerunner/script/scene/nr02.cpp @@ -129,7 +129,7 @@ bool SceneScriptNR02::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(533); - Set_Enter(54, kSceneNR01); + Set_Enter(kSetNR01, kSceneNR01); } return true; } diff --git a/engines/bladerunner/script/scene/nr03.cpp b/engines/bladerunner/script/scene/nr03.cpp index beb3ec7632..c06b7ed6af 100644 --- a/engines/bladerunner/script/scene/nr03.cpp +++ b/engines/bladerunner/script/scene/nr03.cpp @@ -131,7 +131,7 @@ bool SceneScriptNR03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(534); - Set_Enter(54, kSceneNR01); + Set_Enter(kSetNR01, kSceneNR01); } return true; } @@ -157,7 +157,7 @@ bool SceneScriptNR03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(438); - Set_Enter(12, kSceneNR04); + Set_Enter(kSetNR04, kSceneNR04); } return true; @@ -173,8 +173,8 @@ bool SceneScriptNR03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(536); - Set_Enter(13, kSceneNR05); - Scene_Loop_Start_Special(1, 2, 0); + Set_Enter(kSetNR05_NR08, kSceneNR05); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 2, 0); return true; } Actor_Face_Heading(kActorMcCoy, 680, false); diff --git a/engines/bladerunner/script/scene/nr04.cpp b/engines/bladerunner/script/scene/nr04.cpp index 00aee0b4ad..6b8d606c9d 100644 --- a/engines/bladerunner/script/scene/nr04.cpp +++ b/engines/bladerunner/script/scene/nr04.cpp @@ -137,7 +137,7 @@ bool SceneScriptNR04::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(437); - Set_Enter(55, kSceneNR03); + Set_Enter(kSetNR03, kSceneNR03); } return true; } diff --git a/engines/bladerunner/script/scene/nr05.cpp b/engines/bladerunner/script/scene/nr05.cpp index 9552734544..15a626ae2b 100644 --- a/engines/bladerunner/script/scene/nr05.cpp +++ b/engines/bladerunner/script/scene/nr05.cpp @@ -119,15 +119,15 @@ bool SceneScriptNR05::ClickedOnExit(int exitId) { Actor_Face_Heading(kActorMcCoy, 1021, false); Actor_Change_Animation_Mode(kActorMcCoy, 53); Game_Flag_Set(537); - Set_Enter(55, kSceneNR03); - Scene_Loop_Start_Special(1, 3, 0); + Set_Enter(kSetNR03, kSceneNR03); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, 0); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -777.56f, 0.0f, -166.86f, 0, 1, false, 0)) { Game_Flag_Set(546); - Set_Enter(13, kSceneNR08); + Set_Enter(kSetNR05_NR08, kSceneNR08); } return true; } diff --git a/engines/bladerunner/script/scene/nr06.cpp b/engines/bladerunner/script/scene/nr06.cpp index 6b304dc5f0..2c227165bb 100644 --- a/engines/bladerunner/script/scene/nr06.cpp +++ b/engines/bladerunner/script/scene/nr06.cpp @@ -84,7 +84,7 @@ bool SceneScriptNR06::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 48.0f, -71.88f, -26.0f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Game_Flag_Set(441); - Set_Enter(57, kSceneNR07); + Set_Enter(kSetNR07, kSceneNR07); } return true; } @@ -96,7 +96,7 @@ bool SceneScriptNR06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(439); - Set_Enter(13, kSceneNR08); + Set_Enter(kSetNR05_NR08, kSceneNR08); } return true; } diff --git a/engines/bladerunner/script/scene/nr07.cpp b/engines/bladerunner/script/scene/nr07.cpp index bb43b9b7e9..2d5d86120f 100644 --- a/engines/bladerunner/script/scene/nr07.cpp +++ b/engines/bladerunner/script/scene/nr07.cpp @@ -121,7 +121,7 @@ bool SceneScriptNR07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(442); - Set_Enter(56, kSceneNR06); + Set_Enter(kSetNR06, kSceneNR06); } return true; } @@ -140,7 +140,7 @@ void SceneScriptNR07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo void SceneScriptNR07::PlayerWalkedIn() { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -110.0f, -73.5f, -169.0f, 0, 0, false, 0); - if (Actor_Query_In_Set(kActorDektora, 57)) { + if (Actor_Query_In_Set(kActorDektora, kSetNR07)) { if (Game_Flag_Query(508)) { Actor_Modify_Friendliness_To_Other(kActorDektora, kActorMcCoy, -2); Actor_Says(kActorDektora, 530, 31); @@ -182,7 +182,7 @@ void SceneScriptNR07::sub_4018D4() { } else { Actor_Set_Goal_Number(kActorDektora, 295); Game_Flag_Set(591); - Actor_Put_In_Set(kActorDektora, 91); + Actor_Put_In_Set(kActorDektora, kSetFreeSlotA); Actor_Set_At_Waypoint(kActorDektora, 33, 0); } Player_Gains_Control(); diff --git a/engines/bladerunner/script/scene/nr08.cpp b/engines/bladerunner/script/scene/nr08.cpp index 9af74908eb..b946f3e612 100644 --- a/engines/bladerunner/script/scene/nr08.cpp +++ b/engines/bladerunner/script/scene/nr08.cpp @@ -97,7 +97,7 @@ bool SceneScriptNR08::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -1102.88f, 0.0f, 107.43f, 0, 1, false, 0)) { Game_Flag_Set(547); - Set_Enter(13, kSceneNR05); + Set_Enter(kSetNR05_NR08, kSceneNR05); } return true; } @@ -106,7 +106,7 @@ bool SceneScriptNR08::ClickedOnExit(int exitId) { Actor_Face_Heading(kActorMcCoy, 505, false); Loop_Actor_Travel_Stairs(kActorMcCoy, 4, 1, 0); Game_Flag_Set(440); - Set_Enter(56, kSceneNR06); + Set_Enter(kSetNR06, kSceneNR06); } return true; } @@ -117,7 +117,7 @@ bool SceneScriptNR08::ClickedOnExit(int exitId) { Loop_Actor_Travel_Stairs(kActorMcCoy, 6, 1, 0); Footstep_Sound_Override_Off(); Game_Flag_Set(614); - Set_Enter(58, kSceneNR09); + Set_Enter(kSetNR09, kSceneNR09); } } return false; @@ -153,7 +153,7 @@ void SceneScriptNR08::SceneFrameAdvanced(int frame) { Scene_Loop_Start_Special(kSceneLoopModeOnce, 3, true); } if (frame == 95) { - Actor_Put_In_Set(kActorDektora, 91); + Actor_Put_In_Set(kActorDektora, kSetFreeSlotA); Actor_Set_At_Waypoint(kActorDektora, 33, 0); Actor_Change_Animation_Mode(kActorDektora, 0); Actor_Set_Goal_Number(kActorDektora, 200); diff --git a/engines/bladerunner/script/scene/nr09.cpp b/engines/bladerunner/script/scene/nr09.cpp index 7f786e17c8..f924652270 100644 --- a/engines/bladerunner/script/scene/nr09.cpp +++ b/engines/bladerunner/script/scene/nr09.cpp @@ -75,7 +75,7 @@ bool SceneScriptNR09::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -564.07f, 0.35f, 399.04f, 0, 1, false, 0)) { Game_Flag_Set(475); - Set_Enter(59, kSceneNR10); + Set_Enter(kSetNR10, kSceneNR10); return true; } } @@ -85,7 +85,7 @@ bool SceneScriptNR09::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Looping_Sounds(1); if (!v1) { Game_Flag_Set(615); - Set_Enter(13, kSceneNR08); + Set_Enter(kSetNR05_NR08, kSceneNR08); return true; } } diff --git a/engines/bladerunner/script/scene/nr10.cpp b/engines/bladerunner/script/scene/nr10.cpp index f580463187..e5bd41c6e9 100644 --- a/engines/bladerunner/script/scene/nr10.cpp +++ b/engines/bladerunner/script/scene/nr10.cpp @@ -91,7 +91,7 @@ bool SceneScriptNR10::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -152.78f, 2.84f, -238.43f, 0, 1, false, 0)) { Game_Flag_Set(476); - Set_Enter(58, kSceneNR09); + Set_Enter(kSetNR09, kSceneNR09); return true; } } @@ -100,7 +100,7 @@ bool SceneScriptNR10::ClickedOnExit(int exitId) { Actor_Face_Heading(kActorMcCoy, 55, false); Loop_Actor_Travel_Ladder(kActorMcCoy, 8, 1, 0); Game_Flag_Set(641); - Set_Enter(60, kSceneNR11); + Set_Enter(kSetNR11, kSceneNR11); return true; } } diff --git a/engines/bladerunner/script/scene/nr11.cpp b/engines/bladerunner/script/scene/nr11.cpp index 5c4f4c141c..16ccfda8d0 100644 --- a/engines/bladerunner/script/scene/nr11.cpp +++ b/engines/bladerunner/script/scene/nr11.cpp @@ -208,7 +208,7 @@ bool SceneScriptNR11::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 100.0f, 1.75f, -8.0f, 0, 1, false, 0)) { Game_Flag_Set(477); - Set_Enter(59, kSceneNR10); + Set_Enter(kSetNR10, kSceneNR10); return true; } } @@ -296,7 +296,7 @@ void SceneScriptNR11::PlayerWalkedIn() { if (Game_Flag_Query(632)) { Game_Flag_Reset(632); Game_Flag_Set(634); - Actor_Put_In_Set(kActorDektora, 99); + Actor_Put_In_Set(kActorDektora, kSetFreeSlotI); Actor_Set_At_Waypoint(kActorDektora, 41, 0); Actor_Set_Invisible(kActorMcCoy, false); Player_Set_Combat_Mode(false); @@ -323,7 +323,7 @@ void SceneScriptNR11::PlayerWalkedIn() { Actor_Says_With_Pause(kActorSteele, 1730, 0.2f, 14); Actor_Says(kActorSteele, 1740, 15); Actor_Set_Goal_Number(kActorDektora, 599); - Actor_Put_In_Set(kActorDektora, 99); + Actor_Put_In_Set(kActorDektora, kSetFreeSlotI); Actor_Set_At_Waypoint(kActorDektora, 41, 0); Actor_Set_Goal_Number(kActorSteele, 275); } diff --git a/engines/bladerunner/script/scene/ps01.cpp b/engines/bladerunner/script/scene/ps01.cpp index 013b6021d9..69fcdf7395 100644 --- a/engines/bladerunner/script/scene/ps01.cpp +++ b/engines/bladerunner/script/scene/ps01.cpp @@ -80,89 +80,89 @@ bool SceneScriptPS01::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1920.0f, 16581.0f, -2653.0f, 12, 1, false, 0)) { Game_Flag_Set(718); - Set_Enter(62, kScenePS02); + Set_Enter(kSetPS02, kScenePS02); } return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1877.9f, 16592.0f, -2975.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1877.9f, 16592.0f, -2975.0f, 0, true, false, 0)) { Actor_Set_At_XYZ(kActorMcCoy, 1872.0f, 16592.0f, -2975.0f, 870); - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(180); - Game_Flag_Reset(261); - Game_Flag_Reset(177); - Game_Flag_Reset(258); - int spinnerDest = Spinner_Interface_Choose_Dest(3, 1); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtARxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); + Game_Flag_Reset(kFlagMcCoyAtDRxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + int spinnerDest = Spinner_Interface_Choose_Dest(3, true); switch (spinnerDest) { - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtPS01); - Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtMA01); + Set_Enter(kSetMA01, kSceneMA01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtPS01); - Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtRC01); + Set_Enter(kSetRC01, kSceneRC01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtPS01); Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetCT01_CT12, kSceneCT01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 5: - Game_Flag_Set(261); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtPS01); - Game_Flag_Set(kFlagSpinnerAtTB02); - Set_Enter(17, kSceneTB02); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationTyrellBuilding: + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtPS01); - Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); - Scene_Loop_Start_Special(1, 4, 1); + Game_Flag_Set(kFlagSpinnerAtTB02); + Set_Enter(kSetTB02_TB03, kSceneTB02); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtPS01); Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtPS01); Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetBB01, kSceneBB01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtPS01); Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetNR01, kSceneNR01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; - case 9: - Game_Flag_Set(257); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtPS01); Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); - Scene_Loop_Start_Special(1, 4, 1); + Set_Enter(kSetHF01, kSceneHF01); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 4, true); break; default: Actor_Face_Heading(kActorMcCoy, 870, false); - Game_Flag_Set(178); + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Set(273); Player_Loses_Control(); Scene_Loop_Start_Special(2, 3, 1); diff --git a/engines/bladerunner/script/scene/ps02.cpp b/engines/bladerunner/script/scene/ps02.cpp index e3a908b50f..c577640df1 100644 --- a/engines/bladerunner/script/scene/ps02.cpp +++ b/engines/bladerunner/script/scene/ps02.cpp @@ -54,35 +54,35 @@ bool SceneScriptPS02::ClickedOn3DObject(const char *objectName, bool a2) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Set_Enter(kSetPS01, kScenePS01); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } } else if (Game_Flag_Query(kFlagPS02toPS05)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -5.0f, -40.0f, -15.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Set_Enter(kSetPS05, kScenePS05); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } } else if (Game_Flag_Query(kFlagPS02toPS07)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -5.0f, -40.0f, -15.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Set_Enter(kSetPS07, kScenePS07); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } } else if (Game_Flag_Query(kFlagPS02toPS03)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -5.0f, -40.0f, -15.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Set_Enter(kSetPS03, kScenePS03); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } } else if (Game_Flag_Query(kFlagPS02toPS09)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -5.0f, -40.0f, -15.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(true); Ambient_Sounds_Remove_All_Looping_Sounds(1); Set_Enter(kSetPS09, kScenePS09); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } } } @@ -126,19 +126,19 @@ void SceneScriptPS02::PlayerWalkedIn() { Player_Loses_Control(); if (Game_Flag_Query(kFlagPS02toPS01) ) { Set_Enter(kSetPS01, kScenePS01); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } else if (Game_Flag_Query(kFlagPS02toPS05) ) { Set_Enter(kSetPS05, kScenePS05); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } else if (Game_Flag_Query(kFlagPS02toPS07) ) { Set_Enter(kSetPS07, kScenePS07); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } else if (Game_Flag_Query(kFlagPS02toPS03) ) { Set_Enter(kSetPS03, kScenePS03); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } else if (Game_Flag_Query(kFlagPS02toPS09) ) { Set_Enter(kSetPS09, kScenePS09); - Scene_Loop_Start_Special(1, 3, true); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, true); } //return true; } diff --git a/engines/bladerunner/script/scene/ps04.cpp b/engines/bladerunner/script/scene/ps04.cpp index 394e006575..2d372b0ade 100644 --- a/engines/bladerunner/script/scene/ps04.cpp +++ b/engines/bladerunner/script/scene/ps04.cpp @@ -31,7 +31,7 @@ void SceneScriptPS04::InitializeScene() { } Setup_Scene_Information(-668.0f, -354.0f, 974.0f, 475); if (Global_Variable_Query(kVariableChapter) == 1) { - Actor_Put_In_Set(kActorGuzza, 64); + Actor_Put_In_Set(kActorGuzza, kSetPS04); Actor_Set_At_XYZ(kActorGuzza, -728.0f, -354.0f, 1090.0f, 150); Actor_Change_Animation_Mode(kActorGuzza, 53); } @@ -155,7 +155,9 @@ void SceneScriptPS04::sub_4017E4() { Dialogue_Menu_Disappear(); switch (answer) { case 130: - if (Game_Flag_Query(kFlagZubenRetired) && !Game_Flag_Query(kFlagGuzzaTalkZubenRetired)) { + if ( Game_Flag_Query(kFlagZubenRetired) + && !Game_Flag_Query(kFlagGuzzaTalkZubenRetired) + ) { Actor_Says(kActorMcCoy, 3920, 13); Actor_Says(kActorGuzza, 140, 30); Actor_Face_Current_Camera(kActorGuzza, true); @@ -187,7 +189,9 @@ void SceneScriptPS04::sub_4017E4() { Global_Variable_Increment(kVariableChinyen, 200); } Game_Flag_Set(kFlagZubenBountyPaid); - } else if (Game_Flag_Query(kFlagZubenSpared) && !Game_Flag_Query(kFlagGuzzaTalkZubenEscaped)) { + } else if ( Game_Flag_Query(kFlagZubenSpared) + && !Game_Flag_Query(kFlagGuzzaTalkZubenEscaped) + ) { Actor_Says(kActorMcCoy, 3955, 13); Actor_Says(kActorGuzza, 280, 30); Actor_Says(kActorMcCoy, 3960, 18); @@ -201,9 +205,9 @@ void SceneScriptPS04::sub_4017E4() { ( Actor_Clue_Query(kActorMcCoy, kClueChopstickWrapper) || Actor_Clue_Query(kActorMcCoy, kClueSushiMenu) ) - && Actor_Clue_Query(kActorMcCoy, kClueRunciterInterviewA) - && Actor_Query_Friendliness_To_Other(kActorGuzza, kActorMcCoy) < 50 - && !Game_Flag_Query(161) + && Actor_Clue_Query(kActorMcCoy, kClueRunciterInterviewA) + && Actor_Query_Friendliness_To_Other(kActorGuzza, kActorMcCoy) < 50 + && !Game_Flag_Query(kFlagGuzzaTalk1) ) { Actor_Says(kActorMcCoy, 3970, 18); Actor_Says(kActorGuzza, 330, 30); @@ -218,18 +222,18 @@ void SceneScriptPS04::sub_4017E4() { Actor_Says(kActorMcCoy, 3985, 18); Actor_Says(kActorGuzza, 400, 34); Actor_Says(kActorGuzza, 410, 31); - Game_Flag_Set(161); + Game_Flag_Set(kFlagGuzzaTalk1); } else if ( ( Actor_Clue_Query(kActorMcCoy, kClueChopstickWrapper) || Actor_Clue_Query(kActorMcCoy, kClueSushiMenu) ) - && Actor_Clue_Query(kActorMcCoy, kClueRunciterInterviewA) - && !Game_Flag_Query(162) + && Actor_Clue_Query(kActorMcCoy, kClueRunciterInterviewA) + && !Game_Flag_Query(kFlagGuzzaTalk2) ) { Actor_Says(kActorMcCoy, 3920, 13); Actor_Says(kActorGuzza, 570, 32); Actor_Says(kActorMcCoy, 4070, 13); - Game_Flag_Set(162); + Game_Flag_Set(kFlagGuzzaTalk2); } else if (Actor_Query_Friendliness_To_Other(kActorGuzza, kActorMcCoy) >= 50) { Actor_Says(kActorMcCoy, 4020, 13); Actor_Says(kActorGuzza, 580, 34); diff --git a/engines/bladerunner/script/scene/ps07.cpp b/engines/bladerunner/script/scene/ps07.cpp index b6c6a3a92f..5f11993488 100644 --- a/engines/bladerunner/script/scene/ps07.cpp +++ b/engines/bladerunner/script/scene/ps07.cpp @@ -71,7 +71,7 @@ bool SceneScriptPS07::ClickedOnActor(int actorId) { if (!Game_Flag_Query(kFlagKleinTalkClues)) { Actor_Says(kActorMcCoy, 4115, 13); } - if (!Game_Flag_Query(kFlagKleinTalkClues) && (Game_Flag_Query(kFlagPlayerHasShellCasings) || Game_Flag_Query(kFlagPlayerHasOfficersStatement) || Game_Flag_Query(kFlagPlayerHasPaintTransfer) || Game_Flag_Query(kFlagPlayerHasChromeDebris))) { + if (!Game_Flag_Query(kFlagKleinTalkClues) && (Game_Flag_Query(kFlagMcCoyHasShellCasings) || Game_Flag_Query(kFlagMcCoyHasOfficersStatement) || Game_Flag_Query(kFlagMcCoyHasPaintTransfer) || Game_Flag_Query(kFlagMcCoyHasChromeDebris))) { Actor_Face_Actor(kActorKlein, kActorMcCoy, true); Actor_Says(kActorKlein, 30, 12); Game_Flag_Set(kFlagKleinTalkClues); @@ -80,7 +80,7 @@ bool SceneScriptPS07::ClickedOnActor(int actorId) { Actor_Says(kActorMcCoy, 4130, 18); } } - if (Game_Flag_Query(kFlagPlayerHasShellCasings) && !Game_Flag_Query(kFlagKleinTalkShellCasings)) { + if (Game_Flag_Query(kFlagMcCoyHasShellCasings) && !Game_Flag_Query(kFlagKleinTalkShellCasings)) { Game_Flag_Set(kFlagKleinTalkShellCasings); Actor_Clue_Acquire(kActorMcCoy, kClueLabShellCasings, 0, kActorKlein); Actor_Says(kActorKlein, 50, 16); @@ -93,7 +93,7 @@ bool SceneScriptPS07::ClickedOnActor(int actorId) { Actor_Set_Goal_Number(kActorKlein, 1); return true; } - if (Game_Flag_Query(kFlagPlayerHasOfficersStatement) && !Game_Flag_Query(kFlagKleinTalkOfficersStatement)) { + if (Game_Flag_Query(kFlagMcCoyHasOfficersStatement) && !Game_Flag_Query(kFlagKleinTalkOfficersStatement)) { Game_Flag_Set(kFlagKleinTalkOfficersStatement); Actor_Clue_Acquire(kActorMcCoy, kClueLabCorpses, 0, kActorKlein); Actor_Says(kActorKlein, 100, 13); @@ -113,7 +113,7 @@ bool SceneScriptPS07::ClickedOnActor(int actorId) { Actor_Set_Goal_Number(kActorKlein, 1); return true; } - if (Game_Flag_Query(kFlagPlayerHasPaintTransfer) && !Game_Flag_Query(kFlagKleinTalkPaintTransfer)) { + if (Game_Flag_Query(kFlagMcCoyHasPaintTransfer) && !Game_Flag_Query(kFlagKleinTalkPaintTransfer)) { Game_Flag_Set(kFlagKleinTalkPaintTransfer); Actor_Clue_Acquire(kActorMcCoy, kClueLabPaintTransfer, 0, kActorKlein); Actor_Says(kActorKlein, 170, 14); @@ -127,7 +127,7 @@ bool SceneScriptPS07::ClickedOnActor(int actorId) { Actor_Set_Goal_Number(kActorKlein, 1); return true; } - if (Game_Flag_Query(kFlagPlayerHasChromeDebris) && !Game_Flag_Query(kFlagKleinTalkChromeDebris)) { + if (Game_Flag_Query(kFlagMcCoyHasChromeDebris) && !Game_Flag_Query(kFlagKleinTalkChromeDebris)) { Game_Flag_Set(kFlagKleinTalkChromeDebris); Actor_Says(kActorKlein, 220, 12); Actor_Says(kActorMcCoy, 4190, 13); diff --git a/engines/bladerunner/script/scene/ps09.cpp b/engines/bladerunner/script/scene/ps09.cpp index 946d953d9f..d4888b0ad2 100644 --- a/engines/bladerunner/script/scene/ps09.cpp +++ b/engines/bladerunner/script/scene/ps09.cpp @@ -25,7 +25,7 @@ namespace BladeRunner { void SceneScriptPS09::InitializeScene() { - if (Game_Flag_Query(465)) { + if (Game_Flag_Query(kFlagMcCoyArrested)) { Setup_Scene_Information(-410.0f, 0.26f, -200.0f, 512); } else { Setup_Scene_Information(-559.0f, 0.0f, -85.06f, 250); @@ -38,21 +38,21 @@ void SceneScriptPS09::InitializeScene() { Ambient_Sounds_Add_Sound(125, 15, 60, 7, 10, 100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(126, 25, 60, 7, 10, 100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(127, 25, 60, 7, 10, 100, 100, -101, -101, 0, 0); - if (!Game_Flag_Query(55)) { - Actor_Put_In_Set(kActorGrigorian, 67); + if (!Game_Flag_Query(kFlagGrigorianArrested)) { + Actor_Put_In_Set(kActorGrigorian, kSetPS09); Actor_Set_At_XYZ(kActorGrigorian, -417.88f, 0.0f, -200.74f, 512); - Game_Flag_Set(55); + Game_Flag_Set(kFlagGrigorianArrested); } - if (Game_Flag_Query(465)) { - Actor_Put_In_Set(kActorGrigorian, 94); + if (Game_Flag_Query(kFlagMcCoyArrested)) { + Actor_Put_In_Set(kActorGrigorian, kSetFreeSlotD); Actor_Set_At_XYZ(kActorGrigorian, 0.0f, 0.0f, 0.0f, 512); } - if (Game_Flag_Query(164)) { - Actor_Put_In_Set(kActorIzo, 67); + if (Game_Flag_Query(kFlagIzoArrested)) { + Actor_Put_In_Set(kActorIzo, kSetPS09); Actor_Set_At_XYZ(kActorIzo, -476.0f, 0.2f, -225.0f, 518); } - if (Game_Flag_Query(165)) { - Actor_Put_In_Set(kActorCrazylegs, 67); + if (Game_Flag_Query(kFlagCrazylegsArrested)) { + Actor_Put_In_Set(kActorCrazylegs, kSetPS09); Actor_Set_At_XYZ(kActorCrazylegs, -290.0f, 0.33f, -235.0f, 207); } } @@ -72,98 +72,148 @@ bool SceneScriptPS09::ClickedOn3DObject(const char *objectName, bool a2) { } bool SceneScriptPS09::ClickedOnActor(int actorId) { - if (actorId == 11 && !Loop_Actor_Walk_To_XYZ(kActorMcCoy, -381.11f, 0.0f, -135.55f, 0, 1, false, 0)) { - Actor_Face_Actor(kActorMcCoy, kActorGrigorian, true); - Actor_Face_Actor(kActorGrigorian, kActorMcCoy, true); - if (!Game_Flag_Query(49)) { - Actor_Says(kActorGrigorian, 0, 12); - Actor_Says(kActorMcCoy, 4235, 18); - Actor_Says(kActorGrigorian, 10, 13); - Game_Flag_Set(49); - return true; - } - if (Game_Flag_Query(49) && !Game_Flag_Query(54) && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2)) { - Actor_Says(kActorMcCoy, 4245, 14); - Actor_Says(kActorGrigorian, 20, 14); - Game_Flag_Set(54); - return true; - } - if ((!Game_Flag_Query(53) && Game_Flag_Query(49) && Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA)) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2) || Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote)) { - Game_Flag_Set(53); - Actor_Says(kActorMcCoy, 4240, 13); - Actor_Says(kActorGrigorian, 550, 15); - Actor_Says(kActorGrigorian, 480, 16); - sub_402090(); - return true; - } - if (Game_Flag_Query(51)) { + if (actorId == kActorGrigorian) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -381.11f, 0.0f, -135.55f, 0, true, false, 0)) { + Actor_Face_Actor(kActorMcCoy, kActorGrigorian, true); + Actor_Face_Actor(kActorGrigorian, kActorMcCoy, true); + + if (!Game_Flag_Query(kFlagPS09GrigorianTalk1)) { + Actor_Says(kActorGrigorian, 0, 12); + Actor_Says(kActorMcCoy, 4235, 18); + Actor_Says(kActorGrigorian, 10, 13); + Game_Flag_Set(kFlagPS09GrigorianTalk1); + return true; + } + + if ( Game_Flag_Query(kFlagPS09GrigorianTalk1) + && !Game_Flag_Query(kFlagPS09GrigorianTalk2) + && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) + && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) + && !Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2) + ) { + Actor_Says(kActorMcCoy, 4245, 14); + Actor_Says(kActorGrigorian, 20, 14); + Game_Flag_Set(kFlagPS09GrigorianTalk2); + return true; + } + + if ((!Game_Flag_Query(kFlagPS09GrigorianDialogue) + && Game_Flag_Query(kFlagPS09GrigorianTalk1) + && Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) + ) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2) + || Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote) + ) { + Game_Flag_Set(kFlagPS09GrigorianDialogue); + Actor_Says(kActorMcCoy, 4240, 13); + Actor_Says(kActorGrigorian, 550, 15); + Actor_Says(kActorGrigorian, 480, 16); + dialogueWithGregorian(); + return true; + } + + if (Game_Flag_Query(kFlagGrigorianDislikeMcCoy)) { + Actor_Says(kActorMcCoy, 4270, 18); + Actor_Says(kActorGrigorian, 30, 14); + Actor_Says(kActorGrigorian, 40, 13); + return true; + } + + if (Game_Flag_Query(kFlagPS09GrigorianDialogue) + && Game_Flag_Query(kFlagPS09GrigorianTalk1) + && (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) + || Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote) + ) + ) { + dialogueWithGregorian(); + return true; + } + Actor_Says(kActorMcCoy, 4270, 18); Actor_Says(kActorGrigorian, 30, 14); Actor_Says(kActorGrigorian, 40, 13); return true; } - if (Game_Flag_Query(53) && Game_Flag_Query(49) && (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) || Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote))) { - sub_402090(); - return true; - } - Actor_Says(kActorMcCoy, 4270, 18); - Actor_Says(kActorGrigorian, 30, 14); - Actor_Says(kActorGrigorian, 40, 13); - return true; } - if (actorId == 7 && !Loop_Actor_Walk_To_XYZ(kActorMcCoy, -473.0f, 0.2f, -133.0f, 12, 1, false, 0)) { - Actor_Face_Actor(kActorMcCoy, kActorIzo, true); - Actor_Face_Actor(kActorIzo, kActorMcCoy, true); - if (!Game_Flag_Query(167)) { - Actor_Says(kActorMcCoy, 4200, 14); - Actor_Says(kActorIzo, 570, 3); - Actor_Says(kActorMcCoy, 4205, 18); - Game_Flag_Set(167); - return true; - } - if (Game_Flag_Query(167) && !Game_Flag_Query(168)) { - Actor_Says(kActorMcCoy, 4210, 18); - Actor_Says(kActorIzo, 580, 3); - Actor_Says(kActorMcCoy, 4215, 14); - Actor_Says(kActorIzo, 590, 3); - Actor_Says(kActorIzo, 600, 3); - Actor_Says(kActorMcCoy, 4220, 18); - Actor_Says(kActorIzo, 610, 3); - Actor_Says(kActorMcCoy, 4225, 19); - Actor_Says(kActorIzo, 620, 3); - Actor_Says(kActorMcCoy, 4230, 14); - Game_Flag_Set(168); + + if (actorId == kActorIzo) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -473.0f, 0.2f, -133.0f, 12, true, false, 0)) { + Actor_Face_Actor(kActorMcCoy, kActorIzo, true); + Actor_Face_Actor(kActorIzo, kActorMcCoy, true); + + if (!Game_Flag_Query(kFlagPS09IzoTalk1)) { + Actor_Says(kActorMcCoy, 4200, 14); + Actor_Says(kActorIzo, 570, 3); + Actor_Says(kActorMcCoy, 4205, 18); + Game_Flag_Set(kFlagPS09IzoTalk1); + return true; + } + + if ( Game_Flag_Query(kFlagPS09IzoTalk1) + && !Game_Flag_Query(kFlagPS09IzoTalk2) + ) { + Actor_Says(kActorMcCoy, 4210, 18); + Actor_Says(kActorIzo, 580, 3); + Actor_Says(kActorMcCoy, 4215, 14); + Actor_Says(kActorIzo, 590, 3); + Actor_Says(kActorIzo, 600, 3); + Actor_Says(kActorMcCoy, 4220, 18); + Actor_Says(kActorIzo, 610, 3); + Actor_Says(kActorMcCoy, 4225, 19); + Actor_Says(kActorIzo, 620, 3); + Actor_Says(kActorMcCoy, 4230, 14); + Game_Flag_Set(kFlagPS09IzoTalk2); + return true; + } + + Actor_Says(kActorMcCoy, 4200, 13); return true; } - Actor_Says(kActorMcCoy, 4200, 13); } - if (actorId == 9 && !Loop_Actor_Walk_To_XYZ(kActorMcCoy, -295.0f, 0.34f, -193.0f, 12, 1, false, 0)) { - Actor_Face_Actor(kActorMcCoy, kActorCrazylegs, true); - Actor_Face_Actor(kActorCrazylegs, kActorMcCoy, true); - //TODO: cleanup - if (Game_Flag_Query(166) || (Actor_Says(kActorMcCoy, 4415, 18) , Actor_Says(kActorCrazylegs, 1090, 3) , Actor_Says(kActorMcCoy, 4420, 18) , Game_Flag_Set(166) , Game_Flag_Query(166) != 1) || Game_Flag_Query(55) != 1 || Game_Flag_Query(56)) { - if (!Game_Flag_Query(166) || Game_Flag_Query(55) || Game_Flag_Query(175)) { - Actor_Says(kActorMcCoy, 4425, 18); - Actor_Says(kActorCrazylegs, 1160, 3); + + if (actorId == kActorCrazylegs) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -295.0f, 0.34f, -193.0f, 12, true, false, 0)) { + Actor_Face_Actor(kActorMcCoy, kActorCrazylegs, true); + Actor_Face_Actor(kActorCrazylegs, kActorMcCoy, true); + + if (!Game_Flag_Query(kFlagPS09CrazylegsTalk1)) { + Actor_Says(kActorMcCoy, 4415, 18); + Actor_Says(kActorCrazylegs, 1090, 3); + Actor_Says(kActorMcCoy, 4420, 18); + Game_Flag_Set(kFlagPS09CrazylegsTalk1); + } + + if ( Game_Flag_Query(kFlagPS09CrazylegsTalk1) + && Game_Flag_Query(kFlagGrigorianArrested) + && !Game_Flag_Query(kFlagPS09CrazylegsGrigorianTalk) + ) { + Actor_Face_Actor(kActorGrigorian, kActorCrazylegs, true); + Actor_Says(kActorGrigorian, 420, 14); + Actor_Face_Actor(kActorCrazylegs, kActorGrigorian, true); + Actor_Says(kActorCrazylegs, 1120, 3); + Actor_Face_Actor(kActorMcCoy, kActorGrigorian, true); + Actor_Says(kActorMcCoy, 4435, 14); + Actor_Says(kActorGrigorian, 430, 16); + Actor_Says(kActorCrazylegs, 1130, 3); + Game_Flag_Set(kFlagPS09CrazylegsGrigorianTalk); return true; - } else { + } + + if ( Game_Flag_Query(kFlagPS09CrazylegsTalk1) + && !Game_Flag_Query(kFlagGrigorianArrested) + && !Game_Flag_Query(kFlagPS09CrazylegsTalk2)) { Actor_Says(kActorMcCoy, 4425, 18); Actor_Says(kActorCrazylegs, 1100, 3); Actor_Says(kActorMcCoy, 4430, 19); Actor_Says(kActorCrazylegs, 1110, 3); - Game_Flag_Set(175); + Game_Flag_Set(kFlagPS09CrazylegsTalk2); return true; } - } else { - Actor_Face_Actor(kActorGrigorian, kActorCrazylegs, true); - Actor_Says(kActorGrigorian, 420, 14); - Actor_Face_Actor(kActorCrazylegs, kActorGrigorian, true); - Actor_Says(kActorCrazylegs, 1120, 3); - Actor_Face_Actor(kActorMcCoy, kActorGrigorian, true); - Actor_Says(kActorMcCoy, 4435, 14); - Actor_Says(kActorGrigorian, 430, 16); - Actor_Says(kActorCrazylegs, 1130, 3); - Game_Flag_Set(56); + + Actor_Says(kActorMcCoy, 4425, 18); + Actor_Says(kActorCrazylegs, 1160, 3); return true; } } @@ -179,8 +229,8 @@ bool SceneScriptPS09::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -559.15f, 0.0f, -85.06f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Set_Enter(62, kScenePS02); - Game_Flag_Reset(211); + Set_Enter(kSetPS02, kScenePS02); + Game_Flag_Reset(kFlagPS09Entered); } return true; } @@ -202,18 +252,18 @@ void SceneScriptPS09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptPS09::PlayerWalkedIn() { - if (Game_Flag_Query(465)) { + if (Game_Flag_Query(kFlagMcCoyArrested)) { Player_Loses_Control(); Delay(2000); Actor_Retired_Here(kActorMcCoy, 6, 6, 1, -1); //return true; return; } - if (!Game_Flag_Query(211)) { + if (!Game_Flag_Query(kFlagPS09Entered)) { Player_Loses_Control(); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -491.15f, 0.0f, -73.06f, 0, 0, false, 0); Player_Gains_Control(); - Game_Flag_Set(211); + Game_Flag_Set(kFlagPS09Entered); } if (Game_Flag_Query(kFlagPS02toPS09)) { Game_Flag_Reset(kFlagPS02toPS09); @@ -229,14 +279,22 @@ void SceneScriptPS09::PlayerWalkedOut() { void SceneScriptPS09::DialogueQueueFlushed(int a1) { } -void SceneScriptPS09::sub_402090() { +void SceneScriptPS09::dialogueWithGregorian() { Dialogue_Menu_Clear_List(); - if (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2)) { + if (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2) + ) { DM_Add_To_List_Never_Repeat_Once_Selected(170, 5, 5, 3); DM_Add_To_List_Never_Repeat_Once_Selected(180, -1, 5, 5); DM_Add_To_List_Never_Repeat_Once_Selected(200, -1, 3, 6); } - if (Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote) && (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2))) { + if (Actor_Clue_Query(kActorMcCoy, kClueGrigoriansNote) + && (Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewA) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB1) + || Actor_Clue_Query(kActorMcCoy, kClueGrigorianInterviewB2) + ) + ) { DM_Add_To_List_Never_Repeat_Once_Selected(190, 5, 6, -1); } Dialogue_Menu_Add_To_List(210); @@ -292,7 +350,7 @@ void SceneScriptPS09::sub_402090() { Actor_Says(kActorGrigorian, 290, 15); Actor_Says(kActorMcCoy, 4340, 13); Actor_Modify_Friendliness_To_Other(kActorGrigorian, kActorMcCoy, -5); - if (Game_Flag_Query(165)) { + if (Game_Flag_Query(kFlagCrazylegsArrested)) { Actor_Says(kActorGrigorian, 300, 12); Actor_Face_Actor(kActorCrazylegs, kActorGrigorian, true); Actor_Says(kActorCrazylegs, 1010, 3); diff --git a/engines/bladerunner/script/scene/ps14.cpp b/engines/bladerunner/script/scene/ps14.cpp index 93877ccc6a..e8d3f31c0f 100644 --- a/engines/bladerunner/script/scene/ps14.cpp +++ b/engines/bladerunner/script/scene/ps14.cpp @@ -83,7 +83,7 @@ bool SceneScriptPS14::ClickedOnExit(int exitId) { Loop_Actor_Travel_Stairs(kActorMcCoy, 3, 0, 0); } else { Game_Flag_Set(135); - Set_Enter(63, kScenePS03); + Set_Enter(kSetPS03, kScenePS03); } } return true; @@ -91,9 +91,9 @@ bool SceneScriptPS14::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -785.45f, 508.14f, -1652.0f, 0, 1, false, 0)) { Game_Flag_Set(673); - Game_Flag_Reset(178); - Game_Flag_Set(179); - Set_Enter(53, kSceneMA07); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Set(kFlagMcCoyAtMAxx); + Set_Enter(kSetMA07, kSceneMA07); } return true; } diff --git a/engines/bladerunner/script/scene/ps15.cpp b/engines/bladerunner/script/scene/ps15.cpp index 9aeeb3fc38..e04ff08caf 100644 --- a/engines/bladerunner/script/scene/ps15.cpp +++ b/engines/bladerunner/script/scene/ps15.cpp @@ -36,7 +36,7 @@ void SceneScriptPS15::InitializeScene() { Ambient_Sounds_Add_Sound(158, 5, 20, 30, 30, -70, 70, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(73, 5, 20, 5, 9, -70, 70, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(74, 5, 20, 5, 9, -70, 70, -101, -101, 0, 0); - Actor_Put_In_Set(kActorSergeantWalls, 101); + Actor_Put_In_Set(kActorSergeantWalls, kSetPS15); Actor_Set_At_XYZ(kActorSergeantWalls, -265.4f, -113.43f, -31.29f, 623); } diff --git a/engines/bladerunner/script/scene/rc01.cpp b/engines/bladerunner/script/scene/rc01.cpp index 1239967c53..e535fec8dc 100644 --- a/engines/bladerunner/script/scene/rc01.cpp +++ b/engines/bladerunner/script/scene/rc01.cpp @@ -74,7 +74,7 @@ void SceneScriptRC01::InitializeScene() { // Global_Variable_Set(kVariableChapter, 2); // Chapter_Enter(2, kSetRC03, kSceneRC03); - // Set_Enter(14, 73); + // Set_Enter(kSetPS10_PS11_PS12_PS13, 73); #endif @@ -393,7 +393,7 @@ bool SceneScriptRC01::ClickedOnItem(int itemId, bool a2) { void SceneScriptRC01::walkToCenter() { Player_Loses_Control(); - Game_Flag_Set(182); + Game_Flag_Set(kFlagMcCoyAtRCxx); Actor_Set_Immunity_To_Obstacles(kActorMcCoy, true); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -151.98f, -0.3f, 318.15f, 0, 0, false, 0); Actor_Set_Immunity_To_Obstacles(kActorMcCoy, false); @@ -443,10 +443,10 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } Actor_Set_Immunity_To_Obstacles(kActorMcCoy, false); Player_Gains_Control(); - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); int spinnerDest; if (Game_Flag_Query(kFlagRC01PoliceDone)) { spinnerDest = Spinner_Interface_Choose_Dest(kRC01LoopDoorAnimNoCrowd, true); @@ -456,7 +456,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { switch (spinnerDest) { case kSpinnerDestinationPoliceStation: - Game_Flag_Set(178); + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtPS01); Set_Enter(kSetPS01, kScenePS01); @@ -467,7 +467,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationMcCoysApartment: - Game_Flag_Set(179); + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtMA01); Set_Enter(kSetMA01, kSceneMA01); @@ -478,7 +478,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationChinatown: - Game_Flag_Set(176); + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtCT01); Set_Enter(kSetCT01_CT12, kSceneCT01); @@ -489,7 +489,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationTyrellBuilding: - Game_Flag_Set(261); + Game_Flag_Set(kFlagMcCoyAtTBxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtTB02); Set_Enter(kSetTB02_TB03, kSceneTB02); @@ -500,7 +500,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationAnimoidRow: - Game_Flag_Set(180); + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtAR01); Set_Enter(kSetAR01_AR02, kSceneAR01); @@ -511,7 +511,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationDNARow: - Game_Flag_Set(177); + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtDR01); Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); @@ -522,7 +522,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationBradburyBuilding: - Game_Flag_Set(258); + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtBB01); Set_Enter(kSetBB01, kSceneBB01); @@ -533,7 +533,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationNightclubRow: - Game_Flag_Set(181); + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtNR01); Set_Enter(kSetNR01, kSceneNR01); @@ -544,7 +544,7 @@ bool SceneScriptRC01::ClickedOnExit(int exitId) { } break; case kSpinnerDestinationHysteriaHall: - Game_Flag_Set(257); + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtRC01); Game_Flag_Set(kFlagSpinnerAtHF01); Set_Enter(kSetHF01, kSceneHF01); diff --git a/engines/bladerunner/script/scene/rc02.cpp b/engines/bladerunner/script/scene/rc02.cpp index 5200c1e6ec..4227196873 100644 --- a/engines/bladerunner/script/scene/rc02.cpp +++ b/engines/bladerunner/script/scene/rc02.cpp @@ -270,7 +270,7 @@ bool SceneScriptRC02::ClickedOnActor(int actorId) { } if (Game_Flag_Query(kFlagRC02TalkedToRunciter)) { if (Player_Query_Agenda() == kPlayerAgendaPolite) { - Game_Flag_Reset(0); + Game_Flag_Reset(kFlagNotUsed0); dialogueWithRunciter(); AI_Movement_Track_Unpause(kActorRunciter); return true; diff --git a/engines/bladerunner/script/scene/rc03.cpp b/engines/bladerunner/script/scene/rc03.cpp index 9581f72c42..9578378040 100644 --- a/engines/bladerunner/script/scene/rc03.cpp +++ b/engines/bladerunner/script/scene/rc03.cpp @@ -154,8 +154,8 @@ bool SceneScriptRC03::ClickedOnExit(int exitId) { Game_Flag_Set(702); } Game_Flag_Set(kFlagRC03toAR02); - Game_Flag_Reset(182); - Game_Flag_Set(180); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Set(kFlagMcCoyAtARxx); Set_Enter(kSetAR01_AR02, kSceneAR02); } return true; @@ -163,8 +163,8 @@ bool SceneScriptRC03::ClickedOnExit(int exitId) { if (exitId == 2) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 147.51f, -4.0f, 166.48f, 0, 1, false, 0)) { Game_Flag_Set(kFlagRC03toUG01); - Game_Flag_Reset(182); - Game_Flag_Set(259); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Set(kFlagMcCoyAtUGxx); if (Game_Flag_Query(289)) { Game_Flag_Set(702); } @@ -176,7 +176,7 @@ bool SceneScriptRC03::ClickedOnExit(int exitId) { if (exitId == 3) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -487.0f, 1.0f, 116.0f, 0, 1, false, 0)) { Game_Flag_Set(kFlagRC03toHC04); - Game_Flag_Reset(182); + Game_Flag_Reset(kFlagMcCoyAtRCxx); Game_Flag_Set(479); if (Game_Flag_Query(289)) { Game_Flag_Set(702); @@ -241,7 +241,7 @@ void SceneScriptRC03::PlayerWalkedIn() { Player_Set_Combat_Mode(false); Player_Loses_Control(); Actor_Set_At_XYZ(kActorMcCoy, 147.51f, -4.0f, 166.48f, 500); - Actor_Put_In_Set(kActorIzo, 70); + Actor_Put_In_Set(kActorIzo, kSetRC03); Actor_Set_At_XYZ(kActorIzo, 196.0f, -4.0f, 184.0f, 775); Actor_Face_Actor(kActorIzo, kActorMcCoy, true); Actor_Face_Actor(kActorMcCoy, kActorIzo, true); @@ -260,7 +260,7 @@ void SceneScriptRC03::PlayerWalkedIn() { } Player_Gains_Control(); } else { - Actor_Put_In_Set(kActorIzo, 70); + Actor_Put_In_Set(kActorIzo, kSetRC03); Actor_Set_At_XYZ(kActorIzo, -226.0f, 1.72f, 86.0f, 0); Actor_Set_Targetable(kActorIzo, true); Actor_Set_Goal_Number(kActorIzo, 110); @@ -269,7 +269,7 @@ void SceneScriptRC03::PlayerWalkedIn() { if (Actor_Query_Goal_Number(kActorIzo) == 103) { Player_Loses_Control(); Actor_Set_Goal_Number(kActorSteele, 200); - Actor_Put_In_Set(kActorSteele, 70); + Actor_Put_In_Set(kActorSteele, kSetRC03); if (Game_Flag_Query(kFlagUG01toRC03) || Game_Flag_Query(kFlagRC04toRC03) ) { diff --git a/engines/bladerunner/script/scene/rc04.cpp b/engines/bladerunner/script/scene/rc04.cpp index 6aa15f698e..1c768c58dd 100644 --- a/engines/bladerunner/script/scene/rc04.cpp +++ b/engines/bladerunner/script/scene/rc04.cpp @@ -29,7 +29,7 @@ void SceneScriptRC04::InitializeScene() { Game_Flag_Reset(kFlagRC03toRC04); Scene_Exit_Add_2D_Exit(0, 225, 47, 359, 248, 0); if (!Game_Flag_Query(289)) { - Actor_Put_In_Set(kActorBulletBob, 71); + Actor_Put_In_Set(kActorBulletBob, kSetRC04); Actor_Set_At_XYZ(kActorBulletBob, -60.0f, -11.0f, 62.0f, 12); } if (Game_Flag_Query(289)) { diff --git a/engines/bladerunner/script/scene/tb02.cpp b/engines/bladerunner/script/scene/tb02.cpp index 5e4cf0f0db..04142e8706 100644 --- a/engines/bladerunner/script/scene/tb02.cpp +++ b/engines/bladerunner/script/scene/tb02.cpp @@ -29,7 +29,7 @@ void SceneScriptTB02::InitializeScene() { Setup_Scene_Information(-152.0f, 0.0f, 1774.0f, 999); } else if (Game_Flag_Query(kFlagTB05toTB02)) { Setup_Scene_Information(-32.0f, 0.0f, 1578.0f, 639); - } else if (Game_Flag_Query(608)) { + } else if (Game_Flag_Query(kFlagTB07toTB02)) { Setup_Scene_Information(-32.0f, 0.0f, 1578.0f, 639); } else { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); @@ -72,7 +72,7 @@ void SceneScriptTB02::InitializeScene() { } else { Scene_Loop_Set_Default(1); } - Actor_Put_In_Set(kActorTyrellGuard, 17); + Actor_Put_In_Set(kActorTyrellGuard, kSetTB02_TB03); Actor_Set_At_XYZ(kActorTyrellGuard, -38.53f, 2.93f, 1475.97f, 673); if (Global_Variable_Query(kVariableChapter) == 4) { if (Actor_Query_Goal_Number(kActorTyrellGuard) < 300) { @@ -153,7 +153,7 @@ bool SceneScriptTB02::ClickedOnItem(int itemId, bool a2) { bool SceneScriptTB02::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -152.0f, 0.0f, 1774.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -152.0f, 0.0f, 1774.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(kFlagTB02toTB03); @@ -164,7 +164,7 @@ bool SceneScriptTB02::ClickedOnExit(int exitId) { return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -32.0f, 0.0f, 1578.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -32.0f, 0.0f, 1578.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); if (Global_Variable_Query(kVariableChapter) < 4) { @@ -178,77 +178,77 @@ bool SceneScriptTB02::ClickedOnExit(int exitId) { return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -192.0f, 0.0f, 1430.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -192.0f, 0.0f, 1430.0f, 0, true, false, 0)) { Actor_Face_Heading(kActorMcCoy, 800, false); - Loop_Actor_Travel_Stairs(kActorMcCoy, 9, 0, 0); + Loop_Actor_Travel_Stairs(kActorMcCoy, 9, false, 0); if (Actor_Query_Goal_Number(kActorTyrellGuard) == 300) { Actor_Set_Goal_Number(kActorTyrellGuard, 301); } else { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - Game_Flag_Reset(257); - Game_Flag_Reset(261); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtHFxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); Game_Flag_Reset(450); - switch (Spinner_Interface_Choose_Dest(-1, 0)) { - case 9: - Game_Flag_Set(257); + switch (Spinner_Interface_Choose_Dest(-1, false)) { + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagSpinnerAtPS01); + Set_Enter(kSetPS01, kScenePS01); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); + Game_Flag_Set(kFlagSpinnerAtMA01); + Set_Enter(kSetMA01, kSceneMA01); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); + Game_Flag_Set(kFlagSpinnerAtRC01); + Set_Enter(kSetRC01, kSceneRC01); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); + Game_Flag_Set(kFlagSpinnerAtCT01); + Set_Enter(kSetCT01_CT12, kSceneCT01); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtTB02); Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); + Game_Flag_Set(kFlagSpinnerAtDR01); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); + Game_Flag_Set(kFlagSpinnerAtBB01); + Set_Enter(kSetBB01, kSceneBB01); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); + Game_Flag_Set(kFlagSpinnerAtNR01); + Set_Enter(kSetNR01, kSceneNR01); break; - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); + Game_Flag_Set(kFlagSpinnerAtHF01); + Set_Enter(kSetHF01, kSceneHF01); break; default: - Game_Flag_Set(261); + Game_Flag_Set(kFlagMcCoyAtTBxx); break; } } @@ -269,18 +269,22 @@ void SceneScriptTB02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptTB02::PlayerWalkedIn() { - if (Game_Flag_Query(625) && ((Game_Flag_Reset(625) , Global_Variable_Query(kVariableChapter) == 2) || Global_Variable_Query(kVariableChapter) == 3)) { - Set_Enter(18, kSceneTB07); - //return true; - return; + if (Game_Flag_Query(625)) { + Game_Flag_Reset(625); + if (Global_Variable_Query(kVariableChapter) == 2 + || Global_Variable_Query(kVariableChapter) == 3 + ) { + Set_Enter(kSetTB07, kSceneTB07); + return; // true; + } } if (Game_Flag_Query(kFlagTB03toTB02)) { Async_Actor_Walk_To_XYZ(kActorMcCoy, -152.0f, 0.0f, 1702.0f, 0, false); Game_Flag_Reset(kFlagTB03toTB02); } else if (Game_Flag_Query(kFlagTB05toTB02)) { Game_Flag_Reset(kFlagTB05toTB02); - } else if (Game_Flag_Query(608)) { - Game_Flag_Reset(608); + } else if (Game_Flag_Query(kFlagTB07toTB02)) { + Game_Flag_Reset(kFlagTB07toTB02); if (Actor_Query_Goal_Number(kActorTyrellGuard) == 300) { Actor_Set_Goal_Number(kActorTyrellGuard, 302); } @@ -289,12 +293,12 @@ void SceneScriptTB02::PlayerWalkedIn() { Loop_Actor_Travel_Stairs(kActorMcCoy, 9, 1, 0); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -140.0f, 0.79f, 1470.0f, 0, 0, false, 0); } - int v0 = Global_Variable_Query(kVariableChapter); - if (v0 > 4) { + int chapter = Global_Variable_Query(kVariableChapter); + if (chapter > 4) { //return false; return; } - if (v0 == 2) { + if (chapter == 2) { if (!Game_Flag_Query(453)) { Player_Loses_Control(); Actor_Says(kActorMcCoy, 5125, 18); @@ -339,7 +343,7 @@ void SceneScriptTB02::PlayerWalkedIn() { //return false; return; } - if (v0 == 3 && !Game_Flag_Query(455)) { + if (chapter == 3 && !Game_Flag_Query(455)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -131.28f, 0.79f, 1448.25f, 12, 1, false, 0); Actor_Says(kActorTyrellGuard, 260, 15); Actor_Says(kActorMcCoy, 5225, 16); diff --git a/engines/bladerunner/script/scene/tb03.cpp b/engines/bladerunner/script/scene/tb03.cpp index 611c76e225..babef94e1e 100644 --- a/engines/bladerunner/script/scene/tb03.cpp +++ b/engines/bladerunner/script/scene/tb03.cpp @@ -55,7 +55,7 @@ void SceneScriptTB03::InitializeScene() { Ambient_Sounds_Add_Sound(194, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0); Ambient_Sounds_Add_Sound(195, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0); } - Actor_Put_In_Set(kActorTyrellGuard, 17); + Actor_Put_In_Set(kActorTyrellGuard, kSetTB02_TB03); Actor_Set_At_XYZ(kActorTyrellGuard, -38.53f, 2.93f, 1475.97f, 673); if (Global_Variable_Query(kVariableChapter) == 4) { int goal = Actor_Query_Goal_Number(kActorTyrellGuard); @@ -108,7 +108,7 @@ bool SceneScriptTB03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(447); - Set_Enter(88, kSceneUG17); + Set_Enter(kSetUG17, kSceneUG17); } return true; } diff --git a/engines/bladerunner/script/scene/tb05.cpp b/engines/bladerunner/script/scene/tb05.cpp index 0489b34399..acdca33535 100644 --- a/engines/bladerunner/script/scene/tb05.cpp +++ b/engines/bladerunner/script/scene/tb05.cpp @@ -152,7 +152,7 @@ bool SceneScriptTB05::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 23.0f, 151.53f, -205.0f, 12, 1, false, 0)) { Game_Flag_Set(kFlagTB05toTB06); Set_Enter(kSetTB06, kSceneTB06); - Scene_Loop_Start_Special(1, 2, 1); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 2, 1); } return true; } diff --git a/engines/bladerunner/script/scene/tb06.cpp b/engines/bladerunner/script/scene/tb06.cpp index e69394ccff..acd539b381 100644 --- a/engines/bladerunner/script/scene/tb06.cpp +++ b/engines/bladerunner/script/scene/tb06.cpp @@ -35,7 +35,7 @@ void SceneScriptTB06::InitializeScene() { //return false; return; } else { - Actor_Put_In_Set(kActorMarcus, 73); + Actor_Put_In_Set(kActorMarcus, kSetTB06); Actor_Set_At_XYZ(kActorMarcus, 135.0f, 151.0f, -671.0f, 800); Actor_Retired_Here(kActorMarcus, 60, 32, 1, -1); //return true; @@ -129,7 +129,7 @@ bool SceneScriptTB06::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -16.0f, 149.0f, -427.0f, 12, 1, false, 0)) { Game_Flag_Set(kFlagTB06toTB05); Set_Enter(kSetTB05, kSceneTB05); - Scene_Loop_Start_Special(1, 2, 1); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 2, 1); } return true; } diff --git a/engines/bladerunner/script/scene/tb07.cpp b/engines/bladerunner/script/scene/tb07.cpp index 9f14d4c370..e09b41277f 100644 --- a/engines/bladerunner/script/scene/tb07.cpp +++ b/engines/bladerunner/script/scene/tb07.cpp @@ -65,7 +65,7 @@ bool SceneScriptTB07::ClickedOnActor(int actorId) { } bool SceneScriptTB07::ClickedOnItem(int itemId, bool a2) { - if (!Loop_Actor_Walk_To_Item(kActorMcCoy, itemId, 36, 1, false)) { + if (!Loop_Actor_Walk_To_Item(kActorMcCoy, itemId, 36, true, false)) { Actor_Face_Item(kActorMcCoy, itemId, true); if (itemId == 83) { Item_Pickup_Spin_Effect(941, 331, 296); @@ -78,79 +78,79 @@ bool SceneScriptTB07::ClickedOnItem(int itemId, bool a2) { bool SceneScriptTB07::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 68.0f, 12.0f, 288.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 68.0f, 12.0f, 288.0f, 0, true, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); if (Global_Variable_Query(kVariableChapter) == 4) { - Game_Flag_Set(608); - Set_Enter(17, kSceneTB02); + Game_Flag_Set(kFlagTB07toTB02); + Set_Enter(kSetTB02_TB03, kSceneTB02); } else { - Game_Flag_Reset(176); - Game_Flag_Reset(182); - Game_Flag_Reset(179); - Game_Flag_Reset(178); - Game_Flag_Reset(258); - Game_Flag_Reset(257); - Game_Flag_Reset(261); + Game_Flag_Reset(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtRCxx); + Game_Flag_Reset(kFlagMcCoyAtMAxx); + Game_Flag_Reset(kFlagMcCoyAtPSxx); + Game_Flag_Reset(kFlagMcCoyAtBBxx); + Game_Flag_Reset(kFlagMcCoyAtHFxx); + Game_Flag_Reset(kFlagMcCoyAtTBxx); Game_Flag_Reset(450); - switch (Spinner_Interface_Choose_Dest(-1, 0)) { - case 9: - Game_Flag_Set(257); + switch (Spinner_Interface_Choose_Dest(-1, false)) { + case kSpinnerDestinationPoliceStation: + Game_Flag_Set(kFlagMcCoyAtPSxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtHF01); - Set_Enter(37, kSceneHF01); + Game_Flag_Set(kFlagSpinnerAtPS01); + Set_Enter(kSetPS01, kScenePS01); break; - case 8: - Game_Flag_Set(181); + case kSpinnerDestinationMcCoysApartment: + Game_Flag_Set(kFlagMcCoyAtMAxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtNR01); - Set_Enter(54, kSceneNR01); + Game_Flag_Set(kFlagSpinnerAtMA01); + Set_Enter(kSetMA01, kSceneMA01); break; - case 7: - Game_Flag_Set(258); + case kSpinnerDestinationRuncitersAnimals: + Game_Flag_Set(kFlagMcCoyAtRCxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtBB01); - Set_Enter(20, kSceneBB01); + Game_Flag_Set(kFlagSpinnerAtRC01); + Set_Enter(kSetRC01, kSceneRC01); break; - case 6: - Game_Flag_Set(177); + case kSpinnerDestinationChinatown: + Game_Flag_Set(kFlagMcCoyAtCTxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtDR01); - Set_Enter(7, kSceneDR01); + Game_Flag_Set(kFlagSpinnerAtCT01); + Set_Enter(kSetCT01_CT12, kSceneCT01); break; - case 4: - Game_Flag_Set(180); + case kSpinnerDestinationAnimoidRow: + Game_Flag_Set(kFlagMcCoyAtARxx); Game_Flag_Reset(kFlagSpinnerAtTB02); Game_Flag_Set(kFlagSpinnerAtAR01); - Set_Enter(0, kSceneAR01); + Set_Enter(kSetAR01_AR02, kSceneAR01); break; - case 3: - Game_Flag_Set(176); + case kSpinnerDestinationDNARow: + Game_Flag_Set(kFlagMcCoyAtDRxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtCT01); - Set_Enter(4, kSceneCT01); + Game_Flag_Set(kFlagSpinnerAtDR01); + Set_Enter(kSetDR01_DR02_DR04, kSceneDR01); break; - case 2: - Game_Flag_Set(182); + case kSpinnerDestinationBradburyBuilding: + Game_Flag_Set(kFlagMcCoyAtBBxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtRC01); - Set_Enter(69, kSceneRC01); + Game_Flag_Set(kFlagSpinnerAtBB01); + Set_Enter(kSetBB01, kSceneBB01); break; - case 1: - Game_Flag_Set(179); + case kSpinnerDestinationNightclubRow: + Game_Flag_Set(kFlagMcCoyAtNRxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtMA01); - Set_Enter(49, kSceneMA01); + Game_Flag_Set(kFlagSpinnerAtNR01); + Set_Enter(kSetNR01, kSceneNR01); break; - case 0: - Game_Flag_Set(178); + case kSpinnerDestinationHysteriaHall: + Game_Flag_Set(kFlagMcCoyAtHFxx); Game_Flag_Reset(kFlagSpinnerAtTB02); - Game_Flag_Set(kFlagSpinnerAtPS01); - Set_Enter(61, kScenePS01); + Game_Flag_Set(kFlagSpinnerAtHF01); + Set_Enter(kSetHF01, kSceneHF01); break; default: - Game_Flag_Set(261); - Loop_Actor_Walk_To_XYZ(kActorMcCoy, 44.0f, 12.0f, 176.0f, 0, 0, false, 0); + Game_Flag_Set(kFlagMcCoyAtTBxx); + Loop_Actor_Walk_To_XYZ(kActorMcCoy, 44.0f, 12.0f, 176.0f, 0, false, false, 0); break; } } @@ -195,7 +195,7 @@ void SceneScriptTB07::sub_401B0C() { Loop_Actor_Walk_To_XYZ(kActorMcCoy, 44.98f, 12.0f, 49.79f, 0, 0, false, 0); Actor_Face_Heading(kActorMcCoy, 178, true); Delay(3000); - Actor_Put_In_Set(kActorRachael, 18); + Actor_Put_In_Set(kActorRachael, kSetTB07); Actor_Set_At_XYZ(kActorRachael, -260.15f, 12.0f, -19.16f, 256); Actor_Change_Animation_Mode(kActorRachael, 0); Outtake_Play(kOuttakeRachel, true, -1); @@ -250,7 +250,7 @@ void SceneScriptTB07::sub_401B0C() { Actor_Says_With_Pause(kActorMcCoy, 5415, 1.0f, 17); Actor_Says(kActorMcCoy, 5420, 14); Actor_Says(kActorRachael, 660, 15); - Actor_Put_In_Set(kActorTyrell, 18); + Actor_Put_In_Set(kActorTyrell, kSetTB07); Actor_Set_At_XYZ(kActorTyrell, 68.0f, 12.0f, 288.0f, 0); Actor_Change_Animation_Mode(kActorTyrell, 0); Scene_Loop_Set_Default(3); diff --git a/engines/bladerunner/script/scene/ug01.cpp b/engines/bladerunner/script/scene/ug01.cpp index 820821c696..71227df96e 100644 --- a/engines/bladerunner/script/scene/ug01.cpp +++ b/engines/bladerunner/script/scene/ug01.cpp @@ -25,9 +25,9 @@ namespace BladeRunner { void SceneScriptUG01::InitializeScene() { - if (Game_Flag_Query(317)) { + if (Game_Flag_Query(kFlagUG10toUG01)) { Setup_Scene_Information(34.47f, -50.13f, -924.11f, 500); - Game_Flag_Reset(317); + Game_Flag_Reset(kFlagUG10toUG01); } else if (Game_Flag_Query(kFlagRC03toUG01)) { Setup_Scene_Information(-68.0f, -50.13f, -504.0f, 377); } else { @@ -99,26 +99,26 @@ bool SceneScriptUG01::ClickedOnItem(int itemId, bool a2) { bool SceneScriptUG01::ClickedOnExit(int exitId) { if (exitId == 0) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -32.0f, -50.13f, -1350.0f, 12, 1, false, 0)) { - Game_Flag_Set(316); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -32.0f, -50.13f, -1350.0f, 12, true, false, 0)) { + Game_Flag_Set(kFlagUG01toUG10); Set_Enter(kSetUG10, kSceneUG10); } return true; } if (exitId == 1) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -70.0f, -50.13f, -500.0f, 0, 1, false, 0)) { + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -70.0f, -50.13f, -500.0f, 0, true, false, 0)) { Actor_Face_Heading(kActorMcCoy, 768, false); - Loop_Actor_Travel_Ladder(kActorMcCoy, 12, 1, 0); + Loop_Actor_Travel_Ladder(kActorMcCoy, 12, true, 0); Game_Flag_Set(kFlagUG01toRC03); - Game_Flag_Reset(259); - Game_Flag_Set(182); + Game_Flag_Reset(kFlagMcCoyAtUGxx); + Game_Flag_Set(kFlagMcCoyAtRCxx); Set_Enter(kSetRC03, kSceneRC03); } return true; } if (exitId == 2) { - if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -126.0f, -50.13f, -286.0f, 0, 1, false, 0)) { - Game_Flag_Set(314); + if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -126.0f, -50.13f, -286.0f, 0, true, false, 0)) { + Game_Flag_Set(kFlagUG01toUG02); Set_Enter(kSetUG02, kSceneUG02); } return true; @@ -150,9 +150,9 @@ void SceneScriptUG01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptUG01::PlayerWalkedIn() { - if (Game_Flag_Query(315)) { + if (Game_Flag_Query(kFlagUG02toUG01)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -55.0f, -50.13f, -288.0f, 12, 0, false, 0); - Game_Flag_Reset(315); + Game_Flag_Reset(kFlagUG02toUG01); } if (Game_Flag_Query(kFlagRC03toUG01)) { Actor_Set_At_XYZ(kActorMcCoy, -70.0f, 93.87f, -500.0f, 768); diff --git a/engines/bladerunner/script/scene/ug02.cpp b/engines/bladerunner/script/scene/ug02.cpp index f8f1e84578..600279170f 100644 --- a/engines/bladerunner/script/scene/ug02.cpp +++ b/engines/bladerunner/script/scene/ug02.cpp @@ -25,7 +25,7 @@ namespace BladeRunner { void SceneScriptUG02::InitializeScene() { - if (Game_Flag_Query(319)) { + if (Game_Flag_Query(kFlagHC03toUG02)) { Setup_Scene_Information(-313.0f, 155.73f, -128.0f, 556); } else { Setup_Scene_Information(-95.0f, 74.78f, -503.0f, 556); @@ -156,8 +156,8 @@ bool SceneScriptUG02::ClickedOnExit(int exitId) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -96.57f, 74.87f, -271.28f, 0, 0, v3, 0); int v4 = Player_Query_Combat_Mode(); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -95.0f, 74.87f, -503.0f, 0, 0, v4, 0); - Game_Flag_Set(315); - Set_Enter(74, kSceneUG01); + Game_Flag_Set(kFlagUG02toUG01); + Set_Enter(kSetUG01, kSceneUG01); } } return true; @@ -173,15 +173,15 @@ bool SceneScriptUG02::ClickedOnExit(int exitId) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -304.75f, 155.75f, -171.0f, 0, 0, false, 0); Actor_Face_Heading(kActorMcCoy, 14, false); Loop_Actor_Travel_Ladder(kActorMcCoy, 9, 1, 0); - Game_Flag_Set(318); - Game_Flag_Reset(259); + Game_Flag_Set(kFlagUG02toHC03); + Game_Flag_Reset(kFlagMcCoyAtUGxx); Game_Flag_Set(479); if (!Game_Flag_Query(403)) { Game_Flag_Set(388); Game_Flag_Set(403); Item_Remove_From_World(121); } - Set_Enter(8, kSceneHC03); + Set_Enter(kSetHC01_HC02_HC03_HC04, kSceneHC03); return true; } return false; @@ -199,19 +199,19 @@ void SceneScriptUG02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bo } void SceneScriptUG02::PlayerWalkedIn() { - if (Game_Flag_Query(314)) { + if (Game_Flag_Query(kFlagUG01toUG02)) { Actor_Set_At_XYZ(kActorMcCoy, -106.01f, 84.13f, -228.62f, 575); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -148.0f, 84.13f, -67.0f, 0, 0, false, 0); Actor_Face_Heading(kActorMcCoy, 761, false); Footstep_Sound_Override_On(2); - Loop_Actor_Travel_Stairs(kActorMcCoy, 4, 1, 0); + Loop_Actor_Travel_Stairs(kActorMcCoy, 4, true, 0); Footstep_Sound_Override_Off(); - Game_Flag_Reset(314); + Game_Flag_Reset(kFlagUG01toUG02); Game_Flag_Set(498); - } else if (Game_Flag_Query(319)) { + } else if (Game_Flag_Query(kFlagHC03toUG02)) { Actor_Set_At_XYZ(kActorMcCoy, -304.75f, 265.0f, -171.0f, 0); - Loop_Actor_Travel_Ladder(kActorMcCoy, 9, 0, 0); - Game_Flag_Reset(319); + Loop_Actor_Travel_Ladder(kActorMcCoy, 9, false, 0); + Game_Flag_Reset(kFlagHC03toUG02); Game_Flag_Reset(498); } else { Actor_Set_At_XYZ(kActorMcCoy, -269.24f, 120.16f, -9.94f, 477); diff --git a/engines/bladerunner/script/scene/ug03.cpp b/engines/bladerunner/script/scene/ug03.cpp index 88ea49695c..01d6848ba5 100644 --- a/engines/bladerunner/script/scene/ug03.cpp +++ b/engines/bladerunner/script/scene/ug03.cpp @@ -106,7 +106,7 @@ bool SceneScriptUG03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(336); - Set_Enter(83, kSceneUG10); + Set_Enter(kSetUG10, kSceneUG10); } } return true; @@ -116,7 +116,7 @@ bool SceneScriptUG03::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(334); - Set_Enter(77, kSceneUG04); + Set_Enter(kSetUG04, kSceneUG04); } return true; } diff --git a/engines/bladerunner/script/scene/ug04.cpp b/engines/bladerunner/script/scene/ug04.cpp index b747c2fde3..497b3d6b3d 100644 --- a/engines/bladerunner/script/scene/ug04.cpp +++ b/engines/bladerunner/script/scene/ug04.cpp @@ -88,21 +88,21 @@ bool SceneScriptUG04::ClickedOnExit(int exitId) { if (exitId == 0) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -172.0f, 16.29f, -735.0f, 0, 1, false, 0)) { Game_Flag_Set(335); - Set_Enter(76, kSceneUG03); + Set_Enter(kSetUG03, kSceneUG03); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 0.0f, -1.74f, -2400.0f, 0, 1, false, 0)) { Game_Flag_Set(338); - Set_Enter(78, kSceneUG05); + Set_Enter(kSetUG05, kSceneUG05); } return true; } if (exitId == 2) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 164.0f, 11.87f, -1013.0f, 0, 1, false, 0)) { Game_Flag_Set(340); - Set_Enter(79, kSceneUG06); + Set_Enter(kSetUG06, kSceneUG06); } return true; } diff --git a/engines/bladerunner/script/scene/ug05.cpp b/engines/bladerunner/script/scene/ug05.cpp index 3348ebbfb6..73101f29bb 100644 --- a/engines/bladerunner/script/scene/ug05.cpp +++ b/engines/bladerunner/script/scene/ug05.cpp @@ -116,19 +116,19 @@ bool SceneScriptUG05::ClickedOnExit(int exitId) { if (Game_Flag_Query(663) && !Game_Flag_Query(368)) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -356.35f, 132.77f, -1092.36f, 0, 0, false, 0); Game_Flag_Set(361); - Set_Enter(43, kSceneHF07); + Set_Enter(kSetHF07, kSceneHF07); } else if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -156.72f, 3.03f, -1118.17f, 0, 1, false, 0)) { Actor_Face_Heading(kActorMcCoy, 760, false); Loop_Actor_Travel_Stairs(kActorMcCoy, 3, 1, 0); Game_Flag_Set(361); - Set_Enter(43, kSceneHF07); + Set_Enter(kSetHF07, kSceneHF07); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 4.0f, -11.67f, -4.0f, 0, 1, false, 0)) { Game_Flag_Set(339); - Set_Enter(77, kSceneUG04); + Set_Enter(kSetUG04, kSceneUG04); } return true; } @@ -173,29 +173,29 @@ void SceneScriptUG05::PlayerWalkedIn() { if (Game_Flag_Query(663)) { if (Game_Flag_Query(368)) { Music_Stop(2); - Actor_Put_In_Set(kActorOfficerGrayford, 78); + Actor_Put_In_Set(kActorOfficerGrayford, kSetUG05); Actor_Set_At_XYZ(kActorOfficerGrayford, 4.22f, -1.37f, -925.0f, 750); Actor_Set_Goal_Number(kActorOfficerGrayford, 599); Actor_Retired_Here(kActorOfficerGrayford, 70, 36, 1, -1); int v0 = sub_4021B0(); if (v0 == kActorDektora) { - Actor_Put_In_Set(kActorDektora, 78); + Actor_Put_In_Set(kActorDektora, kSetUG05); Actor_Set_At_XYZ(kActorDektora, -100.0f, -10.31f, -906.0f, 866); Actor_Force_Stop_Walking(kActorDektora); } else if (v0 == kActorLucy){ - Actor_Put_In_Set(kActorLucy, 78); + Actor_Put_In_Set(kActorLucy, kSetUG05); Actor_Set_At_XYZ(kActorLucy, -100.0f, -10.31f, -906.0f, 866); Actor_Force_Stop_Walking(kActorLucy); } } else { - if (!Actor_Query_In_Set(kActorOfficerLeary, 78)) { - Actor_Put_In_Set(kActorOfficerLeary, 78); + if (!Actor_Query_In_Set(kActorOfficerLeary, kSetUG05)) { + Actor_Put_In_Set(kActorOfficerLeary, kSetUG05); Actor_Set_At_XYZ(kActorOfficerLeary, 0.0f, -1.37f, -1400.0f, 768); } - if (!Actor_Query_In_Set(kActorOfficerGrayford, 78)) { + if (!Actor_Query_In_Set(kActorOfficerGrayford, kSetUG05)) { ADQ_Flush(); ADQ_Add(kActorOfficerGrayford, 280, 3); - Actor_Put_In_Set(kActorOfficerGrayford, 78); + Actor_Put_In_Set(kActorOfficerGrayford, kSetUG05); Actor_Set_At_XYZ(kActorOfficerGrayford, -16.0f, -1.37f, -960.0f, 768); } } diff --git a/engines/bladerunner/script/scene/ug06.cpp b/engines/bladerunner/script/scene/ug06.cpp index e17aa542f7..1f0124d6ad 100644 --- a/engines/bladerunner/script/scene/ug06.cpp +++ b/engines/bladerunner/script/scene/ug06.cpp @@ -95,7 +95,7 @@ bool SceneScriptUG06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(341); - Set_Enter(77, kSceneUG04); + Set_Enter(kSetUG04, kSceneUG04); } return true; } @@ -107,7 +107,7 @@ bool SceneScriptUG06::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(342); - Set_Enter(54, kSceneNR01); + Set_Enter(kSetNR01, kSceneNR01); } return true; } diff --git a/engines/bladerunner/script/scene/ug07.cpp b/engines/bladerunner/script/scene/ug07.cpp index 4a256b02c7..6880d2008a 100644 --- a/engines/bladerunner/script/scene/ug07.cpp +++ b/engines/bladerunner/script/scene/ug07.cpp @@ -98,7 +98,7 @@ bool SceneScriptUG07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(427); - Set_Enter(82, kSceneUG09); + Set_Enter(kSetUG09, kSceneUG09); return true; } } @@ -107,7 +107,7 @@ bool SceneScriptUG07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(425); - Set_Enter(81, kSceneUG08); + Set_Enter(kSetUG08, kSceneUG08); return true; } } @@ -115,7 +115,7 @@ bool SceneScriptUG07::ClickedOnExit(int exitId) { if (!Game_Flag_Query(607) && Game_Flag_Query(671) && Global_Variable_Query(kVariableChapter) == 4 && !Game_Flag_Query(598)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 49.0f, -12.21f, -130.0f, 0, 1, false, 0)) { Game_Flag_Set(598); - Actor_Put_In_Set(kActorClovis, 80); + Actor_Put_In_Set(kActorClovis, kSetUG07); Actor_Set_At_XYZ(kActorClovis, 118.02f, -12.21f, -154.0f, 768); Player_Set_Combat_Mode(true); Actor_Face_Actor(kActorMcCoy, kActorClovis, true); @@ -146,7 +146,7 @@ bool SceneScriptUG07::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(423); - Set_Enter(83, kSceneUG10); + Set_Enter(kSetUG10, kSceneUG10); return true; } } @@ -182,7 +182,7 @@ void SceneScriptUG07::PlayerWalkedOut() { Actor_Set_Goal_Number(kActorOfficerLeary, 306); Actor_Set_Goal_Number(kActorOfficerGrayford, 306); } - if (Actor_Query_In_Set(kActorClovis, 80)) { + if (Actor_Query_In_Set(kActorClovis, kSetUG07)) { Actor_Set_Goal_Number(kActorClovis, 400); } } diff --git a/engines/bladerunner/script/scene/ug08.cpp b/engines/bladerunner/script/scene/ug08.cpp index c346ac9a67..9b4306e980 100644 --- a/engines/bladerunner/script/scene/ug08.cpp +++ b/engines/bladerunner/script/scene/ug08.cpp @@ -89,7 +89,7 @@ bool SceneScriptUG08::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(426); - Set_Enter(80, kSceneUG07); + Set_Enter(kSetUG07, kSceneUG07); } } else if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -312.0f, -2.0f, 152.0f, 0, 1, false, 0)) { @@ -102,8 +102,8 @@ bool SceneScriptUG08::ClickedOnExit(int exitId) { Actor_Set_Invisible(kActorMcCoy, true); Game_Flag_Set(429); Game_Flag_Reset(431); - Set_Enter(85, kSceneUG13); - Scene_Loop_Start_Special(1, 3, 0); + Set_Enter(kSetUG13, kSceneUG13); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, 0); } } return false; diff --git a/engines/bladerunner/script/scene/ug09.cpp b/engines/bladerunner/script/scene/ug09.cpp index c3595cecae..f238161a4b 100644 --- a/engines/bladerunner/script/scene/ug09.cpp +++ b/engines/bladerunner/script/scene/ug09.cpp @@ -103,8 +103,8 @@ bool SceneScriptUG09::ClickedOnExit(int exitId) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, -67.0f, 156.94f, -425.0f, 0, 1, false, 0)) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); - Game_Flag_Set(432); - Set_Enter(4, kSceneCT12); + Game_Flag_Set(kFlagUG09toCT12); + Set_Enter(kSetCT01_CT12, kSceneCT12); } return true; } @@ -113,7 +113,7 @@ bool SceneScriptUG09::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(428); - Set_Enter(80, kSceneUG07); + Set_Enter(kSetUG07, kSceneUG07); } return true; } @@ -138,12 +138,15 @@ void SceneScriptUG09::PlayerWalkedIn() { } void SceneScriptUG09::PlayerWalkedOut() { - if (Global_Variable_Query(kVariableChapter) == 4 && Global_Variable_Query(kVariableChapter) != 5) { + if (Global_Variable_Query(kVariableChapter) == 4 + && Global_Variable_Query(kVariableChapter) != 5 + ) { Game_Flag_Reset(630); } - if (Game_Flag_Query(432)) { - Game_Flag_Set(176); - Game_Flag_Reset(259); + + if (Game_Flag_Query(kFlagUG09toCT12)) { + Game_Flag_Set(kFlagMcCoyAtCTxx); + Game_Flag_Reset(kFlagMcCoyAtUGxx); } } diff --git a/engines/bladerunner/script/scene/ug10.cpp b/engines/bladerunner/script/scene/ug10.cpp index 9239881bb2..98629b194f 100644 --- a/engines/bladerunner/script/scene/ug10.cpp +++ b/engines/bladerunner/script/scene/ug10.cpp @@ -103,8 +103,8 @@ bool SceneScriptUG10::ClickedOnExit(int exitId) { if (exitId == 0) { if ((!Game_Flag_Query(474) && x > 125.0f) || Game_Flag_Query(474)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 235.0f, 1.15f, 29.0f, 0, 1, false, 0)) { - Game_Flag_Set(317); - Set_Enter(74, kSceneUG01); + Game_Flag_Set(kFlagUG10toUG01); + Set_Enter(kSetUG01, kSceneUG01); return true; } } else if (!Game_Flag_Query(474)) { @@ -117,7 +117,7 @@ bool SceneScriptUG10::ClickedOnExit(int exitId) { Loop_Actor_Travel_Stairs(kActorMcCoy, 9, 1, 0); Loop_Actor_Walk_To_XYZ(kActorMcCoy, -92.0f, 81.83f, -652.0f, 0, 0, false, 0); Game_Flag_Set(337); - Set_Enter(76, kSceneUG03); + Set_Enter(kSetUG03, kSceneUG03); return true; } } else if (!Game_Flag_Query(474)) { @@ -129,7 +129,7 @@ bool SceneScriptUG10::ClickedOnExit(int exitId) { Actor_Face_Heading(kActorMcCoy, 1001, false); Loop_Actor_Travel_Ladder(kActorMcCoy, 1, 1, 0); Game_Flag_Set(424); - Set_Enter(80, kSceneUG07); + Set_Enter(kSetUG07, kSceneUG07); return true; } } else if (!Game_Flag_Query(474)) { @@ -139,7 +139,7 @@ bool SceneScriptUG10::ClickedOnExit(int exitId) { if ((!Game_Flag_Query(474) && x < 120.0f) || Game_Flag_Query(474)) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 2.5f, 1.15f, 405.0f, 0, 1, false, 0)) { Game_Flag_Set(347); - Set_Enter(86, kSceneUG14); + Set_Enter(kSetUG14, kSceneUG14); return true; } } else if (!Game_Flag_Query(474)) { @@ -207,8 +207,8 @@ void SceneScriptUG10::PlayerWalkedIn() { if (Game_Flag_Query(346)) { Game_Flag_Reset(346); Loop_Actor_Walk_To_XYZ(kActorMcCoy, 2.5f, 1.15f, 377.0f, 0, 0, false, 0); - } else if (Game_Flag_Query(316)) { - Game_Flag_Reset(316); + } else if (Game_Flag_Query(kFlagUG01toUG10)) { + Game_Flag_Reset(kFlagUG01toUG10); Loop_Actor_Walk_To_XYZ(kActorMcCoy, 207.0f, 1.15f, 29.0f, 0, 0, false, 0); } else if (Game_Flag_Query(336)) { Game_Flag_Reset(336); diff --git a/engines/bladerunner/script/scene/ug12.cpp b/engines/bladerunner/script/scene/ug12.cpp index 7b696c6938..90f72d52bd 100644 --- a/engines/bladerunner/script/scene/ug12.cpp +++ b/engines/bladerunner/script/scene/ug12.cpp @@ -84,7 +84,7 @@ bool SceneScriptUG12::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(344); - Set_Enter(86, kSceneUG14); + Set_Enter(kSetUG14, kSceneUG14); } return true; } @@ -93,7 +93,7 @@ bool SceneScriptUG12::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(412); - Set_Enter(45, kSceneKP02); + Set_Enter(kSetKP02, kSceneKP02); } return true; } diff --git a/engines/bladerunner/script/scene/ug13.cpp b/engines/bladerunner/script/scene/ug13.cpp index 3a0fd02425..9520fbace5 100644 --- a/engines/bladerunner/script/scene/ug13.cpp +++ b/engines/bladerunner/script/scene/ug13.cpp @@ -156,15 +156,15 @@ bool SceneScriptUG13::ClickedOnExit(int exitId) { Player_Loses_Control(); Game_Flag_Set(430); Game_Flag_Set(431); - Set_Enter(81, kSceneUG08); - Scene_Loop_Start_Special(1, 3, 0); + Set_Enter(kSetUG08, kSceneUG08); + Scene_Loop_Start_Special(kSceneLoopModeChangeSet, 3, 0); } return true; } if (exitId == 1) { if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 39.0f, 52.94f, -528.0f, 0, 1, false, 0)) { Game_Flag_Set(351); - Set_Enter(87, kSceneUG15); + Set_Enter(kSetUG15, kSceneUG15); } return true; } @@ -177,7 +177,7 @@ bool SceneScriptUG13::ClickedOnExit(int exitId) { if (!sub_402AD0()) { Loop_Actor_Walk_To_XYZ(kActorMcCoy, -477.0f, 141.9f, -870.0f, 0, 0, false, 0); Game_Flag_Set(434); - Set_Enter(89, kSceneUG18); + Set_Enter(kSetUG18, kSceneUG18); return true; } Actor_Face_Heading(kActorMcCoy, 325, false); diff --git a/engines/bladerunner/script/scene/ug14.cpp b/engines/bladerunner/script/scene/ug14.cpp index bb25791992..3fe534089d 100644 --- a/engines/bladerunner/script/scene/ug14.cpp +++ b/engines/bladerunner/script/scene/ug14.cpp @@ -96,7 +96,7 @@ bool SceneScriptUG14::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(348); - Set_Enter(90, kSceneUG19); + Set_Enter(kSetUG19, kSceneUG19); } return true; } @@ -114,7 +114,7 @@ bool SceneScriptUG14::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(345); - Set_Enter(6, kSceneUG12); + Set_Enter(kSetCT08_CT51_UG12, kSceneUG12); } return true; } @@ -137,7 +137,7 @@ bool SceneScriptUG14::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(346); - Set_Enter(83, kSceneUG10); + Set_Enter(kSetUG10, kSceneUG10); } return true; } diff --git a/engines/bladerunner/script/scene/ug15.cpp b/engines/bladerunner/script/scene/ug15.cpp index 09153094da..231c1a3e42 100644 --- a/engines/bladerunner/script/scene/ug15.cpp +++ b/engines/bladerunner/script/scene/ug15.cpp @@ -108,7 +108,7 @@ bool SceneScriptUG15::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(352); - Set_Enter(88, kSceneUG17); + Set_Enter(kSetUG17, kSceneUG17); } return true; } @@ -129,7 +129,7 @@ bool SceneScriptUG15::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(354); - Set_Enter(19, kSceneUG16); + Set_Enter(kSetUG16, kSceneUG16); } return true; } @@ -138,7 +138,7 @@ bool SceneScriptUG15::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(350); - Set_Enter(85, kSceneUG13); + Set_Enter(kSetUG13, kSceneUG13); } return true; } diff --git a/engines/bladerunner/script/scene/ug16.cpp b/engines/bladerunner/script/scene/ug16.cpp index 70a892c0b4..8f9fc01e5b 100644 --- a/engines/bladerunner/script/scene/ug16.cpp +++ b/engines/bladerunner/script/scene/ug16.cpp @@ -153,7 +153,7 @@ bool SceneScriptUG16::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(551); - Set_Enter(36, kSceneDR06); + Set_Enter(kSetDR06, kSceneDR06); } return true; } diff --git a/engines/bladerunner/script/scene/ug17.cpp b/engines/bladerunner/script/scene/ug17.cpp index 2889cac6a9..e05648f3f0 100644 --- a/engines/bladerunner/script/scene/ug17.cpp +++ b/engines/bladerunner/script/scene/ug17.cpp @@ -68,7 +68,7 @@ bool SceneScriptUG17::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(353); - Set_Enter(87, kSceneUG15); + Set_Enter(kSetUG15, kSceneUG15); } return true; } @@ -82,7 +82,7 @@ bool SceneScriptUG17::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(448); - Set_Enter(17, kSceneTB03); + Set_Enter(kSetTB02_TB03, kSceneTB03); } } return true; diff --git a/engines/bladerunner/script/scene/ug18.cpp b/engines/bladerunner/script/scene/ug18.cpp index 38ea0896aa..60d9210bd1 100644 --- a/engines/bladerunner/script/scene/ug18.cpp +++ b/engines/bladerunner/script/scene/ug18.cpp @@ -70,10 +70,10 @@ void SceneScriptUG18::SceneLoaded() { Clickable_Object("MACHINE_01"); Unclickable_Object("MACHINE_01"); if (Game_Flag_Query(671)) { - Actor_Put_In_Set(kActorGuzza, 99); + Actor_Put_In_Set(kActorGuzza, kSetFreeSlotI); Actor_Set_At_Waypoint(kActorGuzza, 41, 0); if (Actor_Query_Which_Set_In(kActorSadik) == 89) { - Actor_Put_In_Set(kActorSadik, 91); + Actor_Put_In_Set(kActorSadik, kSetFreeSlotA); Actor_Set_At_Waypoint(kActorSadik, 33, 0); } } @@ -114,7 +114,7 @@ bool SceneScriptUG18::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(435); - Set_Enter(85, kSceneUG13); + Set_Enter(kSetUG13, kSceneUG13); } return true; } diff --git a/engines/bladerunner/script/scene/ug19.cpp b/engines/bladerunner/script/scene/ug19.cpp index f73e9f8196..1f5eccdf65 100644 --- a/engines/bladerunner/script/scene/ug19.cpp +++ b/engines/bladerunner/script/scene/ug19.cpp @@ -92,7 +92,7 @@ bool SceneScriptUG19::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(356); - Set_Enter(53, kSceneMA07); + Set_Enter(kSetMA07, kSceneMA07); } return true; } @@ -101,7 +101,7 @@ bool SceneScriptUG19::ClickedOnExit(int exitId) { Ambient_Sounds_Remove_All_Non_Looping_Sounds(1); Ambient_Sounds_Remove_All_Looping_Sounds(1); Game_Flag_Set(349); - Set_Enter(86, kSceneUG14); + Set_Enter(kSetUG14, kSceneUG14); } return true; } |