2016-09-10 18:33:04 +02:00
|
|
|
/* ScummVM - Graphic Adventure Engine
|
|
|
|
*
|
|
|
|
* ScummVM is the legal property of its developers, whose names
|
|
|
|
* are too numerous to list here. Please refer to the COPYRIGHT
|
|
|
|
* file distributed with this source distribution.
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2018-02-10 20:34:28 +01:00
|
|
|
#include "bladerunner/script/scene_script.h"
|
2016-09-10 18:33:04 +02:00
|
|
|
|
|
|
|
namespace BladeRunner {
|
|
|
|
|
2019-01-26 18:25:39 +01:00
|
|
|
enum kPS01Loops {
|
2019-04-27 19:57:55 +03:00
|
|
|
kPS01LoopInshot = 0,
|
2019-01-26 18:25:39 +01:00
|
|
|
kPS01LoopMainLoop = 1,
|
|
|
|
kPS01LoopDoorAnim = 3,
|
2019-04-27 19:57:55 +03:00
|
|
|
kPS01LoopOutshot = 4,
|
2019-01-26 18:25:39 +01:00
|
|
|
kPS01LoopNoSpinner = 5
|
|
|
|
};
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::InitializeScene() {
|
2016-09-10 18:33:04 +02:00
|
|
|
Setup_Scene_Information(1872.0f, 16592.0f, -2975.0f, 200);
|
|
|
|
Scene_Exit_Add_2D_Exit(0, 36, 194, 138, 326, 0);
|
2019-01-13 20:38:17 +01:00
|
|
|
if (Game_Flag_Query(kFlagSpinnerAtPS01)) {
|
2016-09-10 18:33:04 +02:00
|
|
|
Scene_Exit_Add_2D_Exit(1, 344, 288, 584, 384, 2);
|
|
|
|
}
|
2019-04-06 00:02:32 +03:00
|
|
|
Ambient_Sounds_Add_Looping_Sound(kSfxRAIN10, 100, 1, 1);
|
2019-04-06 19:21:00 +03:00
|
|
|
Ambient_Sounds_Add_Sound(kSfxSPIN2B, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
|
|
|
|
Ambient_Sounds_Add_Sound(kSfxSPIN3A, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
|
|
|
|
Ambient_Sounds_Add_Sound(kSfxTHNDER2, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
|
|
|
|
Ambient_Sounds_Add_Sound(kSfxTHNDER3, 50, 180, 50, 100, 0, 0, -101, -101, 0, 0);
|
|
|
|
Ambient_Sounds_Add_Sound(kSfxTHNDER4, 50, 180, 50, 100, 0, 0, -101, -101, 0, 0);
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2018-03-07 22:27:28 +01:00
|
|
|
if (Game_Flag_Query(kFlagPS02toPS01)) {
|
2019-01-13 20:38:17 +01:00
|
|
|
if (Game_Flag_Query(kFlagSpinnerAtPS01)) {
|
2019-01-26 18:25:39 +01:00
|
|
|
Scene_Loop_Set_Default(kPS01LoopMainLoop);
|
2016-09-10 18:33:04 +02:00
|
|
|
} else {
|
2019-01-26 18:25:39 +01:00
|
|
|
Scene_Loop_Set_Default(kPS01LoopNoSpinner);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
} else {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Invisible(kActorMcCoy, true);
|
2019-01-19 23:12:45 +01:00
|
|
|
Game_Flag_Set(kFlagArrivedFromSpinner2);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeLoseControl, kPS01LoopInshot, false);
|
2019-01-26 18:25:39 +01:00
|
|
|
Scene_Loop_Set_Default(kPS01LoopMainLoop);
|
2016-09-10 18:33:04 +02:00
|
|
|
Player_Loses_Control();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::SceneLoaded() {
|
2016-09-10 18:33:04 +02:00
|
|
|
Obstacle_Object("TUBE81", true);
|
2019-01-13 20:38:17 +01:00
|
|
|
if (Game_Flag_Query(kFlagSpinnerAtPS01)) {
|
2016-09-10 18:33:04 +02:00
|
|
|
Unobstacle_Object("Barrier Obstacle", true);
|
|
|
|
}
|
|
|
|
Unobstacle_Object("BOX38", true);
|
|
|
|
Unobstacle_Object("TUBE81", true);
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::MouseClick(int x, int y) {
|
2016-09-10 18:33:04 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::ClickedOn3DObject(const char *objectName, bool a2) {
|
2016-09-10 18:33:04 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::ClickedOnActor(int actorId) {
|
2016-09-10 18:33:04 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::ClickedOnItem(int itemId, bool a2) {
|
2016-09-10 18:33:04 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::ClickedOnExit(int exitId) {
|
2016-09-10 18:33:04 +02:00
|
|
|
if (exitId == 0) {
|
2019-05-09 15:15:33 +03:00
|
|
|
if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1920.0f, 16581.0f, -2653.0f, 12, true, false, false)) {
|
2019-01-26 18:25:39 +01:00
|
|
|
Game_Flag_Set(kflagPS01toPS02);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetPS02, kScenePS02);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (exitId == 1) {
|
2019-05-09 15:15:33 +03:00
|
|
|
if (!Loop_Actor_Walk_To_XYZ(kActorMcCoy, 1877.9f, 16592.0f, -2975.0f, 0, true, false, false)) {
|
2019-05-08 00:49:15 +03:00
|
|
|
#if BLADERUNNER_ORIGINAL_BUGS
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_At_XYZ(kActorMcCoy, 1872.0f, 16592.0f, -2975.0f, 870);
|
2019-05-08 00:49:15 +03:00
|
|
|
#else
|
|
|
|
// reduce glitch with spinner door
|
|
|
|
Actor_Set_At_XYZ(kActorMcCoy, 1872.0f, 16592.0f, -2994.0f, 870);
|
|
|
|
#endif // BLADERUNNER_ORIGINAL_BUGS
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Reset(kFlagMcCoyInChinaTown);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInRunciters);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInMcCoyApartment);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInPoliceStation);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInAnimoidRow);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInTyrellBuilding);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInDNARow);
|
|
|
|
Game_Flag_Reset(kFlagMcCoyInBradburyBuilding);
|
2019-01-26 18:25:39 +01:00
|
|
|
int spinnerDest = Spinner_Interface_Choose_Dest(kPS01LoopDoorAnim, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
switch (spinnerDest) {
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationMcCoysApartment:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInMcCoyApartment);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Game_Flag_Set(kFlagSpinnerAtMA01);
|
|
|
|
Set_Enter(kSetMA01, kSceneMA01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationRuncitersAnimals:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInRunciters);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Game_Flag_Set(kFlagSpinnerAtRC01);
|
|
|
|
Set_Enter(kSetRC01, kSceneRC01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationChinatown:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInChinaTown);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
|
|
|
Game_Flag_Set(kFlagSpinnerAtCT01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetCT01_CT12, kSceneCT01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationAnimoidRow:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInAnimoidRow);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Game_Flag_Set(kFlagSpinnerAtAR01);
|
|
|
|
Set_Enter(kSetAR01_AR02, kSceneAR01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationTyrellBuilding:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInTyrellBuilding);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Game_Flag_Set(kFlagSpinnerAtTB02);
|
|
|
|
Set_Enter(kSetTB02_TB03, kSceneTB02);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationDNARow:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInDNARow);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
|
|
|
Game_Flag_Set(kFlagSpinnerAtDR01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetDR01_DR02_DR04, kSceneDR01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationBradburyBuilding:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInBradburyBuilding);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
|
|
|
Game_Flag_Set(kFlagSpinnerAtBB01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetBB01, kSceneBB01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationNightclubRow:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInNightclubRow);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
|
|
|
Game_Flag_Set(kFlagSpinnerAtNR01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetNR01, kSceneNR01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-14 21:09:12 +01:00
|
|
|
case kSpinnerDestinationHysteriaHall:
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInHysteriaHall);
|
2019-01-13 20:38:17 +01:00
|
|
|
Game_Flag_Reset(kFlagSpinnerAtPS01);
|
|
|
|
Game_Flag_Set(kFlagSpinnerAtHF01);
|
2019-01-14 21:09:12 +01:00
|
|
|
Set_Enter(kSetHF01, kSceneHF01);
|
2019-04-27 19:57:55 +03:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeChangeSet, kPS01LoopOutshot, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
|
|
|
default:
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Face_Heading(kActorMcCoy, 870, false);
|
2019-01-24 22:57:41 +01:00
|
|
|
Game_Flag_Set(kFlagMcCoyInPoliceStation);
|
2019-01-19 23:12:45 +01:00
|
|
|
Game_Flag_Set(kFlagArrivedFromSpinner2);
|
2016-09-10 18:33:04 +02:00
|
|
|
Player_Loses_Control();
|
2019-01-26 18:25:39 +01:00
|
|
|
Scene_Loop_Start_Special(kSceneLoopModeOnce, kPS01LoopDoorAnim, true);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
bool SceneScriptPS01::ClickedOn2DRegion(int region) {
|
2016-09-10 18:33:04 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::SceneFrameAdvanced(int frame) {
|
2019-01-26 18:25:39 +01:00
|
|
|
if (frame == 71
|
|
|
|
|| frame == 188
|
|
|
|
) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxSPINOPN4, 100, 40, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
|
|
|
if (frame == 108
|
|
|
|
|| frame == 228
|
|
|
|
) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxSPINCLS1, 100, 40, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 1) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxCARDOWN3, 40, 0, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 76) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxSERVOD1, 50, 0, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 192) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxSERVOU1, 50, 0, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 59) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxMTLHIT1, 15, 0, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 275) {
|
2019-04-05 21:33:47 +03:00
|
|
|
Sound_Play(kSfxCARUP3, 40, 0, 0, 50);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2019-01-19 23:12:45 +01:00
|
|
|
if (!Game_Flag_Query(kFlagArrivedFromSpinner2)) {
|
2016-09-10 18:33:04 +02:00
|
|
|
switch (frame) {
|
|
|
|
case 196:
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Face_Heading(kActorMcCoy, 870, false);
|
|
|
|
Actor_Set_Frame_Rate_FPS(kActorMcCoy, -1);
|
2019-01-26 18:25:39 +01:00
|
|
|
Actor_Change_Animation_Mode(kActorMcCoy, kAnimationModeSpinnerGetIn);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
case 220:
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Frame_Rate_FPS(kActorMcCoy, 0);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
case 240:
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Frame_Rate_FPS(kActorMcCoy, -2);
|
2016-09-10 18:33:04 +02:00
|
|
|
break;
|
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
return; // true;
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 75) {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Face_Heading(kActorMcCoy, 870, false);
|
2019-01-26 18:25:39 +01:00
|
|
|
Actor_Change_Animation_Mode(kActorMcCoy, kAnimationModeSpinnerGetOut);
|
|
|
|
return; // true;
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 119) {
|
2019-01-19 23:12:45 +01:00
|
|
|
Game_Flag_Reset(kFlagArrivedFromSpinner2);
|
2016-09-10 18:33:04 +02:00
|
|
|
Player_Gains_Control();
|
2019-01-26 18:25:39 +01:00
|
|
|
return; // true;
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame > 195) {
|
|
|
|
if (frame == 239) {
|
2019-01-19 23:12:45 +01:00
|
|
|
Game_Flag_Reset(kFlagArrivedFromSpinner2);
|
2016-09-10 18:33:04 +02:00
|
|
|
Player_Gains_Control();
|
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
return; // true;
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2016-09-10 18:33:04 +02:00
|
|
|
if (frame == 181) {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Face_Heading(kActorMcCoy, 870, false);
|
2019-01-26 18:25:39 +01:00
|
|
|
Actor_Change_Animation_Mode(kActorMcCoy, kAnimationModeSpinnerGetOut);
|
2016-09-10 18:33:04 +02:00
|
|
|
} else if (frame == 182) {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Frame_Rate_FPS(kActorMcCoy, 0);
|
2016-09-10 18:33:04 +02:00
|
|
|
} else if (frame == 195) {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Frame_Rate_FPS(kActorMcCoy, -2);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-01-26 18:25:39 +01:00
|
|
|
|
|
|
|
return; // true;
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::PlayerWalkedIn() {
|
2018-03-07 22:27:28 +01:00
|
|
|
if (Game_Flag_Query(kFlagPS02toPS01)) {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_At_XYZ(kActorMcCoy, 1920.0f, 16581.0f, -2653.0f, 150);
|
2018-03-07 22:27:28 +01:00
|
|
|
Game_Flag_Reset(kFlagPS02toPS01);
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
2019-05-13 00:19:17 +03:00
|
|
|
if (_vm->_cutContent) {
|
|
|
|
if (!Game_Flag_Query(kFlagCT01Visited) && !Actor_Clue_Query(kActorMcCoy, kClueDispatchHitAndRun)) {
|
|
|
|
Actor_Clue_Acquire(kActorMcCoy, kClueDispatchHitAndRun, false, kActorDispatcher);
|
|
|
|
ADQ_Add(kActorDispatcher, 80, kAnimationModeTalk);
|
|
|
|
if (Game_Flag_Query(kFlagRC01PoliceDone)) {
|
|
|
|
ADQ_Add(kActorOfficerLeary, 340, kAnimationModeTalk); // sector 3 - go ahead
|
|
|
|
} else {
|
|
|
|
ADQ_Add(kActorOfficerGrayford, 360, kAnimationModeTalk); // sector 3 - go ahead
|
|
|
|
}
|
|
|
|
ADQ_Add(kActorDispatcher, 90, kAnimationModeTalk);
|
|
|
|
ADQ_Add(kActorDispatcher, 100, kAnimationModeTalk);
|
|
|
|
ADQ_Add(kActorDispatcher, 110, kAnimationModeTalk);
|
|
|
|
if (Game_Flag_Query(kFlagRC01PoliceDone)) {
|
|
|
|
ADQ_Add(kActorOfficerLeary, 350, kAnimationModeTalk); // sector 3 - responding code 3
|
|
|
|
} else {
|
|
|
|
ADQ_Add(kActorOfficerGrayford, 370, kAnimationModeTalk); // sector 3 - responding code 3
|
|
|
|
}
|
|
|
|
ADQ_Add_Pause(1000);
|
|
|
|
ADQ_Add(kActorDispatcher, 120, kAnimationModeTalk);
|
|
|
|
ADQ_Add(kActorDispatcher, 130, kAnimationModeTalk);
|
|
|
|
ADQ_Add(kActorDispatcher, 140, kAnimationModeTalk);
|
|
|
|
ADQ_Add(kActorDispatcher, 150, kAnimationModeTalk);
|
|
|
|
}
|
|
|
|
}
|
2016-09-10 18:33:04 +02:00
|
|
|
//return false;
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::PlayerWalkedOut() {
|
2017-03-29 01:50:47 +02:00
|
|
|
Actor_Set_Invisible(kActorMcCoy, false);
|
2019-01-21 21:57:44 +01:00
|
|
|
Ambient_Sounds_Remove_All_Non_Looping_Sounds(true);
|
2016-09-10 18:33:04 +02:00
|
|
|
Ambient_Sounds_Remove_All_Looping_Sounds(1);
|
2019-01-26 18:25:39 +01:00
|
|
|
|
2019-05-13 00:19:17 +03:00
|
|
|
if (_vm->_cutContent) {
|
|
|
|
ADQ_Flush(); // for dispatcher queue cleanup
|
|
|
|
}
|
|
|
|
|
2019-04-28 00:20:05 +03:00
|
|
|
if (!Game_Flag_Query(kflagPS01toPS02)) {
|
|
|
|
if (Global_Variable_Query(kVariableChapter) == 1) {
|
|
|
|
Outtake_Play(kOuttakeTowards3, true, -1);
|
|
|
|
}
|
|
|
|
#if BLADERUNNER_ORIGINAL_BUGS
|
|
|
|
#else
|
|
|
|
else {
|
|
|
|
// Acts 2, 3 - should still use a spinner fly-through transition
|
|
|
|
if (!Game_Flag_Query(kFlagMcCoyInTyrellBuilding)) {
|
|
|
|
// don't play an extra outtake when going to Tyrell Building
|
|
|
|
Outtake_Play(kOuttakeInside2, true, -1); // available in Acts 1, 2, 3
|
|
|
|
Outtake_Play(kOuttakeTowards3, true, -1); // available in Acts 1, 2, 3
|
|
|
|
}
|
|
|
|
}
|
|
|
|
#endif // BLADERUNNER_ORIGINAL_BUGS
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-03-23 16:20:10 +01:00
|
|
|
void SceneScriptPS01::DialogueQueueFlushed(int a1) {
|
2016-09-10 18:33:04 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
} // End of namespace BladeRunner
|