aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorPeter Kohaut2016-09-10 18:33:04 +0200
committerEugene Sandulenko2016-09-29 22:33:41 +0200
commitbf44e97d79019c926b214f9f6b109a192d46e2ec (patch)
tree1e48b1b846253f25233d83f4992743210860d6aa /engines
parentb67bca20b5db7f3d6473341efd7fabfa6532f465 (diff)
downloadscummvm-rg350-bf44e97d79019c926b214f9f6b109a192d46e2ec.tar.gz
scummvm-rg350-bf44e97d79019c926b214f9f6b109a192d46e2ec.tar.bz2
scummvm-rg350-bf44e97d79019c926b214f9f6b109a192d46e2ec.zip
BLADERUNNER: added all scene scripts, esper script, kia script, vk script, completed init script. Added decoding of lights from VQA. Moved view from scene.
Diffstat (limited to 'engines')
-rw-r--r--engines/bladerunner/actor.cpp6
-rw-r--r--engines/bladerunner/actor.h1
-rw-r--r--engines/bladerunner/audio_player.cpp2
-rw-r--r--engines/bladerunner/bladerunner.cpp67
-rw-r--r--engines/bladerunner/bladerunner.h7
-rw-r--r--engines/bladerunner/light.cpp33
-rw-r--r--engines/bladerunner/light.h2
-rw-r--r--engines/bladerunner/lights.cpp65
-rw-r--r--engines/bladerunner/lights.h2
-rw-r--r--engines/bladerunner/module.mk113
-rw-r--r--engines/bladerunner/mouse.cpp4
-rw-r--r--engines/bladerunner/scene.cpp3
-rw-r--r--engines/bladerunner/scene.h2
-rw-r--r--engines/bladerunner/script/ar01.cpp361
-rw-r--r--engines/bladerunner/script/ar02.cpp390
-rw-r--r--engines/bladerunner/script/bb01.cpp231
-rw-r--r--engines/bladerunner/script/bb02.cpp159
-rw-r--r--engines/bladerunner/script/bb03.cpp163
-rw-r--r--engines/bladerunner/script/bb04.cpp132
-rw-r--r--engines/bladerunner/script/bb05.cpp215
-rw-r--r--engines/bladerunner/script/bb06.cpp178
-rw-r--r--engines/bladerunner/script/bb07.cpp186
-rw-r--r--engines/bladerunner/script/bb08.cpp138
-rw-r--r--engines/bladerunner/script/bb09.cpp124
-rw-r--r--engines/bladerunner/script/bb10.cpp205
-rw-r--r--engines/bladerunner/script/bb11.cpp132
-rw-r--r--engines/bladerunner/script/bb12.cpp144
-rw-r--r--engines/bladerunner/script/bb51.cpp123
-rw-r--r--engines/bladerunner/script/ct01.cpp514
-rw-r--r--engines/bladerunner/script/ct02.cpp294
-rw-r--r--engines/bladerunner/script/ct03.cpp133
-rw-r--r--engines/bladerunner/script/ct04.cpp237
-rw-r--r--engines/bladerunner/script/ct05.cpp241
-rw-r--r--engines/bladerunner/script/ct06.cpp180
-rw-r--r--engines/bladerunner/script/ct07.cpp104
-rw-r--r--engines/bladerunner/script/ct08.cpp196
-rw-r--r--engines/bladerunner/script/ct09.cpp214
-rw-r--r--engines/bladerunner/script/ct10.cpp160
-rw-r--r--engines/bladerunner/script/ct11.cpp213
-rw-r--r--engines/bladerunner/script/ct12.cpp284
-rw-r--r--engines/bladerunner/script/ct51.cpp129
-rw-r--r--engines/bladerunner/script/dr01.cpp262
-rw-r--r--engines/bladerunner/script/dr02.cpp183
-rw-r--r--engines/bladerunner/script/dr03.cpp288
-rw-r--r--engines/bladerunner/script/dr04.cpp269
-rw-r--r--engines/bladerunner/script/dr05.cpp189
-rw-r--r--engines/bladerunner/script/dr06.cpp225
-rw-r--r--engines/bladerunner/script/esper.cpp385
-rw-r--r--engines/bladerunner/script/esper.h45
-rw-r--r--engines/bladerunner/script/hc01.cpp433
-rw-r--r--engines/bladerunner/script/hc02.cpp216
-rw-r--r--engines/bladerunner/script/hc03.cpp188
-rw-r--r--engines/bladerunner/script/hc04.cpp242
-rw-r--r--engines/bladerunner/script/hf01.cpp475
-rw-r--r--engines/bladerunner/script/hf02.cpp145
-rw-r--r--engines/bladerunner/script/hf03.cpp254
-rw-r--r--engines/bladerunner/script/hf04.cpp167
-rw-r--r--engines/bladerunner/script/hf05.cpp673
-rw-r--r--engines/bladerunner/script/hf06.cpp286
-rw-r--r--engines/bladerunner/script/hf07.cpp154
-rw-r--r--engines/bladerunner/script/init.cpp3729
-rw-r--r--engines/bladerunner/script/kia.cpp951
-rw-r--r--engines/bladerunner/script/kia.h45
-rw-r--r--engines/bladerunner/script/kp01.cpp171
-rw-r--r--engines/bladerunner/script/kp02.cpp147
-rw-r--r--engines/bladerunner/script/kp03.cpp262
-rw-r--r--engines/bladerunner/script/kp04.cpp118
-rw-r--r--engines/bladerunner/script/kp05.cpp171
-rw-r--r--engines/bladerunner/script/kp06.cpp237
-rw-r--r--engines/bladerunner/script/kp07.cpp178
-rw-r--r--engines/bladerunner/script/ma01.cpp257
-rw-r--r--engines/bladerunner/script/ma02.cpp267
-rw-r--r--engines/bladerunner/script/ma04.cpp567
-rw-r--r--engines/bladerunner/script/ma05.cpp142
-rw-r--r--engines/bladerunner/script/ma06.cpp154
-rw-r--r--engines/bladerunner/script/ma07.cpp159
-rw-r--r--engines/bladerunner/script/ma08.cpp81
-rw-r--r--engines/bladerunner/script/nr01.cpp436
-rw-r--r--engines/bladerunner/script/nr02.cpp215
-rw-r--r--engines/bladerunner/script/nr03.cpp351
-rw-r--r--engines/bladerunner/script/nr04.cpp358
-rw-r--r--engines/bladerunner/script/nr05.cpp369
-rw-r--r--engines/bladerunner/script/nr06.cpp162
-rw-r--r--engines/bladerunner/script/nr07.cpp379
-rw-r--r--engines/bladerunner/script/nr08.cpp242
-rw-r--r--engines/bladerunner/script/nr09.cpp145
-rw-r--r--engines/bladerunner/script/nr10.cpp164
-rw-r--r--engines/bladerunner/script/nr11.cpp382
-rw-r--r--engines/bladerunner/script/ps01.cpp277
-rw-r--r--engines/bladerunner/script/ps02.cpp177
-rw-r--r--engines/bladerunner/script/ps03.cpp134
-rw-r--r--engines/bladerunner/script/ps04.cpp304
-rw-r--r--engines/bladerunner/script/ps05.cpp273
-rw-r--r--engines/bladerunner/script/ps06.cpp137
-rw-r--r--engines/bladerunner/script/ps07.cpp189
-rw-r--r--engines/bladerunner/script/ps09.cpp354
-rw-r--r--engines/bladerunner/script/ps10.cpp248
-rw-r--r--engines/bladerunner/script/ps11.cpp285
-rw-r--r--engines/bladerunner/script/ps12.cpp302
-rw-r--r--engines/bladerunner/script/ps13.cpp285
-rw-r--r--engines/bladerunner/script/ps14.cpp127
-rw-r--r--engines/bladerunner/script/ps15.cpp175
-rw-r--r--engines/bladerunner/script/rc01.cpp526
-rw-r--r--engines/bladerunner/script/rc02.cpp392
-rw-r--r--engines/bladerunner/script/rc03.cpp301
-rw-r--r--engines/bladerunner/script/rc04.cpp420
-rw-r--r--engines/bladerunner/script/rc51.cpp130
-rw-r--r--engines/bladerunner/script/script.cpp575
-rw-r--r--engines/bladerunner/script/script.h646
-rw-r--r--engines/bladerunner/script/tb02.cpp469
-rw-r--r--engines/bladerunner/script/tb03.cpp155
-rw-r--r--engines/bladerunner/script/tb05.cpp197
-rw-r--r--engines/bladerunner/script/tb06.cpp192
-rw-r--r--engines/bladerunner/script/tb07.cpp290
-rw-r--r--engines/bladerunner/script/ug01.cpp179
-rw-r--r--engines/bladerunner/script/ug02.cpp256
-rw-r--r--engines/bladerunner/script/ug03.cpp146
-rw-r--r--engines/bladerunner/script/ug04.cpp140
-rw-r--r--engines/bladerunner/script/ug05.cpp275
-rw-r--r--engines/bladerunner/script/ug06.cpp161
-rw-r--r--engines/bladerunner/script/ug07.cpp193
-rw-r--r--engines/bladerunner/script/ug08.cpp145
-rw-r--r--engines/bladerunner/script/ug09.cpp153
-rw-r--r--engines/bladerunner/script/ug10.cpp234
-rw-r--r--engines/bladerunner/script/ug12.cpp122
-rw-r--r--engines/bladerunner/script/ug13.cpp410
-rw-r--r--engines/bladerunner/script/ug14.cpp193
-rw-r--r--engines/bladerunner/script/ug15.cpp204
-rw-r--r--engines/bladerunner/script/ug16.cpp369
-rw-r--r--engines/bladerunner/script/ug17.cpp117
-rw-r--r--engines/bladerunner/script/ug18.cpp409
-rw-r--r--engines/bladerunner/script/ug19.cpp139
-rw-r--r--engines/bladerunner/script/vk.cpp3524
-rw-r--r--engines/bladerunner/script/vk.h65
-rw-r--r--engines/bladerunner/set.cpp15
-rw-r--r--engines/bladerunner/shape.cpp2
-rw-r--r--engines/bladerunner/slice_animations.cpp8
-rw-r--r--engines/bladerunner/slice_animations.h7
-rw-r--r--engines/bladerunner/slice_renderer.cpp8
-rw-r--r--engines/bladerunner/vqa_decoder.cpp70
-rw-r--r--engines/bladerunner/vqa_decoder.h16
-rw-r--r--engines/bladerunner/vqa_player.cpp14
-rw-r--r--engines/bladerunner/vqa_player.h7
143 files changed, 35615 insertions, 1531 deletions
diff --git a/engines/bladerunner/actor.cpp b/engines/bladerunner/actor.cpp
index b4bdd68835..4b893c6851 100644
--- a/engines/bladerunner/actor.cpp
+++ b/engines/bladerunner/actor.cpp
@@ -186,6 +186,10 @@ void Actor::setAtWaypoint(int waypointId, int angle, int moving, bool retired)
setAtXYZ(waypointPosition, angle, true, moving, retired);
}
+void Actor::loopWalkToXYZ(float x, float y, float z, int a4, int a5, int a6, int a7) {
+ this->loopWalkToXYZ(Vector3(x, y, z));
+}
+
void Actor::loopWalkToXYZ(Vector3 destination)
{
int unk1;
@@ -660,7 +664,7 @@ void Actor::setGoal(int goalNumber) {
//TODO: _vm->actorScript->GoalChanged(_id, _goalNumber, goalNumber);
- _vm->_script->SceneActorChangedGoal(_id, goalNumber, _goalNumber, _vm->_scene->getSetId() == _setId);
+ _vm->_script->ActorChangedGoal(_id, goalNumber, _goalNumber, _vm->_scene->getSetId() == _setId);
}
int Actor::getGoal() {
diff --git a/engines/bladerunner/actor.h b/engines/bladerunner/actor.h
index 34d8a5abfb..7827141210 100644
--- a/engines/bladerunner/actor.h
+++ b/engines/bladerunner/actor.h
@@ -121,6 +121,7 @@ public:
void setFPS(int fps);
void loopWalkToXYZ(Vector3 destination);
+ void loopWalkToXYZ(float x, float y, float z, int a4, int a5, int a6, int a7);
void loopWalkToSceneObject(const char *objectName, int destinationOffset = 0);
bool tick(bool forceUpdate);
diff --git a/engines/bladerunner/audio_player.cpp b/engines/bladerunner/audio_player.cpp
index 851b0bc6f7..1698bfbd4f 100644
--- a/engines/bladerunner/audio_player.cpp
+++ b/engines/bladerunner/audio_player.cpp
@@ -166,7 +166,7 @@ void AudioPlayer::fadeAndStopTrack(Track *track, int time)
int AudioPlayer::playAud(const Common::String &name, int volume, int panFrom, int panTo, int priority, byte flags) {
/* Find first available track or, alternatively, the lowest priority playing track */
Track *track = NULL;
- int lowestPriority;
+ int lowestPriority = INT_MAX;
Track *lowestPriorityTrack = NULL;
for (int i = 0; i != 6; ++i) {
diff --git a/engines/bladerunner/bladerunner.cpp b/engines/bladerunner/bladerunner.cpp
index bd38fe7e75..bf9077f3df 100644
--- a/engines/bladerunner/bladerunner.cpp
+++ b/engines/bladerunner/bladerunner.cpp
@@ -555,7 +555,7 @@ void BladeRunnerEngine::gameTick() {
if (_settings->getNewScene() == -1 || _script->_inScriptCounter /* || in_ai */) {
- _sliceRenderer->setView(_scene->_view);
+ _sliceRenderer->setView(*_view);
// Tick and draw all actors in current set
for (int i = 0, end = _gameInfo->getActorCount(); i != end; ++i) {
@@ -611,29 +611,66 @@ void BladeRunnerEngine::handleMouseClick(int x, int y) {
int isTarget;
int sceneObjectId = _sceneObjects->findByXYZ(&isClickable, &isObstacle, &isTarget, mousePosition.x, mousePosition.y, mousePosition.z, 1, 0, 1);
- int exitType = _scene->_exits->getTypeAtXY(x, y);
+ int exitIndex = _scene->_exits->getTypeAtXY(x, y);
- debug("%d %d", sceneObjectId, exitType);
+ debug("%d %d", sceneObjectId, exitIndex);
- if ((sceneObjectId < 0 || sceneObjectId > 73) && exitType >= 0) {
- // clickedOnExit(exitType, x, y);
- debug("clicked on exit %d %d %d", exitType, x, y);
+ if ((sceneObjectId < 0 || sceneObjectId > 73) && exitIndex >= 0) {
+ handleMouseClickExit(x, y, exitIndex);
return;
}
int regionIndex = _scene->_regions->getRegionAtXY(x, y);
if (regionIndex >= 0) {
- debug("clicked on region %d %d %d", regionIndex, x, y);
- _script->ClickedOn2DRegion(regionIndex);
+ handleMouseClickRegion(x, y, regionIndex);
+ return;
}
- if (sceneObjectId >= 198 && sceneObjectId <= 293) {
- const char *objectName = _scene->objectGetName(sceneObjectId - 198);
- debug("%s", objectName);
- _script->ClickedOn3DObject(objectName);
+ if (sceneObjectId == -1) {
+ debug("Clicked on nothing");
+ return;
+ } else if (sceneObjectId >= 0 && sceneObjectId <= 73) {
+ handleMouseClickActor(x, y, sceneObjectId);
+ return;
+ } else if (sceneObjectId >= 74 && sceneObjectId <= 197) {
+ handleMouseClickItem(x, y, sceneObjectId - 74);
+ return;
+ } else if (sceneObjectId >= 198 && sceneObjectId <= 293) {
+ handleMouseClick3DObject(x, y, sceneObjectId - 198, isClickable, isTarget);
return;
}
+}
+
+void BladeRunnerEngine::handleMouseClickExit(int x, int y, int exitIndex)
+{
+ // clickedOnExit(exitType, x, y);
+ debug("clicked on exit %d %d %d", exitIndex, x, y);
+ _script->ClickedOnExit(exitIndex);
+}
+
+void BladeRunnerEngine::handleMouseClickRegion(int x, int y, int regionIndex)
+{
+ debug("clicked on region %d %d %d", regionIndex, x, y);
+ _script->ClickedOn2DRegion(regionIndex);
+}
+
+void BladeRunnerEngine::handleMouseClick3DObject(int x, int y, int objectId, bool isClickable, bool isTarget)
+{
+ const char *objectName = _scene->objectGetName(objectId);
+ debug("Clicked on object %s", objectName);
+ _script->ClickedOn3DObject(objectName, false);
+}
+
+void BladeRunnerEngine::handleMouseClickItem(int x, int y, int itemId)
+{
+ debug("Clicked on item %d", itemId);
+ _script->ClickedOnItem(itemId, false);
+}
+void BladeRunnerEngine::handleMouseClickActor(int x, int y, int actorId)
+{
+ debug("Clicked on actor %d", actorId);
+ _script->ClickedOnActor(actorId);
}
void BladeRunnerEngine::gameWaitForActive() {
@@ -655,12 +692,6 @@ void BladeRunnerEngine::loopActorSpeaking() {
playerGainsControl();
}
-void BladeRunnerEngine::loopActorWalkToXYZ(int actorId, float x, float y, float z, int a4, int a5, int a6, int a7) {
- Actor *actor = _actors[actorId];
-
- actor->loopWalkToXYZ(Vector3(x, y, z));
-}
-
void BladeRunnerEngine::outtakePlay(int id, bool noLocalization, int container) {
Common::String name = _gameInfo->getOuttake(id);
diff --git a/engines/bladerunner/bladerunner.h b/engines/bladerunner/bladerunner.h
index fba793c116..082617e65b 100644
--- a/engines/bladerunner/bladerunner.h
+++ b/engines/bladerunner/bladerunner.h
@@ -143,11 +143,14 @@ public:
void gameTick();
void handleEvents();
void handleMouseClick(int x, int y);
+ void handleMouseClickExit(int x, int y, int exitIndex);
+ void handleMouseClickRegion(int x, int y, int regionIndex);
+ void handleMouseClickItem(int x, int y, int itemId);
+ void handleMouseClickActor(int x, int y, int actorId);
+ void handleMouseClick3DObject(int x, int y, int objectId, bool isClickable, bool isTarget);
void gameWaitForActive();
void loopActorSpeaking();
- void loopActorWalkToXYZ(int actorId, float x, float y, float z, int a4, int a5, int a6, int a7);
-
void outtakePlay(int id, bool no_localization, int container = -1);
bool openArchive(const Common::String &name);
diff --git a/engines/bladerunner/light.cpp b/engines/bladerunner/light.cpp
index 3689ab42ce..d1d79b870b 100644
--- a/engines/bladerunner/light.cpp
+++ b/engines/bladerunner/light.cpp
@@ -48,8 +48,39 @@ void Light::read(Common::ReadStream* stream, int framesCount, int frame, int ani
setupFrame(frame);
}
-void Light::readVqa(Common::ReadStream* stream)
+void Light::readVqa(Common::ReadStream* stream, int framesCount, int frame, int animated)
{
+ _framesCount = framesCount;
+ _animated = animated;
+
+ _animatedParameters = stream->readUint32LE();
+
+ int size = stream->readUint32LE();
+
+ _animationData = new float[size / sizeof(float)];
+ stream->read(_animationData, size);
+
+ _m11ptr = _animationData;
+ _m12ptr = _m11ptr + (_animatedParameters & 0x1 ? framesCount : 1);
+ _m13ptr = _m12ptr + (_animatedParameters & 0x2 ? framesCount : 1);
+ _m14ptr = _m13ptr + (_animatedParameters & 0x4 ? framesCount : 1);
+ _m21ptr = _m14ptr + (_animatedParameters & 0x8 ? framesCount : 1);
+ _m22ptr = _m21ptr + (_animatedParameters & 0x10 ? framesCount : 1);
+ _m23ptr = _m22ptr + (_animatedParameters & 0x20 ? framesCount : 1);
+ _m24ptr = _m23ptr + (_animatedParameters & 0x40 ? framesCount : 1);
+ _m31ptr = _m24ptr + (_animatedParameters & 0x80 ? framesCount : 1);
+ _m32ptr = _m31ptr + (_animatedParameters & 0x100 ? framesCount : 1);
+ _m33ptr = _m32ptr + (_animatedParameters & 0x200 ? framesCount : 1);
+ _m34ptr = _m33ptr + (_animatedParameters & 0x400 ? framesCount : 1);
+ _colorRPtr = _m34ptr + (_animatedParameters & 0x800 ? framesCount : 1);
+ _colorGPtr = _colorRPtr + (_animatedParameters & 0x1000 ? framesCount : 1);
+ _colorBPtr = _colorGPtr + (_animatedParameters & 0x2000 ? framesCount : 1);
+ _field16ptr = _colorGPtr + (_animatedParameters & 0x4000 ? framesCount : 1);
+ _field17ptr = _field16ptr + (_animatedParameters & 0x8000 ? framesCount : 1);
+ _field18ptr = _field17ptr + (_animatedParameters & 0x10000 ? framesCount : 1);
+ _field19ptr = _field18ptr + (_animatedParameters & 0x20000 ? framesCount : 1);
+
+ setupFrame(frame);
}
void Light::setupFrame(int frame)
diff --git a/engines/bladerunner/light.h b/engines/bladerunner/light.h
index bfece071dc..b075c914c2 100644
--- a/engines/bladerunner/light.h
+++ b/engines/bladerunner/light.h
@@ -77,7 +77,7 @@ public:
~Light();
void read(Common::ReadStream *stream, int framesCount, int frame, int animated);
- void readVqa(Common::ReadStream *stream);
+ void readVqa(Common::ReadStream *stream, int framesCount, int frame, int animated);
void setupFrame(int frame);
diff --git a/engines/bladerunner/lights.cpp b/engines/bladerunner/lights.cpp
index 29e4c2f58e..7a6be94c6d 100644
--- a/engines/bladerunner/lights.cpp
+++ b/engines/bladerunner/lights.cpp
@@ -19,7 +19,7 @@ Lights::~Lights()
reset();
}
-void Lights::read(Common::ReadStream* stream, int framesCount)
+void Lights::read(Common::ReadStream *stream, int framesCount)
{
_ambientLightColor.r = stream->readFloatLE();
_ambientLightColor.g = stream->readFloatLE();
@@ -58,11 +58,66 @@ void Lights::read(Common::ReadStream* stream, int framesCount)
}
}
-void Lights::readVqa(Common::ReadStream* stream)
+void Lights::removeAnimated()
{
- reset();
- //int framesCount = stream->readUint32LE();
- //int count = stream->readUint32LE();
+ Light **nextLight;
+ Light *light;
+
+ nextLight = &this->_lights;
+ light = this->_lights;
+ if (light)
+ {
+ do
+ {
+ if (light->_animated)
+ {
+ *nextLight = light->_next;
+ delete light;
+ }
+ else
+ {
+ nextLight = &light->_next;
+ }
+ light = *nextLight;
+ } while (*nextLight);
+ }
+}
+
+void Lights::readVqa(Common::ReadStream *stream)
+{
+ removeAnimated();
+ if (stream->eos())
+ return;
+
+ int framesCount = stream->readUint32LE();
+ int count = stream->readUint32LE();
+ for (int i = 0; i < count; i++) {
+ int lightType = stream->readUint32LE();
+ Light* light;
+ switch(lightType)
+ {
+ case 5:
+ light = new Light5();
+ break;
+ case 4:
+ light = new Light4();
+ break;
+ case 3:
+ light = new Light3();
+ break;
+ case 2:
+ light = new Light2();
+ break;
+ case 1:
+ light = new Light1();
+ break;
+ default:
+ light = new Light();
+ }
+ light->readVqa(stream, framesCount, _frame, 1);
+ light->_next = _lights;
+ _lights = light;
+ }
}
void Lights::setupFrame(int frame)
diff --git a/engines/bladerunner/lights.h b/engines/bladerunner/lights.h
index 71e6d21b2f..0db7a07fe8 100644
--- a/engines/bladerunner/lights.h
+++ b/engines/bladerunner/lights.h
@@ -52,6 +52,8 @@ public:
void reset();
void setupFrame(int frame);
+private:
+ void removeAnimated();
};
} // End of namespace BladeRunner
diff --git a/engines/bladerunner/module.mk b/engines/bladerunner/module.mk
index e6b8e43584..60bea4a368 100644
--- a/engines/bladerunner/module.mk
+++ b/engines/bladerunner/module.mk
@@ -37,7 +37,120 @@ MODULE_OBJS = \
script/ai_00_mccoy.o \
script/aiscript_officer_leroy.o \
script/init.o \
+ script/kia.o \
+ script/vk.o \
+ script/esper.o \
+ script/ar01.o \
+ script/ar02.o \
+ script/bb01.o \
+ script/bb02.o \
+ script/bb03.o \
+ script/bb04.o \
+ script/bb05.o \
+ script/bb06.o \
+ script/bb07.o \
+ script/bb08.o \
+ script/bb09.o \
+ script/bb10.o \
+ script/bb11.o \
+ script/bb12.o \
+ script/bb51.o \
+ script/ct01.o \
+ script/ct02.o \
+ script/ct03.o \
+ script/ct04.o \
+ script/ct05.o \
+ script/ct06.o \
+ script/ct07.o \
+ script/ct08.o \
+ script/ct09.o \
+ script/ct10.o \
+ script/ct11.o \
+ script/ct12.o \
+ script/ct51.o \
+ script/dr01.o \
+ script/dr02.o \
+ script/dr03.o \
+ script/dr04.o \
+ script/dr05.o \
+ script/dr06.o \
+ script/hc01.o \
+ script/hc02.o \
+ script/hc03.o \
+ script/hc04.o \
+ script/hf01.o \
+ script/hf02.o \
+ script/hf03.o \
+ script/hf04.o \
+ script/hf05.o \
+ script/hf06.o \
+ script/kp01.o \
+ script/kp02.o \
+ script/kp03.o \
+ script/kp04.o \
+ script/kp05.o \
+ script/kp06.o \
+ script/kp07.o \
+ script/ma01.o \
+ script/ma02.o \
+ script/ma04.o \
+ script/ma05.o \
+ script/ma06.o \
+ script/ma07.o \
+ script/ma08.o \
+ script/nr01.o \
+ script/nr02.o \
+ script/nr03.o \
+ script/nr04.o \
+ script/nr05.o \
+ script/nr06.o \
+ script/nr07.o \
+ script/nr08.o \
+ script/nr09.o \
+ script/nr10.o \
+ script/nr11.o \
+ script/ps01.o \
+ script/ps02.o \
+ script/ps03.o \
+ script/ps04.o \
+ script/ps05.o \
+ script/ps06.o \
+ script/ps07.o \
+ script/ps09.o \
+ script/ps10.o \
+ script/ps11.o \
+ script/ps12.o \
+ script/ps13.o \
+ script/ps14.o \
+ script/ps15.o \
script/rc01.o \
+ script/rc02.o \
+ script/rc03.o \
+ script/rc04.o \
+ script/rc51.o \
+ script/tb02.o \
+ script/tb03.o \
+ script/tb05.o \
+ script/tb06.o \
+ script/tb07.o \
+ script/ug01.o \
+ script/ug02.o \
+ script/ug03.o \
+ script/ug04.o \
+ script/ug05.o \
+ script/ug06.o \
+ script/ug07.o \
+ script/ug08.o \
+ script/ug09.o \
+ script/ug10.o \
+ script/ug12.o \
+ script/ug13.o \
+ script/ug14.o \
+ script/ug15.o \
+ script/ug16.o \
+ script/ug17.o \
+ script/ug18.o \
+ script/ug19.o \
script/script.o \
set.o \
settings.o \
diff --git a/engines/bladerunner/mouse.cpp b/engines/bladerunner/mouse.cpp
index ba747c2e94..14a2151e43 100644
--- a/engines/bladerunner/mouse.cpp
+++ b/engines/bladerunner/mouse.cpp
@@ -308,7 +308,7 @@ Vector3 Mouse::getXYZ(int x, int y)
int screenRight = 640 - x;
int screenDown = 480 - y;
- float zcoef = 1.0f / tan(_vm->_scene->_view._fovX / 2.0f);
+ float zcoef = 1.0f / tan(_vm->_view->_fovX / 2.0f);
float x3d = (2.0f / 640.0f * screenRight - 1.0f);
float y3d = (2.0f / 480.0f * screenDown - 1.0f) * 0.75f;
@@ -320,7 +320,7 @@ Vector3 Mouse::getXYZ(int x, int y)
pos.x = pos.z / zcoef * x3d;
pos.y = pos.z / zcoef * y3d;
- Matrix4x3 matrix = _vm->_scene->_view._frameViewMatrix;
+ Matrix4x3 matrix = _vm->_view->_frameViewMatrix;
matrix.unknown();
diff --git a/engines/bladerunner/scene.cpp b/engines/bladerunner/scene.cpp
index ba4ca44f1c..29d73f3070 100644
--- a/engines/bladerunner/scene.cpp
+++ b/engines/bladerunner/scene.cpp
@@ -136,7 +136,8 @@ int Scene::advanceFrame(Graphics::Surface &surface, uint16 *&zBuffer) {
if (frame >= 0) {
surface.copyFrom(*_vqaPlayer.getSurface());
memcpy(zBuffer, _vqaPlayer.getZBuffer(), 640*480*2);
- _view = _vqaPlayer.getView();
+ _vqaPlayer.updateView(_vm->_view);
+ _vqaPlayer.updateLights(_vm->_lights);
}
if (frame < 0) {
diff --git a/engines/bladerunner/scene.h b/engines/bladerunner/scene.h
index 1a3c9f38bf..e4a2406eea 100644
--- a/engines/bladerunner/scene.h
+++ b/engines/bladerunner/scene.h
@@ -56,7 +56,6 @@ public:
Vector3 _actorStartPosition;
int _actorStartFacing;
bool _playerWalkedIn;
- View _view;
Regions* _regions;
Regions* _exits;
@@ -64,7 +63,6 @@ public:
// _default_loop_id = 0;
// _scene_vqa_frame_number = -1;
-
public:
Scene(BladeRunnerEngine *vm)
: _vm(vm),
diff --git a/engines/bladerunner/script/ar01.cpp b/engines/bladerunner/script/ar01.cpp
new file mode 100644
index 0000000000..dda8a8c3b9
--- /dev/null
+++ b/engines/bladerunner/script/ar01.cpp
@@ -0,0 +1,361 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptAR01::InitializeScene() {
+ Music_Play(0, 25, 0, 2, -1, 1, 2);
+ if (Game_Flag_Query(323)) {
+ Setup_Scene_Information(-477.0f, 0.0f, -149.0f, 333);
+ } else if (Game_Flag_Query(321) == 1) {
+ Setup_Scene_Information(-182.0f, 0.0f, -551.0f, 518);
+ } else {
+ Setup_Scene_Information(-152.0f, 0.0f, 332.0f, 545);
+ }
+ Scene_Exit_Add_2D_Exit(0, 134, 165, 177, 290, 3);
+ Scene_Exit_Add_2D_Exit(1, 319, 0, 639, 207, 0);
+ if (Game_Flag_Query(252)) {
+ Scene_Exit_Add_2D_Exit(2, 0, 404, 99, 479, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(81, 60, 100, 1);
+ Ambient_Sounds_Add_Looping_Sound(241, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Ambient_Sounds_Add_Sound(242, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(243, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(244, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(245, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(246, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(247, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(248, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(249, 3, 30, 11, 11, 50, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(68, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ 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(252) && !Game_Flag_Query(321) && !Game_Flag_Query(323)) {
+ Actor_Set_Invisible(0, true);
+ Game_Flag_Set(273);
+ Scene_Loop_Start_Special(0, 1, 0);
+ Scene_Loop_Set_Default(2);
+ } else if (Game_Flag_Query(252) && Game_Flag_Query(321)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Reset(321);
+ } else if (!Game_Flag_Query(252) && Game_Flag_Query(321)) {
+ Scene_Loop_Start_Special(0, 6, 0);
+ Scene_Loop_Set_Default(7);
+ Game_Flag_Reset(321);
+ } else if (Game_Flag_Query(252) && Game_Flag_Query(323)) {
+ Scene_Loop_Set_Default(2);
+ } else if (!Game_Flag_Query(252) && Game_Flag_Query(323)) {
+ Scene_Loop_Set_Default(7);
+ } else {
+ Scene_Loop_Set_Default(7);
+ }
+}
+
+void ScriptAR01::SceneLoaded() {
+ Obstacle_Object("DF_BOOTH", true);
+ Unobstacle_Object("SPINNER BODY", true);
+}
+
+bool ScriptAR01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptAR01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptAR01::ClickedOnActor(int actorId) {
+ if (actorId == 16 || actorId == 20) {
+ Actor_Face_Actor(0, actorId, true);
+ Actor_Says(0, 8910, 14);
+ return true;
+ }
+ if (actorId == 29) {
+ Actor_Set_Goal_Number(29, 2);
+ if (!Loop_Actor_Walk_To_XYZ(0, -120.73f, 0.0f, 219.17f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 29, true);
+ Actor_Face_Actor(29, 0, true);
+ if (Game_Flag_Query(328)) {
+ if (Actor_Clue_Query(0, 93) && !Actor_Clue_Query(0, 64)) {
+ Actor_Says(0, 40, 11);
+ Actor_Says(29, 120, 14);
+ Actor_Says(0, 45, 17);
+ Actor_Says(29, 130, 14);
+ Actor_Says(29, 140, 14);
+ Actor_Says(0, 50, 13);
+ Actor_Says(29, 150, 14);
+ Actor_Clue_Acquire(0, 64, 1, 0);
+ } else {
+ if (Random_Query(1, 2) == 1) {
+ Actor_Says(0, 30, 17);
+ Actor_Says(29, 100, 14);
+ Actor_Says(29, 110, 14);
+ Actor_Says(0, 35, 13);
+ } else {
+ Actor_Says(0, 30, 17);
+ Actor_Says(29, 220, 14);
+ }
+ }
+ Actor_Set_Goal_Number(29, 1);
+ } else {
+ Actor_Says(0, 0, 18);
+ Actor_Says(29, 0, 14);
+ Actor_Says(29, 10, 14);
+ Actor_Says(29, 20, 14);
+ Actor_Says(29, 30, 14);
+ Actor_Says(0, 5, 17);
+ Actor_Says(29, 40, 14);
+ Actor_Says(0, 10, 13);
+ Actor_Says(29, 50, 14);
+ Actor_Says(0, 15, 17);
+ Actor_Says(29, 60, 14);
+ Actor_Says(29, 70, 14);
+ Actor_Says(29, 80, 14);
+ Actor_Says(29, 90, 14);
+ Actor_Says(0, 25, 13);
+ Game_Flag_Set(328);
+ Actor_Set_Goal_Number(29, 1);
+ }
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptAR01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptAR01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -358.0, 0.0, -149.0, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -477.0, 0.0, -149.0, 0, 0, false, 0);
+ Game_Flag_Set(322);
+ Game_Flag_Set(464);
+ Game_Flag_Reset(180);
+ Game_Flag_Set(479);
+ Set_Enter(8, 31);
+ Actor_Set_Goal_Number(29, 3);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -182.0, 0.0, -551.0, 0, 1, false, 0)) {
+ Game_Flag_Set(320);
+ Async_Actor_Walk_To_XYZ(0, -222.0, 0.0, -690.0, 0, false);
+ Set_Enter(0, 1);
+ Actor_Set_Goal_Number(29, 3);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (Game_Flag_Query(486) == 1) {
+ Spinner_Set_Selectable_Destination_Flag(6, 1);
+ }
+ int v1 = Loop_Actor_Walk_To_XYZ(0, -164.0f, 0.0f, 332.0f, 0, 1, false, 0);
+ Actor_Face_Heading(0, 545, false);
+ if (Actor_Query_Goal_Number(7) >= 2 && Actor_Query_Goal_Number(7) <= 103) {
+ Player_Loses_Control();
+ Actor_Put_In_Set(7, 0);
+ Actor_Set_At_XYZ(7, -448.0, 0.0, 130.0, 0);
+ Loop_Actor_Walk_To_XYZ(7, -323.0f, 0.64f, 101.74f, 48, 0, true, 0);
+ Loop_Actor_Walk_To_Actor(7, 0, 48, 0, true);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Change_Animation_Mode(7, 6);
+ Actor_Says(0, 1800, 21);
+ Actor_Change_Animation_Mode(0, 48);
+ Player_Gains_Control();
+ Actor_Retired_Here(0, 12, 48, 1, 7);
+ } else if (!v1) {
+ if (Game_Flag_Query(486) && !Game_Flag_Query(660)) {
+ Actor_Voice_Over(4310, 99);
+ Actor_Voice_Over(4320, 99);
+ Actor_Voice_Over(4330, 99);
+ Actor_Voice_Over(4340, 99);
+ Actor_Voice_Over(4350, 99);
+ 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);
+
+ int spinnerDest = Spinner_Interface_Choose_Dest(4, 0);
+ Actor_Face_Heading(0, 545, 0);
+
+ switch (spinnerDest) {
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(252);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ default:
+ Game_Flag_Set(180);
+ Actor_Set_Invisible(0, 0);
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptAR01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptAR01::SceneFrameAdvanced(int frame) {
+ if (frame == 16) {
+ Ambient_Sounds_Play_Sound(118, 40, 0, 0, 99);
+ }
+ if (frame == 78 || frame == 199) {
+ Ambient_Sounds_Play_Sound(116, 100, -50, -50, 99);
+ }
+ if (frame == 122 || frame == 242) {
+ Ambient_Sounds_Play_Sound(119, 100, -50, -50, 99);
+ }
+ if (frame == 256) {
+ Ambient_Sounds_Play_Sound(117, 40, -50, 80, 99);
+ }
+ if ((frame == 75 || frame == 196) && Game_Flag_Query(273)) {
+ Actor_Face_Heading(0, 545, false);
+ Actor_Change_Animation_Mode(0, 42);
+ Game_Flag_Reset(273);
+ } else if (frame == 196 && !Game_Flag_Query(273)) {
+ Actor_Change_Animation_Mode(0, 41);
+ }
+}
+
+void ScriptAR01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptAR01::PlayerWalkedIn() {
+ if (!Game_Flag_Query(710)) {
+ Game_Flag_Set(710);
+ }
+ if (Game_Flag_Query(323) == 1) {
+ Loop_Actor_Walk_To_XYZ(0, -358.0f, 0.0f, -149.0f, 0, 1, false, 0);
+ Game_Flag_Reset(323);
+ }
+ if (Actor_Query_Goal_Number(37) < 199) {
+ Actor_Set_Goal_Number(37, 199);
+ }
+}
+
+void ScriptAR01::PlayerWalkedOut() {
+ Actor_Set_Invisible(0, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(479)) {
+ Music_Stop(2);
+ }
+ if (!Game_Flag_Query(322) && !Game_Flag_Query(320)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(38, 1, -1);
+ }
+}
+
+void ScriptAR01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ar02.cpp b/engines/bladerunner/script/ar02.cpp
new file mode 100644
index 0000000000..5b6be5f25b
--- /dev/null
+++ b/engines/bladerunner/script/ar02.cpp
@@ -0,0 +1,390 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptAR02::InitializeScene() {
+ Music_Play(0, 22, 0, 2, -1, 1, 2);
+ if (Game_Flag_Query(116)) {
+ Setup_Scene_Information(-560.0f, 0.0f, -799.0f, 333);
+ } else {
+ Setup_Scene_Information(-182.0f, 0.0f, -551.0f, 973);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 439, 212, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 81, 202, 215, 406, 3);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(81, 60, 100, 1);
+ Ambient_Sounds_Add_Looping_Sound(241, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Ambient_Sounds_Add_Sound(242, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(243, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(244, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(245, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(246, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(247, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(248, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(249, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(68, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ 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(252) && Game_Flag_Query(320)) {
+ Scene_Loop_Start_Special(0, 1, 0);
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Reset(320);
+ } else if (!Game_Flag_Query(252) && Game_Flag_Query(320)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Reset(320);
+ } else {
+ Scene_Loop_Set_Default(2);
+ }
+}
+
+void ScriptAR02::SceneLoaded() {
+ Obstacle_Object("DF_BOOTH", true);
+ if (!Game_Flag_Query(374)) {
+ Item_Add_To_World(106, 976, 0, -442.84f, 36.77f, -1144.51f, 360, 36, 36, false, true, false, true);
+ }
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(374)) {
+ Game_Flag_Set(0);
+ Item_Remove_From_World(106);
+ }
+}
+
+bool ScriptAR02::MouseClick(int x, int y) {
+ return Region_Check(250, 215, 325, 260);
+}
+
+bool ScriptAR02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptAR02::ClickedOnActor(int actorId) {
+ if (actorId == 16) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -386.96f, 0.0f, -1078.45f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 16, true);
+ Actor_Face_Actor(16, 0, true);
+ if (Global_Variable_Query(1) == 2) {
+ if (Game_Flag_Query(329) && !Game_Flag_Query(366)) {
+ Game_Flag_Set(366);
+ Player_Loses_Control();
+ ADQ_Flush();
+ ADQ_Add(16, 210, 14);
+ Loop_Actor_Walk_To_XYZ(0, -350.66f, 0.0f, -1117.19f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 16,true);
+ Actor_Says(0, 110, 18);
+ Actor_Says(16, 230, 14);
+ Actor_Says(0, 115, 18);
+ Actor_Says(16, 240, 14);
+ Item_Pickup_Spin_Effect(956, 288, 257);
+ Actor_Says(16, 250, 14);
+ Player_Gains_Control();
+ sub_402AE0();
+ } else if (Game_Flag_Query(329)) {
+ Actor_Says(0, 75, 18);
+ Actor_Says(16, 60, 12);
+ Actor_Says(16, 70, 14);
+ } else {
+ sub_402694();
+ }
+ } else if (Global_Variable_Query(1) > 2) {
+ if (Actor_Clue_Query(0, 56) && !Actor_Clue_Query(0, 90)) {
+ Actor_Says(0, 205, 16);
+ Actor_Says(16, 290, 12);
+ Actor_Says(16, 300, 13);
+ Actor_Says(0, 210, 15);
+ Actor_Says(16, 310, 12);
+ Actor_Says(0, 215, 13);
+ if (Game_Flag_Query(374)) {
+ Actor_Says(0, 220, 14);
+ Actor_Says(16, 320, 12);
+ Actor_Says(0, 225, 13);
+ Actor_Says(16, 330, 14);
+ Actor_Says(0, 230, 19);
+ Actor_Says(16, 340, 13);
+ Actor_Says(16, 350, 12);
+ Actor_Says(0, 235, 16);
+ Actor_Clue_Acquire(0, 79, 0, 16);
+ }
+ Actor_Clue_Acquire(0, 90, 0, 16);
+ } else {
+ Actor_Says(0, 240, 17);
+ Actor_Says(16, 360, 13);
+ Actor_Says(16, 370, 14);
+ Actor_Says(0, 245, 13);
+ }
+ }
+ return true;
+ }
+ }
+ if (actorId == 20 && Global_Variable_Query(1) == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -240.79f, 0.0f, -1328.89f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 20, true);
+ Actor_Face_Actor(20, 0, true);
+ if (Game_Flag_Query(330)) {
+ sub_402CE4();
+ return false;
+ }
+ Actor_Says(20, 0, 14);
+ Actor_Says(0, 140, 18);
+ Game_Flag_Set(330);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptAR02::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 106) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -386.96f, 0.0f, -1078.45f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 16, true);
+ if (!Game_Flag_Query(331)) {
+ Actor_Says(16, 0, 14);
+ Actor_Says(0, 55, 18);
+ Actor_Says(16, 10, 14);
+ Actor_Says(0, 60, 18);
+ Actor_Says(16, 20, 14);
+ Game_Flag_Set(331);
+ } else if (Game_Flag_Query(331) && !Game_Flag_Query(367)) {
+ Actor_Says(0, 65, 21);
+ Actor_Says(16, 30, 14);
+ Actor_Says(16, 40, 14);
+ Actor_Says(0, 70, 18);
+ Actor_Says(16, 50, 14);
+ Game_Flag_Set(367);
+ } else {
+ Actor_Says(0, 8527, 14);
+ }
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptAR02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -182.0f, 0.0f, -551.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(321);
+ Async_Actor_Walk_To_XYZ(0, -182.0f, 0.0f, -407.0f, 0, false);
+ Set_Enter(0, 0);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -465.0f, 0.0f, -799.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -560.0f, 0.0f, -799.0f, 0, 0, false, 0);
+ Game_Flag_Set(117);
+ Game_Flag_Reset(180);
+ Game_Flag_Set(182);
+ Music_Stop(3);
+ Set_Enter(70, 80);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptAR02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptAR02::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptAR02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptAR02::PlayerWalkedIn() {
+ if (Game_Flag_Query(116) == 1) {
+ Loop_Actor_Walk_To_XYZ(0, -465.0f, 0.0f, -799.0f, 0, 0, false, 0);
+ Game_Flag_Reset(116);
+ }
+ Game_Flag_Set(726);
+}
+
+void ScriptAR02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptAR02::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptAR02::sub_402694() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 44) || Actor_Clue_Query(0, 47)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(490, 3, 5, 5);
+ }
+ if (Actor_Clue_Query(0, 14) && !Actor_Clue_Query(0, 44) && !Actor_Clue_Query(0, 47)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(500, 3, 5, 5);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(510, 8, 3, -1);
+ Dialogue_Menu_Add_DONE_To_List(520);
+ Dialogue_Menu_Appear(320, 240);
+ int answerValue = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answerValue) {
+ case 490:
+ case 500:
+ if (answerValue == 490) {
+ Actor_Says(0, 145, 15);
+ } else {
+ Actor_Says(0, 150, 15);
+ }
+ Actor_Says(16, 80, 14);
+ Actor_Says(0, 80, 16);
+ Actor_Says(16, 90, 12);
+ Actor_Says(0, 85, 17);
+ Actor_Says(16, 100, 14);
+ Actor_Says(16, 110, 12);
+ Actor_Says(16, 120, 12);
+ Actor_Says(0, 90, 13);
+ Actor_Says(16, 130, 12);
+ Actor_Says(16, 140, 14);
+ Actor_Says(0, 95, 15);
+ Actor_Says(16, 150, 12);
+ Actor_Says(16, 160, 13);
+ Actor_Says(16, 170, 14);
+ Actor_Says(0, 100, 16);
+ Actor_Says(16, 180, 13);
+ Game_Flag_Set(329);
+ Actor_Clue_Acquire(0, 56, 1, 16);
+ break;
+ case 510:
+ Actor_Says(0, 8475, 12);
+ Actor_Says(16, 190, 12);
+ Actor_Says(0, 105, 15);
+ Actor_Says(16, 200, 14);
+ break;
+ case 520:
+ Actor_Says(0, 215, 16);
+ break;
+ }
+}
+
+void ScriptAR02::sub_402AE0() {
+ Dialogue_Menu_Clear_List();
+ if (Global_Variable_Query(2) >= 15 || !Query_Difficulty_Level()) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(530, 7, 5, 3);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(540, 3, 5, 7);
+ Dialogue_Menu_Appear(320, 240);
+ int answerValue = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answerValue == 530) {
+ Actor_Says(0, 120, 12);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 15);
+ }
+ Actor_Clue_Acquire(0, 75, 1, 16);
+ Actor_Modify_Friendliness_To_Other(16, 0, 5);
+ } else if (answerValue == 540) {
+ Actor_Says(0, 125, 13);
+ Actor_Says(16, 260, 3);
+ Actor_Says(0, 130, 15);
+ Actor_Says(16, 270, 3);
+ Actor_Says(16, 280, 3);
+ Actor_Says(0, 135, 11);
+ Actor_Modify_Friendliness_To_Other(16, 0, -5);
+ }
+}
+
+void ScriptAR02::sub_402CE4() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 93)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(550, 8, 5, 2);
+ }
+ if (Actor_Clue_Query(0, 44)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(560, 6, 5, 7);
+ }
+ Dialogue_Menu_Add_DONE_To_List(570);
+ Dialogue_Menu_Appear(320, 240);
+ int answerValue = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answerValue) {
+ case 550:
+ Actor_Says(0, 145, 11);
+ Actor_Says(20, 30, 11);
+ Actor_Says(0, 160, 11);
+ Actor_Says(20, 40, 11);
+ Actor_Says(0, 165, 11);
+ Actor_Says(20, 50, 11);
+ Actor_Says(0, 170, 11);
+ Actor_Says(20, 60, 11);
+ Actor_Says(0, 175, 11);
+ Game_Flag_Set(370);
+ break;
+ case 560:
+ Actor_Says(0, 150, 11);
+ Actor_Says(20, 140, 11);
+ Actor_Says(0, 185, 11);
+ Actor_Says(20, 150, 11);
+ Actor_Says(20, 160, 11);
+ Actor_Says(0, 190, 11);
+ Actor_Says(20, 170, 11);
+ Actor_Says(0, 195, 11);
+ Actor_Says(20, 180, 11);
+ Actor_Says(20, 190, 11);
+ Actor_Says(20, 200, 11);
+ Actor_Says(0, 200, 11);
+ Actor_Says(20, 210, 11);
+ Actor_Says(20, 220, 11);
+ Actor_Says(20, 230, 11);
+ Game_Flag_Set(370);
+ break;
+ case 570:
+ if (Actor_Clue_Query(0, 57)) {
+ Actor_Says(0, 1315, 11);
+ } else {
+ Actor_Says(0, 940, 13);
+ Actor_Says(20, 70, 12);
+ Actor_Says(20, 90, 12);
+ Actor_Says(0, 180, 15);
+ Actor_Says(20, 100, 14);
+ Actor_Says(20, 110, 12);
+ Actor_Says(20, 120, 13);
+ Actor_Modify_Friendliness_To_Other(20, 0, -1);
+ Actor_Clue_Acquire(0, 57, 0, 20);
+ }
+ break;
+ }
+}
+
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb01.cpp b/engines/bladerunner/script/bb01.cpp
new file mode 100644
index 0000000000..6024a42b09
--- /dev/null
+++ b/engines/bladerunner/script/bb01.cpp
@@ -0,0 +1,231 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB01::InitializeScene() {
+ if (Game_Flag_Query(265)) {
+ Setup_Scene_Information(-253.0f, 9.0f, 715.0f, 266);
+ } else if (Game_Flag_Query(263)) {
+ Setup_Scene_Information(-128.0f, 9.0f, 342.0f, 266);
+ } else {
+ Setup_Scene_Information(43.0f, 0.0f, 1058.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 72, 299, 3);
+ Scene_Exit_Add_2D_Exit(1, 151, 218, 322, 290, 3);
+ if (Game_Flag_Query(254)) {
+ Scene_Exit_Add_2D_Exit(2, 0, 311, 312, 479, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 25, -100, 0);
+ Ambient_Sounds_Add_Sound(82, 5, 60, 40, 60, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(83, 5, 60, 40, 65, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(84, 5, 60, 40, 60, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(67, 5, 80, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(66, 5, 80, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(378, 5, 120, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 5, 120, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(380, 5, 120, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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(254) && !Game_Flag_Query(265) && !Game_Flag_Query(263)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(254) && Game_Flag_Query(265)) {
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(254) && Game_Flag_Query(263)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(5);
+ }
+}
+
+void ScriptBB01::SceneLoaded() {
+ Obstacle_Object("COLUME", true);
+}
+
+bool ScriptBB01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ Loop_Actor_Walk_To_XYZ(0, -140.0f, 9.0f, 818.0f, 0, 1, false, 0);
+ if (!Loop_Actor_Walk_To_XYZ(0, -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, 26);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -125.39f, 9.0f, 372.45f, 0, 1, false, 0)) {
+ Game_Flag_Set(262);
+ Set_Enter(1, 3);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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);
+ switch (spinnerDest) {
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(254);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ default:
+ Game_Flag_Set(258);
+ Scene_Loop_Start_Special(2, 3, 1);
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB01::SceneFrameAdvanced(int frame) {
+ if (frame == 193) {
+ Sound_Play(118, 40, 0, 0, 50);
+ }
+ if (frame == 241 || frame == 363) {
+ Sound_Play(116, 100, -50, -50, 50);
+ }
+ if (frame == 286 || frame == 407) {
+ Sound_Play(119, 100, -50, -50, 50);
+ }
+ if (frame == 433) {
+ Sound_Play(117, 40, -50, 80, 50);
+ }
+ if (frame == 120) {
+ Sound_Play(286, Random_Query(33, 33), 100, -100, 50);
+ }
+}
+
+void ScriptBB01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB01::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);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 43.0f, 0.0f, 954.0f, 0, 0, false, 0);
+ }
+}
+
+void ScriptBB01::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptBB01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb02.cpp b/engines/bladerunner/script/bb02.cpp
new file mode 100644
index 0000000000..0fa6b0c237
--- /dev/null
+++ b/engines/bladerunner/script/bb02.cpp
@@ -0,0 +1,159 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB02::InitializeScene() {
+ if (Game_Flag_Query(281)) {
+ Setup_Scene_Information(179.0f, -415.06f, 274.0f, 904);
+ } else if (Game_Flag_Query(333)) {
+ Setup_Scene_Information(-12.0f, -415.06f, -27.0f, 264);
+ Scene_Loop_Start_Special(0, 0, 0);
+ } else {
+ Setup_Scene_Information(98.0f, -415.06f, -593.0f, 530);
+ Game_Flag_Reset(262);
+ }
+ Scene_Exit_Add_2D_Exit(0, 313, 137, 353, 173, 0);
+ Scene_Exit_Add_2D_Exit(1, 207, 291, 275, 443, 3);
+ Scene_Exit_Add_2D_Exit(2, 303, 422, 639, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(54, 20, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(82, 5, 60, 20, 40, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(83, 5, 60, 20, 45, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(84, 5, 60, 20, 40, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(90, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(72, 5, 80, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 80, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 80, 14, 16, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(494)) {
+ Game_Flag_Set(493);
+ Game_Flag_Set(494);
+ }
+ if (Game_Flag_Query(493)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(4);
+ }
+}
+
+void ScriptBB02::SceneLoaded() {
+ Obstacle_Object("ELEVATOR01", true);
+ Obstacle_Object("U2 DOOR", true);
+}
+
+bool ScriptBB02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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, 2);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -12.0f, -415.06f, -27.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ if (!Game_Flag_Query(493)) {
+ Scene_Loop_Start_Special(2, 0, 1);
+ }
+ Game_Flag_Set(332);
+ Game_Flag_Reset(493);
+ Set_Enter(1, 5);
+ Scene_Loop_Start_Special(1, 3, 0);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 86.0f, -415.06f, 174.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 179.0f, -415.06f, 274.0f, 0, 0, false, 0);
+ Game_Flag_Set(282);
+ Game_Flag_Reset(493);
+ Set_Enter(21, 4);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB02::SceneFrameAdvanced(int frame) {
+ if (frame == 1) {
+ Ambient_Sounds_Play_Sound(434, 40, -50, -50, 0);
+ }
+ if (frame == 124) {
+ Ambient_Sounds_Play_Sound(434, 40, -50, -50, 0);
+ }
+}
+
+void ScriptBB02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB02::PlayerWalkedIn() {
+ if (Game_Flag_Query(281)) {
+ Loop_Actor_Walk_To_XYZ(0, 86.0f, -415.06f, 174.0f, 0, 0, false, 0);
+ Game_Flag_Reset(281);
+ } else if (Game_Flag_Query(333)) {
+ Loop_Actor_Walk_To_XYZ(0, 35.0f, -415.06f, -27.0f, 0, 0, false, 0);
+ Player_Gains_Control();
+ Game_Flag_Reset(333);
+ }
+}
+
+void ScriptBB02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptBB02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb03.cpp b/engines/bladerunner/script/bb03.cpp
new file mode 100644
index 0000000000..24b4332ce8
--- /dev/null
+++ b/engines/bladerunner/script/bb03.cpp
@@ -0,0 +1,163 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB03::InitializeScene() {
+ Setup_Scene_Information(20.0f, 60.16f, 0.0f, 0);
+ Game_Flag_Reset(282);
+ if (Game_Flag_Query(284)) {
+ Setup_Scene_Information(176.0f, 60.16f, 0.0f, 900);
+ }
+ if (Game_Flag_Query(286)) {
+ Setup_Scene_Information(204.0f, 60.16f, -164.0f, 740);
+ }
+ Scene_Exit_Add_2D_Exit(0, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 167, 372, 439, 479, 2);
+ Scene_Exit_Add_2D_Exit(2, 451, 115, 547, 320, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 20, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 34, 100, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(90, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(72, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptBB03::SceneLoaded() {
+ Obstacle_Object("BACKWALL", true);
+ Unobstacle_Object("BOX08", true);
+}
+
+bool ScriptBB03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 176.0f, 60.16f, -64.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 176.0f, 60.16f, 0.0f, 0, 0, false, 0);
+ Game_Flag_Set(283);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(1, 5);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 20.0f, 60.16f, 0.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(281);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(1, 3);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 204.0f, 60.16f, -164.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) < 4) {
+ if (Actor_Query_Goal_Number(56) == 200) {
+ Actor_Says(56, 70, 3);
+ Actor_Says(0, 7010, 13);
+ Actor_Says(56, 80, 3);
+ Actor_Says(0, 7015, 12);
+ Actor_Says(56, 90, 3);
+ Actor_Says(0, 7020, 14);
+ Actor_Says(56, 100, 3);
+ Actor_Says(0, 7025, 15);
+ Actor_Says(56, 110, 3);
+ Actor_Set_Targetable(54, false);
+ Actor_Set_Targetable(58, false);
+ }
+ Game_Flag_Set(285);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(22, 6);
+ } else {
+ Actor_Says(0, 8522, 3);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB03::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptBB03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB03::PlayerWalkedIn() {
+ if (Game_Flag_Query(286)) {
+ Loop_Actor_Walk_To_XYZ(0, 164.0f, 60.16f, -164.0f, 0, 0, false, 0);
+ Game_Flag_Reset(286);
+ }
+ if (Game_Flag_Query(284)) {
+ Loop_Actor_Walk_To_XYZ(0, 176.0f, 60.16f, -64.0f, 0, 0, false, 0);
+ Game_Flag_Reset(284);
+ }
+}
+
+void ScriptBB03::PlayerWalkedOut() {
+
+}
+
+void ScriptBB03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb04.cpp b/engines/bladerunner/script/bb04.cpp
new file mode 100644
index 0000000000..ca96c11ef3
--- /dev/null
+++ b/engines/bladerunner/script/bb04.cpp
@@ -0,0 +1,132 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB04::InitializeScene() {
+ if (Game_Flag_Query(283)) {
+ Setup_Scene_Information(-107.0f, -26.6f, 397.0f, 29);
+ Game_Flag_Reset(283);
+ } else {
+ Setup_Scene_Information(-15.0f, -25.17f, 45.0f, 691);
+ }
+ Scene_Exit_Add_2D_Exit(0, 218, 102, 360, 254, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 334, 639, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(54, 20, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 44, -100, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(90, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(72, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 80, 20, 20, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptBB04::SceneLoaded() {
+ Obstacle_Object("DH TRASH", true);
+}
+
+bool ScriptBB04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB04::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -92.0f, -26.6f, 45.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -15.0f, -25.17f, 45.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(333);
+ Game_Flag_Set(493);
+ Set_Enter(1, 3);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -107.0f, -26.6f, 397.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(284);
+ Set_Enter(21, 4);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB04::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptBB04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB04::PlayerWalkedIn() {
+ if (Game_Flag_Query(332)) {
+ Loop_Actor_Walk_To_XYZ(0, -92.0f, -26.6f, 45.0f, 0, 0, false, 0);
+ Player_Gains_Control();
+ Game_Flag_Reset(332);
+ }
+}
+
+void ScriptBB04::PlayerWalkedOut() {
+
+}
+
+void ScriptBB04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb05.cpp b/engines/bladerunner/script/bb05.cpp
new file mode 100644
index 0000000000..1f2b9745ea
--- /dev/null
+++ b/engines/bladerunner/script/bb05.cpp
@@ -0,0 +1,215 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB05::InitializeScene() {
+ if (Game_Flag_Query(298)) {
+ Setup_Scene_Information(95.0f, -60.31f, 331.0f, 0);
+ } else if (Game_Flag_Query(302)) {
+ Setup_Scene_Information(87.0f, -60.34f, -96.0f, 0);
+ } else if (Game_Flag_Query(300)) {
+ Setup_Scene_Information(271.0f, -60.31f, 203.0f, 0);
+ } else {
+ Setup_Scene_Information(-212.0f, -60.31f, 131.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 92, 125, 187, 317, 3);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(2, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(3, 481, 113, 573, 307, 0);
+ Ambient_Sounds_Add_Looping_Sound(54, 12, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 28, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 14, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(90, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 50, 17, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(72, 5, 80, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 80, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 80, 14, 14, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(495)) {
+ Overlay_Play("BB05OVER", 0, 0, 0, 0);
+ Game_Flag_Set(495);
+ }
+}
+
+void ScriptBB05::SceneLoaded() {
+ Obstacle_Object("PINHEAD", true);
+ Obstacle_Object("X2WALLS&MOLDNG05", true);
+ Obstacle_Object("QUADPATCH04", true);
+ Unobstacle_Object("BOX16", true);
+ Clickable_Object("PINHEAD");
+ Clickable_Object("BOX06");
+ Unclickable_Object("BOX06");
+ Unclickable_Object("BOX14");
+ if (Actor_Query_Goal_Number(56) == 200) {
+ Actor_Set_Goal_Number(58, 299);
+ Actor_Put_In_Set(58, 97);
+ Actor_Set_At_Waypoint(58, 39, 0);
+ }
+}
+
+bool ScriptBB05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB05::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -212.0f, -60.31f, 131.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(286);
+ Set_Enter(21, 4);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 95.0f, -60.31f, 331.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(297);
+ Set_Enter(2, 7);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 271.0f, -60.31f, 203.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(299);
+ Set_Enter(3, 8);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 151.0f, -60.34f, -108.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(301);
+ Set_Enter(102, 120);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB05::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptBB05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB05::PlayerWalkedIn() {
+ if (Game_Flag_Query(298)) {
+ Loop_Actor_Walk_To_XYZ(0, 95.0f, -60.31f, 303.0f, 0, 0, false, 0);
+ Game_Flag_Reset(298);
+ } else if (Game_Flag_Query(300)) {
+ Loop_Actor_Walk_To_XYZ(0, 231.0f, -60.31f, 203.0f, 0, 0, false, 0);
+ Game_Flag_Reset(300);
+ } else if (Game_Flag_Query(302)) {
+ Loop_Actor_Walk_To_XYZ(0, 111.0f, -60.31f, -24.0f, 0, 0, false, 0);
+ Game_Flag_Reset(302);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -76.0f, -60.31f, 131.0f, 0, 0, false, 0);
+ Game_Flag_Reset(285);
+ }
+ if (Actor_Query_Goal_Number(56) == 200) {
+ Actor_Face_Actor(56, 0, true);
+ Actor_Face_Actor(0, 56, true);
+ Actor_Says(56, 120, 13);
+ Actor_Says(0, 7030, 15);
+ Actor_Says(56, 130, 17);
+ Actor_Says(56, 140, 16);
+ Actor_Says(56, 150, 14);
+ Actor_Says(56, 160, 15);
+ Actor_Says(0, 7035, 14);
+ Actor_Says(56, 170, 12);
+ Actor_Says(0, 7040, 14);
+ Actor_Says(56, 180, 16);
+ Actor_Says(0, 7045, 14);
+ if (Game_Flag_Query(399)) {
+ Actor_Says(56, 190, 15);
+ Actor_Says(0, 7050, 17);
+ Actor_Says(56, 200, 16);
+ Actor_Says_With_Pause(56, 210, 1.5f, 14);
+ Actor_Says(0, 7055, 15);
+ } else {
+ Actor_Put_In_Set(58, 22);
+ Actor_Set_At_Waypoint(58, 134, 0);
+ Loop_Actor_Walk_To_Waypoint(58, 135, 0, 0, false);
+ Actor_Says(58, 0, 3);
+ Actor_Face_Actor(0, 58, true);
+ Actor_Face_Actor(56, 58, true);
+ Actor_Says(56, 220, 13);
+ Loop_Actor_Walk_To_Waypoint(58, 134, 0, 0, false);
+ Actor_Face_Actor(56, 0, true);
+ Actor_Face_Actor(0, 56, true);
+ Actor_Says(56, 230, 15);
+ Actor_Says(0, 7060, 17);
+ Actor_Says(56, 240, 12);
+ }
+ Actor_Says(0, 7065, 16);
+ Actor_Says(56, 250, 16);
+ Actor_Says(0, 7070, 18);
+ Actor_Set_Goal_Number(56, 205);
+ Actor_Set_Goal_Number(58, 201);
+ Actor_Set_Goal_Number(54, 101);
+ Actor_Set_Goal_Number(58, 200);
+ }
+}
+
+void ScriptBB05::PlayerWalkedOut() {
+
+}
+
+void ScriptBB05::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb06.cpp b/engines/bladerunner/script/bb06.cpp
new file mode 100644
index 0000000000..d389fcceb6
--- /dev/null
+++ b/engines/bladerunner/script/bb06.cpp
@@ -0,0 +1,178 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB06::InitializeScene() {
+ if (Game_Flag_Query(394)) {
+ Setup_Scene_Information(76.0f, 0.0f, 79.0f, 622);
+ } else if (Game_Flag_Query(395)) {
+ Setup_Scene_Information(55.0f, 0.0f, -96.0f, 761);
+ } else if (Game_Flag_Query(362)) {
+ Setup_Scene_Information(-115.0f, 0.0f, -103.0f, 375);
+ Game_Flag_Reset(362);
+ } else {
+ Setup_Scene_Information(-37.0f, 0.0f, 178.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 43, 14, 478, 3);
+ Scene_Exit_Add_2D_Exit(1, 425, 0, 639, 361, 0);
+ Scene_Exit_Add_2D_Exit(3, 195, 164, 239, 280, 3);
+ Ambient_Sounds_Add_Looping_Sound(103, 28, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(394) || Game_Flag_Query(395)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(394);
+ Game_Flag_Reset(395);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+ if (Game_Flag_Query(410)) {
+ Overlay_Play("BB06OVER", 1, 1, 0, 0);
+ }
+}
+
+void ScriptBB06::SceneLoaded() {
+ Obstacle_Object("V2CHESSTBL01", true);
+ Clickable_Object("BOX31");
+ Item_Add_To_World(77, 931, 2, -127.0f, 68.42f, 57.0f, 0, 8, 8, true, true, false, true);
+}
+
+bool ScriptBB06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB06::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BOX31", objectName)) {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "BOX31", 24, 1, false)) {
+ Actor_Face_Object(0, "BOX31", true);
+ if (Game_Flag_Query(410)) {
+ Actor_Voice_Over(60, 99);
+ Actor_Voice_Over(70, 99);
+ } else {
+ Actor_Voice_Over(50, 99);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptBB06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB06::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 77) {
+ if (Player_Query_Combat_Mode()) {
+ Overlay_Play("BB06OVER", 1, 1, 1, 0);
+ Game_Flag_Set(410);
+ Item_Remove_From_World(77);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptBB06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -37.0f, 0.0f, 178.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(298);
+ Set_Enter(22, 6);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 101.0f, 0.0f, -25.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(393);
+ Set_Enter(1, 104);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -115.0f, 0.0f, -103.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(363);
+ Set_Enter(2, 8);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB06::SceneFrameAdvanced(int frame) {
+ if (frame == 34) {
+ Ambient_Sounds_Play_Sound(447, 40, -50, -50, 10);
+ }
+ if (frame == 16) {
+ Ambient_Sounds_Play_Sound(448, 20, -50, -50, 10);
+ }
+ if (frame == 20) {
+ Ambient_Sounds_Play_Sound(448, 20, -50, -50, 10);
+ }
+ if (frame == 25) {
+ Ambient_Sounds_Play_Sound(448, 20, -50, -50, 10);
+ }
+ if (frame == 29) {
+ Ambient_Sounds_Play_Sound(448, 20, -50, -50, 10);
+ }
+}
+
+void ScriptBB06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB06::PlayerWalkedIn() {
+ if (Game_Flag_Query(297)) {
+ Loop_Actor_Walk_To_XYZ(0, -36.0f, 0.0f, 145.0f, 0, 0, false, 0);
+ Game_Flag_Reset(297);
+ }
+}
+
+void ScriptBB06::PlayerWalkedOut() {
+
+}
+
+void ScriptBB06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb07.cpp b/engines/bladerunner/script/bb07.cpp
new file mode 100644
index 0000000000..3284df89f1
--- /dev/null
+++ b/engines/bladerunner/script/bb07.cpp
@@ -0,0 +1,186 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB07::InitializeScene() {
+ if (Game_Flag_Query(365)) {
+ Setup_Scene_Information(-655.0f, 252.59f, -1136.0f, 323);
+ } else if (Game_Flag_Query(363)) {
+ Setup_Scene_Information(-551.0f, 252.59f, -1004.0f, 29);
+ Game_Flag_Reset(363);
+ } else {
+ Setup_Scene_Information(-652.0f, 252.59f, -1018.0f, 268);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 16, 51, 426, 3);
+ Scene_Exit_Add_2D_Exit(1, 124, 101, 172, 305, 3);
+ Scene_Exit_Add_2D_Exit(2, 282, 408, 476, 479, 2);
+ Scene_2D_Region_Add(0, 308, 283, 354, 308);
+ Ambient_Sounds_Add_Looping_Sound(332, 44, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(331, 24, 0, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Overlay_Play("BB07OVER", 0, 1, 0, 0);
+}
+
+void ScriptBB07::SceneLoaded() {
+ Obstacle_Object("COUCH", true);
+ Unobstacle_Object("X2MAINWALLLEFT01", true);
+ Clickable_Object("PRINTER");
+}
+
+bool ScriptBB07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB07::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("PRINTER", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -472.63f, 252.59f, -1086.81f, 0, 0, false, 0)) {
+ Actor_Face_Object(0, "PRINTER", true);
+ if (Game_Flag_Query(396) && !Game_Flag_Query(398)) {
+ Actor_Voice_Over(130, 99);
+ Item_Pickup_Spin_Effect(941, 439, 242);
+ Actor_Voice_Over(140, 99);
+ Game_Flag_Set(398);
+ Actor_Clue_Acquire(0, 148, 1, -1);
+ } else if (Game_Flag_Query(396) && Game_Flag_Query(398)) {
+ Actor_Face_Object(0, "PRINTER", true);
+ Actor_Says(0, 8570, 13);
+ } else {
+ Actor_Face_Object(0, "PRINTER", true);
+ Actor_Says(0, 8575, 13);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptBB07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB07::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 83) {
+ if (!Loop_Actor_Walk_To_Item(0, 83, 36, 1, false)) {
+ Actor_Face_Item(0, 83, true);
+ if (Game_Flag_Query(396) == 1) {
+ Actor_Voice_Over(150, 99);
+ Actor_Voice_Over(160, 99);
+ Actor_Voice_Over(170, 99);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptBB07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -615.0f, 252.59f, -1018.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Overlay_Remove("BB07OVER");
+ Game_Flag_Set(300);
+ Set_Enter(22, 6);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -619.0f, 252.59f, -1136.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Overlay_Remove("BB07OVER");
+ Game_Flag_Set(364);
+ Set_Enter(102, 120);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -551.0f, 252.59f, -1004.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Overlay_Remove("BB07OVER");
+ Game_Flag_Set(362);
+ Set_Enter(2, 7);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB07::ClickedOn2DRegion(int region) {
+ if (region == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -568.63f, 252.59f, -1114.81f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 229, false);
+ if (Game_Flag_Query(396)) {
+ Actor_Says(0, 8585, 15);
+ } else {
+ Ambient_Sounds_Play_Sound(592, 40, 20, 20, 99);
+ Overlay_Play("BB07OVER", 1, 0, 1, 0);
+ Overlay_Play("BB07OVER", 2, 1, 0, 0);
+ Game_Flag_Set(396);
+ if (!Game_Flag_Query(398)) {
+ Actor_Says(39, 0, 3);
+ }
+ }
+ }
+ }
+ return false;
+}
+
+void ScriptBB07::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptBB07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB07::PlayerWalkedIn() {
+ if (Game_Flag_Query(299)) {
+ Loop_Actor_Walk_To_XYZ(0, -594.0f, 252.59f, -1018.0f, 6, 0, false, 0);
+ Game_Flag_Reset(299);
+ }
+ if (Game_Flag_Query(365)) {
+ Loop_Actor_Walk_To_XYZ(0, -602.0f, 252.59f, -1124.0f, 6, 0, false, 0);
+ Game_Flag_Reset(365);
+ }
+}
+
+void ScriptBB07::PlayerWalkedOut() {
+
+}
+
+void ScriptBB07::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb08.cpp b/engines/bladerunner/script/bb08.cpp
new file mode 100644
index 0000000000..cd05fe84b7
--- /dev/null
+++ b/engines/bladerunner/script/bb08.cpp
@@ -0,0 +1,138 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB08::InitializeScene() {
+ if (Game_Flag_Query(219)) {
+ Setup_Scene_Information(204.0f, 0.0f, 92.0f, 875);
+ } else {
+ Setup_Scene_Information(247.0f, 0.0f, 27.0f, 790);
+ }
+ Scene_Exit_Add_2D_Exit(0, 307, 0, 361, 238, 0);
+ Scene_Exit_Add_2D_Exit(1, 117, 38, 214, 245, 0);
+ Ambient_Sounds_Add_Looping_Sound(105, 44, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 1, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 1, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 1, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 1, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 1, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(496)) {
+ Overlay_Play("BB08OVER", 0, 0, 0, 0);
+ Game_Flag_Set(496);
+ }
+}
+
+void ScriptBB08::SceneLoaded() {
+ Obstacle_Object("BATHTUB", true);
+ Unobstacle_Object("DOORWAY", true);
+ Unclickable_Object("BATHTUB");
+}
+
+bool ScriptBB08::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB08::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB08::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB08::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB08::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 204.0f, 0.1f, 94.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 256, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Ladder(0, 8, 1, 0);
+ 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, 10);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 247.0f, 0.1f, 27.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(506);
+ Set_Enter(102, 120);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB08::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB08::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptBB08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB08::PlayerWalkedIn() {
+ if (Game_Flag_Query(219)) {
+ Actor_Set_At_XYZ(0, 204.0f, 96.1f, 94.0f, 256);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Ladder(0, 8, 0, 0);
+ Footstep_Sound_Override_Off();
+ Actor_Face_Heading(0, 768, false);
+ Game_Flag_Reset(219);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 188.0f, 0.1f, 28.0f, 0, 0, false, 0);
+ }
+}
+
+void ScriptBB08::PlayerWalkedOut() {
+
+}
+
+void ScriptBB08::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb09.cpp b/engines/bladerunner/script/bb09.cpp
new file mode 100644
index 0000000000..0d672612ae
--- /dev/null
+++ b/engines/bladerunner/script/bb09.cpp
@@ -0,0 +1,124 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB09::InitializeScene() {
+ Setup_Scene_Information(111.2f, -8.96f, 134.65f, 0);
+ if (Game_Flag_Query(221)) {
+ Game_Flag_Reset(221);
+ Setup_Scene_Information(115.45f, -8.96f, 134.0f, 628);
+ } else if (Game_Flag_Query(218)) {
+ Game_Flag_Reset(218);
+ Setup_Scene_Information(107.45f, -9.14f, 166.0f, 244);
+ }
+ Scene_Exit_Add_2D_Exit(0, 224, 213, 286, 353, 1);
+ Scene_Exit_Add_2D_Exit(1, 75, 450, 480, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(54, 20, 100, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 50, 55, 1);
+ Ambient_Sounds_Add_Sound(297, 5, 20, 20, 25, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(298, 5, 20, 20, 25, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(299, 5, 20, 20, 25, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Actor_Set_Targetable(8, true);
+}
+
+void ScriptBB09::SceneLoaded() {
+ Obstacle_Object("WICKER CHAIR ", true);
+ Unobstacle_Object("ROOM03 RIGHT WALL", true);
+ Unclickable_Object("WICKER CHAIR ");
+}
+
+bool ScriptBB09::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB09::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB09::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB09::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB09::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 454.56f, -9.0f, 190.31f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 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, 11);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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, 9);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB09::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB09::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptBB09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB09::PlayerWalkedIn() {
+}
+
+void ScriptBB09::PlayerWalkedOut() {
+}
+
+void ScriptBB09::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb10.cpp b/engines/bladerunner/script/bb10.cpp
new file mode 100644
index 0000000000..3a28ebb104
--- /dev/null
+++ b/engines/bladerunner/script/bb10.cpp
@@ -0,0 +1,205 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB10::InitializeScene() {
+ if (Game_Flag_Query(223)) {
+ Setup_Scene_Information(255.29f, 90.24f, -103.0f, 830);
+ } else if (Game_Flag_Query(220)) {
+ Game_Flag_Reset(220);
+ Setup_Scene_Information(151.67f, 66.84f, -313.06f, 0);
+ } else {
+ Setup_Scene_Information(199.67f, 67.4f, -169.06f, 628);
+ }
+ if (Global_Variable_Query(36) > 2) {
+ Scene_Exit_Add_2D_Exit(0, 281, 0, 531, 115, 0);
+ }
+ Scene_Exit_Add_2D_Exit(1, 58, 91, 193, 401, 3);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Add_Looping_Sound(382, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(466)) {
+ Scene_2D_Region_Add(0, 458, 99, 522, 133);
+ Overlay_Play("BB10OVR1", 0, 1, 0, 0);
+ }
+ if (!Game_Flag_Query(467)) {
+ Scene_2D_Region_Add(1, 459, 164, 522, 193);
+ Overlay_Play("BB10OVR2", 0, 1, 0, 0);
+ }
+ if (!Game_Flag_Query(468)) {
+ Scene_2D_Region_Add(2, 458, 194, 522, 223);
+ Overlay_Play("BB10OVR3", 0, 1, 0, 0);
+ }
+ if (!Game_Flag_Query(469)) {
+ Scene_2D_Region_Add(3, 458, 255, 522, 278);
+ Overlay_Play("BB10OVR4", 0, 1, 0, 0);
+ }
+ if (!Game_Flag_Query(470)) {
+ Scene_2D_Region_Add(4, 458, 316, 522, 335);
+ Overlay_Play("BB10OVR5", 0, 1, 0, 0);
+ }
+}
+
+void ScriptBB10::SceneLoaded() {
+ Obstacle_Object("BARB NIGHT", true);
+ Unclickable_Object("BARB NIGHT");
+ Unobstacle_Object("Box-Floor Hole01", true);
+ Unobstacle_Object("Box-Floor Hole02", true);
+ Unobstacle_Object("Box-Floor Hole03", true);
+}
+
+bool ScriptBB10::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB10::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB10::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB10::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB10::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 225.58f, 67.2f, -102.1f, 0, 1, false, 0)) {
+ Player_Set_Combat_Mode(false);
+ Actor_Face_Heading(0, 274, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 2, 1, 0);
+ Footstep_Sound_Override_Off();
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Ladder(0, 3, 1, 0);
+ 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, 12);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 206.01f, 66.84f, -261.62f, 0, 1, false, 0) && !Loop_Actor_Walk_To_XYZ(0, 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, 10);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB10::ClickedOn2DRegion(int region) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 225.58f, 67.2f, -102.1f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 274, false);
+ Sound_Play(Random_Query(289, 290), 40, 70, 70, 50);
+ switch (region) {
+ case 4:
+ Overlay_Remove("BB10OVR5");
+ Game_Flag_Set(470);
+ Scene_2D_Region_Remove(4);
+ break;
+ case 3:
+ Overlay_Remove("BB10OVR4");
+ Game_Flag_Set(469);
+ Scene_2D_Region_Remove(3);
+ break;
+ case 2:
+ Overlay_Remove("BB10OVR3");
+ Game_Flag_Set(468);
+ Scene_2D_Region_Remove(2);
+ break;
+ case 1:
+ Overlay_Remove("BB10OVR2");
+ Game_Flag_Set(467);
+ Scene_2D_Region_Remove(1);
+ break;
+ case 0:
+ Overlay_Remove("BB10OVR1");
+ Game_Flag_Set(466);
+ Scene_2D_Region_Remove(0);
+ break;
+ default:
+ break;
+ }
+ Global_Variable_Increment(36, 1);
+ if (Global_Variable_Query(36) > 4) {
+ Scene_Exit_Add_2D_Exit(0, 281, 0, 531, 115, 0);
+ }
+ return false;
+ }
+ return true;
+}
+
+void ScriptBB10::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptBB10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB10::PlayerWalkedIn() {
+ if (Game_Flag_Query(216)) {
+ Player_Loses_Control();
+ Actor_Set_At_XYZ(0, 214.01f, 66.84f, -349.62f, 462);
+ Loop_Actor_Walk_To_XYZ(0, 206.01f, 66.84f, -261.62f, 0, 0, false, 0);
+ Player_Gains_Control();
+ Game_Flag_Reset(216);
+ } else if (Game_Flag_Query(223)) {
+ Actor_Set_At_XYZ(0, 249.58f, 127.2f, -102.1f, 256);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Ladder(0, 3, 0, 0);
+ Footstep_Sound_Override_Off();
+ Actor_Face_Heading(0, 768, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 3, 0, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Reset(223);
+ }
+}
+
+void ScriptBB10::PlayerWalkedOut() {
+}
+
+void ScriptBB10::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb11.cpp b/engines/bladerunner/script/bb11.cpp
new file mode 100644
index 0000000000..686172d965
--- /dev/null
+++ b/engines/bladerunner/script/bb11.cpp
@@ -0,0 +1,132 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB11::InitializeScene() {
+ Setup_Scene_Information(43.39f, -10.27f, -20.52f, 200);
+ if (!Game_Flag_Query(509)) {
+ Scene_Exit_Add_2D_Exit(0, 280, 154, 388, 247, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(101, 90, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(99, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(100, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(68, 5, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 5, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(509)) {
+ Preload(19);
+ Preload(220);
+ Preload(227);
+ Preload(328);
+ Preload(343);
+ Preload(344);
+ Preload(17);
+ Preload(14);
+ Preload(324);
+ Preload(323);
+ Preload(18);
+ Preload(345);
+ }
+}
+
+void ScriptBB11::SceneLoaded() {
+ Obstacle_Object("X2AIRCON01", true);
+ Unclickable_Object("X2AIRCON01");
+ if (Game_Flag_Query(509)) {
+ Unobstacle_Object("X2PIPES01", true);
+ Unobstacle_Object("X2PIPES02", true);
+ Unobstacle_Object("X2PIPES03", true);
+ Unobstacle_Object("X2_VENTS05", true);
+ Unobstacle_Object("X2_VENTSCYL05", true);
+ }
+}
+
+bool ScriptBB11::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB11::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB11::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB11::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB11::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 43.39f, -10.27f, -68.52f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(223);
+ Set_Enter(25, 11);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB11::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB11::SceneFrameAdvanced(int frame) {
+ if (Actor_Query_Goal_Number(8) == 105 && !Game_Flag_Query(375)) {
+ Actor_Change_Animation_Mode(0, 48);
+ Game_Flag_Set(375);
+ } else {
+ if (frame == 1) {
+ Sound_Play(74, 10, -100, 100, 50);
+ }
+ }
+}
+
+void ScriptBB11::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB11::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(8) == 102 && Global_Variable_Query(1) == 2) {
+ Actor_Set_Invisible(0, true);
+ Actor_Set_Goal_Number(8, 103);
+ Music_Play(11, 61, 0, 1, -1, 0, 0);
+ Player_Loses_Control();
+ }
+}
+
+void ScriptBB11::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptBB11::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb12.cpp b/engines/bladerunner/script/bb12.cpp
new file mode 100644
index 0000000000..336b0592cb
--- /dev/null
+++ b/engines/bladerunner/script/bb12.cpp
@@ -0,0 +1,144 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB12::InitializeScene() {
+ if (Game_Flag_Query(364)) {
+ Setup_Scene_Information(138.0f, 0.0f, 104.0f, 760);
+ } else if (Game_Flag_Query(506)) {
+ Setup_Scene_Information(-129.0f, 0.0f, 64.0f, 307);
+ } else {
+ Setup_Scene_Information(54.0f, 0.0f, 200.0f, 0);
+ Game_Flag_Reset(301);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(2, 377, 374, 533, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(103, 28, 0, 1);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 27, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 25, 25, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(497)) {
+ Overlay_Play("BB12OVER", 0, 0, 0, 0);
+ Game_Flag_Set(497);
+ }
+}
+
+void ScriptBB12::SceneLoaded() {
+ Obstacle_Object("BALLS", true);
+ Unclickable_Object("BALLS");
+}
+
+bool ScriptBB12::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB12::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptBB12::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB12::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB12::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -129.0f, 0.0f, 64.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(507);
+ Set_Enter(23, 9);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 138.0f, 0.0f, 104.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(365);
+ Set_Enter(3, 8);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 54.0f, 0.0f, 200.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(302);
+ Set_Enter(22, 6);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB12::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB12::SceneFrameAdvanced(int frame) {
+ if (frame == 10 || frame == 22 || frame == 33 || frame == 41) {
+ Sound_Play(311, 17, -30, -30, 50);
+ }
+ if (frame == 3) {
+ Sound_Play(313, 16, -30, -30, 50);
+ }
+}
+
+void ScriptBB12::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB12::PlayerWalkedIn() {
+ if (Game_Flag_Query(364)) {
+ Loop_Actor_Walk_To_XYZ(0, 114.0f, 0.0f, 104.0f, 0, 0, false, 0);
+ Game_Flag_Reset(364);
+ } else if (Game_Flag_Query(506)) {
+ Loop_Actor_Walk_To_XYZ(0, -101.0f, 0.0f, 64.0f, 0, 0, false, 0);
+ Game_Flag_Reset(506);
+ }
+}
+
+void ScriptBB12::PlayerWalkedOut() {
+}
+
+void ScriptBB12::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/bb51.cpp b/engines/bladerunner/script/bb51.cpp
new file mode 100644
index 0000000000..38079fa5be
--- /dev/null
+++ b/engines/bladerunner/script/bb51.cpp
@@ -0,0 +1,123 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptBB51::InitializeScene() {
+ Setup_Scene_Information(101.0f, 0.0f, -25.0f, 152);
+ Game_Flag_Reset(393);
+ Scene_Exit_Add_2D_Exit(0, 615, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 323, 241, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(103, 28, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 180, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(309, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(310, 5, 50, 17, 27, -100, 100, -101, -101, 0, 0);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptBB51::SceneLoaded() {
+ Obstacle_Object("V2CHESSTBL01", true);
+ Clickable_Object("V2CHESSTBL01");
+ Clickable_Object("TOP02");
+}
+
+bool ScriptBB51::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptBB51::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("V2CHESSTBL01", objectName)) {
+ Actor_Face_Object(0, "V2CHESSTBL01", true);
+ Actor_Voice_Over(80, 99);
+ Actor_Voice_Over(90, 99);
+ }
+ if (Object_Query_Click("TOP02", objectName)) {
+ Actor_Face_Object(0, "TOP02", true);
+ Actor_Voice_Over(100, 99);
+ Actor_Voice_Over(110, 99);
+ Actor_Voice_Over(120, 99);
+ }
+ return false;
+}
+
+bool ScriptBB51::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptBB51::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptBB51::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 76.0f, 0.0f, 79.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(394);
+ Set_Enter(1, 7);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 55.0f, 0.0f, -96.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(395);
+ Set_Enter(1, 7);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptBB51::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptBB51::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptBB51::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptBB51::PlayerWalkedIn() {
+}
+
+void ScriptBB51::PlayerWalkedOut() {
+}
+
+void ScriptBB51::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct01.cpp b/engines/bladerunner/script/ct01.cpp
new file mode 100644
index 0000000000..88e41faf31
--- /dev/null
+++ b/engines/bladerunner/script/ct01.cpp
@@ -0,0 +1,514 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT01::InitializeScene() {
+ Music_Play(3, 28, 0, 2, -1, 1, 0);
+ Game_Flag_Reset(247);
+ if (Game_Flag_Query(68)) {
+ Game_Flag_Reset(68);
+ Setup_Scene_Information(-35.2f, -6.5f, 352.28f, 603);
+ } else if (Game_Flag_Query(71)) {
+ Game_Flag_Reset(71);
+ Setup_Scene_Information(-311.0f, -6.5f, 710.0f, 878);
+ } else if (Game_Flag_Query(88)) {
+ Game_Flag_Reset(88);
+ Setup_Scene_Information(-419.0f, -6.5f, 696.0f, 28);
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ if (Game_Flag_Query(248)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ } else {
+ Scene_Loop_Start_Special(0, 6, 0);
+ }
+ }
+ } else if (Game_Flag_Query(248)) {
+ Setup_Scene_Information(-530.0f, -6.5f, 241.0f, 506);
+ Game_Flag_Set(247);
+ } else {
+ Setup_Scene_Information(-397.0f, -6.5f, 471.0f, 250);
+ }
+ Scene_Exit_Add_2D_Exit(0, 290, 256, 360, 304, 1);
+ if (Actor_Clue_Query(0, 18)) {
+ Scene_Exit_Add_2D_Exit(1, 571, 233, 639, 367, 1);
+ }
+ if (Game_Flag_Query(94)) {
+ Scene_Exit_Add_2D_Exit(2, 506, 400, 639, 479, 2);
+ }
+ if (Game_Flag_Query(248)) {
+ Scene_Exit_Add_2D_Exit(3, 0, 286, 158, 350, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(55, 40, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 40, 100, 1);
+ Ambient_Sounds_Add_Sound(61, 10, 30, 16, 20, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(62, 10, 30, 16, 20, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(63, 10, 30, 16, 20, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(64, 10, 30, 16, 20, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 20, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 40, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 50, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 20, 40, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 20, 40, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 20, 40, 33, 50, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(248)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(7);
+ }
+}
+
+void ScriptCT01::SceneLoaded() {
+ Obstacle_Object("HYDRANT02", true);
+ Obstacle_Object("HOWWALLRT", true);
+ Obstacle_Object("HOW-CHAIR1", true);
+ Obstacle_Object("HOWWALLLFT", true);
+ Obstacle_Object("HOWDOOR01", true);
+ Unobstacle_Object("SPINNER BODY", true);
+ Unobstacle_Object("HOWFLOOR", true);
+ Unobstacle_Object("PAPER11", true);
+ Unobstacle_Object("PAPER16", true);
+ Unclickable_Object("HYDRANT02");
+ Unclickable_Object("TURBINE");
+ Unclickable_Object("SPINNER BODY");
+ Unclickable_Object("OBJECT04");
+}
+
+bool ScriptCT01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT01::ClickedOn3DObject(const char *objectName, bool a2) {
+ if ("ASIANSITTINGANDEATI" == objectName) { //bug?
+ Actor_Face_Object(0, "ASIANSITTINGANDEATI", true);
+ Actor_Says(0, 365, 13);
+ Actor_Says(28, 160, 13);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT01::ClickedOnActor(int actorId) {
+ if (actorId == 28) {
+ Actor_Set_Goal_Number(28, 50);
+ if (!Loop_Actor_Walk_To_XYZ(0, -335.23f, -6.5f, 578.97f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 28, true);
+ Actor_Face_Actor(28, 0, true);
+ if (!Game_Flag_Query(26)) {
+ Actor_Says(0, 260, 18);
+ Actor_Says(28, 0, 14);
+ Game_Flag_Set(26);
+ Actor_Set_Goal_Number(28, 0);
+ } else if (!Game_Flag_Query(30) && Actor_Query_Friendliness_To_Other(28, 0) >= 40) {
+ sub_40269C();
+ Actor_Set_Goal_Number(28, 0);
+ } else {
+ if (Game_Flag_Query(31)) {
+ Actor_Says(0, 330, 17);
+ Actor_Says(28, 130, 13);
+ Actor_Says(28, 140, 14);
+ } else if (Actor_Query_Friendliness_To_Other(28, 0) < 50) {
+ Actor_Says(0, 330, 13);
+ Actor_Says(28, 160, 15);
+ } else {
+ Actor_Says(0, 310, 11);
+ Actor_Says(28, 10, 16);
+ }
+ Actor_Set_Goal_Number(28, 0);
+ }
+ return true;
+ }
+ }
+ if (actorId == 19) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -335.23f, -6.5f, 578.97f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 19, true);
+ Actor_Says(0, 355, 18);
+ if (!Actor_Query_Goal_Number(19)) {
+ Actor_Says(19, 10, 16);
+ Actor_Face_Actor(28, 0, true);
+ Actor_Says(28, 150, 3);
+ Actor_Face_Actor(0, 28, true);
+ Actor_Says(0, 360, 13);
+ Actor_Modify_Friendliness_To_Other(28, 0, -5);
+ Actor_Modify_Friendliness_To_Other(19, 0, -4);
+ }
+ return true;
+ }
+ }
+ if (actorId == 2) {
+ //todo: some weird code in assembly EBP is used but may not be initialized, loc_401C78
+ if (!Actor_Query_Goal_Number(2)) {
+ if (Loop_Actor_Walk_To_XYZ(0, -338.1f, -6.5f, 419.65f, 6, 1, false, 0)) {
+ return false;
+ }
+ }
+
+ Actor_Face_Actor(0, 2, true);
+ if (!Game_Flag_Query(32)) {
+ Actor_Says(0, 335, 18);
+ Actor_Says(2, 20, 30);
+ Game_Flag_Set(32);
+ Actor_Clue_Acquire(2, 213, 1, 0);
+ Actor_Clue_Acquire(0, 214, 1, 0);
+ Actor_Modify_Friendliness_To_Other(2, 0, -1);
+ } else if (Actor_Query_Goal_Number(2)) {
+ Actor_Says(0, 365, 14);
+ } else {
+ Actor_Says(0, 340, 13);
+ Actor_Says(0, 345, 11);
+ Actor_Says(2, 30, 30);
+ Actor_Says(0, 350, 13);
+ Actor_Says(2, 40, 30);
+ Actor_Modify_Friendliness_To_Other(2, 0, -5);
+ Player_Loses_Control();
+ }
+ if (Actor_Query_Is_In_Current_Set(19)) {
+ Actor_Modify_Friendliness_To_Other(19, 0, -2);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -327.5f, -6.5f, 352.28f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_Waypoint(0, 106, 0, 0, false);
+ Player_Gains_Control();
+ Game_Flag_Reset(247);
+ Set_Enter(27, 14);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -259.0f, -6.5f, 710.0f, 0, 1, false, 0)) {
+ Game_Flag_Reset(247);
+ Set_Enter(5, 15);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -419.0f, -6.5f, 696.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(123);
+ Game_Flag_Reset(247);
+ Set_Enter(4, 24);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -314.0f, -6.5f, 326.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -330.0f, -6.5f, 221.0f, 0, 0, true, 0);
+ Loop_Actor_Walk_To_XYZ(0, -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);
+
+ switch (spinnerDest) {
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(248);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(247);
+ Game_Flag_Reset(248);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 5, 1);
+ break;
+ default:
+ Game_Flag_Set(176);
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -530.0f, -6.5f, 241.0f, 0, 0, true, 0);
+ Loop_Actor_Walk_To_XYZ(0, -330.0f, -6.5f, 221.0f, 0, 0, true, 0);
+ Loop_Actor_Walk_To_XYZ(0, -314.0f, -6.5f, 326.0f, 0, 0, false, 0);
+ Player_Gains_Control();
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT01::SceneFrameAdvanced(int frame) {
+ if ((frame < 316 || frame > 435) && !((frame - 1) % 10)) {
+ /*int v1;
+ int v2 = Random_Query(0, 1);
+ if (v2 <= 1) {
+ if (v2) {
+ v1 = 60;
+ } else {
+ v1 = 59;
+ }
+ }*/
+ Ambient_Sounds_Play_Sound(/*v1*/Random_Query(59, 60), 25, 30, 30, 0);
+ }
+ if (frame == 23) {
+ Ambient_Sounds_Play_Sound(118, 40, 99, 0, 0);
+ }
+ if (frame == 316) {
+ Ambient_Sounds_Play_Sound(373, 50, -50, 100, 99);
+ }
+ if (frame == 196 || frame == 452) {
+ int v3 = Random_Query(0, 6);
+ if (v3 == 0) {
+ Overlay_Play("ct01spnr", 0, 0, 1, 0);
+ if (Random_Query(0, 1)) {
+ Ambient_Sounds_Play_Sound(68, Random_Query(33, 50), 0, 0, 0);
+ } else {
+ Ambient_Sounds_Play_Sound(67, Random_Query(33, 50), 0, 0, 0);
+ }
+ } else if (v3 == 1) {
+ Overlay_Play("ct01spnr", 1, 0, 1, 0);
+ if (Random_Query(0, 1)) {
+ Ambient_Sounds_Play_Sound(69, Random_Query(33, 50), 0, 0, 0);
+ } else {
+ Ambient_Sounds_Play_Sound(66, Random_Query(33, 50), 0, 0, 0);
+ }
+
+ }
+ }
+}
+
+void ScriptCT01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT01::PlayerWalkedIn() {
+ if (Game_Flag_Query(234)) {
+ Loop_Actor_Walk_To_XYZ(0, -327.2f, -6.5f, 352.28f, 0, 0, false, 0);
+ Game_Flag_Reset(234);
+ } else {
+ if (!Game_Flag_Query(247)) {
+ Game_Flag_Reset(247);
+ }
+ Loop_Actor_Walk_To_XYZ(0, -330.0f, -6.5f, 221.0f, 0, 0, false, 0);
+ Loop_Actor_Walk_To_XYZ(0, -314.0f, -6.5f, 326.0f, 0, 0, false, 0);
+ if (!Game_Flag_Query(25)) {
+ Game_Flag_Set(25);
+ if (!Game_Flag_Query(378)) {
+ Actor_Voice_Over(200, 99);
+ Actor_Voice_Over(210, 99);
+ Actor_Voice_Over(220, 99);
+ }
+ }
+ }
+}
+
+void ScriptCT01::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ if (Game_Flag_Query(123)) {
+ Ambient_Sounds_Remove_Looping_Sound(55, true);
+ Ambient_Sounds_Remove_Looping_Sound(56, true);
+ } else {
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ }
+ Music_Stop(5);
+ if (!Game_Flag_Query(176) && Global_Variable_Query(1)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(38, 1, -1);
+ }
+}
+
+void ScriptCT01::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptCT01::sub_40269C() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 13)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(40, 4, 5, 6);
+ }
+ if ((Actor_Clue_Query(0, 8) || Actor_Clue_Query(0, 9)) && !Game_Flag_Query(27)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(50, 5, 5, 4);
+ }
+ if (Actor_Clue_Query(0, 8) && Actor_Clue_Query(0, 9) && Game_Flag_Query(27) && !Game_Flag_Query(28)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(60, 3, 5, 5);
+ }
+ if (Game_Flag_Query(293)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(80, 9, 9, 9);
+ } else if (Game_Flag_Query(29)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(80, 3, 4, 8);
+ }
+ if (Actor_Clue_Query(0, 30) && Actor_Clue_Query(0, 40) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(90, 5, 4, 5);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(70, 7, 3, -1);
+ Dialogue_Menu_Add_DONE_To_List(100);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 40:
+ Actor_Says(0, 265, 11);
+ Actor_Says(28, 20, 14);
+ if (Actor_Query_Is_In_Current_Set(19)) {
+ if (!Actor_Query_Goal_Number(19)) {
+ Actor_Face_Actor(28, 19, true);
+ Actor_Says(28, 120, 14);
+ Actor_Face_Actor(19, 28, true);
+ Actor_Says(19, 40, 18);
+ Actor_Face_Heading(19, 103, false);
+ Actor_Face_Actor(28, 0, true);
+ Actor_Modify_Friendliness_To_Other(19, 0, -2);
+ if (Actor_Query_Is_In_Current_Set(2)) {
+ Actor_Modify_Friendliness_To_Other(2, 0, -3);
+ Actor_Clue_Acquire(2, 213, 1, 0);
+ }
+ }
+ }
+ break;
+ case 50:
+ if (Actor_Clue_Query(0, 8) == 1) {
+ Actor_Says(0, 270, 11);
+ Actor_Says(28, 30, 16);
+ } else {
+ Actor_Says(0, 280, 11);
+ Actor_Says(28, 40, 14);
+ }
+ Game_Flag_Set(27);
+ break;
+ case 60:
+ if (Actor_Clue_Query(0, 9) == 1) {
+ Actor_Says(0, 270, 11);
+ Actor_Says(28, 40, 15);
+ } else {
+ Actor_Says(0, 270, 11);
+ Actor_Says(28, 30, 14);
+ }
+ Actor_Modify_Friendliness_To_Other(28, 0, 5);
+ Game_Flag_Set(28);
+ break;
+ case 70:
+ Actor_Says(0, 290, 13);
+ if (Actor_Query_Friendliness_To_Other(28, 0) <= 49 || Global_Variable_Query(2) <= 10 && Query_Difficulty_Level()) {
+ Actor_Says(28, 130, 15);
+ } else {
+ Actor_Says(28, 50, 3);
+ Actor_Says(28, 60, 3);
+ Actor_Face_Actor(28, 0, true);
+ Actor_Says(28, 70, 16);
+ Actor_Says(0, 325, 13);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 10);
+ }
+ Game_Flag_Set(192);
+ }
+ break;
+ case 80:
+ Actor_Says(0, 295, 11);
+ Actor_Says(28, 90, 14);
+ Actor_Says(28, 100, 13);
+ Actor_Clue_Acquire(0, 25, 1, 28);
+ Actor_Modify_Friendliness_To_Other(28, 0, -3);
+ break;
+ case 90:
+ Actor_Says(0, 300, 13);
+ Actor_Says(28, 110, 16);
+ break;
+ case 100:
+ Actor_Says(0, 305, 18);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct02.cpp b/engines/bladerunner/script/ct02.cpp
new file mode 100644
index 0000000000..aecf29139a
--- /dev/null
+++ b/engines/bladerunner/script/ct02.cpp
@@ -0,0 +1,294 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT02::InitializeScene() {
+ if (Game_Flag_Query(70)) {
+ Game_Flag_Reset(70);
+ Setup_Scene_Information(-154.83f, -145.11f, 9.39f, 516);
+ } else if (Game_Flag_Query(720)) {
+ Setup_Scene_Information(-213.82f, -145.11f, 214.43f, 82);
+ } else {
+ Setup_Scene_Information(-119.02f, -145.11f, 240.99f, 768);
+ }
+ Scene_Exit_Add_2D_Exit(0, 590, 0, 639, 479, 1);
+ if (Actor_Clue_Query(0, 18)) {
+ Scene_Exit_Add_2D_Exit(1, 332, 163, 404, 297, 0);
+ } else {
+ Overlay_Play("ct02over", 0, 1, 0, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(96, 25, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 38, 100, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 32, 0, 1);
+ Ambient_Sounds_Add_Sound(61, 10, 30, 8, 8, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(62, 10, 30, 7, 7, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(63, 10, 30, 8, 8, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(64, 10, 30, 7, 7, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 19, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 20, 10, 260, 17, 19, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 40, 10, 260, 17, 19, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 50, 10, 260, 17, 19, 100, 100, -101, -101, 1, 1);
+ if (Game_Flag_Query(293)) {
+ Scene_Loop_Set_Default(3);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptCT02::SceneLoaded() {
+ Obstacle_Object("STOVE-1", true);
+ Unobstacle_Object("BACK-DOOR", true);
+ Unclickable_Object("STOVE-1");
+ Unclickable_Object("STOVE-2");
+ Unclickable_Object("STOVE-3");
+ Unclickable_Object("STOVE-4");
+ Unclickable_Object("BIGPOT");
+ Unclickable_Object("SOUP-BOWL");
+ Unclickable_Object("HOWCOUNTRM");
+ Unclickable_Object("LFTSTOVE-1");
+ Unclickable_Object("FRIDGE-1");
+ Unclickable_Object("LEFTWALL");
+ Unclickable_Object("RIGHTWALL");
+ Unclickable_Object("BACKWALL");
+ Unclickable_Object("TABLE-1");
+ Unclickable_Object("COUNTER-2");
+ Unclickable_Object("COFFEJUG IN FOREGRO");
+ Unclickable_Object("BACK-DOOR");
+ if (!Game_Flag_Query(293)) {
+ Preload(0);
+ Preload(3);
+ Preload(3);
+ Preload(28);
+ Preload(400);
+ Preload(419);
+ Preload(420);
+ }
+ if (Game_Flag_Query(720)) {
+ Game_Flag_Reset(720);
+ Actor_Change_Animation_Mode(0, 0);
+ Player_Set_Combat_Mode(true);
+ Player_Gains_Control();
+ }
+}
+
+bool ScriptCT02::MouseClick(int x, int y) {
+ if (Actor_Query_Goal_Number(19) == 8) {
+ Actor_Set_Goal_Number(0, 1);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+void ScriptCT02::sub_401ACC() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 13)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(270, 8, 5, 3);
+ }
+ if (Actor_Clue_Query(0, 22) && !Actor_Clue_Query(0, 13)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(280, 8, 5, 3);
+ }
+ int v0 = 0;
+ if (Actor_Clue_Query(0, 2)) {
+ v0 = 1;
+ }
+ if (Actor_Clue_Query(0, 10)) {
+ ++v0;
+ }
+ if (Actor_Clue_Query(0, 3)) {
+ ++v0;
+ }
+ if (Actor_Clue_Query(0, 16)) {
+ ++v0;
+ }
+ if (Actor_Clue_Query(0, 25)) {
+ ++v0;
+ }
+ if (v0 > 3) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(290, -1, 4, 8);
+ }
+ Dialogue_Menu_Add_DONE_To_List(300);
+ Dialogue_Menu_Appear(320, 240);
+ int answerValue = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answerValue) {
+ case 270:
+ Actor_Says(0, 380, 11);
+ Actor_Says(19, 30, 17);
+ Actor_Says(19, 40, 15);
+ Actor_Says(0, 410, 9);
+ Actor_Says(19, 50, 18);
+ Actor_Says(0, 415, 10);
+ Actor_Clue_Acquire(0, 19, 0, -1);
+ Actor_Modify_Friendliness_To_Other(19, 0, -5);
+ if (Actor_Query_Friendliness_To_Other(19, 0) < 44) {
+ Scene_Exits_Disable();
+ Actor_Clue_Acquire(0, 18, 1, -1);
+ Actor_Set_Goal_Number(19, 8);
+ Game_Flag_Set(293);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ }
+ break;
+ case 280:
+ Actor_Says(0, 385, 9);
+ Actor_Says(19, 40, 19);
+ Actor_Modify_Friendliness_To_Other(19, 0, -2);
+ if (Actor_Query_Friendliness_To_Other(19, 0) < 44) {
+ Scene_Exits_Disable();
+ Actor_Clue_Acquire(0, 18, 1, -1);
+ Actor_Set_Goal_Number(19, 8);
+ Game_Flag_Set(293);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ }
+ break;
+ case 290:
+ Actor_Says(0, 395, 9);
+ Actor_Says(0, 400, 9);
+ Actor_Says(19, 70, 17);
+ Actor_Says(0, 420, 10);
+ Actor_Says(19, 80, 14);
+ Actor_Modify_Friendliness_To_Other(19, 0, -10);
+ if (Actor_Query_Friendliness_To_Other(19, 0) < 44) {
+ Scene_Exits_Disable();
+ Actor_Clue_Acquire(0, 18, 1, -1);
+ Actor_Set_Goal_Number(19, 8);
+ Game_Flag_Set(293);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ }
+ break;
+ case 300:
+ Actor_Says(0, 405, 11);
+ if (Actor_Query_Friendliness_To_Other(19, 0) < 44) {
+ Scene_Exits_Disable();
+ Actor_Clue_Acquire(0, 18, 1, -1);
+ Actor_Set_Goal_Number(19, 8);
+ Game_Flag_Set(293);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ }
+ break;
+ }
+}
+
+bool ScriptCT02::ClickedOnActor(int actorId) {
+ if (actorId == 19 && Actor_Query_Goal_Number(19) == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -255.02f, -145.11f, 212.42f, 0, 1, false, 0)) {
+ Actor_Face_Actor(0, 19, true);
+ Actor_Face_Actor(19, 0, true);
+ if (!Game_Flag_Query(59)) {
+ Actor_Says(0, 370, 10);
+ Actor_Says(19, 20, 19);
+ Actor_Says(0, 375, 9);
+ Game_Flag_Set(59);
+ }
+ sub_401ACC();
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptCT02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -111.2f, -145.11f, 243.28f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(234);
+ Game_Flag_Set(68);
+ Set_Enter(4, 13);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ bool v1;
+ if (Player_Query_Combat_Mode()) {
+ v1 = Loop_Actor_Walk_To_XYZ(0, -154.83f, -145.11f, -82.61f, 0, 1, true, 0);
+ } else {
+ v1 = Loop_Actor_Walk_To_XYZ(0, -154.83f, -145.11f, -82.61f, 0, 1, false, 0);
+ }
+ if (!v1) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(69);
+ Set_Enter(5, 15);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT02::SceneFrameAdvanced(int frame) {
+ if (frame == 6 || frame == 12 || frame == 19 || frame == 25 || frame == 46 || frame == 59) {
+ Sound_Play(97, Random_Query(25, 33), -70, -70, 50);
+ }
+ if (frame == 72) {
+ Sound_Play(200, 50, 0, 0, 50);
+ }
+ if (frame == 71) {
+ Sound_Play(204, 40, 0, 0, 50);
+ }
+ if (frame == 72) {
+ Sound_Play(203, 60, -20, 40, 50);
+ }
+ if (frame == 61) {
+ Music_Play(1, 50, 0, 2, -1, 0, 0);
+ }
+ if (frame == 81) {
+ Scene_Exit_Add_2D_Exit(1, 332, 163, 404, 297, 0);
+ Scene_Exits_Enable();
+ }
+}
+
+void ScriptCT02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT02::PlayerWalkedIn() {
+}
+
+void ScriptCT02::PlayerWalkedOut() {
+ if (Actor_Clue_Query(0, 18)) {
+ return;
+ }
+ Overlay_Remove("ct02over");
+}
+
+void ScriptCT02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct03.cpp b/engines/bladerunner/script/ct03.cpp
new file mode 100644
index 0000000000..133c5d0c18
--- /dev/null
+++ b/engines/bladerunner/script/ct03.cpp
@@ -0,0 +1,133 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT03::InitializeScene() {
+ if (Game_Flag_Query(719)) {
+ Setup_Scene_Information(-852.58f, -621.3f, 285.6f, 0);
+ } else if (Game_Flag_Query(69)) {
+ Game_Flag_Reset(69);
+ Setup_Scene_Information(-557.1f, -616.31f, 224.29f, 249);
+ } else if (Game_Flag_Query(73)) {
+ Game_Flag_Reset(73);
+ Setup_Scene_Information(-173.99f, -619.19f, 347.54f, 808);
+ } else {
+ Setup_Scene_Information(-708.58f, -619.19f, 277.6f, 239);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 40, 40, 134, 302, 3);
+ Scene_Exit_Add_2D_Exit(2, 390, 0, 539, 230, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 22, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 34, -100, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(61, 3, 30, 8, 10, -100, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(62, 3, 30, 8, 10, -100, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(63, 3, 30, 8, 10, -100, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(64, 3, 30, 8, 10, -100, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 20, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 40, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 50, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Sound(376, 10, 60, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 60, 33, 50, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptCT03::SceneLoaded() {
+ Obstacle_Object("TRASH CAN", true);
+ Unclickable_Object("TRASH CAN");
+ Footstep_Sounds_Set(0, 0);
+ Footstep_Sounds_Set(1, 1);
+}
+
+bool ScriptCT03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -745.09f, -619.09f, 293.36f, 0, 1, false, 0)) {
+ Game_Flag_Set(71);
+ Set_Enter(4, 13);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -604.38f, -616.15f, 221.6f, 0, 1, false, 0)) {
+ Game_Flag_Set(70);
+ Set_Enter(27, 14);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -150.0f, -621.3f, 357.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(72);
+ Async_Actor_Walk_To_XYZ(0, -67.0f, -621.3f, 477.0f, 0, false);
+ Set_Enter(5, 16);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT03::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptCT03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT03::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(19) == 2) {
+ Actor_Set_Goal_Number(19, 13);
+ }
+}
+
+void ScriptCT03::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptCT03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct04.cpp b/engines/bladerunner/script/ct04.cpp
new file mode 100644
index 0000000000..795cf945e9
--- /dev/null
+++ b/engines/bladerunner/script/ct04.cpp
@@ -0,0 +1,237 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT04::InitializeScene() {
+ if (Game_Flag_Query(72)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(-150.0f, -621.3f, 357.0f, 533);
+ } else {
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(-82.86f, -621.3f, 769.03f, 1020);
+ }
+ Scene_Exit_Add_2D_Exit(0, 590, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 194, 84, 320, 274, 0);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 15, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 34, 100, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 40, 33, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(376, 10, 60, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 60, 33, 50, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptCT04::SceneLoaded() {
+ Obstacle_Object("DUMPSTER", true);
+ Obstacle_Object("RIGHTWALL01", true);
+ Obstacle_Object("BACK-BLDNG", true);
+ Clickable_Object("DUMPSTER");
+ Footstep_Sounds_Set(0, 1);
+ if (Game_Flag_Query(72)) {
+ Game_Flag_Reset(72);
+ }
+ if (!Actor_Query_Goal_Number(12)) {
+ Actor_Change_Animation_Mode(12, 38);
+ }
+}
+
+bool ScriptCT04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT04::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (objectName) {
+ if (!Game_Flag_Query(137) && !Game_Flag_Query(169) && !Actor_Query_Goal_Number(12)) {
+ Game_Flag_Set(137);
+ Actor_Set_Goal_Number(12, 2);
+ }
+ if (Game_Flag_Query(169) && !Game_Flag_Query(170) && !Game_Flag_Query(171) && !Game_Flag_Query(172) && Global_Variable_Query(1) == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -147.41f, -621.3f, 724.57f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Face_Heading(0, 792, false);
+ Actor_Put_In_Set(12, 99);
+ Actor_Set_At_XYZ(12, 0, 0, 0, 0);
+ Actor_Change_Animation_Mode(0, 40);
+ Actor_Voice_Over(320, 99);
+ Actor_Voice_Over(330, 99);
+ Actor_Voice_Over(340, 99);
+ Game_Flag_Set(170);
+ Game_Flag_Set(173);
+ }
+ return false;
+ }
+ if (Game_Flag_Query(170)) {
+ if (Game_Flag_Query(172)) {
+ Actor_Voice_Over(270, 99);
+ Actor_Voice_Over(280, 99);
+ } else if (Game_Flag_Query(171)) {
+ Actor_Voice_Over(250, 99);
+ Actor_Voice_Over(260, 99);
+ } else {
+ Actor_Voice_Over(230, 99);
+ Actor_Voice_Over(240, 99);
+ Game_Flag_Reset(173);
+ }
+ return true;
+ }
+ if (Game_Flag_Query(174)) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 75, 0, 1, false)) {
+ Actor_Face_Heading(0, 707, false);
+ Actor_Change_Animation_Mode(0, 38);
+ Ambient_Sounds_Play_Sound(553, 45, 30, 30, 0);
+ Actor_Voice_Over(1810, 99);
+ Actor_Voice_Over(1820, 99);
+ return true;
+ }
+ return false;
+ }
+ if (!Loop_Actor_Walk_To_Waypoint(0, 75, 0, 1, false)) {
+ Actor_Face_Heading(0, 707, false);
+ Actor_Change_Animation_Mode(0, 38);
+ Actor_Clue_Acquire(0, 37, 1, -1);
+ Item_Pickup_Spin_Effect(952, 392, 225);
+ Game_Flag_Set(174);
+ return true;
+ }
+ }
+ return false;
+}
+
+void ScriptCT04::sub_401D4C() {
+ Dialogue_Menu_Clear_List();
+ if (Global_Variable_Query(2) > 10 || !Query_Difficulty_Level()) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(410, 8, 4, -1);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(420, 2, 6, 8);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 410) {
+ Actor_Says(12, 10, 14);
+ Actor_Says(12, 20, 14);
+ Actor_Modify_Friendliness_To_Other(12, 0, 5);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 10);
+ }
+ } else if (answer == 420) {
+ Actor_Says(0, 430, 3);
+ Actor_Says(12, 30, 14);
+ Actor_Modify_Friendliness_To_Other(12, 0, -5);
+ }
+}
+
+bool ScriptCT04::ClickedOnActor(int actorId) {
+ if (actorId == 12) {
+ if (Game_Flag_Query(169)) {
+ if (!Loop_Actor_Walk_To_Actor(0, 12, 36, 1, false)) {
+ Actor_Voice_Over(290, 99);
+ Actor_Voice_Over(300, 99);
+ Actor_Voice_Over(310, 99);
+ }
+ } else {
+ Actor_Set_Targetable(12, false);
+ if (!Loop_Actor_Walk_To_Actor(0, 12, 36, 1, false)) {
+ Actor_Face_Actor(0, 12, true);
+ if (!Game_Flag_Query(137)) {
+ if (Game_Flag_Query(40)) {
+ Actor_Says(0, 435, 3);
+ Actor_Set_Goal_Number(12, 2);
+ } else {
+ Music_Stop(3);
+ Actor_Says(0, 425, 3);
+ Actor_Says(12, 0, 13);
+ sub_401D4C();
+ Actor_Set_Goal_Number(12, 2);
+ }
+ Game_Flag_Set(137);
+ } else {
+ Actor_Face_Actor(0, 12, true);
+ Actor_Says(0, 435, 3);
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT04::ClickedOnExit(int exitId) {
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -82.86f, -621.3f, 769.03f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Actor_Query_Goal_Number(12)) {
+ Actor_Set_Goal_Number(12, 2);
+ }
+ Game_Flag_Set(74);
+ Set_Enter(28, 17);
+ }
+ return true;
+ }
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -187.0f, -621.3f, 437.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(73);
+ Set_Enter(5, 15);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT04::SceneFrameAdvanced(int frame) {
+ if (Game_Flag_Query(325)) {
+ Game_Flag_Reset(325);
+ Sound_Play(180, 100, 80, 80, 50);
+ }
+}
+
+void ScriptCT04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT04::PlayerWalkedIn() {
+}
+
+void ScriptCT04::PlayerWalkedOut() {
+}
+
+void ScriptCT04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct05.cpp b/engines/bladerunner/script/ct05.cpp
new file mode 100644
index 0000000000..0249110653
--- /dev/null
+++ b/engines/bladerunner/script/ct05.cpp
@@ -0,0 +1,241 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT05::InitializeScene() {
+ if (Game_Flag_Query(90)) {
+ Game_Flag_Reset(90);
+ Setup_Scene_Information(-128.42f, -109.91f, 112.83f, 516);
+ } else if (Game_Flag_Query(78)) {
+ Setup_Scene_Information(192.35f, 43.09f, 128.97f, 768);
+ } else {
+ Setup_Scene_Information(-375.0f, -109.91f, 750.0f, 600);
+ }
+ if (Game_Flag_Query(94)) {
+ Scene_Exit_Add_2D_Exit(0, 228, 205, 293, 300, 0);
+ }
+ Scene_Exit_Add_2D_Exit(1, 320, 458, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(2, 380, 110, 542, 300, 0);
+ Ambient_Sounds_Add_Looping_Sound(106, 15, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(107, 15, 100, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 13, -100, 1);
+ Ambient_Sounds_Add_Sound(90, 5, 20, 8, 10, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 20, 8, 10, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(205, 5, 30, 18, 30, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(94)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+ if (Actor_Query_Goal_Number(53) == 1) {
+ Overlay_Play("ct05over", 0, 1, 0, 0);
+ }
+}
+
+void ScriptCT05::SceneLoaded() {
+ Obstacle_Object("STAIR 1", true);
+ Obstacle_Object("STAIR 2", true);
+ Obstacle_Object("GRGDOOR", true);
+ Obstacle_Object("GRGDOOR2", true);
+ Obstacle_Object("TURBINE", true);
+ Obstacle_Object("BARREL", true);
+ Obstacle_Object("GRNDPIPE", true);
+ Clickable_Object("TURBINE");
+ Clickable_Object("LFTDOOR");
+ Clickable_Object("BARREL");
+ Clickable_Object("GRNDPIPE");
+ Unclickable_Object("GDFRAME");
+ Unclickable_Object("GDFRAME2");
+ Unclickable_Object("WINFRAME1");
+ Unclickable_Object("WINFRAME2");
+ Unclickable_Object("STAIR 1");
+ Unclickable_Object("STAIR 2");
+ Unclickable_Object("LFTDOOR");
+ Unclickable_Object("LFTDOORFRM");
+}
+
+bool ScriptCT05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT05::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("STAIR1", objectName)) {
+ Actor_Face_Object(0, objectName, true);
+ return true;
+ }
+ if (Object_Query_Click("STAIR2", objectName)) {
+ Actor_Face_Object(0, objectName, true);
+ return true;
+ }
+ if (Object_Query_Click("GRGDOOR", objectName)) {
+ Loop_Actor_Walk_To_Scene_Object(0, "GRGDOOR", 24, 1, false);
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8522, 12);
+ return true;
+ }
+ if (Object_Query_Click("GRGDOOR2", objectName)) {
+ Loop_Actor_Walk_To_Scene_Object(0, "GRGDOOR2", 24, 1, false);
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8522, 12);
+ return true;
+ }
+ if (Object_Query_Click("TURBINE", objectName)) {
+ Loop_Actor_Walk_To_Scene_Object(0, "TURBINE", 36, 1, false);
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8528, 12);
+ return true;
+ }
+ if (Object_Query_Click("LFTDOOR", objectName)) {
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8522, 12);
+ return true;
+ }
+ if (Object_Query_Click("BARREL", objectName)) {
+ Loop_Actor_Walk_To_Scene_Object(0, "BARREL", 36, 1, false);
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8529, 12);
+ return true;
+ }
+ if (Object_Query_Click("GRNDPIPE", objectName)) {
+ Loop_Actor_Walk_To_Scene_Object(0, "GRNDPIPE", 24, 1, false);
+ Actor_Face_Object(0, objectName, true);
+ Actor_Says(0, 8528, 12);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -128.42f, -109.91f, 112.83f, 0, 1, false, 0)) {
+ Game_Flag_Set(76);
+ if (Actor_Query_Goal_Number(53) == 1) {
+ Overlay_Remove("ct05over");
+ }
+ Set_Enter(4, 24);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -308.18f, -109.91f, 674.77f, 0, 1, false, 0)) {
+ Game_Flag_Set(75);
+ if (Actor_Query_Goal_Number(53) == 1) {
+ Overlay_Remove("ct05over");
+ Actor_Set_Goal_Number(53, 5);
+ Game_Flag_Set(409);
+ }
+ Set_Enter(5, 16);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 71.99f, -109.91f, 288.79f, 0, 1, false, 0)) {
+ Footstep_Sound_Override_On(2);
+ Actor_Face_Object(0, "STAIR 2", true);
+ Loop_Actor_Travel_Stairs(0, 9, 1, 0);
+ Actor_Set_At_XYZ(0, 99.73f, -19.91f, 134.97f, 256);
+ Loop_Actor_Travel_Stairs(0, 5, 1, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Set(77);
+ if (Actor_Query_Goal_Number(53) == 1) {
+ Overlay_Remove("ct05over");
+ }
+ Set_Enter(29, 18);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT05::SceneFrameAdvanced(int frame) {
+ if (frame == 7 || frame == 15 || frame == 29) {
+ switch (Random_Query(0, 4)) {
+ case 4:
+ Sound_Play(40, Random_Query(25, 50), -70, -70, 50);
+ break;
+ case 3:
+ Sound_Play(44, Random_Query(25, 50), -70, -70, 50);
+ break;
+ case 2:
+ Sound_Play(43, Random_Query(25, 50), -70, -70, 50);
+ break;
+ case 1:
+ Sound_Play(42, Random_Query(25, 50), -70, -70, 50);
+ break;
+ case 0:
+ Sound_Play(41, Random_Query(25, 50), -70, -70, 50);
+ break;
+ }
+ }
+}
+
+void ScriptCT05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT05::PlayerWalkedIn() {
+ if (Game_Flag_Query(74)) {
+ Player_Loses_Control();
+ Game_Flag_Reset(74);
+ if (Player_Query_Combat_Mode()) {
+ Loop_Actor_Walk_To_XYZ(0, -308.18f, -109.91f, 674.77f, 0, 0, true, 0);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -308.18f, -109.91f, 674.77f, 0, 0, false, 0);
+ }
+ Player_Gains_Control();
+ }
+ if (Game_Flag_Query(78)) {
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 7, 0, 0);
+ Actor_Set_At_XYZ(0, 90.73f, -19.91f, 164.97f, 520);
+ Loop_Actor_Travel_Stairs(0, 10, 0, 0);
+ Game_Flag_Reset(78);
+ Footstep_Sound_Override_Off();
+ if (Actor_Query_Goal_Number(2) == 2 && Game_Flag_Query(145)) {
+ Actor_Set_Goal_Number(2, 3);
+ }
+ }
+}
+
+void ScriptCT05::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptCT05::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct06.cpp b/engines/bladerunner/script/ct06.cpp
new file mode 100644
index 0000000000..30dfd19bd3
--- /dev/null
+++ b/engines/bladerunner/script/ct06.cpp
@@ -0,0 +1,180 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT06::InitializeScene() {
+ if (Game_Flag_Query(77)) {
+ Setup_Scene_Information(20.41f, -58.23f, 2.17f, 247);
+ Game_Flag_Reset(77);
+ } else if (Game_Flag_Query(144)) {
+ Setup_Scene_Information(203.91f, -58.02f, 0.47f, 768);
+ } else {
+ Setup_Scene_Information(175.91f, -58.23f, 24.47f, 768);
+ }
+ 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(40) && Actor_Query_In_Set(19, 30)) {
+ Actor_Put_In_Set(19, 29);
+ Actor_Set_At_XYZ(19, 58.41f, -58.23f, -24.97f, 240);
+ Actor_Retired_Here(19, 72, 36, 1, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(205, 20, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(67, 80, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 50, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 50, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(380, 70, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Actor_Query_Goal_Number(19) == 13) {
+ Ambient_Sounds_Add_Sound(196, 1, 5, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(197, 1, 5, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(198, 1, 5, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(199, 1, 5, 25, 25, -100, 100, -101, -101, 0, 0);
+ }
+}
+
+void ScriptCT06::SceneLoaded() {
+ Obstacle_Object("BOX02", true);
+ Obstacle_Object("CB BOX01", true);
+ Obstacle_Object("CB BOX02", true);
+ Obstacle_Object("CB BOX03", true);
+ Unobstacle_Object("INSULPIP01", true);
+ Unobstacle_Object("CB BOX04", true);
+ Unclickable_Object("DOOR");
+ if (Actor_Query_Goal_Number(19) == 13) {
+ Preload(3);
+ Preload(4);
+ Preload(389);
+ Preload(390);
+ Preload(398);
+ Preload(421);
+ Preload(421);
+ }
+}
+
+bool ScriptCT06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT06::ClickedOnActor(int actorId) {
+ if (actorId == 19) {
+ Loop_Actor_Walk_To_Actor(0, 19, 24, 1, false);
+ Actor_Face_Actor(0, 19, true);
+ if (Game_Flag_Query(145)) {
+ Actor_Says(0, 8570, 13);
+ return false;
+ }
+ Actor_Clue_Acquire(0, 20, 1, -1);
+ Item_Pickup_Spin_Effect(984, 340, 369);
+ Actor_Voice_Over(350, 99);
+ Actor_Voice_Over(360, 99);
+ Actor_Voice_Over(370, 99);
+ if (!Game_Flag_Query(378)) {
+ Actor_Voice_Over(380, 99);
+ Actor_Voice_Over(390, 99);
+ Actor_Voice_Over(400, 99);
+ Actor_Voice_Over(410, 99);
+ }
+ Game_Flag_Set(145);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 20.41f, -58.23f, -2.17f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(78);
+ Set_Enter(28, 17);
+ Game_Flag_Reset(212);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (Actor_Query_Goal_Number(19) == 13) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 203.91f, -58.02f, 0.47f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_Sound(196, true);
+ Ambient_Sounds_Remove_Sound(197, true);
+ Ambient_Sounds_Remove_Sound(198, true);
+ Ambient_Sounds_Remove_Sound(199, true);
+ Player_Loses_Control();
+ Actor_Set_Goal_Number(19, 11);
+ Game_Flag_Reset(212);
+ }
+ return true;
+ }
+ if (!Loop_Actor_Walk_To_XYZ(0, 203.91f, -58.02f, 0.47f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) < 3) {
+ Actor_Face_Object(0, "DOOR", true);
+ Actor_Says(0, 8522, 12);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(79);
+ Set_Enter(6, 20);
+ Game_Flag_Reset(212);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptCT06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT06::PlayerWalkedIn() {
+ if (Game_Flag_Query(144) == 1) {
+ Game_Flag_Reset(144);
+ }
+}
+
+void ScriptCT06::PlayerWalkedOut() {
+}
+
+void ScriptCT06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct07.cpp b/engines/bladerunner/script/ct07.cpp
new file mode 100644
index 0000000000..771d4be676
--- /dev/null
+++ b/engines/bladerunner/script/ct07.cpp
@@ -0,0 +1,104 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT07::InitializeScene() {
+ Setup_Scene_Information(202.32f, -58.23f, -12.86f, 225);
+ Actor_Put_In_Set(19, 30);
+ Actor_Set_At_XYZ(19, -9.68f, -58.23f, 11.14f, 250);
+ Ambient_Sounds_Add_Looping_Sound(54, 30, 90, 1);
+ Ambient_Sounds_Add_Looping_Sound(205, 20, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 40, 100, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(67, 80, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 50, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 10, 60, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 6, 50, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(61, 10, 30, 12, 14, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(62, 10, 30, 12, 14, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(63, 10, 30, 12, 14, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(64, 10, 30, 12, 14, 100, 100, -101, -101, 0, 0);
+}
+
+void ScriptCT07::SceneLoaded() {
+ Obstacle_Object("BOX01", true);
+ Obstacle_Object("BOX02", true);
+ Obstacle_Object("BOX03", true);
+ Obstacle_Object("BOX04", true);
+ Unclickable_Object("BOX01");
+ Unclickable_Object("BOX02");
+ Unclickable_Object("BOX03");
+ Unclickable_Object("BOX04");
+}
+
+bool ScriptCT07::MouseClick(int x, int y) {
+ return true;
+}
+
+bool ScriptCT07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT07::ClickedOnExit(int exitId) {
+ return false;
+}
+
+bool ScriptCT07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT07::PlayerWalkedIn() {
+ Player_Gains_Control();
+ Non_Player_Actor_Combat_Mode_On(19, 0, 0, 0, 2, 4, 7, 8, 0, 0, 100, 15, 300, 0);
+ Game_Flag_Set(516);
+ Actor_Face_Actor(0, 19, true);
+}
+
+void ScriptCT07::PlayerWalkedOut() {
+ Music_Stop(2);
+}
+
+void ScriptCT07::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct08.cpp b/engines/bladerunner/script/ct08.cpp
new file mode 100644
index 0000000000..42b924e498
--- /dev/null
+++ b/engines/bladerunner/script/ct08.cpp
@@ -0,0 +1,196 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT08::InitializeScene() {
+ if (Game_Flag_Query(679)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(2, 0, -1);
+ if (Game_Flag_Query(46)) {
+ Outtake_Play(3, 0, -1);
+ } else if (Game_Flag_Query(47)) {
+ Outtake_Play(4, 0, -1);
+ } else {
+ Outtake_Play(5, 0, -1);
+ }
+ Outtake_Play(6, 0, -1);
+ Game_Flag_Reset(679);
+ }
+ Actor_Force_Stop_Walking(0);
+ if (Game_Flag_Query(380)) {
+ Setup_Scene_Information(-11.0f, 0.0f, -156.0f, 769);
+ } else if (Game_Flag_Query(79)) {
+ Setup_Scene_Information(-143.0f, 0.0f, -92.0f, 420);
+ } else {
+ Setup_Scene_Information(-183.0f, 0.0f, 128.0f, 205);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 389, 0, 639, 303, 0);
+ Scene_Exit_Add_2D_Exit(2, 115, 87, 137, 267, 3);
+ if (Game_Flag_Query(550)) {
+ Scene_2D_Region_Add(0, 185, 185, 230, 230);
+ }
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(205, 20, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(67, 80, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 50, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(380, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(380)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptCT08::SceneLoaded() {
+ Obstacle_Object("ASHTRAY", 1);
+ Unobstacle_Object("BLANKET03", 1);
+ if (!Actor_Clue_Query(0, 85)) {
+ Item_Add_To_World(85, 943, 6, 44.0f, 0.0f, -95.0f, 540, 12, 12, 0, 1, 0, 1);
+ }
+ if (!Actor_Clue_Query(0, 87)) {
+ Item_Add_To_World(81, 936, 6, -102.0f, 2.0f, 41.0f, 432, 6, 6, 0, 1, 0, 1);
+ }
+}
+
+bool ScriptCT08::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT08::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT08::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT08::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 81) {
+ if (!Loop_Actor_Walk_To_Item(0, 81, 36, 1, 0) && !Game_Flag_Query(550)) {
+ Actor_Clue_Acquire(0, 87, 1, -1);
+ Item_Pickup_Spin_Effect(936, 266, 328);
+ Item_Remove_From_World(81);
+ Actor_Voice_Over(480, 99);
+ Actor_Voice_Over(490, 99);
+ Actor_Voice_Over(500, 99);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT08::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -183.0f, 0.0f, 128.0f, 0, 1, 0, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(81);
+ Set_Enter(31, 21);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -11.0f, 0.0f, -156.0f, 0, 1, 0, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 0.0f, 0.0f, -102.0f, 0, 0, 0, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(379);
+ Set_Enter(6, 105);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -143.0f, 0.0f, -92.0f, 0, 1, 0, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(80);
+ Set_Enter(29, 18);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT08::ClickedOn2DRegion(int region) {
+ if (region == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -108.0f, 0.0f, -178.0f, 0, 1, 0, 0)) {
+ Actor_Face_Heading(0, 512, 0);
+ Game_Flag_Reset(550);
+ Player_Set_Combat_Mode_Access(1);
+ Scene_Exits_Enable();
+ Ambient_Sounds_Play_Sound(564, 40, 99, 0, 0);
+ Scene_2D_Region_Remove(0);
+ Player_Loses_Control();
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptCT08::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT08::PlayerWalkedIn() {
+ if (Game_Flag_Query(550)) {
+ Actor_Change_Animation_Mode(0, 3);
+ Actor_Change_Animation_Mode(0, 0);
+ Actor_Set_At_XYZ(0, -148.0f, 0.0f, 4.0f, 256);
+ Player_Set_Combat_Mode_Access(0);
+ Scene_Exits_Disable();
+ Game_Flag_Reset(380);
+ Game_Flag_Reset(79);
+ Autosave_Game(1);
+ } else if (Game_Flag_Query(380)) {
+ Game_Flag_Reset(380);
+ } else if (Game_Flag_Query(79)) {
+ Game_Flag_Reset(79);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -156.0f, 0.0f, 128.0f, 0, 0, 0, 0);
+ Game_Flag_Reset(84);
+ }
+}
+
+void ScriptCT08::PlayerWalkedOut() {
+ if (!Actor_Clue_Query(0, 85)) {
+ Item_Remove_From_World(85);
+ }
+}
+
+void ScriptCT08::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct09.cpp b/engines/bladerunner/script/ct09.cpp
new file mode 100644
index 0000000000..0cc9910b19
--- /dev/null
+++ b/engines/bladerunner/script/ct09.cpp
@@ -0,0 +1,214 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT09::InitializeScene() {
+ if (Game_Flag_Query(85)) {
+ Setup_Scene_Information(160.0f, 349.0f, 587.0f, 490);
+ } else if (Game_Flag_Query(81)) {
+ Setup_Scene_Information(235.0f, 3348.52f, 599.0f, 800);
+ } else {
+ Setup_Scene_Information(107.0f, 348.52f, 927.0f, 200);
+ }
+ Scene_Exit_Add_2D_Exit(0, 321, 164, 345, 309, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 15, 479, 3);
+ Scene_Exit_Add_2D_Exit(2, 198, 177, 263, 311, 0);
+ Ambient_Sounds_Add_Looping_Sound(336, 28, 0, 1);
+ Ambient_Sounds_Add_Sound(375, 6, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+}
+
+void ScriptCT09::SceneLoaded() {
+ Obstacle_Object("PHONE01", true);
+ Unobstacle_Object("MAINBEAM01", true);
+ Unobstacle_Object("MIDDLE WALL", true);
+ Clickable_Object("BELL");
+}
+
+bool ScriptCT09::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT09::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BELL", objectName)) {
+ if (Actor_Query_Which_Set_In(62) != 31) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 229.0f, 348.52f, 851.0f, 36, 1, false, 0)) {
+ Actor_Face_Object(0, "BELL", true);
+ Sound_Play(337, 100, 0, 0, 50);
+ if (!Actor_Query_Goal_Number(27)) {
+ Actor_Says(27, 160, 3);
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT09::ClickedOnActor(int actorId) {
+ if (actorId == 27) {
+ if (!Actor_Query_Goal_Number(27) && Actor_Query_Which_Set_In(62) != 31) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 270.0f, 348.52f, 846.0f, 12, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Face_Actor(0, 27, true);
+ if (Global_Variable_Query(1) < 3) {
+ Actor_Says(0, 650, 3);
+ Actor_Says(27, 250, 12);
+ Actor_Says(0, 665, 18);
+ } else if (Game_Flag_Query(540)) {
+ Actor_Says(0, 650, 18);
+ Actor_Says(27, 220, 15);
+ } else {
+ Game_Flag_Set(540);
+ Actor_Says(27, 170, 13);
+ Actor_Says(0, 630, 12);
+ Actor_Says(27, 180, 14);
+ Actor_Says(0, 635, 3);
+ Actor_Says(27, 190, 15);
+ Actor_Says(0, 640, 12);
+ Actor_Says(0, 645, 3);
+ Actor_Says(27, 200, 13);
+ Actor_Says(27, 210, 14);
+ }
+ Player_Gains_Control();
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT09::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT09::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 206.0f, 348.52f, 599.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 235.0f, 348.52f, 599.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(84);
+ Set_Enter(6, 20);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 107.0f, 348.52f, 927.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(83);
+ Set_Enter(33, 23);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 159.0f, 349.0f, 570.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(82);
+ Set_Enter(32, 22);
+ }
+ return true;
+ }
+ return false;;
+}
+
+bool ScriptCT09::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT09::SceneFrameAdvanced(int frame) {
+ if (frame == 6 || frame == 12 || frame == 19 || frame == 25 || frame == 46 || frame == 59) {
+ Sound_Play(97, Random_Query(47, 47), 70, 70, 50);
+ }
+}
+
+void ScriptCT09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT09::PlayerWalkedIn() {
+ bool v0 = false;
+ if (Global_Variable_Query(1) == 3 && !Game_Flag_Query(538)) {
+ Game_Flag_Set(538);
+ Actor_Set_Goal_Number(62, 1);
+ v0 = true;
+ }
+ if (Game_Flag_Query(85)) {
+ Game_Flag_Reset(85);
+ } else if (Game_Flag_Query(81)) {
+ if (v0) {
+ Async_Actor_Walk_To_XYZ(0, 206.0f, 348.52f, 599.0f, 0, false);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 206.0f, 348.52f, 599.0f, 0, 0, false, 0);
+ }
+ Game_Flag_Reset(81);
+ } else {
+ if (v0) {
+ Async_Actor_Walk_To_XYZ(0, 124.0f, 348.52f, 886.0f, 0, false);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 124.0f, 348.52f, 886.0f, 0, 0, false, 0);
+ }
+ Game_Flag_Reset(304);
+ }
+ if (Actor_Query_Goal_Number(27) == 2) {
+ if (Game_Flag_Query(539)) {
+ Actor_Says(27, 70, 13);
+ Actor_Face_Actor(0, 27, true);
+ Actor_Says(0, 600, 17);
+ Actor_Says(27, 80, 14);
+ Actor_Says(0, 605, 13);
+ Actor_Says(27, 90, 15);
+ } else {
+ Actor_Says(27, 20, 12);
+ Actor_Face_Actor(0, 27, true);
+ Actor_Says(0, 585, 18);
+ Actor_Says(27, 40, 15);
+ Actor_Says(0, 590, 16);
+ Actor_Says(27, 50, 14);
+ Actor_Says(0, 595, 14);
+ Actor_Says(27, 60, 13);
+ Actor_Modify_Friendliness_To_Other(27, 0, -1);
+ }
+ Actor_Set_Goal_Number(27, 0);
+ }
+}
+
+void ScriptCT09::PlayerWalkedOut() {
+}
+
+void ScriptCT09::DialogueQueueFlushed(int a1) {
+ Actor_Force_Stop_Walking(0);
+ if (Actor_Query_Goal_Number(62) == 1 && !Game_Flag_Query(539)) {
+ Player_Loses_Control();
+ Actor_Set_Goal_Number(62, 2);
+ //return true;
+ } else {
+ //return false;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct10.cpp b/engines/bladerunner/script/ct10.cpp
new file mode 100644
index 0000000000..1781394c57
--- /dev/null
+++ b/engines/bladerunner/script/ct10.cpp
@@ -0,0 +1,160 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT10::InitializeScene() {
+ Setup_Scene_Information(-121.0f, 0.0f, -78.0f, 446);
+ Game_Flag_Reset(84);
+ Scene_Exit_Add_2D_Exit(0, 135, 74, 238, 340, 0);
+ Ambient_Sounds_Add_Looping_Sound(336, 28, 0, 1);
+ Ambient_Sounds_Add_Sound(375, 6, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 33, 33, 0, 0, -101, -101, 0, 0);
+}
+
+void ScriptCT10::SceneLoaded() {
+ Obstacle_Object("BED", true);
+ Unobstacle_Object("WINDOW", true);
+ Unobstacle_Object("LOFT01", true);
+ Unobstacle_Object("LOFT02", true);
+ Unobstacle_Object("LOFT03", true);
+ Unobstacle_Object("LOFT04", true);
+ Unobstacle_Object("LOFT05", true);
+ Unobstacle_Object("LOFT06", true);
+ Unobstacle_Object("LOFT10", true);
+ Unobstacle_Object("LOFT11", true);
+ Unobstacle_Object("LOFT12", true);
+ Unobstacle_Object("LINE02", true);
+ Unobstacle_Object("CABINETFRONT", true);
+ Unobstacle_Object("CABINTESIDE", true);
+ Unobstacle_Object("BUSTEDTAPE2", true);
+ Unobstacle_Object("BOX CLOSET 1", true);
+ Clickable_Object("BED");
+ Clickable_Object("CABINETFRONT");
+ Clickable_Object("CABINETTOP");
+ Clickable_Object("TUB");
+ Scene_2D_Region_Add(0, 379, 229, 454, 375);
+}
+
+bool ScriptCT10::MouseClick(int x, int y) {
+ return false;
+}
+
+void ScriptCT10::sub_401844() {
+ if (!Loop_Actor_Walk_To_XYZ(0, 10.6f, 0.0f, -50.5f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Face_Heading(0, 0, false);
+ Sound_Play(339, 100, 0, 0, 50);
+ Delay(1000);
+ if (Actor_Clue_Query(0, 110)) {
+ Actor_Voice_Over(3700, 99);
+ } else {
+ Item_Pickup_Spin_Effect(931, 435, 258);
+ Actor_Clue_Acquire(0, 110, 1, -1);
+ }
+ Player_Gains_Control();
+ }
+}
+
+bool ScriptCT10::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("TUB", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -41.0f, 0.0f, -106.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Face_Heading(0, 850, false);
+ Actor_Change_Animation_Mode(0, 38);
+ Delay(1000);
+ Sound_Play(338, 33, 0, 0, 50);
+ Delay(3000);
+ if (Actor_Clue_Query(0, 93)) {
+ Actor_Voice_Over(3700, 99);
+ } else {
+ Actor_Clue_Acquire(0, 93, 1, -1);
+ Item_Pickup_Spin_Effect(969, 364, 214);
+ }
+ Delay(1000);
+ Loop_Actor_Walk_To_XYZ(0, -41.0f, 0.0f, -82.0f, 0, 0, false, 1);
+ Player_Gains_Control();
+ }
+ return true;
+ }
+ if (Object_Query_Click("CABINETTOP", objectName) || Object_Query_Click("CABINETFRONT", objectName)) {
+ sub_401844();
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT10::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT10::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT10::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -93.0f, 0.0f, -38.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -121.0f, 0.0f, -78.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(85);
+ Set_Enter(31, 21);
+ }
+ }
+ return false;
+}
+
+bool ScriptCT10::ClickedOn2DRegion(int region) {
+ if (region == 0) {
+ sub_401844();
+ }
+ return false;
+}
+
+void ScriptCT10::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT10::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, -93.0f, 0.0f, -38.0f, 0, 0, false, 0);
+ Loop_Actor_Walk_To_XYZ(0, -49.0f, 0.0f, -38.0f, 0, 0, false, 0);
+ if (!Game_Flag_Query(525)) {
+ Actor_Voice_Over(450, 99);
+ Actor_Voice_Over(460, 99);
+ Actor_Voice_Over(470, 99);
+ Game_Flag_Set(525);
+ }
+}
+
+void ScriptCT10::PlayerWalkedOut() {
+}
+
+void ScriptCT10::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct11.cpp b/engines/bladerunner/script/ct11.cpp
new file mode 100644
index 0000000000..3ef0bec48d
--- /dev/null
+++ b/engines/bladerunner/script/ct11.cpp
@@ -0,0 +1,213 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT11::InitializeScene() {
+ if (Game_Flag_Query(91)) {
+ Setup_Scene_Information(-378.0f, 9.68f, -55.0f, 440);
+ } else if (Game_Flag_Query(558)) {
+ Setup_Scene_Information(315.0f, 0.0f, 628.0f, 0);
+ } else {
+ Setup_Scene_Information(152.0f, 9.68f, -8.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 257, 240, 364, 330, 1);
+ Scene_Exit_Add_2D_Exit(1, 97, 0, 155, 324, 0);
+ Scene_Exit_Add_2D_Exit(2, 0, 0, 20, 479, 3);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Sound(67, 5, 80, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(66, 5, 80, 16, 25, -100, 100, -101, -101, 0, 0);
+ 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 (Global_Variable_Query(1) <= 3) {
+ Scene_Loop_Set_Default(0);
+ } else {
+ Scene_Loop_Set_Default(2);
+ }
+}
+
+void ScriptCT11::SceneLoaded() {
+ Obstacle_Object("TRASH CAN", true);
+ Unobstacle_Object("BOX NORTHWEST 1", true);
+ Unobstacle_Object("BOX SOUTH 1", true);
+ if (Global_Variable_Query(1) < 4) {
+ if (!Game_Flag_Query(645)) {
+ Item_Add_To_World(115, 951, 33, 640.21002f, 30.0f, 470.0f, 512, 12, 12, false, true, false, true);
+ Scene_2D_Region_Add(0, 505, 316, 513, 321);
+ Game_Flag_Set(725);
+ }
+ if (!Actor_Clue_Query(0, 111)) {
+ Scene_2D_Region_Add(1, 412, 258, 552, 358);
+ }
+ } else {
+ if (Game_Flag_Query(725)) {
+ Item_Remove_From_World(115);
+ Game_Flag_Reset(725);
+ Game_Flag_Set(645);
+ }
+ Unobstacle_Object("BRIDGE SUPPORT", true);
+ Unobstacle_Object("BODY", true);
+ Unobstacle_Object("HEADLIGHTS", true);
+ Unobstacle_Object("LICENSE PLATE-FRONT", true);
+ Unobstacle_Object("LICENSE PLATE-REAR", true);
+ Unobstacle_Object("BRAKE DISC RF", true);
+ Unobstacle_Object("TIRE RF", true);
+ Unobstacle_Object("RIM RF", true);
+ Unobstacle_Object("DOOR RIGHT", true);
+ Unobstacle_Object("BUMPER REAR", true);
+ }
+ Unclickable_Object("TRASH CAN");
+}
+
+bool ScriptCT11::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT11::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT11::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT11::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT11::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 121.0f, 9.6800003f, -42.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(304);
+ Set_Enter(31, 21);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -300.0f, 9.6800003f, 66.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -400.0f, 9.6800003f, -70.0f, 0, 1, false, 0);
+ Game_Flag_Set(86);
+ Set_Enter(4, 24);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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, 25);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT11::ClickedOn2DRegion(int region) {
+ if (region == 0 && Game_Flag_Query(725)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 686.0f, 0.0f, 658.0f, 12, 1, false, 0)) {
+ Actor_Face_Heading(0, 47, false);
+ Item_Remove_From_World(115);
+ Actor_Clue_Acquire(0, 118, 0, -1);
+ Item_Pickup_Spin_Effect(951, 510, 319);
+ Game_Flag_Reset(725);
+ Game_Flag_Set(645);
+ Actor_Voice_Over(550, 99);
+ Actor_Voice_Over(560, 99);
+ Actor_Voice_Over(570, 99);
+ Actor_Voice_Over(580, 99);
+ }
+ return true;
+ }
+ if (region == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 686.0f, 0.0f, 658.0f, 12, 1, false, 0)) {
+ Actor_Face_Heading(0, 47, false);
+ int temp = 0;
+ if (Actor_Clue_Query(0, 17)) {
+ temp = 1;
+ }
+ if (Actor_Clue_Query(0, 26)) {
+ ++temp;
+ }
+ if (Actor_Clue_Query(0, 39)) {
+ ++temp;
+ }
+ if (Actor_Clue_Query(0, 37)) {
+ temp += 2;
+ }
+ if (Actor_Clue_Query(0, 30)) {
+ temp += 2;
+ }
+ if (Actor_Clue_Query(0, 31)) {
+ temp += 2;
+ }
+ if (temp <= 2 || Actor_Clue_Query(0, 111)) {
+ Actor_Says(0, 8525, 12);
+ } else {
+ Actor_Voice_Over(510, 99);
+ Actor_Voice_Over(520, 99);
+ Actor_Voice_Over(530, 99);
+ Actor_Voice_Over(540, 99);
+ Actor_Clue_Acquire(0, 111, 0, -1);
+ Scene_2D_Region_Remove(1);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptCT11::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT11::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT11::PlayerWalkedIn() {
+ if (Game_Flag_Query(91)) {
+ Loop_Actor_Walk_To_XYZ(0, -358.0f, 9.68f, 32.0f, 0, 0, false, 0);
+ Game_Flag_Reset(91);
+ } else if (Game_Flag_Query(558)) {
+ Loop_Actor_Walk_To_XYZ(0, 329.0f, 0.0f, 617.0f, 0, 0, false, 0);
+ Game_Flag_Reset(558);
+ } else {
+ Player_Loses_Control();
+ Actor_Set_Immunity_To_Obstacles(0, true);
+ Loop_Actor_Walk_To_XYZ(0, 125.0f, 9.68f, 74.0f, 0, 0, false, 0);
+ Actor_Set_Immunity_To_Obstacles(0, false);
+ Player_Gains_Control();
+ Game_Flag_Reset(83);
+ }
+}
+
+void ScriptCT11::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptCT11::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct12.cpp b/engines/bladerunner/script/ct12.cpp
new file mode 100644
index 0000000000..eabd25b76c
--- /dev/null
+++ b/engines/bladerunner/script/ct12.cpp
@@ -0,0 +1,284 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT12::InitializeScene() {
+ if (Game_Flag_Query(123)) {
+ Setup_Scene_Information(-419.0f, -6.5f, 696.0f, 616);
+ } else if (Game_Flag_Query(432)) {
+ Setup_Scene_Information(-292.0f, -6.5f, 990.0f, 827);
+ if (!Game_Flag_Query(150)) {
+ Game_Flag_Set(150);
+ }
+ Game_Flag_Reset(432);
+ } else if (Game_Flag_Query(86)) {
+ Setup_Scene_Information(-493.0f, -6.5f, 1174.0f, 990);
+ } else {
+ Setup_Scene_Information(-386.13f, -6.5f, 1132.72f, 783);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 40, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 78, 224, 162, 330, 0);
+ Scene_Exit_Add_2D_Exit(2, 500, 180, 619, 346, 0);
+ if (Global_Variable_Query(1) > 2) {
+ Scene_Exit_Add_2D_Exit(3, 620, 0, 639, 479, 1);
+ }
+ if (Global_Variable_Query(1) > 3) {
+ Scene_Exit_Add_2D_Exit(4, 324, 150, 435, 340, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 33, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(55, 20, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(56, 20, -100, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 20, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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(1) < 2 && Actor_Query_Goal_Number(53) == 1) {
+ Actor_Put_In_Set(53, 4);
+ Actor_Set_At_XYZ(53, -534.0f, -6.5f, 952.0f, 367);
+ Game_Flag_Set(294);
+ }
+ if (Game_Flag_Query(123) && Game_Flag_Query(248)) {
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Scene_Loop_Start_Special(0, 1, 0);
+ }
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Reset(123);
+ } else if (Game_Flag_Query(123) && !Game_Flag_Query(248)) {
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ }
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Reset(123);
+ } else if (Game_Flag_Query(76) && Game_Flag_Query(294)) {
+ Game_Flag_Reset(76);
+ Scene_Loop_Set_Default(4);
+ } else if (Game_Flag_Query(76) && !Game_Flag_Query(294)) {
+ Game_Flag_Reset(76);
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(2);
+
+ }
+}
+
+void ScriptCT12::SceneLoaded() {
+ Obstacle_Object("BOX18", true);
+ Unobstacle_Object("SPINNER BODY", true);
+ Unobstacle_Object("HOWFLOOR", true);
+ Unclickable_Object("TURBINE");
+}
+
+bool ScriptCT12::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptCT12::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptCT12::ClickedOnActor(int actorId) {
+ if (actorId == 28) {
+ Actor_Face_Actor(0, 28, true);
+ Actor_Says(0, 8910, 16);
+ }
+ if (actorId == 24 && Global_Variable_Query(1) == 4 && Game_Flag_Query(671) && Game_Flag_Query(703)) {
+ Actor_Face_Actor(24, 0, true);
+ Actor_Face_Actor(0, 24, true);
+ Actor_Says(0, 710, 3);
+ Actor_Says(24, 20, 3);
+ Actor_Says(0, 715, 3);
+ Actor_Says(24, 30, 3);
+ Actor_Says(0, 720, 3);
+ Actor_Says(24, 40, 3);
+ Actor_Says(24, 50, 3);
+ Actor_Says(24, 60, 3);
+ Actor_Says(0, 725, 3);
+ Actor_Says(24, 70, 3);
+ Actor_Says(24, 80, 3);
+ Actor_Says(24, 90, 3);
+ Actor_Says(24, 100, 3);
+ Actor_Says(24, 110, 3);
+ Game_Flag_Set(629);
+ Game_Flag_Set(666);
+ Actor_Set_Goal_Number(0, 400);
+ }
+ return false;
+}
+
+bool ScriptCT12::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptCT12::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -419.14999f, -6.5f, 696.94f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Game_Flag_Set(88);
+ Set_Enter(4, 13);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -182.69f, -6.5f, 696.94f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(89);
+ Set_Enter(5, 15);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -386.13f, -6.5f, 1132.72f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(90);
+ Set_Enter(28, 17);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -493.0f, -6.5f, 1174.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(91);
+ Set_Enter(33, 23);
+ }
+ return true;
+ }
+ if (exitId == 4) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -292.0f, -6.5f, 990.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) == 4) {
+ Game_Flag_Set(629);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(433);
+ Set_Enter(82, 94);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT12::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT12::SceneFrameAdvanced(int frame) {
+ if (!((frame - 1) % 10)) {
+ /*int v2 = Random_Query(0, 1);
+ if (v2 <= 1)
+ {
+ if (v2)
+ {
+ v1 = 60;
+ }
+ else
+ {
+ v1 = 59;
+ }
+ }*/
+ Sound_Play(/*v1*/Random_Query(59, 60), 10, -80, -80, 50);
+ }
+ if (frame == 160) {
+ Actor_Change_Animation_Mode(53, 41);
+ }
+ if (frame == 152) {
+ Sound_Play(116, 100, 40, 0, 50);
+ }
+ if (frame == 203) {
+ Sound_Play(119, 100, 40, 0, 50);
+ }
+ if (frame == 212) {
+ Sound_Play(117, 40, 0, 0, 50);
+ }
+ if (frame == 269) {
+ Player_Gains_Control();
+ Player_Set_Combat_Mode(false);
+ Actor_Set_Invisible(53, false);
+ }
+}
+
+void ScriptCT12::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT12::PlayerWalkedIn() {
+ if (Global_Variable_Query(1) < 2 && !Game_Flag_Query(64) && Actor_Query_Goal_Number(53) == 1) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_Actor(53, 0, 48, 0, false);
+ Actor_Face_Actor(53, 0, true);
+ Actor_Face_Actor(0, 53, true);
+ Actor_Says(53, 0, 3);
+ Actor_Says(0, 670, 3);
+ Actor_Says(53, 10, 3);
+ Actor_Says(0, 675, 3);
+ Actor_Says(53, 20, 3);
+ Actor_Says(0, 680, 3);
+ Actor_Says(53, 30, 3);
+ Actor_Says(0, 685, 3);
+ Actor_Says(53, 40, 3);
+ Actor_Says(0, 690, 3);
+ Actor_Clue_Acquire(0, 33, 1, 53);
+ Game_Flag_Set(64);
+ CDB_Set_Crime(20, 8);
+ if (Game_Flag_Query(64) && Game_Flag_Query(40)) {
+ Actor_Says(53, 50, 3);
+ Actor_Says(0, 695, 3);
+ Actor_Says(53, 60, 3);
+ Actor_Says(0, 700, 3);
+ Actor_Says(53, 70, 3);
+ Actor_Clue_Acquire(53, 222, 1, -1);
+ } else if (Game_Flag_Query(64) && Game_Flag_Query(41)) {
+ Actor_Says(53, 80, 3);
+ Actor_Says(53, 90, 3);
+ Actor_Says(0, 705, 3);
+ Actor_Says(53, 100, 3);
+ Actor_Clue_Acquire(53, 215, 1, -1);
+ }
+ Actor_Set_Goal_Number(53, 2);
+ }
+ if (Game_Flag_Query(86)) {
+ Loop_Actor_Walk_To_XYZ(0, -520.0f, -6.5f, 1103.0f, 0, 0, false, 0);
+ Game_Flag_Reset(86);
+ }
+}
+
+void ScriptCT12::PlayerWalkedOut() {
+ Game_Flag_Reset(443);
+ if (Game_Flag_Query(433)) {
+ Game_Flag_Reset(176);
+ Game_Flag_Set(259);
+ }
+}
+
+void ScriptCT12::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ct51.cpp b/engines/bladerunner/script/ct51.cpp
new file mode 100644
index 0000000000..bc47dddb21
--- /dev/null
+++ b/engines/bladerunner/script/ct51.cpp
@@ -0,0 +1,129 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptCT51::InitializeScene() {
+ Setup_Scene_Information(0.0f, 0.0f, -102.0f, 470);
+ Game_Flag_Reset(379);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptCT51::SceneLoaded() {
+ Unobstacle_Object("BLANKET03", true);
+ Clickable_Object("BED02");
+ if (!Actor_Clue_Query(0, 85)) {
+ Item_Add_To_World(85, 943, 6, 44.0f, 0.0f, -95.0f, 540, 24, 24, false, true, false, true);
+ }
+ if (!Actor_Clue_Query(0, 86)) {
+ Item_Add_To_World(120, 984, 6, 44.0f, 0.0f, -22.0f, 0, 12, 12, false, true, false, true);
+ }
+}
+
+bool ScriptCT51::MouseClick(int x, int y) {
+ return true;
+}
+
+bool ScriptCT51::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BED02", objectName)) {
+ if (Actor_Clue_Query(0, 84)) {
+ Actor_Says(0, 8580, 12);
+ return false;
+ }
+ Item_Pickup_Spin_Effect(970, 203, 200);
+ Actor_Clue_Acquire(0, 84, 1, -1);
+ Actor_Voice_Over(420, 99);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT51::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptCT51::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 85) {
+ Actor_Clue_Acquire(0, 85, 1, -1);
+ Item_Pickup_Spin_Effect(943, 260, 200);
+ Ambient_Sounds_Play_Sound(563, 40, 99, 0, 0);
+ Item_Remove_From_World(85);
+ return true;
+ }
+ if (itemId == 120) {
+ Actor_Clue_Acquire(0, 86, 1, -1);
+ Item_Pickup_Spin_Effect(984, 490, 307);
+ Item_Remove_From_World(120);
+ Actor_Says(0, 8527, 3);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptCT51::ClickedOnExit(int exitId) {
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 0.0f, 0.0f, -102.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -11.0f, 0.0f, -156.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(380);
+ Set_Enter(6, 20);
+ }
+ return true;
+ }
+ return false;
+
+}
+
+bool ScriptCT51::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptCT51::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptCT51::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptCT51::PlayerWalkedIn() {
+}
+
+void ScriptCT51::PlayerWalkedOut() {
+ if (!Actor_Clue_Query(0, 85)) {
+ Item_Remove_From_World(85);
+ }
+}
+
+void ScriptCT51::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr01.cpp b/engines/bladerunner/script/dr01.cpp
new file mode 100644
index 0000000000..e8d89a27fe
--- /dev/null
+++ b/engines/bladerunner/script/dr01.cpp
@@ -0,0 +1,262 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR01::InitializeScene() {
+ if (Game_Flag_Query(225)) {
+ Setup_Scene_Information(-835.0f, -0.04f, -118.0f, 664);
+ } else if (Game_Flag_Query(11)) {
+ Setup_Scene_Information(-711.0f, -0.04f, 70.0f, 307);
+ } else if (Game_Flag_Query(531)) {
+ Setup_Scene_Information(-1765.28f, -0.04f, -23.82f, 269);
+ } else {
+ Setup_Scene_Information(-386.0f, -0.04f, -82.0f, 792);
+ }
+ Scene_Exit_Add_2D_Exit(0, 240, 60, 450, 250, 0);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ if (Game_Flag_Query(253) && Global_Variable_Query(1) < 4) {
+ Scene_Exit_Add_2D_Exit(2, 610, 0, 639, 479, 1);
+ }
+ if (Global_Variable_Query(1) >= 3) {
+ Scene_Exit_Add_2D_Exit(3, 0, 45, 142, 201, 0);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(219, 12, 85, 1);
+ Ambient_Sounds_Add_Looping_Sound(98, 14, 85, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(67, 5, 80, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(66, 5, 80, 16, 25, -100, 100, -101, -101, 0, 0);
+ 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(11)) {
+ Scene_Loop_Start_Special(0, 3, 0);
+ Scene_Loop_Set_Default(4);
+ } else if (!Game_Flag_Query(272) && Game_Flag_Query(11)) {
+ Scene_Loop_Start_Special(0, 2, 0);
+ Scene_Loop_Set_Default(4);
+ } else if (Game_Flag_Query(225)) {
+ Scene_Loop_Start_Special(0, 1, 0);
+ Scene_Loop_Set_Default(4);
+ } else if (Game_Flag_Query(531) == 1) {
+ Scene_Loop_Set_Default(4);
+ } else {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(4);
+ }
+}
+
+void ScriptDR01::SceneLoaded() {
+ Obstacle_Object("TRASH CAN WITH FIRE", true);
+ Obstacle_Object("V2PYLON02", true);
+ Obstacle_Object("V2PYLON04", true);
+ Obstacle_Object("U2 CHEWDOOR", true);
+ Obstacle_Object("MMTRASHCAN", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("TRANSFORMER 01", true);
+ Obstacle_Object("TRANSFORMER 02", true);
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("Z2TRSHCAN", true);
+ Obstacle_Object("Z2ENTRYDR", true);
+ Obstacle_Object("Z2DR2", true);
+ Unobstacle_Object("V2 BUILD01", true);
+}
+
+bool ScriptDR01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptDR01::ClickedOnActor(int actorId) {
+ return actorId == 50;
+}
+
+bool ScriptDR01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptDR01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -835.0f, -0.04f, -118.0f, 0, 1, false, 0)) {
+ Async_Actor_Walk_To_XYZ(0, -911.0f, -0.04f, -118.0f, 0, false);
+ Ambient_Sounds_Adjust_Looping_Sound(112, 10, -100, 1);
+ Game_Flag_Set(224);
+ Set_Enter(7, 26);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -711.0f, -0.04f, 70.0f, 0, 1, false, 0)) {
+ Async_Actor_Walk_To_XYZ(0, -796.0f, -0.04f, 166.0f, 0, false);
+ Game_Flag_Set(10);
+ Set_Enter(7, 28);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (Loop_Actor_Walk_To_XYZ(0, -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);
+ switch (spinnerDest) {
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ break;
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(253);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ break;
+ default:
+ Player_Loses_Control();
+ Game_Flag_Set(177);
+ Loop_Actor_Walk_To_XYZ(0, -447.39f, 0.16f, -92.38f, 0, 0, true, 0);
+ Player_Gains_Control();
+ break;
+ }
+ }
+ return true;
+ }
+
+ if (exitId == 3) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ bool v7 = false;
+ if (-1200 < x) {
+ v7 = Loop_Actor_Walk_To_XYZ(0, -1236.4f, -0.04f, -13.91f, 0, 1, false, 0);
+ }
+ if (!v7) {
+ Game_Flag_Set(558);
+ Game_Flag_Set(176);
+ Game_Flag_Reset(177);
+ Set_Enter(33, 23);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptDR01::SceneFrameAdvanced(int frame) {
+ if (frame < 75) {
+ Actor_Set_Invisible(0, true);
+ } else {
+ Actor_Set_Invisible(0, false);
+ }
+ if (frame == 2) {
+ Ambient_Sounds_Play_Sound(487, 40, -40, 100, 99);
+ }
+}
+
+void ScriptDR01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR01::PlayerWalkedIn() {
+ if (Game_Flag_Query(531)) {
+ Async_Actor_Walk_To_XYZ(0, -757.15f, -0.04f, 24.64f, 0, false);
+ } else if (!Game_Flag_Query(225) && !Game_Flag_Query(11)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -447.39f, 0.16f, -92.38f, 0, 0, false, 0);
+ Player_Gains_Control();
+ }
+ Game_Flag_Reset(225);
+ Game_Flag_Reset(11);
+ Game_Flag_Reset(531);
+}
+
+void ScriptDR01::PlayerWalkedOut() {
+ if (!Game_Flag_Query(10) && !Game_Flag_Query(224) && !Game_Flag_Query(558)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(35, 1, -1);
+ }
+}
+
+void ScriptDR01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr02.cpp b/engines/bladerunner/script/dr02.cpp
new file mode 100644
index 0000000000..c075d808f5
--- /dev/null
+++ b/engines/bladerunner/script/dr02.cpp
@@ -0,0 +1,183 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR02::InitializeScene() {
+ if (Game_Flag_Query(227)) {
+ Setup_Scene_Information(-1162.0f, 7.18f, -322.0f, 552);
+ } else if (Game_Flag_Query(224)) {
+ Setup_Scene_Information(-835.0f, -0.04f, -118.0f, 193);
+ } else if (Game_Flag_Query(264)) {
+ Setup_Scene_Information(-1258.0f, 7.18f, -314.0f, 400);
+ } else {
+ Setup_Scene_Information(168.78f, 0.16f, -775.71997f, 193);
+ }
+ Scene_Exit_Add_2D_Exit(0, 605, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 222, 176, 279, 314, 0);
+ if (Game_Flag_Query(326)) {
+ Scene_Exit_Add_2D_Exit(2, 95, 0, 148, 292, 0);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Remove_All_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(219, 27, 85, 1);
+ Ambient_Sounds_Add_Looping_Sound(98, 38, 85, 1);
+ Ambient_Sounds_Add_Sound(378, 2, 50, 33, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 2, 50, 33, 100, -100, 100, -101, -101, 0, 0);
+ 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);
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptDR02::SceneLoaded() {
+ Obstacle_Object("TRASH CAN WITH FIRE", true);
+ Obstacle_Object("V2PYLON02", true);
+ Obstacle_Object("V2PYLON04", true);
+ Obstacle_Object("U2 CHEWDOOR", true);
+ Obstacle_Object("MMTRASHCAN", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("TRANSFORMER 01", true);
+ Obstacle_Object("TRANSFORMER 02", true);
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("Z2ENTRYDR", true);
+ Obstacle_Object("Z2DR2", true);
+ Clickable_Object("TRASH CAN WITH FIRE");
+ Clickable_Object("U2 CHEWDOOR");
+ Clickable_Object("MMTRASHCAN");
+ Clickable_Object("U2 EYE");
+ Clickable_Object("U2 E");
+ Clickable_Object("MMNEWSP01");
+ Clickable_Object("MMNEWSP01");
+ Clickable_Object("MMNEWSP04");
+ Clickable_Object("MMNEWSP05");
+ Clickable_Object("MMNEWSP07");
+ Clickable_Object("PARKMETR02");
+ Clickable_Object("TRANSFORMER 01");
+ Clickable_Object("TRANSFORMER 02");
+ Clickable_Object("V2CANPIPE02");
+ Unclickable_Object("TRASH CAN WITH FIRE");
+ Unclickable_Object("U2 CHEWDOOR");
+ Unclickable_Object("MMTRASHCAN");
+ Unclickable_Object("U2 EYE");
+ Unclickable_Object("U2 E");
+ Unclickable_Object("MMNEWSP01");
+ Unclickable_Object("MMNEWSP02");
+ Unclickable_Object("MMNEWSP04");
+ Unclickable_Object("MMNEWSP06");
+ Unclickable_Object("MMNEWSP07");
+ Unclickable_Object("PARKMETR02");
+ Unclickable_Object("TRANSFORMER 01");
+ Unclickable_Object("TRANSFORMER 02");
+ Unclickable_Object("V2CANPIPE02");
+}
+
+bool ScriptDR02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptDR02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptDR02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptDR02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -835.0f, -0.04f, -118.0f, 0, 1, false, 0)) {
+ Async_Actor_Walk_To_XYZ(0, -727.0f, -0.04f, -118.0f, 0, false);
+ Game_Flag_Set(225);
+ Set_Enter(7, 25);
+ }
+ 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(0, -1162.0f, 7.18f, -322.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) > 2) {
+ Actor_Says(0, 8522, 15);
+ } else {
+ Game_Flag_Set(226);
+ Set_Enter(34, 27);
+ }
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -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, 2);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptDR02::SceneFrameAdvanced(int frame) {
+ if (frame == 1) {
+ Sound_Play(1, 10, 85, 85, 50);
+ }
+}
+
+void ScriptDR02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR02::PlayerWalkedIn() {
+ if (Game_Flag_Query(227)) {
+ Game_Flag_Reset(227);
+ }
+ if (Game_Flag_Query(224)) {
+ Game_Flag_Reset(224);
+ }
+ if (Game_Flag_Query(264)) {
+ Game_Flag_Reset(264);
+ }
+}
+
+void ScriptDR02::PlayerWalkedOut() {
+}
+
+void ScriptDR02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr03.cpp b/engines/bladerunner/script/dr03.cpp
new file mode 100644
index 0000000000..cea23b7ec3
--- /dev/null
+++ b/engines/bladerunner/script/dr03.cpp
@@ -0,0 +1,288 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR03::InitializeScene() {
+ if (Game_Flag_Query(226)) {
+ Game_Flag_Reset(226);
+ 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(1) == 3) {
+ Actor_Put_In_Set(52, 34);
+ Actor_Set_At_XYZ(52, 431.21f, 4.27f, -776.26f, 0);
+ } else {
+ Actor_Put_In_Set(52, 34);
+ Actor_Set_At_XYZ(52, 360.77f, 4.4f, -806.67f, 126);
+ }
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Ambient_Sounds_Add_Looping_Sound(110, 7, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(109, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 20, 70, 1);
+}
+
+void ScriptDR03::SceneLoaded() {
+ Obstacle_Object("W2-CENTCASE02", 1);
+ Obstacle_Object("W2-CARTTOP", 1);
+ Obstacle_Object("W2-TANKAFLUID01", 1);
+}
+
+bool ScriptDR03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptDR03::ClickedOnActor(int actorId) {
+ if (actorId == 52) {
+ Actor_Face_Actor(0, 52, 1);
+ Actor_Face_Actor(52, 0, 1);
+ if (!Game_Flag_Query(267)) {
+ Actor_Says(0, 755, 18);
+ Actor_Says(52, 10, 14);
+ Actor_Says(0, 760, 18);
+ Actor_Says(52, 20, 14);
+ Actor_Says(0, 765, 18);
+ Actor_Says(52, 30, 14);
+ Game_Flag_Set(267);
+ return true;
+ }
+ if (Actor_Clue_Query(0, 67)) {
+ if (Game_Flag_Query(266) && Game_Flag_Query(267)) {
+ Actor_Says(0, 815, 18);
+ Actor_Says(52, 60, 14);
+ Actor_Says(52, 70, 14);
+ Actor_Says(52, 80, 14);
+ Actor_Says(0, 820, 18);
+ Actor_Says(52, 90, 14);
+ Actor_Says(0, 825, 18);
+ Actor_Says(52, 100, 14);
+ Game_Flag_Reset(266);
+ Game_Flag_Set(505);
+ return true;
+ }
+ if ((Actor_Clue_Query(0, 147) || Actor_Clue_Query(0, 71) || Actor_Clue_Query(0, 76) || Actor_Clue_Query(0, 67))
+ && Game_Flag_Query(505)) {
+ sub_401B18();
+ } else {
+ Actor_Says(0, 810, 18);
+ Actor_Says(52, 40, 14);
+ Actor_Says(52, 50, 14);
+ }
+ return true;
+ }
+ Actor_Says(0, 770, 12);
+ Actor_Says(52, 110, 12);
+ Actor_Says(52, 120, 13);
+ Actor_Says(0, 835, 13);
+ Actor_Says(52, 130, 14);
+ Actor_Says(0, 840, 16);
+ Actor_Says(52, 140, 15);
+ if (!Game_Flag_Query(505)) {
+ Actor_Says(52, 150, 13);
+ Actor_Says(0, 845, 17);
+ Actor_Says(52, 170, 18);
+ Actor_Says(52, 180, 16);
+ Actor_Says(0, 850, 15);
+ Actor_Says(52, 190, 14);
+ Actor_Says(52, 200, 13);
+ Actor_Says(0, 855, 18);
+ Actor_Says(52, 210, 12);
+ }
+ Actor_Clue_Acquire(0, 67, 1, 52);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptDR03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 330.31f, 4.27f, -910.91f, 24, 1, 0, 0)) {
+ Game_Flag_Set(227);
+ Set_Enter(7, 26);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptDR03::SceneFrameAdvanced(int frame) {
+ if (frame == 1 || frame == 4 || frame == 8 || frame == 10 || frame == 19 || frame == 21 || frame == 22 || frame == 23 || frame == 30 || frame == 31 || frame == 32 || frame == 33 || frame == 46 || frame == 49) {
+ if (Random_Query(0, 1)) {
+ Sound_Play(97, Random_Query(20, 33), 80, 80, 50);
+ } else {
+ Sound_Play(59, Random_Query(5, 6), 80, 80, 50);
+ }
+ }
+}
+
+void ScriptDR03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR03::PlayerWalkedIn() {
+ if (!Game_Flag_Query(226)) {
+ if (Random_Query(1, 2) == 1) {
+ Actor_Says(52, 660, 14);
+ Actor_Says(52, 680, 14);
+ } else if (Random_Query(1, 2) == 2) {
+ Actor_Says(52, 670, 14);
+ Actor_Says(52, 620, 14);
+ } else {
+ Actor_Says(52, 690, 14);
+ Actor_Says(52, 710, 14);
+ }
+ }
+}
+
+void ScriptDR03::PlayerWalkedOut() {
+}
+
+void ScriptDR03::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptDR03::sub_401B18() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 67) || Actor_Clue_Query(0, 71) || Actor_Clue_Query(0, 68)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(650, 5, 5, 5);
+ }
+ if (Actor_Clue_Query(0, 67)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(660, 5, 5, 5);
+ }
+ if (Actor_Clue_Query(0, 279)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(670, 6, 5, 2);
+ }
+ if (Game_Flag_Query(505)) {
+ if (Actor_Clue_Query(0, 71)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(680, 8, 8, 8);
+ }
+ if (Actor_Clue_Query(0, 76)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1270, 2, 5, 7);
+ }
+ }
+ Dialogue_Menu_Add_DONE_To_List(690);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 640:
+ Actor_Says(0, 770, 12);
+ Actor_Says(52, 110, 12);
+ Actor_Says(52, 120, 13);
+ Actor_Says(0, 835, 13);
+ Actor_Says(52, 130, 14);
+ Actor_Says(0, 840, 16);
+ Actor_Says(52, 140, 15);
+ if (!Game_Flag_Query(505)) {
+ Actor_Says(52, 150, 13);
+ Actor_Says(0, 845, 17);
+ Actor_Says(52, 170, 18);
+ Actor_Says(52, 180, 16);
+ Actor_Says(0, 850, 15);
+ Actor_Says(52, 190, 14);
+ Actor_Says(52, 200, 13);
+ Actor_Says(0, 855, 18);
+ Actor_Says(52, 210, 12);
+ }
+ Actor_Clue_Acquire(0, 67, 1, 52);
+ break;
+ case 650:
+ Actor_Says(0, 775, 11);
+ Actor_Says(52, 220, 14);
+ Actor_Says(0, 860, 11);
+ Actor_Says(52, 230, 14);
+ Actor_Says(0, 865, 11);
+ Actor_Says(52, 240, 14);
+ Actor_Says(52, 250, 14);
+ break;
+ case 660:
+ Actor_Says(0, 780, 13);
+ if (Game_Flag_Query(505)) {
+ Actor_Says(52, 260, 14);
+ Actor_Says(52, 270, 13);
+ Actor_Says(52, 280, 12);
+ } else {
+ Actor_Says(52, 260, 14);
+ Actor_Says(52, 270, 13);
+ Actor_Says(52, 280, 12);
+ Actor_Says(0, 870, 18);
+ Actor_Says(52, 290, 15);
+ if (!Game_Flag_Query(266)) {
+ Actor_Says(52, 300, 12);
+ }
+ }
+ Actor_Clue_Acquire(0, 67, 1, 52);
+ break;
+ case 670:
+ Actor_Says(0, 765, 12);
+ Actor_Says(0, 790, 13);
+ Actor_Says(52, 310, 12);
+ Actor_Says(52, 320, 3);
+ break;
+ case 680:
+ Actor_Says(0, 795, 3);
+ if (Game_Flag_Query(505) == 1) {
+ Actor_Says(52, 330, 12);
+ Actor_Says(52, 340, 15);
+ Actor_Says(0, 875, 16);
+ Actor_Says(52, 350, 12);
+ Actor_Says(52, 360, 15);
+ Game_Flag_Set(326);
+ } else {
+ Actor_Says(52, 320, 13);
+ Actor_Says(52, 150, 14);
+ Game_Flag_Set(326);
+ }
+ break;
+ case 1270:
+ Actor_Says(0, 800, 16);
+ Actor_Says(52, 370, 3);
+ Actor_Says(0, 880, 15);
+ Actor_Says(52, 380, 13);
+ Actor_Says(52, 390, 12);
+ Actor_Says(0, 885, 14);
+ Actor_Says(52, 400, 13);
+ Actor_Says(52, 410, 15);
+ Actor_Says(0, 890, 18);
+ Actor_Says(52, 420, 13);
+ Actor_Says(52, 430, 12);
+ break;
+ case 690:
+ Actor_Says(0, 805, 3);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr04.cpp b/engines/bladerunner/script/dr04.cpp
new file mode 100644
index 0000000000..1cef91b967
--- /dev/null
+++ b/engines/bladerunner/script/dr04.cpp
@@ -0,0 +1,269 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR04::InitializeScene() {
+ if (Game_Flag_Query(515)) {
+ Setup_Scene_Information(0.0f, 0.0f, 0.0f, 0);
+ } else if (Game_Flag_Query(10)) {
+ Setup_Scene_Information(-711.0f, -0.04f, 70.0f, 472);
+ } else if (Game_Flag_Query(229)) {
+ Setup_Scene_Information(-1067.0f, 7.18f, 421.0f, 125);
+ } else if (Game_Flag_Query(231)) {
+ Setup_Scene_Information(-897.75f, 134.45f, 569.75f, 512);
+ } else {
+ Setup_Scene_Information(-810.0f, -0.04f, 242.0f, 125);
+ }
+ Scene_Exit_Add_2D_Exit(0, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 443, 264, 488, 353, 0);
+ Scene_Exit_Add_2D_Exit(2, 222, 110, 269, 207, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(288, 55, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(217, 28, -100, 100);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(67, 40, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(66, 40, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(378, 5, 80, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(379, 5, 80, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(380, 5, 80, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(272)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(4);
+ }
+ if (Game_Flag_Query(10)) {
+ if (Game_Flag_Query(272)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ } else {
+ Scene_Loop_Start_Special(0, 3, 0);
+ }
+ }
+}
+
+void ScriptDR04::SceneLoaded() {
+ Obstacle_Object("TRASH CAN WITH FIRE", true);
+ Obstacle_Object("V2PYLON02", true);
+ Obstacle_Object("V2PYLON04", true);
+ Obstacle_Object("U2 CHEWDOOR", true);
+ Obstacle_Object("MMTRASHCAN", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("TRANSFORMER 01", true);
+ Obstacle_Object("TRANSFORMER 02", true);
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("Z2ENTRYDR", true);
+ Obstacle_Object("Z2DR2", true);
+ Unclickable_Object("PARKMETR01");
+ Unclickable_Object("Z2ENTRYDR");
+ Unclickable_Object("Z2DR2");
+}
+
+bool ScriptDR04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptDR04::ClickedOnActor(int actorId) {
+ if (actorId == 35 && !Player_Query_Combat_Mode()) {
+ if (Actor_Query_Goal_Number(35) != 21) {
+ if (Actor_Query_Goal_Number(35) == 23) {
+ if (!Loop_Actor_Walk_To_Actor(0, 35, 36, 1, false)) {
+ Actor_Set_Goal_Number(24, 106);
+ return true;
+ }
+ }
+ return false;
+ }
+ if (!Loop_Actor_Walk_To_Waypoint(0, 109, 0, 1, true)) {
+ Actor_Face_Actor(0, 35, true);
+ Actor_Says(0, 945, 13);
+ Actor_Says(35, 0, 3);
+ Actor_Says(35, 10, 3);
+ Actor_Says(0, 950, 13);
+ Actor_Says(35, 20, 3);
+ Actor_Says(35, 30, 3);
+ Actor_Says(0, 955, 13);
+ Actor_Says_With_Pause(35, 40, 0, 3);
+ Actor_Says(35, 50, 3);
+ Actor_Clue_Acquire(0, 68, 1, 35);
+ Actor_Set_Goal_Number(35, 22);
+ Actor_Set_Goal_Number(24, 101);
+ return true;
+ }
+ return false;
+ }
+ return false;
+}
+
+bool ScriptDR04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptDR04::ClickedOnExit(int exitId) {
+ if (Actor_Query_Goal_Number(35) == 21) {
+ Actor_Force_Stop_Walking(0);
+ Actor_Set_Goal_Number(35, 22);
+ Actor_Set_Goal_Number(24, 101);
+ return true;
+ }
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -761.0f, -0.04f, 97.0f, 0, 1, false, 0)) {
+ Async_Actor_Walk_To_XYZ(0, -683.0f, -0.04f, 43.0f, 0, false);
+ Game_Flag_Set(11);
+ Set_Enter(7, 25);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1067.0f, 7.18f, 421.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(232);
+ Game_Flag_Set(228);
+ Set_Enter(35, 29);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -851.0f, 6.98f, 560.0f, 0, 1, false, 0)) {
+ Footstep_Sound_Override_On(3);
+ Actor_Set_Immunity_To_Obstacles(0, true);
+ Actor_Face_Heading(0, 512, false);
+ Loop_Actor_Travel_Stairs(0, 7, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, -899.0f, 71.64f, 647.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 0, false);
+ Loop_Actor_Travel_Stairs(0, 7, 1, 0);
+ Actor_Set_Immunity_To_Obstacles(0, false);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Set(230);
+ Set_Enter(36, 30);
+ }
+ return true;
+ }
+ return true; //bug?
+}
+
+bool ScriptDR04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+bool ScriptDR04::sub_401160() {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ return (x + 1089.94f) * (x + 1089.94f) + (z - 443.49f) * (z - 443.49f) >= (360.0f * 360.0f);
+}
+
+void ScriptDR04::SceneFrameAdvanced(int frame) {
+ if (Game_Flag_Query(515)) {
+ Game_Flag_Reset(515);
+ Game_Flag_Reset(271);
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 6, 1);
+ Music_Stop(4);
+ Actor_Set_Goal_Number(35, 99);
+ } else {
+ if (Game_Flag_Query(271)) {
+ Game_Flag_Reset(271);
+ Game_Flag_Set(272);
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 6, 1);
+ Item_Remove_From_World(78);
+ }
+ switch (frame) {
+ case 193:
+ Sound_Play(301, 100, 0, 100, 50);
+ Actor_Set_Goal_Number(35, 30);
+ Player_Loses_Control();
+ Actor_Force_Stop_Walking(0);
+ if (sub_401160()) {
+ if (Player_Query_Combat_Mode()) {
+ Actor_Change_Animation_Mode(0, 22);
+ } else {
+ Actor_Change_Animation_Mode(0, 21);
+ }
+ } else {
+ Sound_Play_Speech_Line(0, 9905, 100, 0, 99);
+ Actor_Change_Animation_Mode(0, 48);
+ Actor_Retired_Here(0, 6, 6, 1, -1);
+ }
+ Player_Gains_Control();
+ break;
+ case 235:
+ if (Actor_Query_Goal_Number(35) != 20 && Actor_Query_Goal_Number(35) != 21 && Actor_Query_Goal_Number(35) != 99) {
+ Actor_Set_Goal_Number(24, 101);
+ }
+ Scene_Exits_Enable();
+ break;
+ case 237:
+ Overlay_Play("DR04OVER", 0, 1, 1, 0);
+ break;
+ }
+ }
+}
+
+void ScriptDR04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR04::PlayerWalkedIn() {
+ if (Game_Flag_Query(515)) {
+ Player_Loses_Control();
+ Delay(4000);
+ Actor_Retired_Here(0, 6, 6, 1, -1);
+ } else {
+ if (Game_Flag_Query(269) && !Game_Flag_Query(272)) {
+ Scene_Exits_Disable();
+ }
+ if (Game_Flag_Query(231)) {
+ Footstep_Sound_Override_On(3);
+ Actor_Set_Immunity_To_Obstacles(0, true);
+ Actor_Face_Heading(0, 512, false);
+ Loop_Actor_Travel_Stairs(0, 7, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -851.0f, 71.64f, 647.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 0, false);
+ Loop_Actor_Travel_Stairs(0, 7, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -774.85f, 7.18f, 386.67001f, 0, 0, false, 0);
+ Actor_Set_Immunity_To_Obstacles(0, false);
+ Footstep_Sound_Override_Off();
+ }
+ }
+ Game_Flag_Reset(10);
+ Game_Flag_Reset(229);
+ Game_Flag_Reset(231);
+}
+
+void ScriptDR04::PlayerWalkedOut() {
+ Music_Stop(2);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptDR04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr05.cpp b/engines/bladerunner/script/dr05.cpp
new file mode 100644
index 0000000000..c7beafe6ba
--- /dev/null
+++ b/engines/bladerunner/script/dr05.cpp
@@ -0,0 +1,189 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR05::InitializeScene() {
+ Setup_Scene_Information(-22.0f, 0.3f, 221.0f, 0);
+ Game_Flag_Reset(228);
+ Scene_Exit_Add_2D_Exit(0, 0, 38, 80, 467, 3);
+ Ambient_Sounds_Add_Looping_Sound(383, 25, 0, 1);
+ if (!Game_Flag_Query(272)) {
+ Overlay_Play("DR05OVER", 0, 1, 0, 0);
+ }
+ if (Game_Flag_Query(272)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptDR05::SceneLoaded() {
+ Obstacle_Object("MAN PROPHI", true);
+ Unobstacle_Object("BOX06", true);
+ Unobstacle_Object("BOX183", true);
+ Clickable_Object("T2 DOORWAY");
+ if (!Game_Flag_Query(272)) {
+ Item_Add_To_World(78, 932, 35, -1.57f, 31.33f, 75.21f, 540, 16, 16, true, true, false, true);
+ if (!Actor_Query_Goal_Number(35)) {
+ Item_Add_To_World(122, 931, 35, 37.35f, 1.59f, 46.72f, 0, 20, 20, true, true, false, true);
+ }
+ }
+}
+
+bool ScriptDR05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR05::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("T2 DOORWAY", objectName)) {
+ if (Game_Flag_Query(276) || Actor_Query_Goal_Number(35)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 57.61f, 0.3f, 69.27f, 0, 1, false, 0)) {
+ Actor_Face_Object(0, "T2 DOORWAY", true);
+ Actor_Says(0, 8522, 13);
+ Actor_Says(0, 8521, 14);
+ }
+ } else {
+ Actor_Face_Object(0, "T2 DOORWAY", true);
+ Actor_Says(0, 1020, 14);
+ Actor_Says(35, 90, 13);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptDR05::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 78) {
+ if (Player_Query_Combat_Mode()) {
+ Game_Flag_Set(271);
+ Actor_Set_Goal_Number(35, 30);
+ } else if (!Game_Flag_Query(272) && !Loop_Actor_Walk_To_Item(0, 78, 24, 1, true) && Actor_Query_Goal_Number(35) != 11) {
+ if (!Actor_Query_Goal_Number(35)) {
+ Actor_Says_With_Pause(0, 1015, 0.1f, 12);
+ Actor_Says(35, 70, 13);
+ }
+ Actor_Set_Goal_Number(35, 30);
+ }
+ //return true; //bug?
+ }
+ if (itemId == 122 && Player_Query_Combat_Mode() && !Actor_Query_Goal_Number(35)) {
+ Overlay_Play("DR05OVER", 1, 0, 1, 0);
+ Item_Remove_From_World(122);
+ Game_Flag_Set(270);
+ Actor_Set_Goal_Number(35, 10);
+ Music_Play(18, 71, 0, 0, -1, 0, 2);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -22.0f, 0.3f, 221.0f, 0, 1, false, 0)) {
+ Game_Flag_Reset(232);
+ Game_Flag_Set(229);
+ Set_Enter(7, 28);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptDR05::SceneFrameAdvanced(int frame) {
+ if (frame == 49) {
+ Sound_Play(148, Random_Query(50, 50), 80, 80, 50);
+ }
+ if (Game_Flag_Query(271)) {
+ Item_Remove_From_World(78);
+ Game_Flag_Reset(271);
+ Game_Flag_Set(272);
+ Actor_Set_Goal_Number(35, 30);
+ }
+}
+
+void ScriptDR05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR05::PlayerWalkedIn() {
+ if (!Game_Flag_Query(511) && !Game_Flag_Query(270) && Game_Flag_Query(272)) {
+ Item_Remove_From_World(122);
+ }
+ if (Game_Flag_Query(272)) {
+ Loop_Actor_Walk_To_XYZ(0, -10.0f, 0.3f, 133.0f, 0, 0, false, 0);
+ if (!Game_Flag_Query(511)) {
+ Game_Flag_Set(511);
+ if (Game_Flag_Query(48)) {
+ Actor_Voice_Over(730, 99);
+ Actor_Voice_Over(740, 99);
+ Actor_Voice_Over(750, 99);
+ Actor_Voice_Over(760, 99);
+ Actor_Clue_Acquire(0, 269, 1, -1);
+ } else {
+ Actor_Voice_Over(670, 99);
+ Actor_Voice_Over(680, 99);
+ Actor_Voice_Over(700, 99);
+ Actor_Voice_Over(710, 99);
+ Actor_Voice_Over(720, 99);
+ Actor_Clue_Acquire(0, 270, 1, -1);
+ }
+ }
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -10.0f, 0.3f, 133.0f, 0, 0, true, 0);
+ }
+ if (!Game_Flag_Query(274) && !Actor_Query_Goal_Number(35)) {
+ Actor_Face_Actor(0, 35, true);
+ Actor_Says(0, 1010, 13);
+ Actor_Face_Item(0, 78, true);
+ Player_Set_Combat_Mode(true);
+ Actor_Says(35, 60, 12);
+ Actor_Change_Animation_Mode(0, 0);
+ Game_Flag_Set(274);
+ //return true;
+ }
+ //return false;
+}
+
+void ScriptDR05::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (Actor_Query_Goal_Number(35) == 10 || Actor_Query_Goal_Number(35) == 18 || Actor_Query_Goal_Number(35) == 19) {
+ Actor_Set_Goal_Number(35, 11);
+ //return true;
+ }
+ //return false;
+}
+
+void ScriptDR05::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/dr06.cpp b/engines/bladerunner/script/dr06.cpp
new file mode 100644
index 0000000000..ebaa83205a
--- /dev/null
+++ b/engines/bladerunner/script/dr06.cpp
@@ -0,0 +1,225 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptDR06::InitializeScene() {
+ if (Game_Flag_Query(230)) {
+ Setup_Scene_Information(-733.57001f, 136.60001f, -968.64001f, 0);
+ } else {
+ Setup_Scene_Information(-707.57001f, 136.60001f, -1132.64f, 472);
+ }
+ Scene_Exit_Add_2D_Exit(0, 601, 11, 639, 479, 1);
+ if (Global_Variable_Query(1) > 3 && Game_Flag_Query(715)) {
+ Scene_Exit_Add_2D_Exit(1, 0, 272, 46, 477, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(383, 25, 0, 1);
+ Ambient_Sounds_Add_Sound(73, 5, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(268)) {
+ Overlay_Play("DR06over", 1, 1, 0, 0);
+ Ambient_Sounds_Add_Looping_Sound(300, 47, -75, 0);
+ } else {
+ Overlay_Play("DR06over", 0, 1, 0, 0);
+ }
+ if (Game_Flag_Query(548)) {
+ Overlay_Play("DR06ovr2", 0, 1, 0, 0);
+ }
+}
+
+void ScriptDR06::SceneLoaded() {
+ Obstacle_Object("X2_ASHTRAY", true);
+ Clickable_Object("X2_ASHTRAY");
+ Clickable_Object("X2KEYBRD02");
+ Clickable_Object("X2_MON01D01");
+ Clickable_Object("X2_MON01A04");
+ Clickable_Object("X2_TORSO04HIRES");
+ Clickable_Object("BOX16");
+ if (Actor_Clue_Query(0, 76)) {
+ Unclickable_Object("X2_TORSO04HIRES");
+ }
+}
+
+bool ScriptDR06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptDR06::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BOX16", objectName)) {
+ Loop_Actor_Walk_To_XYZ(0, -743.0f, 136.6f, -1091.0f, 0, 1, false, 0);
+ Actor_Face_Object(0, "BOX16", true);
+ if (!Game_Flag_Query(268)) {
+ Overlay_Play("DR06over", 1, 1, 1, 0);
+ Ambient_Sounds_Add_Looping_Sound(300, 47, -75, 0);
+ Game_Flag_Set(268);
+ return true;
+ }
+ Overlay_Play("DR06over", 0, 1, 1, 0);
+ Ambient_Sounds_Remove_Looping_Sound(300, false);
+ Game_Flag_Reset(268);
+ return true;
+ }
+ if (Object_Query_Click("X2_MON01A04", objectName)) {
+ if (Actor_Clue_Query(0, 71)) {
+ Actor_Face_Object(0, "X2_MON01A04", true);
+ Actor_Says(0, 8570, 13);
+ } else if (!Loop_Actor_Walk_To_XYZ(0, -684.94f, 136.6f, -1136.12f, 0, 1, false, 0)) {
+ Actor_Face_Object(0, "X2_MON01A04", true);
+ Actor_Says(39, 10, 3);
+ Actor_Says(39, 20, 3);
+ Actor_Says(39, 30, 3);
+ Actor_Says(0, 1025, 13);
+ Actor_Says(56, 0, 3);
+ Actor_Says(56, 10, 3);
+ Actor_Says(56, 20, 3);
+ Actor_Says(56, 30, 3);
+ Actor_Says(56, 40, 3);
+ Actor_Says(56, 50, 3);
+ Actor_Says(39, 40, 3);
+ Actor_Says(0, 1030, 13);
+ Actor_Says(39, 50, 3);
+ Actor_Clue_Acquire(0, 71, 1, 39);
+ }
+ return true;
+ }
+ if (Object_Query_Click("X2_MON01D01", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -645.34f, 136.6f, -1047.37f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 329, false);
+ if (Actor_Clue_Query(0, 125) && Actor_Clue_Query(0, 126) && !Game_Flag_Query(670)) {
+ Actor_Set_Goal_Number(0, 350);
+ Game_Flag_Set(670);
+ } else if (Game_Flag_Query(280)) {
+ Actor_Says(0, 8570, 13);
+ } else {
+ Actor_Voice_Over(770, 99);
+ Actor_Voice_Over(780, 99);
+ Actor_Voice_Over(790, 99);
+ Actor_Voice_Over(800, 99);
+ Game_Flag_Set(280);
+ }
+ }
+ return true;
+ }
+ if (Object_Query_Click("X2_KEYBRD02", objectName) && !Game_Flag_Query(278)) {
+ Loop_Actor_Walk_To_XYZ(0, -655.57f, 136.6f, -1092.64f, 0, 1, false, 0);
+ Actor_Face_Object(0, "X2_KEYBRD02", true);
+ Actor_Voice_Over(830, 99);
+ Actor_Voice_Over(840, 99);
+ Game_Flag_Set(278);
+ return true;
+ }
+ if (Object_Query_Click("X2_TORSO04HIRES", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -700.0f, 136.6f, -1133.0f, 4, 1, false, 0)) {
+ Actor_Face_Object(0, "x2_TORSO04HIRES", true);
+ if (Global_Variable_Query(39) > 12) {
+ return true;
+ }
+ if (Game_Flag_Query(548)) {
+ Overlay_Remove("DR06ovr2");
+ Game_Flag_Reset(548);
+ Sound_Play(161, 100, 0, 0, 50);
+ } else {
+ Overlay_Play("DR06ovr2", 0, 1, 0, 0);
+ Game_Flag_Set(548);
+ Sound_Play(160, 100, 0, 0, 50);
+ if (!Actor_Clue_Query(0, 76)) {
+ Actor_Voice_Over(850, 99);
+ Item_Pickup_Spin_Effect(944, 171, 280);
+ Actor_Voice_Over(860, 99);
+ Actor_Voice_Over(870, 99);
+ Actor_Voice_Over(880, 99);
+ Actor_Clue_Acquire(0, 76, 1, 13);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Increment(2, 200);
+ }
+ }
+ }
+ Global_Variable_Increment(39, 1);
+ if (Global_Variable_Query(39) > 12) {
+ Sound_Play(204, 100, 0, 0, 50);
+ Unclickable_Object("X2_TORSO04HIRES");
+ }
+ }
+ return true;
+ }
+ Actor_Face_Object(0, "X2_MON01D01", true);
+ Actor_Says(0, 8525, 13);
+ return true;
+}
+
+bool ScriptDR06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptDR06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptDR06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -733.0f, 136.6f, -980.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(231);
+ Set_Enter(7, 28);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -707.57f, 136.6f, -1132.64f, 0, 1, false, 0)) {
+ Game_Flag_Set(552);
+ Set_Enter(19, 100);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptDR06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptDR06::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptDR06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptDR06::PlayerWalkedIn() {
+ if (Game_Flag_Query(230)) {
+ Loop_Actor_Walk_To_XYZ(0, -729.57f, 136.6f, -1016.0f, 0, 0, false, 0);
+ }
+ Game_Flag_Reset(230);
+ Game_Flag_Reset(551);
+}
+
+void ScriptDR06::PlayerWalkedOut() {
+ Overlay_Remove("DR06over");
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptDR06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/esper.cpp b/engines/bladerunner/script/esper.cpp
new file mode 100644
index 0000000000..778542f6c9
--- /dev/null
+++ b/engines/bladerunner/script/esper.cpp
@@ -0,0 +1,385 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/esper.h"
+
+#include "bladerunner/bladerunner.h"
+
+namespace BladeRunner {
+
+void ScriptESPER::SCRIPT_ESPER_DLL_Initialize() {
+ int v0 = 0;
+ if (Actor_Clue_Query(0, 12)) {
+ if (!Actor_Clue_Query(0, 28)) {
+ Actor_Says(39, 160, 3);
+ Actor_Says(39, 180, 3);
+ Actor_Clue_Acquire(0, 28, 1, 15);
+ v0 = 1;
+ }
+ ESPER_Add_Photo("RC02_FA.IMG", 0, 0);
+ if (!Actor_Clue_Query(0, 29)) {
+ Actor_Clue_Acquire(0, 29, 1, 15);
+ }
+ ESPER_Add_Photo("RC02_FA.IMG", 1, 1);
+ }
+ if (Actor_Clue_Query(0, 89)) {
+ if (!Actor_Clue_Query(0, 245)) {
+ Actor_Says(39, 160, 3);
+ Actor_Says(39, 170, 3);
+ Actor_Clue_Acquire(0, 245, 1, -1);
+ v0 = 1;
+ }
+ ESPER_Add_Photo("NR060000.IMG", 2, 2);
+ }
+ if (Actor_Clue_Query(0, 88)) {
+ ESPER_Add_Photo("NR070000.IMG", 3, 3);
+ }
+ if (Actor_Clue_Query(0, 246)) {
+ ESPER_Add_Photo("HC01AR11.IMG", 4, 4);
+ }
+ if (Actor_Clue_Query(0, 247)) {
+ ESPER_Add_Photo("HC01AR12.IMG", 5, 5);
+ }
+ if (Actor_Clue_Query(0, 260)) {
+ ESPER_Add_Photo("HC02CB1.IMG", 6, 6);
+ }
+ if (Actor_Clue_Query(0, 257)) {
+ if (!Actor_Clue_Query(0, 78)) {
+ Actor_Says(39, 160, 3);
+ Actor_Says(39, 170, 3);
+ Actor_Clue_Acquire(0, 78, 1, 32);
+ v0 = 1;
+ }
+ ESPER_Add_Photo("HC02CB2.IMG", 7, 7);
+ }
+ if (Actor_Clue_Query(0, 45)) {
+ if (!Actor_Clue_Query(0, 259)) {
+ Actor_Says(39, 160, 3);
+ Actor_Says(39, 170, 3);
+ Actor_Clue_Acquire(0, 259, 1, 17);
+ v0 = 1;
+ }
+ ESPER_Add_Photo("TB060000.IMG", 8, 8);
+ }
+ if (Actor_Clue_Query(0, 86)) {
+ ESPER_Add_Photo("KP06.IMG", 9, 9);
+ }
+ if (v0) {
+ Actor_Says(39, 200, 3);
+ }
+}
+
+void ScriptESPER::SCRIPT_ESPER_DLL_Photo_Selected(int photo) {
+ switch (photo) {
+ case 9:
+ Actor_Says(39, 270, 3);
+ ESPER_Define_Special_Region(22, 1208, 330, 1218, 340, 1050, 160, 1279, 550, 956, 203, 1278, 497, "KP06ESP1");
+ ESPER_Define_Special_Region(23, 854, 371, 858, 375, 790, 320, 940, 560, 722, 220, 1000, 505, "KP06ESP2");
+ ESPER_Define_Special_Region(24, 615, 325, 648, 365, 440, 220, 820, 959, 326, 140, 948, 474, "KP06ESP3");
+ ESPER_Define_Special_Region(25, 373, 417, 382, 426, 310, 370, 480, 560, 228, 323, 493, 509, "KP06ESP4");
+ break;
+ case 8:
+ Actor_Says(39, 230, 3);
+ ESPER_Define_Special_Region(18, 166, 623, 177, 632, 38, 528, 320, 770, 26, 530, 313, 771, "TB06ESP1");
+ ESPER_Define_Special_Region(19, 156, 356, 164, 360, 60, 280, 250, 460, 14, 251, 257, 459, "TB06ESP2");
+ ESPER_Define_Special_Region(20, 395, 158, 410, 185, 270, 70, 760, 640, 125, 0, 560, 307, "TB06ESP3");
+ ESPER_Define_Special_Region(21, 343, 269, 352, 276, 290, 200, 410, 340, 157, 118, 565, 405, "TB06ESP4");
+ break;
+ case 7:
+ Actor_Says(39, 250, 3);
+ ESPER_Define_Special_Region(16, 1171, 457, 1184, 466, 1060, 370, 1279, 730, 910, 300, 1279, 678, "HC02ESP3");
+ ESPER_Define_Special_Region(17, 328, 398, 340, 413, 250, 350, 460, 640, 100, 236, 530, 612, "HC02ESP4");
+ break;
+ case 6:
+ Actor_Says(39, 250, 3);
+ ESPER_Define_Special_Region(14, 879, 221, 882, 225, 640, 0, 1000, 512, 265, 146, 1014, 813, "HC02ESP5");
+ ESPER_Define_Special_Region(15, 660, 550, 678, 572, 560, 480, 850, 910, 265, 146, 1014, 813, "HC02ESP2");
+ break;
+ case 5:
+ Actor_Says(39, 240, 3);
+ ESPER_Define_Special_Region(13, 720, 485, 728, 491, 640, 390, 780, 630, 257, 94, 1013, 804, "HC01ESP3");
+ break;
+ case 4:
+ Actor_Says(39, 240, 3);
+ ESPER_Define_Special_Region(11, 420, 436, 434, 450, 350, 380, 520, 680, 257, 94, 1013, 804, "HC01ESP1");
+ ESPER_Define_Special_Region(12, 407, 489, 410, 509, 370, 450, 500, 560, 257, 94, 1013, 804, "HC01ESP2");
+ break;
+ case 3:
+ Actor_Says(39, 260, 3);
+ ESPER_Define_Special_Region(10, 893, 298, 901, 306, 770, 230, 980, 500, 340, 216, 942, 747, "NR07ESP1");
+ ESPER_Define_Special_Region(9, 479, 381, 482, 385, 430, 320, 520, 470, 265, 200, 815, 720, "NR07ESP2");
+ break;
+ case 2:
+ Actor_Says(39, 260, 3);
+ ESPER_Define_Special_Region(7, 102, 809, 108, 861, 20, 720, 200, 930, 191, 95, 1085, 870, "NR06ESP1");
+ ESPER_Define_Special_Region(8, 661, 437, 664, 443, 530, 320, 720, 600, 330, 200, 945, 750, "NR06ESP2");
+ break;
+ case 1:
+ Actor_Says(39, 220, 3);
+ ESPER_Define_Special_Region(3, 560, 210, 580, 220, 450, 130, 680, 540, 0, 0, 1279, 959, "RC02ESP4");
+ ESPER_Define_Special_Region(4, 584, 482, 595, 493, 460, 400, 660, 540, 0, 0, 1279, 959, "RC02ESP5");
+ ESPER_Define_Special_Region(5, 669, 322, 675, 329, 620, 230, 740, 390, 0, 0, 1279, 959, "RC02ESP6");
+ ESPER_Define_Special_Region(6, 698, 236, 748, 274, 600, 160, 850, 420, 160, 0, 1279, 750, "RC02ESP7");
+ break;
+ case 0:
+ Actor_Says(39, 220, 3);
+ ESPER_Define_Special_Region(0, 490, 511, 496, 517, 400, 440, 580, 580, 380, 260, 900, 710, "RC02ESP1");
+ ESPER_Define_Special_Region(1, 473, 342, 479, 349, 400, 300, 580, 580, 350, 250, 900, 710, "RC02ESP2");
+ ESPER_Define_Special_Region(2, 444, 215, 461, 223, 380, 120, 570, 340, 354, 160, 577, 354, "RC02ESP3");
+ break;
+ default:
+ return;
+ }
+}
+
+bool ScriptESPER::SCRIPT_ESPER_DLL_Special_Region_Selected(int photo, int region) {
+ switch (photo) {
+ case 9:
+ switch (region) {
+ case 22:
+ Actor_Says(0, 8705, 3);
+ if (!Actor_Clue_Query(0, 274)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 274, 1, -1);
+ }
+ break;
+ case 23:
+ Actor_Voice_Over(4240, 99);
+ if (!Actor_Clue_Query(0, 275)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 275, 1, -1);
+ }
+ break;
+ case 24:
+ Actor_Voice_Over(4220, 99);
+ if (!Actor_Clue_Query(0, 276)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 276, 1, -1);
+ }
+ break;
+ case 25:
+ if (!Actor_Clue_Query(0, 277)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 277, 1, -1);
+ }
+ break;
+ }
+ return false;
+ case 8:
+ switch (region) {
+ case 18:
+ Actor_Says(0, 8775, 3);
+ if (!Actor_Clue_Query(0, 263)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 263, 1, -1);
+ }
+ break;
+ case 19:
+ Actor_Voice_Over(4160, 99);
+ if (!Actor_Clue_Query(0, 262)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 262, 1, -1);
+ }
+ break;
+ case 20:
+ Actor_Voice_Over(2140, 99);
+ Actor_Voice_Over(2150, 99);
+ Actor_Voice_Over(2160, 99);
+ if (!Actor_Clue_Query(0, 47)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 47, 1, -1);
+ }
+ break;
+ case 21:
+ Actor_Says(0, 8890, 3);
+ if (!Actor_Clue_Query(0, 261)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 261, 1, -1);
+ }
+ break;
+ }
+ return false;
+ case 7:
+ if (region == 16) {
+ Actor_Voice_Over(4080, 99);
+ if (!Actor_Clue_Query(0, 255)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 255, 1, -1);
+ }
+ } else if (region == 17) {
+ Actor_Voice_Over(4210, 99);
+ if (!Actor_Clue_Query(0, 256)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 256, 1, -1);
+ }
+ }
+ return false;
+ case 6:
+ if (region == 14) {
+ Actor_Says(0, 6975, 3);
+ if (!Actor_Clue_Query(0, 254)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 254, 1, -1);
+ }
+ } else if (region == 15) {
+ Actor_Voice_Over(4220, 99);
+ if (!Actor_Clue_Query(0, 77)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 77, 1, -1);
+ }
+ }
+ return false;
+ case 5:
+ if (region == 13) {
+ Actor_Says(0, 8830, 3);
+ if (!Actor_Clue_Query(0, 253)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 253, 1, -1);
+ }
+ }
+ return false;
+ case 4:
+ if (region == 11) {
+ Actor_Voice_Over(4090, 99);
+ if (!Actor_Clue_Query(0, 251)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 251, 1, -1);
+ }
+ } else if (region == 12) {
+ Actor_Voice_Over(4180, 99);
+ if (!Actor_Clue_Query(0, 252)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 252, 1, -1);
+ }
+ }
+ return false;
+ case 3:
+ if (region == 9) {
+ Actor_Voice_Over(4230, 99);
+ if (!Actor_Clue_Query(0, 249)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 249, 1, -1);
+ }
+ return true;
+ } else if (region == 10) {
+ Actor_Voice_Over(4040, 99);
+ if (!Actor_Clue_Query(0, 250)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 250, 1, -1);
+ }
+ return true;
+ }
+ return false;
+ case 2:
+ if (region == 8) {
+ Actor_Voice_Over(4260, 99);
+ if (!Actor_Clue_Query(0, 248)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 248, 1, -1);
+ }
+ } else if (region == 7) {
+ Actor_Voice_Over(4190, 99);
+ if (!Actor_Clue_Query(0, 258)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 258, 1, -1);
+ }
+ }
+ return true;
+ case 1:
+ if (region == 3) {
+ Actor_Voice_Over(4080, 99);
+ if (!Actor_Clue_Query(0, 243)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 243, 1, -1);
+ }
+ } else if (region == 4) {
+ Actor_Voice_Over(4110, 99);
+ if (!Actor_Clue_Query(0, 244)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 244, 1, -1);
+ }
+ } else if (region == 5) {
+ Actor_Voice_Over(4120, 99);
+ if (!Actor_Clue_Query(0, 31)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 31, 1, -1);
+ }
+ } else if (region == 6) {
+ Actor_Voice_Over(4070, 99);
+ if (!Actor_Clue_Query(0, 30)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 30, 1, -1);
+ }
+ }
+ return true;
+ case 0:
+ if (region == 0) {
+ Actor_Voice_Over(4050, 99);
+ if (!Actor_Clue_Query(0, 14)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 14, 1, -1);
+ }
+ } else if (region == 1) {
+ Actor_Voice_Over(4040, 99);
+ if (!Actor_Clue_Query(0, 13)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 13, 1, -1);
+ }
+ } else if (region == 2) {
+ Actor_Voice_Over(4060, 99);
+ if (!Actor_Clue_Query(0, 9)) {
+ Actor_Says(0, 6945, 3);
+ Sound_Play(417, 50, 0, 0, 50);
+ Actor_Clue_Acquire(0, 9, 1, -1);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/esper.h b/engines/bladerunner/script/esper.h
new file mode 100644
index 0000000000..9532e11b79
--- /dev/null
+++ b/engines/bladerunner/script/esper.h
@@ -0,0 +1,45 @@
+/* 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.
+ *
+ */
+
+#ifndef BLADERUNNER_SCRIPT_ESPER_H
+#define BLADERUNNER_SCRIPT_ESPER_H
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+class BladeRunnerEngine;
+
+class ScriptESPER : ScriptBase {
+public:
+ ScriptESPER(BladeRunnerEngine *vm)
+ : ScriptBase(vm) {
+ }
+
+ void SCRIPT_ESPER_DLL_Initialize();
+ void SCRIPT_ESPER_DLL_Photo_Selected(int photo);
+ bool SCRIPT_ESPER_DLL_Special_Region_Selected(int photo, int region);
+};
+
+} // End of namespace BladeRunner
+
+#endif
diff --git a/engines/bladerunner/script/hc01.cpp b/engines/bladerunner/script/hc01.cpp
new file mode 100644
index 0000000000..aac8b282da
--- /dev/null
+++ b/engines/bladerunner/script/hc01.cpp
@@ -0,0 +1,433 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHC01::InitializeScene() {
+ Music_Play(0, 31, 0, 2, -1, 1, 2);
+ if (Game_Flag_Query(385)) {
+ Setup_Scene_Information(64.0f, 0.14f, 83.0f, 266);
+ } else if (Game_Flag_Query(387)) {
+ Setup_Scene_Information(607.0f, 0.14f, 9.0f, 530);
+ } else {
+ Setup_Scene_Information(780.0f, 0.14f, 153.0f, 815);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ if (Game_Flag_Query(402)) {
+ Scene_Exit_Add_2D_Exit(1, 394, 229, 485, 371, 1);
+ }
+ Scene_Exit_Add_2D_Exit(2, 117, 0, 286, 319, 0);
+ Ambient_Sounds_Add_Looping_Sound(103, 50, 50, 0);
+ Ambient_Sounds_Add_Looping_Sound(241, 50, 50, 0);
+ Ambient_Sounds_Add_Sound(242, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(243, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(244, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(245, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(246, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(247, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(248, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(249, 3, 30, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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);
+ Scene_Loop_Set_Default(0);
+}
+
+void ScriptHC01::SceneLoaded() {
+ Obstacle_Object("PILLAR", true);
+ if (Game_Flag_Query(322)) {
+ Preload(19);
+ Preload(426);
+ Preload(430);
+ Preload(437);
+ Preload(427);
+ Preload(431);
+ Preload(433);
+ Preload(424);
+ Preload(428);
+ Preload(436);
+ Preload(429);
+ Preload(425);
+ Preload(432);
+ }
+}
+
+bool ScriptHC01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHC01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHC01::ClickedOnActor(int actorId) {
+ if (actorId == 7 && (Actor_Query_Goal_Number(7) == 150 || Actor_Query_Goal_Number(7) == 0)) {
+ AI_Movement_Track_Pause(7);
+ if (!Loop_Actor_Walk_To_XYZ(0, 624.43f, 0.14f, 83.0f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(400)) {
+ Actor_Face_Actor(0, 7, true);
+ Actor_Face_Actor(7, 0, true);
+ sub_402384();
+ } else {
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says_With_Pause(7, 10, 0.2f, 13);
+ Actor_Face_Actor(0, 7, true);
+ Actor_Says(7, 20, 17);
+ Actor_Says(0, 1035, 18);
+ Actor_Says_With_Pause(7, 30, 0.2f, 17);
+ Actor_Says_With_Pause(7, 40, 0.0f, 13);
+ Actor_Says(7, 50, 12);
+ Actor_Says_With_Pause(0, 1040, 1.2f, 13);
+ Actor_Says(7, 60, 16);
+ Actor_Says_With_Pause(7, 70, 1.0f, 13);
+ Actor_Says_With_Pause(0, 1045, 0.6f, 14);
+ Actor_Says(7, 80, 18);
+ Game_Flag_Set(400);
+ }
+ }
+ AI_Movement_Track_Unpause(7);
+ }
+ return false;
+}
+
+bool ScriptHC01::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 107) {
+ Item_Remove_From_World(107);
+ Item_Pickup_Spin_Effect(977, 361, 381);
+ Delay(1500);
+ Item_Pickup_Spin_Effect(984, 377, 397);
+ Delay(1500);
+ Item_Pickup_Spin_Effect(984, 330, 384);
+ if (Game_Flag_Query(374)) {
+ Actor_Clue_Acquire(0, 246, 1, 7);
+ } else {
+ Actor_Clue_Acquire(0, 247, 1, 7);
+ }
+ Actor_Clue_Acquire(0, 260, 1, 7);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 814.0f, 0.14f, 153.0f, 0, 1, false, 0)) {
+ Music_Adjust(12, 0, 2);
+ Game_Flag_Set(323);
+ Set_Enter(0, 0);
+ Game_Flag_Reset(479);
+ Game_Flag_Set(180);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 607.0f, 0.14f, 9.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(386);
+ Set_Enter(8, 33);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 105.0f, 0.14f, 103.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(384);
+ Async_Actor_Walk_To_XYZ(0, -57.0f, 0.14f, 83.0f, 0, false);
+ Set_Enter(8, 32);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHC01::SceneFrameAdvanced(int frame) {
+ Set_Fade_Color(1.0f, 1.0f, 1.0f);
+ if (frame >= 61 && frame < 65) {
+ Set_Fade_Density((frame - 61) / 4.0f);
+ } else if (frame >= 65 && frame < 93) {
+ Set_Fade_Density(1.0f);
+ } else if (frame >= 93 && frame < 106) {
+ Set_Fade_Density((105 - frame) / 13.0f);
+ } else {
+ Set_Fade_Density(0.0f);
+ }
+ if (frame == 61) {
+ Ambient_Sounds_Play_Sound(312, 90, 0, 0, 0);
+ }
+ if (frame == 65) {
+ Ambient_Sounds_Play_Sound(315, 50, 0, 100, 0);
+ }
+ if (frame == 80) {
+ Ambient_Sounds_Play_Sound(316, 40, 100, 100, 0);
+ Item_Add_To_World(121, 931, 8, 582.0f, 27.0f, -41.0f, 0, 8, 8, true, true, false, true);
+ }
+}
+
+void ScriptHC01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHC01::PlayerWalkedIn() {
+ if (Game_Flag_Query(385)) {
+ Loop_Actor_Walk_To_XYZ(0, 105.0f, 0.14f, 103.0f, 0, 0, false, 0);
+ Game_Flag_Reset(385);
+ }
+ if (Game_Flag_Query(387)) {
+ Game_Flag_Reset(387);
+ }
+ if (Game_Flag_Query(322)) {
+ Game_Flag_Reset(322);
+ }
+}
+
+void ScriptHC01::PlayerWalkedOut() {
+ Set_Fade_Density(0.0f);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptHC01::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptHC01::sub_402384() {
+ if (!Game_Flag_Query(401)) {
+ Actor_Says(0, 1055, 13);
+ Actor_Says(7, 130, 13);
+ Actor_Says_With_Pause(0, 1060, 0.2f, 13);
+ Actor_Says(7, 140, 13);
+ Game_Flag_Set(401);
+ }
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 56) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1020, 6, 7, 3);
+ } else if (Actor_Clue_Query(0, 44) || Actor_Clue_Query(0, 47) || Actor_Clue_Query(0, 14)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1010, 6, 7, 3);
+ }
+ if (Actor_Clue_Query(0, 58) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1030, 1, 5, 7);
+ } else if (Actor_Clue_Query(0, 5) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1040, 4, 4, 6);
+ }
+ if (Actor_Clue_Query(0, 181) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1050, -1, 3, 8);
+ } else if (Actor_Clue_Query(0, 180) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1060, -1, 3, 8);
+ }
+ if (!Dialogue_Menu_Query_List_Size()) {
+ Actor_Says_With_Pause(0, 1105, 1.2f, 13);
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 50) {
+ Actor_Says(7, 550, 15);
+ } else {
+ Actor_Says(7, 250, 13);
+ Actor_Modify_Friendliness_To_Other(7, 0, -1);
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 47 && !Query_Difficulty_Level()) {
+ sub_40346C();
+ }
+ }
+ return;
+ }
+ Dialogue_Menu_Add_DONE_To_List(100);
+ bool end = false;
+ do {
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 1020) {
+ Dialogue_Menu_Remove_From_List(1020);
+ Actor_Says(0, 1065, 15);
+ Actor_Says(7, 160, 3);
+ Actor_Says(0, 1110, 16);
+ Actor_Says(7, 170, 3);
+ Actor_Says(7, 180, 3);
+ Actor_Says(7, 190, 12);
+ if (Query_Difficulty_Level() < 2) {
+ Actor_Modify_Friendliness_To_Other(7, 0, -2);
+ }
+ }
+ if (answer == 1010) {
+ Dialogue_Menu_Remove_From_List(1010);
+ Actor_Clue_Acquire(0, 60, 0, 7);
+ Actor_Says(0, 1070, 13);
+ Actor_Says(7, 200, 17);
+ Actor_Says(7, 210, 12);
+ Actor_Says(0, 1115, 12);
+ Actor_Says(7, 220, 16);
+ Actor_Says(7, 230, 3);
+ Actor_Says(7, 240, 15);
+ if (Query_Difficulty_Level() < 2) {
+ Actor_Modify_Friendliness_To_Other(7, 0, -1);
+ }
+ }
+ if (answer == 1010 || answer == 1020) {
+ Actor_Says_With_Pause(0, 1120, 0.9f, 17);
+ Actor_Says(7, 250, 13);
+ Actor_Says(0, 1125, 14);
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 47) {
+ Actor_Set_Goal_Number(7, 1);
+ Player_Loses_Control();
+ Actor_Says(7, 90, 3);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says(7, 100, 3);
+ Actor_Says(7, 110, 3);
+ Actor_Says_With_Pause(0, 1050, 0.2f, 3);
+ Actor_Says(7, 120, 3);
+ Actor_Set_Goal_Number(7, 2);
+ }
+ end = true;
+ }
+ if (answer == 1030) {
+ Dialogue_Menu_Remove_From_List(1030);
+ Actor_Says(0, 1075, 18);
+ Actor_Says(7, 260, 12);
+ Actor_Says(7, 270, 16);
+ Actor_Says(0, 1130, 14);
+ Actor_Says(7, 280, 17);
+ Actor_Says(0, 1135, 15);
+ Actor_Says(7, 290, 15);
+ Actor_Says(7, 300, 12);
+ Actor_Says(7, 310, 17);
+ Actor_Says(0, 1140, 3);
+ if (Query_Difficulty_Level() < 2) {
+ Actor_Modify_Friendliness_To_Other(7, 0, -2);
+ }
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 47) {
+ Actor_Set_Goal_Number(7, 1);
+ Player_Loses_Control();
+ Actor_Says(7, 90, 3);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says(7, 100, 3);
+ Actor_Says(7, 110, 3);
+ Actor_Says_With_Pause(0, 1050, 0.2f, 3);
+ Actor_Says(7, 120, 3);
+ Actor_Set_Goal_Number(7, 2);
+ }
+ end = true;
+ }
+ if (answer == 1040) {
+ Dialogue_Menu_Remove_From_List(1040);
+ Actor_Says(0, 1080, 15);
+ Actor_Says(0, 1085, 17);
+ Actor_Says(7, 320, 17);
+ Actor_Says(0, 1145, 13);
+ Actor_Says(7, 330, 17);
+ Actor_Says(7, 340, 13);
+ Actor_Says(7, 350, 12);
+ end = true;
+ }
+ if (answer == 1050) {
+ Dialogue_Menu_Remove_From_List(1050);
+ Actor_Says(0, 1090, 18);
+ Actor_Says(7, 360, 14);
+ Actor_Says(0, 1150, 17);
+ Actor_Says(7, 370, 13);
+ Actor_Says(0, 1155, 15);
+ Actor_Says(7, 380, 12);
+ Actor_Says(0, 1160, 14);
+ Actor_Says(0, 1165, 18);
+ Actor_Says(7, 390, 16);
+ Actor_Says(0, 1170, 12);
+ Actor_Says(7, 400, 13);
+ Actor_Says(0, 1180, 14);
+ Actor_Says(7, 410, 12);
+ Actor_Says(7, 420, 16);
+ Actor_Says(7, 430, 17);
+ Actor_Says(7, 440, 13);
+ Actor_Modify_Friendliness_To_Other(7, 0, -4);
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 47) {
+ Actor_Set_Goal_Number(7, 1);
+ Player_Loses_Control();
+ Actor_Says(7, 90, 3);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says(7, 100, 3);
+ Actor_Says(7, 110, 3);
+ Actor_Says_With_Pause(0, 1050, 0.2f, 3);
+ Actor_Says(7, 120, 3);
+ Actor_Set_Goal_Number(7, 2);
+ }
+ end = true;
+ }
+ if (answer == 1060) {
+ Dialogue_Menu_Remove_From_List(1060);
+ Actor_Says(0, 1095, 15);
+ Actor_Says_With_Pause(0, 1100, 1.2f, 18);
+ Actor_Says(7, 450, 12);
+ Actor_Says(7, 460, 13);
+ Actor_Says(0, 1185, 18);
+ Actor_Says(7, 470, 14);
+ Actor_Says(0, 1190, 14);
+ Actor_Says(7, 480, 13);
+ Actor_Says(0, 1195, 16);
+ Actor_Says(0, 1200, 18);
+ Actor_Says(7, 490, 12);
+ Actor_Says(0, 1205, 14);
+ Actor_Says(7, 500, 14);
+ Actor_Says(7, 510, 17);
+ Actor_Says(7, 520, 16);
+ Actor_Says(7, 530, 15);
+ Actor_Says(0, 1210, 16);
+ Actor_Modify_Friendliness_To_Other(7, 0, -4);
+ if (Actor_Query_Friendliness_To_Other(7, 0) < 47) {
+ Actor_Set_Goal_Number(7, 1);
+ Player_Loses_Control();
+ Actor_Says(7, 90, 3);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says(7, 100, 3);
+ Actor_Says(7, 110, 3);
+ Actor_Says_With_Pause(0, 1050, 0.2f, 3);
+ Actor_Says(7, 120, 3);
+ Actor_Set_Goal_Number(7, 2);
+ }
+ end = true;
+ }
+ if (answer == 100) {
+ end = true;
+ }
+ } while (!end);
+}
+
+void ScriptHC01::sub_40346C() {
+ Actor_Set_Goal_Number(7, 1);
+ Player_Loses_Control();
+ Actor_Says(7, 90, 3);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Says(7, 100, 3);
+ Actor_Says(7, 110, 3);
+ Actor_Says_With_Pause(0, 1050, 0.2f, 3);
+ Actor_Says(7, 120, 3);
+ Actor_Set_Goal_Number(7, 2);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hc02.cpp b/engines/bladerunner/script/hc02.cpp
new file mode 100644
index 0000000000..908b9922c3
--- /dev/null
+++ b/engines/bladerunner/script/hc02.cpp
@@ -0,0 +1,216 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHC02::InitializeScene() {
+ Music_Play(4, 45, -60, 1, -1, 1, 3);
+ if (Game_Flag_Query(109)) {
+ Setup_Scene_Information(-88.0f, 0.14f, -463.0f, 540);
+ } else {
+ Setup_Scene_Information(-57.0f, 0.14f, 83.0f, 746);
+ }
+ Scene_Exit_Add_2D_Exit(0, 589, 255, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 505, 0, 639, 170, 0);
+ Ambient_Sounds_Add_Looping_Sound(103, 50, 50, 0);
+ Ambient_Sounds_Add_Looping_Sound(280, 50, 50, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 33, 33, -60, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 33, 33, -100, 20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 33, 33, -100, 20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 33, 33, -100, 20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 33, 33, -100, 20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Ambient_Sounds_Add_Sound(242, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(243, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(244, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(245, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(246, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(247, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(248, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(249, 3, 30, 14, 14, 30, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(238, 3, 50, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(240, 3, 50, 25, 25, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(384)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(384);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptHC02::SceneLoaded() {
+ Obstacle_Object("BARSTOOL01", true);
+}
+
+bool ScriptHC02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHC02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHC02::ClickedOnActor(int actorId) {
+ if (actorId == 32) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -150.51f, 0.14f, 62.74f, 0, 1, false, 0)) {
+ Actor_Face_Actor(0, 32, true);
+ if (!Game_Flag_Query(404)) {
+ Actor_Says(0, 1225, 13);
+ Actor_Says_With_Pause(32, 0, 0.0f, 13);
+ Actor_Says(32, 10, 16);
+ Actor_Set_Goal_Number(32, 1);
+ Actor_Change_Animation_Mode(0, 23);
+ Delay(1500);
+ Actor_Change_Animation_Mode(0, 75);
+ Delay(1500);
+ Global_Variable_Increment(42, 1);
+ Game_Flag_Set(404);
+ } else if (Actor_Clue_Query(0, 254) && !Actor_Clue_Query(0, 257)) {
+ Actor_Says(0, 4545, 11);
+ Actor_Says(32, 120, 12);
+ Actor_Says(32, 180, 13);
+ Actor_Clue_Acquire(0, 257, 1, 32);
+ Item_Pickup_Spin_Effect(975, 229, 215);
+ } else if (Actor_Clue_Query(0, 122) && !Actor_Clue_Query(0, 131) && Global_Variable_Query(2) > 20 || Query_Difficulty_Level() == 0) {
+ Actor_Clue_Acquire(0, 131, 1, 32);
+ Actor_Says(0, 1230, 13);
+ Actor_Says(32, 20, 12);
+ Actor_Says(0, 1235, 13);
+ Actor_Says(32, 30, 15);
+ Actor_Says(0, 1240, 13);
+ Actor_Says(32, 40, 14);
+ Item_Pickup_Spin_Effect(945, 229, 215);
+ Actor_Set_Goal_Number(32, 2);
+ Actor_Change_Animation_Mode(0, 23);
+ Delay(1500);
+ Actor_Says_With_Pause(32, 50, 1.6f, 17);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 20);
+ }
+ Actor_Says(0, 1245, 13);
+ } else {
+ if (Actor_Clue_Query(0, 75) && !Game_Flag_Query(405)) {
+ Actor_Says(32, 80, 16);
+ Actor_Says(0, 1265, 13);
+ Actor_Says(32, 90, 13);
+ Game_Flag_Set(405);
+ }
+ if (Global_Variable_Query(2) > 5 || Query_Difficulty_Level() == 0) {
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 5);
+ }
+ Global_Variable_Increment(42, 1);
+ Actor_Says(0, 1250, 13);
+ Actor_Says_With_Pause(32, 60, 0.8f, 14);
+ Actor_Says(0, 1255, 13);
+ Actor_Set_Goal_Number(32, 1);
+ Actor_Change_Animation_Mode(0, 23);
+ Delay(1500);
+ Actor_Change_Animation_Mode(0, 75);
+ Delay(1500);
+ } else {
+ Actor_Says_With_Pause(0, 1260, 0.3f, 13);
+ Actor_Says(32, 70, 14);
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHC02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 7.0f, 0.14f, 79.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(385);
+ Set_Enter(8, 31);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -76.0f, 0.14f, -339.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(110);
+ Async_Actor_Walk_To_XYZ(0, -88.0f, 0.14f, -463.0f, 0, false);
+ Set_Enter(8, 106);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHC02::SceneFrameAdvanced(int frame) {
+ if (frame == 70) {
+ Sound_Play(73, 11, 50, -90, 50);
+ }
+ if (frame == 58) {
+ Sound_Play(73, 11, 50, -90, 50);
+ }
+ if (frame == 69 || frame == 77 || frame == 86 || frame == 95 || frame == 104 || frame == 113 || frame == 119) {
+ Sound_Play(60, Random_Query(6, 7), -20, 20, 50);
+ }
+}
+
+void ScriptHC02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHC02::PlayerWalkedIn() {
+ if (Game_Flag_Query(109)) {
+ Loop_Actor_Walk_To_XYZ(0, -76.0f, 0.14f, -339.0f, 0, 0, false, 0);
+ Game_Flag_Reset(109);
+ }
+}
+
+void ScriptHC02::PlayerWalkedOut() {
+}
+
+void ScriptHC02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hc03.cpp b/engines/bladerunner/script/hc03.cpp
new file mode 100644
index 0000000000..58a822c982
--- /dev/null
+++ b/engines/bladerunner/script/hc03.cpp
@@ -0,0 +1,188 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHC03::InitializeScene() {
+ if (Game_Flag_Query(318)) {
+ Setup_Scene_Information(656.0f, 1.61f, -95.0f, 497);
+ Game_Flag_Set(388);
+ Game_Flag_Reset(318);
+ } else {
+ Setup_Scene_Information(607.0f, 0.14f, 13.0f, 57);
+ Game_Flag_Reset(386);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ if (Game_Flag_Query(403) || Global_Variable_Query(1) > 3) {
+ Item_Remove_From_World(121);
+ Game_Flag_Set(403);
+ Scene_Exit_Add_2D_Exit(1, 400, 275, 515, 375, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(103, 50, 50, 0);
+ Ambient_Sounds_Add_Looping_Sound(241, 50, 50, 0);
+ Ambient_Sounds_Add_Sound(242, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(243, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(244, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(245, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(246, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(247, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(248, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(249, 3, 30, 16, 16, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(238, 3, 50, 25, 25, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(240, 3, 50, 33, 33, -100, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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);
+ if (Game_Flag_Query(388)) {
+ Scene_Loop_Set_Default(6);
+ } else if (Game_Flag_Query(403) || Global_Variable_Query(1) > 3) {
+ Scene_Loop_Set_Default(3);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptHC03::SceneLoaded() {
+ Obstacle_Object("GUITAR01", true);
+ if (Game_Flag_Query(403) || Game_Flag_Query(388) || Global_Variable_Query(1) > 3) {
+ Unobstacle_Object("GPscisGate", true);
+ } else {
+ Obstacle_Object("GPscisGate", true);
+ }
+ Unclickable_Object("GUITAR01");
+}
+
+bool ScriptHC03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHC03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHC03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptHC03::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 121) {
+ if (a2) {
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ Game_Flag_Set(403);
+ Item_Remove_From_World(121);
+ Unobstacle_Object("GPscisGate", true);
+ } else {
+ Actor_Says(0, 8522, 12);
+ }
+ return true;
+ }
+ if (itemId == 107) {
+ Item_Remove_From_World(107);
+ Item_Pickup_Spin_Effect(977, 68, 435);
+ Delay(1500);
+ Item_Pickup_Spin_Effect(984, 78, 435);
+ Delay(1500);
+ Item_Pickup_Spin_Effect(984, 58, 435);
+ if (Game_Flag_Query(374)) {
+ Actor_Clue_Acquire(0, 246, 1, 7);
+ } else {
+ Actor_Clue_Acquire(0, 247, 1, 7);
+ }
+ Actor_Clue_Acquire(0, 260, 1, 7);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 607.0f, 0.14f, 9.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(387);
+ Set_Enter(8, 31);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 628.0f, 2.04f, -123.0f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(388)) {
+ Game_Flag_Set(319);
+ Game_Flag_Reset(479);
+ Game_Flag_Set(259);
+ Game_Flag_Set(388);
+ Music_Stop(2);
+ Set_Enter(75, 87);
+ } else {
+ Scene_Loop_Set_Default(6);
+ Scene_Loop_Start_Special(2, 5, 1);
+ Game_Flag_Set(388);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHC03::SceneFrameAdvanced(int frame) {
+ if (frame == 10 || frame == 19 || frame == 29 || frame == 39 || frame == 49 || frame == 59 || frame == 71 || frame == 82 || frame == 91 || frame == 101 || frame == 111 || frame == 121 || frame == 131) {
+ Sound_Play(281, Random_Query(33, 50), 50, 50, 50);
+ }
+ if (!Game_Flag_Query(521) && frame == 66) {
+ Ambient_Sounds_Play_Sound(328, 90, 0, -40, 99);
+ Sound_Play(201, Random_Query(47, 47), 0, -40, 50);
+ Scene_Exit_Add_2D_Exit(1, 400, 275, 515, 375, 2);
+ Game_Flag_Set(521);
+ }
+}
+
+void ScriptHC03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHC03::PlayerWalkedIn() {
+}
+
+void ScriptHC03::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptHC03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hc04.cpp b/engines/bladerunner/script/hc04.cpp
new file mode 100644
index 0000000000..5582a212b5
--- /dev/null
+++ b/engines/bladerunner/script/hc04.cpp
@@ -0,0 +1,242 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHC04::InitializeScene() {
+ if (Game_Flag_Query(108)) {
+ Setup_Scene_Information(-112.0f, 0.14f, -655.0f, 460);
+ Game_Flag_Reset(108);
+ } else {
+ Setup_Scene_Information(-88.0f, 0.14f, -463.0f, 1013);
+ }
+ Music_Play(4, 14, -90, 1, -1, 1, 2);
+ Actor_Put_In_Set(59, 8);
+ Actor_Set_At_XYZ(59, -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);
+ Ambient_Sounds_Add_Looping_Sound(103, 50, 50, 0);
+ Ambient_Sounds_Add_Looping_Sound(329, 16, 16, 0);
+ Ambient_Sounds_Add_Looping_Sound(330, 40, 40, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(195, 5, 70, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 16, 16, -100, -100, -101, -101, 0, 0);
+ if (Game_Flag_Query(110)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(110);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptHC04::SceneLoaded() {
+ Obstacle_Object("CAN FIRE", true);
+ Unobstacle_Object("ASIANMALE01", true);
+ Clickable_Object("CAN FIRE");
+}
+
+bool ScriptHC04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHC04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHC04::ClickedOnActor(int actorId) {
+ if (actorId == 59) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -155.0f, 0.0f, -475.0f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 59, true);
+ Actor_Face_Actor(59, 0, true);
+ if (Game_Flag_Query(106)) {
+ sub_401B90();
+ return true;
+ } else {
+ Actor_Says(59, 0, 3);
+ Actor_Says(0, 1280, 3);
+ Actor_Says(59, 20, 3);
+ Game_Flag_Set(106);
+ return true;
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptHC04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHC04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -108.0f, 0.14f, -639.0f, 0, 1, false, 0)) {
+ Music_Stop(2);
+ Game_Flag_Set(107);
+ Game_Flag_Reset(479);
+ Game_Flag_Set(182);
+ Set_Enter(70, 80);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -72.0f, 0.14f, -399.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(109);
+ Set_Enter(8, 32);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHC04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHC04::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptHC04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHC04::PlayerWalkedIn() {
+}
+
+void ScriptHC04::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptHC04::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptHC04::sub_401B90() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 263) || Actor_Clue_Query(0, 53)) {
+ if (Actor_Clue_Query(0, 47)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(340, 5, 6, 5);
+ } else if (Actor_Clue_Query(0, 259)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(350, 5, 6, 5);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(360, 6, 4, 3);
+ }
+ if (Actor_Clue_Query(0, 87) && !Actor_Clue_Query(0, 101)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(370, 3, 4, 7);
+ }
+ if (Actor_Clue_Query(0, 101)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(380, -1, 5, 8);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(390, 7, 5, -1);
+ Dialogue_Menu_Add_DONE_To_List(400);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 340:
+ Actor_Says(0, 1285, 3);
+ Actor_Says(59, 50, 3);
+ Actor_Says(0, 1330, 3);
+ Actor_Says(59, 60, 3);
+ break;
+ case 350:
+ Actor_Says(0, 1290, 3);
+ Actor_Says(59, 70, 3);
+ Actor_Says(0, 1335, 3);
+ Actor_Says(59, 80, 3);
+ Actor_Says(0, 1340, 3);
+ Actor_Says(59, 90, 3);
+ Actor_Says(0, 1345, 3);
+ break;
+ case 360:
+ Actor_Says(0, 1295, 3);
+ Actor_Says(59, 100, 3);
+ Actor_Says(0, 1350, 3);
+ Actor_Says(59, 110, 3);
+ Actor_Says(0, 1355, 3);
+ Actor_Says(59, 130, 3);
+ Actor_Says(0, 1360, 3);
+ break;
+ case 370:
+ Actor_Says(0, 1300, 3);
+ Actor_Says(59, 140, 3);
+ Actor_Says(0, 1365, 3);
+ Actor_Says(59, 150, 3);
+ break;
+ case 380:
+ Actor_Says(0, 1305, 3);
+ Actor_Modify_Friendliness_To_Other(59, 0, -2);
+ Actor_Says(59, 160, 3);
+ Actor_Says(0, 1370, 3);
+ Actor_Says(59, 170, 3);
+ Actor_Says(0, 1375, 3);
+ Actor_Says(59, 180, 3);
+ Actor_Says(0, 1380, 3);
+ Actor_Says(59, 190, 3);
+ Actor_Says(59, 210, 3);
+ Actor_Says(59, 240, 3);
+ Actor_Says(0, 1385, 3);
+ Actor_Says(59, 260, 3);
+ Actor_Says(0, 1390, 3);
+ Actor_Says(59, 300, 3);
+ Actor_Says(59, 310, 3);
+ Actor_Says(59, 320, 3);
+ Actor_Says(0, 1395, 3);
+ Actor_Says(59, 330, 3);
+ Actor_Clue_Acquire(0, 102, 0, 59);
+ break;
+ case 390:
+ Actor_Says(0, 1310, 3);
+ Actor_Modify_Friendliness_To_Other(59, 0, 2);
+ Actor_Says(59, 340, 3);
+ break;
+ case 400:
+ Actor_Says(0, 1315, 3);
+ break;
+ default:
+ Actor_Says(0, 1320, 3);
+ Actor_Says(59, 30, 3);
+ Actor_Says(0, 1325, 3);
+ Actor_Says(0, 1345, 3);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf01.cpp b/engines/bladerunner/script/hf01.cpp
new file mode 100644
index 0000000000..509f472d74
--- /dev/null
+++ b/engines/bladerunner/script/hf01.cpp
@@ -0,0 +1,475 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF01::InitializeScene() {
+ if (Game_Flag_Query(617)) {
+ Setup_Scene_Information(243.94f, 8.0f, -341.9f, 342);
+ } else if (Game_Flag_Query(313)) {
+ Setup_Scene_Information(-202.0f, 0.0f, -619.0f, 407);
+ } else if (Game_Flag_Query(311)) {
+ Setup_Scene_Information(124.0f, 8.0f, -880.0f, 455);
+ } else if (Game_Flag_Query(309)) {
+ Setup_Scene_Information(406.0f, 8.0f, -813.0f, 455);
+ } else {
+ Setup_Scene_Information(100.0f, 0.0f, -260.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 81, 226, 169, 321, 0);
+ if (!Game_Flag_Query(663)) {
+ Scene_Exit_Add_2D_Exit(1, 304, 239, 492, 339, 0);
+ Scene_Exit_Add_2D_Exit(2, 560, 231, 639, 360, 0);
+ if (Game_Flag_Query(256)) {
+ Scene_Exit_Add_2D_Exit(3, 0, 311, 66, 417, 2);
+ }
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(340, 25, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(81, 60, 100, 1);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Ambient_Sounds_Add_Sound(68, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ 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(256)) {
+ if (!Game_Flag_Query(309) && !Game_Flag_Query(311) && !Game_Flag_Query(313)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ }
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(663)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(5);
+ }
+}
+
+void ScriptHF01::SceneLoaded() {
+ Obstacle_Object("LOFT41", true);
+ if (!Game_Flag_Query(256)) {
+ Unobstacle_Object("OBSTACLE BOX15", true);
+ }
+}
+
+bool ScriptHF01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHF01::ClickedOnActor(int actorId) {
+ int v1;
+ if (Global_Variable_Query(45) == 2) {
+ v1 = 3;
+ } else if (Global_Variable_Query(45) == 3) {
+ v1 = 6;
+ } else {
+ v1 = -1;
+ }
+ if (actorId == 22 || actorId == 31) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 504.04f, 8.0f, -242.17f, 12, 1, false, 0)) {
+ ADQ_Flush();
+ Actor_Face_Actor(0, 31, true);
+ if (Game_Flag_Query(382)) {
+ sub_4026B4();
+ } else {
+ Actor_Says(0, 1455, 15);
+ Actor_Says(31, 40, 13);
+ Actor_Says(0, 1460, 13);
+ Actor_Says(31, 50, 12);
+ Item_Pickup_Spin_Effect(951, 396, 359);
+ Actor_Face_Heading(31, 271, false);
+ Actor_Says(31, 60, 12);
+ Actor_Says(0, 1465, 15);
+ Actor_Face_Actor(31, 0, true);
+ Actor_Says(31, 70, 13);
+ Actor_Says(0, 1470, 14);
+ Actor_Says(22, 30, 3);
+ Actor_Says(31, 80, 15);
+ Actor_Says(22, 50, 3);
+ Actor_Says(31, 110, 14);
+ Game_Flag_Set(382);
+ }
+ return true;
+ }
+ return false;
+ }
+ if (actorId == v1) {
+ if (!Loop_Actor_Walk_To_Actor(0, actorId, 28, 1, false)) {
+ if (Actor_Query_Goal_Number(v1) == 599) {
+ Actor_Says(0, 8630, 13);
+ return true;
+ }
+ if (Global_Variable_Query(1) == 5 && (Actor_Clue_Query(0, 139) || Actor_Clue_Query(0, 141)) && !Game_Flag_Query(165) && Actor_Query_Goal_Number(9) != 2 && Game_Flag_Query(653) && !Game_Flag_Query(662)) {
+ Game_Flag_Set(662);
+ Actor_Face_Actor(0, v1, true);
+ Actor_Face_Actor(v1, 0, true);
+ if (v1 == 3) {
+ sub_4032DC();
+ } else if (v1 == 6) {
+ sub_403484();
+ }
+ Async_Actor_Walk_To_XYZ(v1, -175.0f, 8.0f, -617.0f, 0, false);
+ Loop_Actor_Walk_To_XYZ(0, -137.0f, 8.0f, -577.0f, 0, 0, false, 1);
+ Game_Flag_Set(312);
+ Set_Enter(41, 38);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptHF01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -202.0f, 8.0f, -619.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(312);
+ Set_Enter(41, 38);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 124.0f, 8.0f, -724.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 124.0f, 8.0f, -880.0f, 0, 0, false, 0);
+ Game_Flag_Set(310);
+ Set_Enter(39, 36);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 406.0f, 8.0f, -717.0f, 0, 1, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, 406.0f, 8.0f, -813.0f, 0, 0, false, 0);
+ Game_Flag_Set(308);
+ Set_Enter(38, 35);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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);
+ switch (spinnerDest) {
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(256);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ default:
+ Game_Flag_Set(257);
+ Loop_Actor_Walk_To_XYZ(0, 100.0f, 0.0f, -300.0f, 0, 1, false, 0);
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF01::SceneFrameAdvanced(int frame) {
+ if (frame == 10) {
+ Sound_Play(118, 40, 0, 0, 50);
+ }
+ if (frame == 72 || frame == 193) {
+ Sound_Play(116, 100, -50, -50, 50);
+ }
+ if (frame == 88 || frame == 214) {
+ Sound_Play(119, 100, -50, -50, 50);
+ }
+ if (frame == 242) {
+ Sound_Play(117, 40, -50, 80, 50);
+ }
+ if (Actor_Query_Goal_Number(31) == 1) {
+ Actor_Set_Goal_Number(31, 0);
+ }
+}
+
+void ScriptHF01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHF01::PlayerWalkedIn() {
+ if (Game_Flag_Query(663)) {
+ ADQ_Flush();
+ ADQ_Add(24, 280, 3);
+ Actor_Put_In_Set(23, 37);
+ Actor_Set_At_XYZ(23, 8.2f, 8.0f, -346.67f, 1021);
+ Actor_Put_In_Set(24, 37);
+ Actor_Set_At_XYZ(24, 51.21f, 8.0f, -540.78f, 796);
+ Non_Player_Actor_Combat_Mode_On(23, 3, 1, 0, 4, 4, 7, 8, 0, 0, 0, 100, 300, 0);
+ Non_Player_Actor_Combat_Mode_On(24, 3, 1, 0, 4, 4, 7, 8, 0, 0, 0, 100, 300, 0);
+ }
+ if (!Game_Flag_Query(165) && Actor_Query_Goal_Number(9) != 2) {
+ if (Actor_Clue_Query(0, 141) && Global_Variable_Query(45) == 3 && Actor_Query_Goal_Number(6) != 599) {
+ Actor_Put_In_Set(6, 37);
+ Actor_Set_At_XYZ(6, -5.0f, 8.0f, -622.0f, 419);
+ Actor_Set_Targetable(6, true);
+ } else if (Actor_Clue_Query(0, 139) && Global_Variable_Query(45) == 2 && Actor_Query_Goal_Number(3) != 599) {
+ Actor_Put_In_Set(3, 37);
+ Actor_Set_At_XYZ(3, -5.0f, 8.0f, -622.0f, 419);
+ Actor_Set_Targetable(3, true);
+ }
+ }
+ if (Game_Flag_Query(617)) {
+ Actor_Set_Goal_Number(1, 280);
+ Game_Flag_Reset(617);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(652)) {
+ Game_Flag_Reset(652);
+ Actor_Voice_Over(950, 99);
+ Actor_Voice_Over(960, 99);
+ Actor_Voice_Over(970, 99);
+ Actor_Voice_Over(980, 99);
+ } else if (!Game_Flag_Query(377) && Global_Variable_Query(1) < 4) {
+ ADQ_Flush();
+ ADQ_Add(31, 0, 14);
+ ADQ_Add(31, 10, 3);
+ ADQ_Add(22, 0, 3);
+ Actor_Face_Actor(31, 22, true);
+ ADQ_Add(31, 20, 13);
+ ADQ_Add(22, 10, 3);
+ ADQ_Add(31, 30, 3);
+ ADQ_Add(22, 20, 3);
+ Actor_Face_Heading(31, 271, false);
+ Game_Flag_Set(377);
+ }
+ if (Game_Flag_Query(311)) {
+ Loop_Actor_Walk_To_XYZ(0, 124.0f, 8.0f, -724.0f, 0, 1, false, 0);
+ } else if (Game_Flag_Query(309)) {
+ Loop_Actor_Walk_To_XYZ(0, 406.0f, 8.0f, -717.0f, 0, 1, false, 0);
+ } else if (!Game_Flag_Query(313)) {
+ Loop_Actor_Walk_To_XYZ(0, 100.0f, 0.0f, -300.0f, 0, 1, false, 0);
+ }
+ Game_Flag_Reset(311);
+ Game_Flag_Reset(309);
+ Game_Flag_Reset(313);
+ //return false;
+}
+
+void ScriptHF01::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)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(35, 1, -1);
+ Outtake_Play(38, 1, -1);
+ }
+ Game_Flag_Reset(722);
+ if (Actor_Query_Goal_Number(6) == 450) {
+ Actor_Put_In_Set(6, 97);
+ Actor_Set_At_Waypoint(6, 39, 0);
+ Actor_Set_Goal_Number(6, 599);
+ }
+ if (Actor_Query_Goal_Number(3) == 450) {
+ Actor_Put_In_Set(3, 97);
+ Actor_Set_At_Waypoint(3, 39, 0);
+ Actor_Set_Goal_Number(3, 599);
+ }
+}
+
+void ScriptHF01::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptHF01::sub_4026B4() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 13) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(440, 8, 6, 3);
+ }
+ if (!Actor_Clue_Query(0, 13) && Actor_Clue_Query(0, 22) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(450, 7, 6, 3);
+ }
+ if (Actor_Clue_Query(0, 87) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(460, 3, 5, 6);
+ }
+ if (Actor_Clue_Query(0, 118) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(470, -1, 3, 8);
+ }
+ Dialogue_Menu_Add_DONE_To_List(480);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 440:
+ Actor_Says(0, 1480, 15);
+ Actor_Says(22, 70, 3);
+ Actor_Says(31, 120, 3);
+ Actor_Says(0, 1505, 14);
+ Actor_Says(22, 80, 3);
+ Actor_Says(31, 130, 3);
+ Actor_Says(22, 90, 3);
+ Actor_Says(0, 1510, 12);
+ break;
+ case 450:
+ Actor_Says(0, 1485, 16);
+ Actor_Says(22, 100, 3);
+ Actor_Says(31, 140, 12);
+ Actor_Says(22, 110, 3);
+ Actor_Says(22, 120, 3);
+ Actor_Says(31, 150, 14);
+ break;
+ case 460:
+ Actor_Says(0, 1490, 13);
+ Actor_Says(31, 160, 15);
+ Actor_Says(22, 130, 13);
+ Actor_Says(31, 170, 12);
+ Actor_Says(31, 180, 13);
+ Actor_Says(31, 190, 14);
+ Actor_Says(0, 1515, 15);
+ Actor_Says(31, 200, 3);
+ Actor_Says(0, 1520, 15);
+ Actor_Says(31, 210, 13);
+ Actor_Says(31, 220, 13);
+ Actor_Says(22, 140, 12);
+ Actor_Says(31, 230, 13);
+ Actor_Clue_Acquire(0, 101, 0, 31);
+ break;
+ case 470:
+ Actor_Says(0, 1495, 14);
+ Actor_Face_Actor(31, 0, true);
+ Actor_Says(31, 240, 13);
+ Actor_Face_Actor(31, 22, true);
+ break;
+ case 480:
+ Actor_Says(0, 1500, 16);
+ break;
+ }
+}
+
+void ScriptHF01::sub_4032DC() {
+ Actor_Says(3, 0, 3);
+ Actor_Says(0, 1400, 3);
+ Actor_Says(3, 10, 3);
+ Actor_Says(0, 1405, 3);
+ Actor_Says(3, 20, 3);
+ Actor_Says(0, 1410, 3);
+ Actor_Says(3, 30, 3);
+ Actor_Says(0, 1415, 3);
+ Actor_Says(3, 40, 3);
+ Actor_Says(3, 50, 3);
+ Actor_Says(3, 60, 3);
+ Actor_Says(3, 70, 3);
+ Actor_Says(0, 1420, 3);
+ Actor_Says(3, 80, 3);
+}
+
+void ScriptHF01::sub_403484() {
+ Actor_Says(6, 0, 3);
+ Actor_Says(0, 1425, 3);
+ Actor_Says(6, 10, 3);
+ Actor_Says(6, 20, 3);
+ Actor_Says(0, 1430, 3);
+ Actor_Says(6, 30, 3);
+ Actor_Says(0, 1435, 3);
+ Actor_Says(6, 40, 3);
+ Actor_Says(6, 50, 3);
+ Actor_Says(0, 1440, 3);
+ Actor_Says(6, 60, 3);
+ Actor_Says(6, 70, 3);
+ Actor_Says(0, 1445, 3);
+ Actor_Says(6, 80, 3);
+ Actor_Says(6, 3030, 3);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf02.cpp b/engines/bladerunner/script/hf02.cpp
new file mode 100644
index 0000000000..8c6e24dad4
--- /dev/null
+++ b/engines/bladerunner/script/hf02.cpp
@@ -0,0 +1,145 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF02::InitializeScene() {
+ if (Game_Flag_Query(567)) {
+ Setup_Scene_Information(874.0f, 47.76f, -252.0f, 775);
+ Game_Flag_Reset(567);
+ } else if (Game_Flag_Query(528)) {
+ Setup_Scene_Information(470.0f, 47.76f, -500.0f, 560);
+ } else {
+ Setup_Scene_Information(-18.0f, 47.76f, -288.0f, 275);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 207, 66, 272, 207, 3);
+ Ambient_Sounds_Add_Looping_Sound(340, 28, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(341, 33, 0, 1);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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);
+}
+
+void ScriptHF02::SceneLoaded() {
+ Obstacle_Object("BARD_NEON", true);
+ Unclickable_Object("BARD_NEON");
+ if (Actor_Query_Goal_Number(1) == 234) {
+ if (Game_Flag_Query(593)) {
+ Actor_Set_Goal_Number(1, 243);
+ } else {
+ Actor_Set_Goal_Number(1, 240);
+ }
+ }
+}
+
+bool ScriptHF02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF02::ClickedOn3DObject(const char *objectName, bool a2) {
+ Sound_Play(342, 47, -80, 0, 50);
+ return false;
+}
+
+bool ScriptHF02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptHF02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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, 34);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 470.0f, 47.76f, -444.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(527);
+ Set_Enter(39, 36);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF02::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptHF02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHF02::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(1) == 240) {
+ Actor_Set_Goal_Number(1, 241);
+ }
+ if (Game_Flag_Query(528)) {
+ Loop_Actor_Walk_To_XYZ(0, 470.0f, 47.76f, -444.0f, 0, 0, false, 0);
+ Game_Flag_Reset(528);
+ } else if (Game_Flag_Query(308)) {
+ Loop_Actor_Walk_To_XYZ(0, 42.0f, 47.76f, -296.0f, 0, 0, false, 0);
+ Game_Flag_Reset(308);
+ }
+ if (Actor_Query_Goal_Number(1) == 243) {
+ if (Actor_Query_Goal_Number(6) == 599) {
+ Actor_Set_Goal_Number(1, 244);
+ } else {
+ Actor_Set_Goal_Number(1, 245);
+ }
+ }
+}
+
+void ScriptHF02::PlayerWalkedOut() {
+
+}
+
+void ScriptHF02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf03.cpp b/engines/bladerunner/script/hf03.cpp
new file mode 100644
index 0000000000..f146b08752
--- /dev/null
+++ b/engines/bladerunner/script/hf03.cpp
@@ -0,0 +1,254 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF03::InitializeScene() {
+ if (Game_Flag_Query(527)) {
+ Setup_Scene_Information(479.0f, 47.76f, -496.0f, 600);
+ } else {
+ Setup_Scene_Information(185.62f, 47.76f, -867.42f, 300);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(2, 323, 110, 380, 166, 0);
+ Ambient_Sounds_Add_Looping_Sound(340, 50, 0, 1);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+}
+
+void ScriptHF03::SceneLoaded() {
+ Obstacle_Object("MAIN", true);
+ Unclickable_Object("MAIN");
+}
+
+bool ScriptHF03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF03::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click(objectName, "MAIN")) {
+ Actor_Says(0, Random_Query(0, 3) + 8525, 18);
+ }
+ return false;
+}
+
+void ScriptHF03::sub_401C80() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(840, -1, 3, 8);
+ DM_Add_To_List_Never_Repeat_Once_Selected(850, 6, 5, 2);
+ DM_Add_To_List_Never_Repeat_Once_Selected(860, 8, -1, -1);
+ DM_Add_To_List_Never_Repeat_Once_Selected(870, 2, 8, 6);
+ Dialogue_Menu_Add_DONE_To_List(880);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 840:
+ Actor_Says(0, 1630, 15);
+ if (Global_Variable_Query(40) == 3) {
+ Actor_Set_Goal_Number(6, 214);
+ } else if (Game_Flag_Query(46)) {
+ Actor_Set_Goal_Number(6, 212);
+ } else {
+ Actor_Set_Goal_Number(6, 210);
+ Game_Flag_Set(593);
+ }
+ break;
+ case 850:
+ Actor_Says(0, 1635, 15);
+ Actor_Says(6, 200, 13);
+ Actor_Modify_Friendliness_To_Other(6, 0, 3);
+ break;
+ case 860:
+ Actor_Says(0, 1640, 12);
+ if (Global_Variable_Query(40) == 3) {
+ Actor_Set_Goal_Number(6, 214);
+ } else {
+ Actor_Says(6, 210, 13);
+ Actor_Says(0, 1655, 15);
+ Actor_Modify_Friendliness_To_Other(6, 0, Random_Query(9, 10));
+ if (Actor_Query_Friendliness_To_Other(6, 0) > 59 && !Global_Variable_Query(45)) {
+ Global_Variable_Set(45, 3);
+ Actor_Says(6, 940, 14);
+ Actor_Says(0, 6780, 11);
+ Actor_Says(6, 950, 12);
+ Actor_Says(6, 960, 13);
+ Actor_Says(0, 6785, 15);
+ Actor_Says(6, 970, 16);
+ Actor_Says(6, 980, 17);
+ if (Game_Flag_Query(47)) {
+ Actor_Says(6, 990, 17);
+ }
+ Actor_Says(0, 6790, 15);
+ Actor_Says(6, 1000, 13);
+ Actor_Says(6, 1010, 17);
+ Actor_Says(6, 1020, 18);
+ Actor_Says(0, 6795, 14);
+ Actor_Says(6, 1030, 17);
+ Actor_Says(0, 6800, 14);
+ }
+ Actor_Says(6, 220, 13);
+ Actor_Says(0, 1660, 15);
+ Actor_Says(6, 230, 14);
+ Actor_Clue_Acquire(6, 219, 1, 0);
+ if (Game_Flag_Query(46)) {
+ Actor_Set_Goal_Number(6, 212);
+ } else {
+ Actor_Set_Goal_Number(6, 210);
+ }
+ }
+ break;
+ case 870:
+ Actor_Says(0, 1645, 18);
+ Actor_Says(6, 240, 14);
+ Actor_Says(6, 250, 12);
+ Actor_Says(6, 260, 13);
+ Actor_Says(6, 270, 19);
+ Actor_Says(0, 1665, 18);
+ Actor_Says(6, 280, 13);
+ Actor_Says(0, 1670, 12);
+ Actor_Says(6, 290, 14);
+ Actor_Says(6, 300, 16);
+ Actor_Says(0, 1675, 12);
+ Actor_Says(6, 310, 13);
+ Actor_Clue_Acquire(0, 273, 0, 6);
+ break;
+ case 880:
+ Actor_Says(0, 1650, 14);
+ break;
+ }
+}
+
+bool ScriptHF03::ClickedOnActor(int actorId) {
+ if (actorId == 6 && Actor_Query_Goal_Number(6) == 205) {
+ if (Game_Flag_Query(46) ? !Loop_Actor_Walk_To_Waypoint(0, 377, 0, 1, false) : !Loop_Actor_Walk_To_Waypoint(0, 378, 0, 1, false)) {
+ Actor_Face_Actor(0, 6, true);
+ if (!Game_Flag_Query(613)) {
+ Game_Flag_Set(613);
+ if (Game_Flag_Query(46)) {
+ Actor_Says(0, 1605, 15);
+ Actor_Says(6, 100, 12);
+ Actor_Says(0, 1610, 14);
+ } else {
+ Actor_Says(0, 1615, 16);
+ Actor_Says(6, 110, 13);
+ }
+ Actor_Says(6, 120, 13);
+ Actor_Says(0, 1620, 14);
+ Actor_Says(6, 130, 17);
+ Actor_Says(0, 1625, 15);
+ if (Game_Flag_Query(46)) {
+ Actor_Says(6, 140, 12);
+ Actor_Says(6, 150, 13);
+ Actor_Says(6, 160, 15);
+ } else {
+ Actor_Says(6, 170, 12);
+ Actor_Says(6, 180, 13);
+ Actor_Says(6, 190, 15);
+ }
+ }
+ sub_401C80();
+ }
+ }
+ return false;
+}
+
+bool ScriptHF03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 179.0f, 46.76f, -824.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(311);
+ Set_Enter(37, 34);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 479.0f, 47.76f, -524.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(528);
+ Set_Enter(38, 35);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 942.0f, 47.76f, -847.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(566);
+ Set_Enter(40, 37);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF03::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptHF03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHF03::PlayerWalkedIn() {
+ if (Game_Flag_Query(527)) {
+ Loop_Actor_Walk_To_XYZ(0, 479.0f, 47.76f, -524.0f, 0, 0, false, 0);
+ Game_Flag_Reset(527);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 179.0f, 47.76f, -824.0f, 0, 0, false, 0);
+ Game_Flag_Reset(310);
+ }
+ if (Actor_Query_Goal_Number(6) == 250) {
+ Actor_Set_Goal_Number(6, 212);
+ Actor_Says(1, 210, 13);
+ Actor_Face_Actor(0, 1, true);
+ Actor_Says(0, 1680, 15);
+ Actor_Says(1, 220, 14);
+ Actor_Says(0, 1685, 13);
+ Actor_Says(1, 230, 16);
+ Actor_Says(0, 1690, 12);
+ Actor_Says(1, 240, 13);
+ Actor_Set_Goal_Number(1, 234);
+ }
+}
+
+void ScriptHF03::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptHF03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf04.cpp b/engines/bladerunner/script/hf04.cpp
new file mode 100644
index 0000000000..afeda9fdc3
--- /dev/null
+++ b/engines/bladerunner/script/hf04.cpp
@@ -0,0 +1,167 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF04::InitializeScene() {
+ Setup_Scene_Information(-33.85f, -0.31f, 395.0f, 0);
+ Game_Flag_Reset(566);
+ Scene_Exit_Add_2D_Exit(0, 602, 104, 639, 177, 1);
+ Ambient_Sounds_Add_Looping_Sound(70, 35, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(109, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(72, 6, 70, 14, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 3, 70, 14, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 70, 14, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 70, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 70, 33, 50, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 70, 33, 50, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(584)) {
+ Scene_Loop_Set_Default(3);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptHF04::SceneLoaded() {
+ if (Game_Flag_Query(584)) {
+ Unobstacle_Object("PIVOT_WALL#1", true);
+ Unobstacle_Object("PIVOT_WALL#02", true);
+ Unobstacle_Object("PIVOT_WALL#03", true);
+ } else {
+ Unobstacle_Object("HIDE_WALL_A", true);
+ Unobstacle_Object("HIDE_WALL_B", true);
+ }
+ if (Actor_Query_Goal_Number(6) == 213) {
+ if (Actor_Clue_Query(6, 219) && Global_Variable_Query(40) != 3) {
+ Game_Flag_Set(593);
+ } else {
+ Actor_Set_Goal_Number(6, 230);
+ Game_Flag_Reset(584);
+ }
+ }
+}
+
+bool ScriptHF04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHF04::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptHF04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1132.27f, -0.31f, -113.46f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(567);
+ Set_Enter(38, 35);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF04::SceneFrameAdvanced(int frame) {
+ if (frame == 62) {
+ Sound_Play(359, Random_Query(43, 43), 0, 0, 50);
+ }
+ if (frame == 154) {
+ Sound_Play(360, Random_Query(43, 43), 0, 0, 50);
+ }
+ if (frame == 179 && Actor_Query_Goal_Number(6) == 235) {
+ Actor_Set_Goal_Number(6, 236);
+ }
+ if (Game_Flag_Query(585)) {
+ Game_Flag_Reset(585);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(586)) {
+ Game_Flag_Reset(586);
+ Scene_Loop_Set_Default(0);
+ Scene_Loop_Start_Special(2, 5, 1);
+ //return true;
+ return;
+ }
+ if (frame == 89) {
+ Game_Flag_Set(584);
+ Obstacle_Object("HIDE_WALL_A", false);
+ Obstacle_Object("HIDE_WALL_B", false);
+ Unobstacle_Object("PIVOT_WALL#1", false);
+ Unobstacle_Object("PIVOT_WALL#02", false);
+ Unobstacle_Object("PIVOT_WALL#03", true);
+ //return true;
+ return;
+ }
+ if (frame == 180) {
+ Unobstacle_Object("HIDE_WALL_A", false);
+ Unobstacle_Object("HIDE_WALL_B", false);
+ Obstacle_Object("PIVOT_WALL#1", false);
+ Obstacle_Object("PIVOT_WALL#02", false);
+ Obstacle_Object("PIVOT_WALL#03", true);
+ Game_Flag_Reset(584);
+ if (Actor_Query_Goal_Number(6) == 234) {
+ Actor_Set_Goal_Number(6, 235);
+ }
+ //return true;
+ return;
+ }
+ //return false;
+}
+
+void ScriptHF04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHF04::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(6) == 230 || Actor_Query_Goal_Number(6) == 233) {
+ Player_Set_Combat_Mode(true);
+ Music_Play(1, 60, 0, 2, -1, 0, 0);
+ }
+ Loop_Actor_Walk_To_XYZ(0, -45.0f, -0.31f, 307.0f, 0, 0, true, 0);
+ Delay(2500);
+}
+
+void ScriptHF04::PlayerWalkedOut() {
+ Music_Stop(5);
+}
+
+void ScriptHF04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf05.cpp b/engines/bladerunner/script/hf05.cpp
new file mode 100644
index 0000000000..94cfadb65d
--- /dev/null
+++ b/engines/bladerunner/script/hf05.cpp
@@ -0,0 +1,673 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF05::InitializeScene() {
+ if (Game_Flag_Query(530)) {
+ Setup_Scene_Information(257.0f, 40.63f, 402.0f, 1000);
+ } else if (Game_Flag_Query(358)) {
+ Setup_Scene_Information(330.0f, 40.63f, -107.0f, 603);
+ } else {
+ Setup_Scene_Information(483.0f, 40.63f, -189.0f, 600);
+ }
+ Scene_Exit_Add_2D_Exit(0, 443, 270, 515, 350, 0);
+ if (Global_Variable_Query(1) > 3) {
+ Scene_Exit_Add_2D_Exit(1, 367, 298, 399, 349, 2);
+ }
+ Scene_Exit_Add_2D_Exit(2, 589, 0, 639, 479, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 40, 1, 1);
+ if (Game_Flag_Query(369)) {
+ Scene_Loop_Set_Default(5);
+ sub_404474();
+ } else if (Game_Flag_Query(559)) {
+ Scene_Loop_Set_Default(2);
+ sub_404474();
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptHF05::SceneLoaded() {
+ Obstacle_Object("MAINBASE", true);
+ Unobstacle_Object("BTIRES02", true);
+ Unobstacle_Object("LFTIRE02", true);
+ if (Game_Flag_Query(369)) {
+ Unobstacle_Object("MONTE CARLO DRY", true);
+ } else {
+ Unobstacle_Object("OBSTACLE_HOLE", true);
+ }
+ Clickable_Object("TOP CON");
+}
+
+bool ScriptHF05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF05::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("TOP CON", objectName) == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 95.0f, 40.63f, 308.0f, 0, 1, false, 0)) {
+ Actor_Face_Object(0, "TOP CON", true);
+ if (Actor_Query_In_Set(9, 41) && Actor_Query_Goal_Number(9) != 1 && Actor_Query_Goal_Number(9) != 2) {
+ Actor_Face_Actor(9, 0, true);
+ Actor_Says(9, 480, 13);
+ } else if (!Game_Flag_Query(662) || Game_Flag_Query(369)) {
+ Actor_Change_Animation_Mode(0, 23);
+ Sound_Play(412, 100, 0, 0, 50);
+ } else {
+ Player_Loses_Control();
+ Actor_Set_Goal_Number(23, 425);
+ Game_Flag_Set(369);
+ Game_Flag_Set(368);
+ Obstacle_Object("OBSTACLE_HOLE", true);
+ Unobstacle_Object("MONTE CARLO DRY", true);
+ if (sub_4048C0()) {
+ Loop_Actor_Walk_To_XYZ(sub_4048C0(), 181.54f, 40.63f, 388.09f, 0, 0, true, 0);
+ Actor_Face_Actor(0, sub_4048C0(), true);
+ Actor_Face_Actor(sub_4048C0(), 0, true);
+ Actor_Says(0, 1785, 3);
+ Actor_Says(0, 1790, 3);
+ }
+ Actor_Face_Heading(0, 0, false);
+ Actor_Change_Animation_Mode(0, 23);
+ Scene_Loop_Set_Default(5);
+ Scene_Loop_Start_Special(2, 4, 1);
+ if (sub_4048C0()) {
+ if (sub_4048C0() == 3) {
+ Actor_Face_Heading(3, 0, false);
+ Ambient_Sounds_Play_Sound(147, 50, 99, 0, 0);
+ Delay(3000);
+ Actor_Face_Heading(3, 0, false);
+ Actor_Change_Animation_Mode(3, 23);
+ } else {
+ Actor_Face_Heading(6, 0, false);
+ Ambient_Sounds_Play_Sound(147, 50, 99, 0, 0);
+ Delay(3000);
+ Actor_Face_Heading(6, 0, false);
+ Actor_Change_Animation_Mode(6, 13);
+ }
+ Actor_Face_Actor(0, sub_4048C0(), true);
+ Actor_Says(0, 1805, 3);
+ } else {
+ ADQ_Flush();
+ ADQ_Add(99, 940, -1);
+ Ambient_Sounds_Play_Sound(147, 50, 99, 0, 0);
+ Delay(1500);
+ Loop_Actor_Walk_To_XYZ(0, 181.53999f, 40.630001f, 388.09f, 0, 0, true, 0);
+ Actor_Face_Heading(0, 0, false);
+ Actor_Change_Animation_Mode(0, 23);
+ Actor_Clue_Lose(0, 146);
+ }
+ Player_Gains_Control();
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF05::ClickedOnActor(int actorId) {
+ if (actorId == 9) {
+ if (!Loop_Actor_Walk_To_Actor(0, 9, 60, 1, false)) {
+ Actor_Face_Actor(0, 9, true);
+ Actor_Face_Actor(9, 0, true);
+ sub_402AE4();
+ }
+ }
+ return false;
+}
+
+bool ScriptHF05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 483.0f, 40.63f, -189.0f, 0, 1, false, 0) && !Game_Flag_Query(684)) {
+ Game_Flag_Set(313);
+ Set_Enter(37, 34);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 330.0f, 40.63f, -85.0f, 0, 1, false, 0) && !Game_Flag_Query(684)) {
+ int v2 = sub_404858();
+ if (Game_Flag_Query(663) && Game_Flag_Query(368) && v2 != -1) {
+ Actor_Face_Actor(0, v2, true);
+ Actor_Says(0, 1810, 16);
+ }
+ Game_Flag_Set(359);
+ Set_Enter(43, 40);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 277.0f, 40.631f, 410.0f, 0, 1, false, 0) && !Game_Flag_Query(684)) {
+ Game_Flag_Set(529);
+ Set_Enter(42, 39);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF05::SceneFrameAdvanced(int frame) {
+ switch (frame) {
+ case 126:
+ Sound_Play(352, 90, -20, 70, 50);
+ break;
+ case 152:
+ Sound_Play(346, 90, 0, 0, 50);
+ break;
+ case 156:
+ Sound_Play(348, 47, 100, 100, 50);
+ break;
+ case 161:
+ Sound_Play(345, 90, 0, 0, 50);
+ break;
+ case 176:
+ Sound_Play(350, 32, 100, 100, 50);
+ break;
+ case 178:
+ Sound_Play(355, 47, 100, 100, 50);
+ break;
+ case 179:
+ Sound_Play(490, 90, 0, 0, 50);
+ Music_Play(1, 50, 0, 2, -1, 0, 0);
+ break;
+ case 186:
+ Sound_Play(343, 32, 100, 100, 50);
+ break;
+ case 209:
+ Sound_Play(353, 90, 100, -20, 50);
+ break;
+ case 243:
+ Sound_Play(349, 40, -20, -20, 50);
+ break;
+ case 261:
+ Sound_Play(344, 47, -20, -20, 50);
+ break;
+ case 268:
+ Sound_Play(351, 58, -20, -20, 50);
+ break;
+ case 269:
+ Sound_Play(354, 43, -20, -20, 50);
+ break;
+ }
+ //return true;
+}
+
+void ScriptHF05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 23 && newGoal == 430) {
+ Game_Flag_Set(684);
+ sub_4042E4();
+ }
+ //return false;
+}
+
+void ScriptHF05::PlayerWalkedIn() {
+ if (Game_Flag_Query(662)) {
+ int v0 = sub_404858();
+ if (Game_Flag_Query(662) && v0 != -1) {
+ Actor_Put_In_Set(v0, 41);
+ Actor_Force_Stop_Walking(v0);
+ if (Game_Flag_Query(312)) {
+ 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)) {
+ Actor_Set_At_XYZ(v0, 288.0f, 40.63f, 410.0f, 909);
+ } else if (Game_Flag_Query(358)) {
+ Actor_Set_At_XYZ(v0, 298.0f, 40.63f, -107.0f, 512);
+ } else {
+ Actor_Set_At_XYZ(v0, 284.0f, 40.63f, 286.0f, 0);
+ }
+ }
+ if (Game_Flag_Query(684)) {
+ sub_4042E4();
+ } else if (Actor_Clue_Query(0, 265) || Game_Flag_Query(559)) {
+ if (Game_Flag_Query(559) && !Game_Flag_Query(663)) {
+ Game_Flag_Set(663);
+ Music_Play(1, 40, 0, 2, -1, 0, 0);
+ Actor_Says(24, 200, 3);
+ Actor_Says(24, 210, 3);
+ Actor_Set_Goal_Number(23, 420);
+ if (sub_4048C0() == 3) {
+ sub_403F0C();
+ } else if (sub_4048C0() == 6) {
+ sub_40410C();
+ }
+ }
+ } else {
+ sub_403A34(v0);
+ }
+ } else if (Game_Flag_Query(312) == 1) {
+ Loop_Actor_Walk_To_XYZ(0, 399.0f, 40.63f, -85.0f, 0, 0, false, 0);
+ } else if (Game_Flag_Query(358)) {
+ Actor_Set_At_XYZ(0, 346.0f, 4.63f, -151.0f, 603);
+ Loop_Actor_Travel_Stairs(0, 4, 1, 0);
+ }
+ if (Actor_Query_In_Set(9, 41)) {
+ if (Game_Flag_Query(562)) {
+ if (!Game_Flag_Query(563) && Global_Variable_Query(1) == 3) {
+ sub_402970();
+ Game_Flag_Set(563);
+ }
+ } else {
+ sub_402370();
+ Game_Flag_Set(562);
+ }
+ }
+ Game_Flag_Reset(312);
+ Game_Flag_Reset(530);
+ Game_Flag_Reset(358);
+
+ //return false;
+}
+
+void ScriptHF05::PlayerWalkedOut() {
+ if (Actor_Query_Goal_Number(9) == 210) {
+ Actor_Set_Goal_Number(9, 2);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptHF05::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptHF05::sub_402970() {
+ Loop_Actor_Walk_To_Actor(9, 0, 72, 0, false);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Says(9, 370, 3);
+ Actor_Says(0, 1855, 3);
+ Actor_Says(9, 380, 12);
+ Actor_Says(9, 390, 14);
+ Actor_Says(9, 400, 15);
+ Actor_Says(9, 410, 16);
+ Actor_Says(0, 1860, 3);
+ Actor_Says(9, 420, 3);
+ Actor_Says(0, 1865, 3);
+}
+
+void ScriptHF05::sub_402AE4() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 99) == 1 && Global_Variable_Query(1) == 3) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1180, 3, 6, 7);
+ }
+ if (Actor_Clue_Query(0, 116) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1190, 2, 7, 4);
+ }
+ if (Actor_Clue_Query(0, 88) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1200, 5, 5, 3);
+ }
+ if (Actor_Clue_Query(0, 13) == 1 && Actor_Query_Goal_Number(6) != 599) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1210, 4, 6, 2);
+ }
+ if (Actor_Clue_Query(0, 237) == 1 || Actor_Clue_Query(0, 99) == 1 && Global_Variable_Query(1) == 3) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1220, -1, 2, 8);
+ }
+ if (Actor_Clue_Query(0, 113) == 1 || Actor_Clue_Query(0, 115) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1230, 4, 7, -1);
+ }
+ if (!Dialogue_Menu_Query_List_Size()) {
+ Actor_Says(0, 1880, 15);
+ Actor_Says(9, 490, 3);
+ Actor_Says(0, 1885, 3);
+ Actor_Says(9, 500, 16);
+ return;
+ }
+ Dialogue_Menu_Add_DONE_To_List(1240);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 1180:
+ Actor_Says(0, 1890, 23);
+ Actor_Says(9, 510, 3);
+ Actor_Says(0, 1920, 23);
+ Actor_Says(0, 1925, 3);
+ Actor_Says(9, 530, 12);
+ Actor_Says(0, 1930, 18);
+ Actor_Says(9, 540, 14);
+ Actor_Says(0, 1935, 14);
+ Actor_Says(9, 550, 16);
+ Actor_Says(0, 1940, 15);
+ Actor_Says(0, 1945, -1);
+ Actor_Says(9, 560, 15);
+ Actor_Says(9, 570, 16);
+ Actor_Says(0, 1950, 17);
+ sub_403738();
+ break;
+ case 1190:
+ Actor_Says(0, 1895, 0);
+ Actor_Says(9, 620, 3);
+ Actor_Says(9, 630, 12);
+ Actor_Says(0, 2000, 13);
+ Actor_Says(9, 640, 14);
+ Actor_Says(9, 650, 15);
+ Actor_Says(9, 660, 16);
+ Actor_Says(0, 2005, 0);
+ Actor_Says(0, 2010, 3);
+ Actor_Says(9, 670, 3);
+ Actor_Says(9, 680, 12);
+ Actor_Says(9, 690, 14);
+ Actor_Says(0, 2015, 14);
+ Actor_Says(9, 700, 15);
+ Actor_Says(0, 2020, 18);
+ break;
+ case 1200:
+ Actor_Says(0, 1900, 23);
+ Actor_Says(9, 710, 16);
+ Actor_Says(0, 2025, 0);
+ Actor_Says(9, 720, 3);
+ Actor_Says(9, 730, 12);
+ break;
+ case 1210:
+ Actor_Says(0, 1905, 23);
+ Actor_Says(9, 740, 14);
+ Actor_Says(0, 2030, 13);
+ Actor_Says(9, 750, 15);
+ Actor_Says(0, 2035, 18);
+ Actor_Says(9, 760, 16);
+ Actor_Says(9, 770, 3);
+ Actor_Says(0, 2040, 0);
+ break;
+ case 1220:
+ Actor_Says(0, 1910, 3);
+ Actor_Says(9, 780, 12);
+ Actor_Says(0, 2045, 17);
+ Actor_Says(0, 2050, 3);
+ Actor_Says(9, 790, 14);
+ Actor_Says(0, 2055, 19);
+ Actor_Says(0, 2060, -1);
+ Actor_Says(9, 800, 15);
+ Actor_Says(0, 2065, 18);
+ Actor_Says(0, 2070, 14);
+ Actor_Says(9, 810, 16);
+ sub_403738();
+ break;
+ case 1230:
+ Actor_Says(0, 1915, 12);
+ if (Actor_Clue_Query(0, 113)) {
+ Actor_Says(9, 820, 3);
+ Actor_Says(0, 2075, 13);
+ Actor_Says(9, 830, 12);
+ Actor_Says(9, 840, 14);
+ Actor_Says(9, 850, 15);
+ Actor_Says(0, 2080, 3);
+ Actor_Says(9, 860, 16);
+ Actor_Says(9, 870, 3);
+ } else if (Actor_Clue_Query(0, 115)) {
+ Actor_Says(9, 880, 12);
+ Actor_Says(9, 890, 14);
+ Actor_Says(0, 2085, 3);
+ Actor_Says(9, 900, 15);
+ Actor_Says(0, 2090, 19);
+ Actor_Says(9, 910, 16);
+ Actor_Says(0, 2095, 14);
+ Actor_Says(9, 920, 3);
+ Actor_Says(0, 2100, 15);
+ Actor_Says(9, 930, 12);
+ Actor_Says(9, 940, 14);
+ Actor_Says(0, 2105, 3);
+ Actor_Says(9, 950, 15);
+ Actor_Says(0, 2110, 0);
+ Actor_Says(9, 960, 16);
+ }
+ break;
+ }
+}
+
+void ScriptHF05::sub_403738() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(1250, -1, -1, 10);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1260, 10, 5, -1);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 1250) {
+ Actor_Says(0, 1955, 17);
+ Actor_Says(0, 1960, 23);
+ Item_Pickup_Spin_Effect(986, 315, 327);
+ Delay(2000);
+ Actor_Says(0, 1980, 23);
+ Actor_Says(0, 1985, 3);
+ Actor_Says(9, 580, 3);
+ Actor_Says(9, 590, 15);
+ Actor_Says(0, 1990, 17);
+ Actor_Says(9, 600, 16);
+ Actor_Says(0, 1995, 3);
+ Game_Flag_Set(165);
+ Actor_Put_In_Set(9, 67);
+ Actor_Set_At_XYZ(9, -315.15f, 0.0f, 241.06f, 583);
+ Actor_Set_Goal_Number(9, 699);
+ Game_Flag_Set(652);
+ if (Game_Flag_Query(255)) {
+ Set_Enter(54, 54);
+ } else {
+ Game_Flag_Set(313);
+ Set_Enter(37, 34);
+ }
+ } else if (answer == 1260) {
+ Actor_Says(0, 1965, 12);
+ Actor_Says(0, 1970, 3);
+ Actor_Says(0, 1975, 3);
+ Actor_Says(9, 610, 16);
+ }
+}
+
+int ScriptHF05::sub_404858() {
+ if (Global_Variable_Query(45) == 2 && Actor_Query_Goal_Number(3) != 599) {
+ return 3;
+ }
+ if (Global_Variable_Query(45) == 3 && Actor_Query_Goal_Number(6) != 599) {
+ return 6;
+ }
+ return -1;
+}
+
+void ScriptHF05::sub_4042E4() {
+ Actor_Force_Stop_Walking(0);
+ Actor_Put_In_Set(23, 41);
+ Actor_Set_At_XYZ(23, 430.39999f, 40.630001f, -258.17999f, 300);
+ Actor_Put_In_Set(24, 41);
+ Actor_Set_At_XYZ(24, 526.40002f, 37.18f, -138.17999f, 300);
+ ADQ_Flush();
+ ADQ_Add(24, 260, -1);
+ Player_Loses_Control();
+ Non_Player_Actor_Combat_Mode_On(23, 3, 1, 0, 4, 4, 7, 8, 0, 0, 100, 100, 1200, 1);
+ return Non_Player_Actor_Combat_Mode_On(24, 3, 1, 0, 4, 4, 7, 8, 0, 0, 100, 100, 300, 1);
+}
+
+void ScriptHF05::sub_403F0C() {
+ Actor_Face_Actor(0, 3, true);
+ Actor_Face_Actor(3, 0, true);
+ Actor_Says(3, 2660, 12);
+ Actor_Says(0, 8990, 3);
+ Actor_Says(3, 2670, 13);
+ Actor_Says(3, 2680, 17);
+ Actor_Says(0, 8995, 14);
+ Actor_Says(3, 2690, 15);
+ Actor_Says_With_Pause(0, 9000, 1.0f, 16);
+ Actor_Says_With_Pause(0, 9005, 1.0f, 19);
+ Actor_Says(0, 1765, 17);
+ Actor_Says(3, 160, 12);
+ Actor_Says(0, 1770, 15);
+ Actor_Says(0, 1775, 3);
+ Actor_Says(3, 170, 3);
+ Actor_Says_With_Pause(0, 1780, 1.0f, 18);
+}
+
+void ScriptHF05::sub_40410C() {
+ Actor_Face_Actor(0, 6, true);
+ Actor_Face_Actor(6, 0, true);
+ Actor_Says(6, 400, 16);
+ Actor_Says(0, 1750, 14);
+ Actor_Says(6, 410, 12);
+ Actor_Says(6, 420, 14);
+ Actor_Says(0, 1755, 16);
+ Actor_Says(6, 430, 18);
+ Actor_Says_With_Pause(0, 1760, 1.0f, 15);
+ Actor_Says(0, 1765, 17);
+ Actor_Says(6, 440, 3);
+ Actor_Says(0, 1770, 15);
+ Actor_Says(0, 1775, 3);
+ Actor_Says(6, 450, 17);
+ Actor_Says_With_Pause(0, 1780, 1.0f, 18);
+}
+
+void ScriptHF05::sub_403A34(int actorId) {
+ if (actorId != -1 && Actor_Query_In_Set(9, 41)) {
+ Async_Actor_Walk_To_Waypoint(actorId, 437, 36, 0);
+ Loop_Actor_Walk_To_Waypoint(0, 437, 0, 0, false);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Face_Actor(actorId, 9, true);
+ Actor_Says(9, 0, 3);
+ Actor_Says(9, 10, 12);
+ Actor_Says(0, 1715, 19);
+ Actor_Says(0, 1720, -1);
+ Actor_Says(9, 20, 14);
+ Actor_Says(9, 30, 15);
+ Actor_Says(0, 1725, 3);
+ Actor_Says(9, 40, 16);
+ Actor_Says(9, 50, 3);
+ Actor_Says(9, 60, 12);
+ Actor_Says(9, 70, 13);
+ Actor_Says(0, 1730, 3);
+ Loop_Actor_Walk_To_Actor(9, 0, 28, 0, false);
+ Item_Pickup_Spin_Effect(986, 315, 327);
+ Actor_Says(9, 80, 23);
+ Actor_Clue_Acquire(0, 265, 1, 9);
+ Actor_Says(9, 90, 15);
+ Actor_Says(0, 1735, 17);
+ Actor_Says(9, 100, 16);
+ Actor_Says(9, 110, 3);
+ Actor_Face_Actor(actorId, 0, true);
+ if (actorId == 3) {
+ Actor_Says(3, 90, 3);
+ } else {
+ Actor_Says(6, 380, 3);
+ }
+ Actor_Says(0, 1740, 14);
+ Actor_Says(9, 120, 12);
+ Actor_Set_Goal_Number(9, 2);
+ if (actorId == 3) {
+ Actor_Says(3, 100, 3);
+ } else {
+ Actor_Says(6, 390, 3);
+ }
+ Actor_Face_Actor(0, actorId, true);
+ Actor_Says(0, 1745, 3);
+ Async_Actor_Walk_To_XYZ(actorId, 309.0f, 40.63f, 402.0f, 0, false);
+ Loop_Actor_Walk_To_XYZ(0, 277.0f, 40.63f, 410.0f, 0, 0, false, 0);
+ Game_Flag_Set(529);
+ Set_Enter(42, 39);
+ }
+}
+
+void ScriptHF05::sub_402370() {
+ Player_Loses_Control();
+ if (Global_Variable_Query(1) == 3) {
+ ADQ_Flush();
+ ADQ_Add(9, 130, 18);
+ ADQ_Add(9, 140, 18);
+ ADQ_Add(9, 150, 18);
+ ADQ_Add(9, 160, 17);
+ }
+ Loop_Actor_Walk_To_XYZ(0, 307.0f, 40.63f, 184.0f, 0, 0, false, 0);
+ Loop_Actor_Walk_To_Actor(9, 0, 72, 0, false);
+ Ambient_Sounds_Play_Sound(149, 99, 99, 0, 0);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Says(9, 170, 3);
+ Actor_Says(9, 180, 12);
+ Actor_Says(9, 190, 14);
+ Actor_Says(9, 200, 15);
+ Actor_Says(0, 1815, 12);
+ Actor_Says(9, 210, 16);
+ Actor_Says(0, 1820, -1);
+ Actor_Says(9, 220, 3);
+ Actor_Says(9, 230, 12);
+ Actor_Says(9, 240, 14);
+ Actor_Says(0, 1825, 0);
+ Actor_Says(9, 250, 15);
+ Actor_Face_Object(9, "MONTE CARLO DRY", true);
+ Actor_Says(9, 260, 16);
+ Actor_Face_Object(0, "MONTE CARLO DRY", true);
+ Actor_Says(0, 1830, 0);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Says(9, 270, 3);
+ Actor_Says(9, 280, 12);
+ Async_Actor_Walk_To_XYZ(9, 276.0f, 40.63f, 182.0f, 12, false);
+ Loop_Actor_Walk_To_XYZ(0, 335.0f, 40.63f, 131.0f, 12, 0, false, 0);
+ Actor_Face_Object(9, "MONTE CARLO DRY", true);
+ Actor_Face_Object(0, "MONTE CARLO DRY", true);
+ Actor_Says(9, 290, 14);
+ Actor_Says(9, 300, 15);
+ Actor_Says(9, 310, 16);
+ Actor_Says(0, 1835, 12);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Says(9, 320, 3);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Says(9, 330, 12);
+ Actor_Says(0, 1840, 3);
+ Actor_Says(9, 340, 14);
+ Actor_Says(0, 1845, 3);
+ Actor_Says(9, 350, 15);
+ Actor_Says(9, 360, 16);
+ Actor_Says(0, 1850, 3);
+ Player_Gains_Control();
+}
+
+void ScriptHF05::sub_404474() {
+ Ambient_Sounds_Add_Sound(87, 20, 80, 20, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(23, 250, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 330, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 340, 5, 90, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 360, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 380, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 510, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 80, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 160, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 280, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+}
+
+int ScriptHF05::sub_4048C0() {
+ if (Actor_Query_In_Set(3, 41) == 1 && Actor_Query_Goal_Number(3) != 599) {
+ return 3;
+ }
+ if (Actor_Query_In_Set(6, 41) == 1 && Actor_Query_Goal_Number(6) != 599) {
+ return 6;
+ }
+ return 0;
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf06.cpp b/engines/bladerunner/script/hf06.cpp
new file mode 100644
index 0000000000..d9a5b3a2fe
--- /dev/null
+++ b/engines/bladerunner/script/hf06.cpp
@@ -0,0 +1,286 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF06::InitializeScene() {
+ Setup_Scene_Information(150.0f, 349.93f, 502.0f, 229);
+ Game_Flag_Reset(529);
+ Scene_Exit_Add_2D_Exit(0, 195, 197, 271, 237, 2);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(99, 40, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(100, 40, 100, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(559)) {
+ Scene_Loop_Set_Default(3);
+ sub_4023E0();
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptHF06::SceneLoaded() {
+ Unobstacle_Object("BOX22", true);
+ Unobstacle_Object("BOX34", true);
+ Clickable_Object("BOX19");
+ Clickable_Object("BOX21");
+ Clickable_Object("BOX23");
+ Clickable_Object("HOOD BOX");
+ Clickable_Object("BOX28");
+ Clickable_Object("BOX29");
+ Clickable_Object("BOX30");
+}
+
+bool ScriptHF06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF06::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(0, 14.33f, 367.93f, 399.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 486, true);
+ if (Actor_Query_In_Set(3, 42) && Actor_Query_Goal_Number(3) != 599) {
+ Actor_Face_Actor(3, 0, true);
+ Actor_Says(3, 210, 12);
+ Actor_Says(0, 2125, 12);
+ } else if (Actor_Query_In_Set(6, 42) && Actor_Query_Goal_Number(6) != 599) {
+ Actor_Face_Actor(6, 0, true);
+ Actor_Says(6, 490, 18);
+ Actor_Says(0, 2125, 12);
+ } else {
+ Actor_Says(0, 8635, 12);
+ }
+ }
+ return false;
+ }
+ if (Object_Query_Click("BOX19", objectName) || Object_Query_Click("BOX21", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 290.0f, 367.93f, 318.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 85, true);
+ Actor_Says(0, 8522, 0);
+ }
+ return false;
+ }
+ if (Object_Query_Click("BOX13", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 63.0f, 367.93f, 120.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 568, true);
+ Actor_Says(0, 8522, 0);
+ }
+ return false;
+ }
+ return false;
+}
+
+bool ScriptHF06::ClickedOnActor(int actorId) {
+ if (actorId == 6 && Actor_Query_Goal_Number(6) != 599) {
+ Actor_Face_Actor(6, 0, true);
+ Actor_Face_Actor(0, 6, true);
+ if (Game_Flag_Query(559)) {
+ Actor_Says(6, 390, 18);
+ Actor_Says(0, 2115, 17);
+ }
+ } else if (actorId == 3 && Actor_Query_Goal_Number(3) != 599) {
+ Actor_Face_Actor(3, 0, true);
+ Actor_Face_Actor(0, 3, true);
+ if (Game_Flag_Query(559)) {
+ Actor_Says(3, 100, 3);
+ Actor_Says(0, 2115, 17);
+ }
+ }
+ return false;
+}
+
+bool ScriptHF06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 170.0f, 367.93f, 497.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 730, false);
+ Loop_Actor_Travel_Stairs(0, 2, 0, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(530);
+ Set_Enter(41, 38);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptHF06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 1 && oldGoal != 599 && newGoal == 599) {
+ Loop_Actor_Walk_To_Actor(0, 1, 24, 0, false);
+ Actor_Says(1, 250, -1);
+ Actor_Says(0, 2120, 4);
+ Actor_Says(1, 260, -1);
+ Actor_Says(1, 270, -1);
+ int otherActorId = -1;
+ if (Actor_Query_In_Set(3, 42) && Actor_Query_Goal_Number(3) == 599) {
+ otherActorId = 3;
+ } else if (Actor_Query_In_Set(6, 42) && Actor_Query_Goal_Number(6) == 599) {
+ otherActorId = 6;
+ }
+ if (otherActorId != -1) {
+ Music_Play(21, 35, 0, 3, -1, 0, 0);
+ Player_Set_Combat_Mode(false);
+ Delay(1000);
+ Actor_Voice_Over(990, 99);
+ Actor_Voice_Over(1000, 99);
+ Actor_Voice_Over(1010, 99);
+ Loop_Actor_Walk_To_Actor(0, otherActorId, 24, 0, false);
+ Item_Pickup_Spin_Effect(932, 355, 200);
+ Actor_Voice_Over(1020, 99);
+ Actor_Voice_Over(1030, 99);
+ Actor_Voice_Over(1040, 99);
+ Actor_Voice_Over(1050, 99);
+ Actor_Clue_Acquire(0, 146, 1, -1);
+ }
+ if (Actor_Query_In_Set(3, 42)) {
+ Actor_Set_Targetable(3, false);
+ }
+ if (Actor_Query_In_Set(6, 42)) {
+ Actor_Set_Targetable(6, false);
+ }
+ Scene_Exits_Enable();
+ }
+}
+
+void ScriptHF06::PlayerWalkedIn() {
+ if (Game_Flag_Query(662)) {
+ int actor_id;
+ if (Global_Variable_Query(45) == 3 && Actor_Query_Goal_Number(6) != 599) {
+ actor_id = 6;
+ } else {
+ actor_id = Global_Variable_Query(45) == 2 && Actor_Query_Goal_Number(3) != 599 ? 3 : -1;
+ }
+ if (actor_id != -1) {
+ Actor_Put_In_Set(actor_id, 42);
+ if (Game_Flag_Query(559)) {
+ Actor_Set_At_XYZ(actor_id, 173.67f, 367.93f, 446.04001f, 229);
+ Async_Actor_Walk_To_XYZ(actor_id, 173.67f, 367.93f, 394.04001f, 0, false);
+ } else {
+ Actor_Set_At_XYZ(actor_id, 97.67f, 367.93f, 534.04f, 725);
+ Async_Actor_Walk_To_XYZ(actor_id, 24.2f, 367.93f, 537.71f, 0, false);
+ }
+ }
+ }
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 2, 1, 0);
+ Footstep_Sound_Override_Off();
+ if (Game_Flag_Query(662) && !Game_Flag_Query(559)) {
+ sub_401EF4();
+ }
+}
+
+void ScriptHF06::PlayerWalkedOut() {
+ Music_Stop(2);
+}
+
+void ScriptHF06::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptHF06::sub_401EF4() {
+ int actorId;
+
+ if (Actor_Query_In_Set(3, 42)) {
+ actorId = 3;
+ } else {
+ if (!Actor_Query_In_Set(6, 42)) {
+ return;
+ }
+ actorId = 6;
+ }
+ Actor_Set_Targetable(actorId, true);
+ Loop_Actor_Walk_To_XYZ(0, 14.33f, 367.93f, 399.0f, 0, 0, true, 0);
+ Actor_Face_Heading(0, 486, true);
+ sub_4023E0();
+ Actor_Put_In_Set(1, 42);
+ Actor_Set_At_XYZ(1, 92.0f, 367.93f, 19.0f, 0);
+ Actor_Set_Targetable(1, true);
+ Actor_Face_Actor(actorId, 1, true);
+ if (actorId == 3) {
+ Actor_Says(3, 90, 13);
+ } else if (actorId == 6) {
+ Actor_Says(6, 380, 13);
+ }
+ Actor_Says(0, 6230, 0);
+ Actor_Says(1, 280, 58);
+ Actor_Face_Actor(0, 1, true);
+ Player_Set_Combat_Mode(true);
+ Actor_Change_Animation_Mode(0, 5);
+ Actor_Change_Animation_Mode(1, 7);
+ Loop_Actor_Walk_To_XYZ(1, 92.0f, 367.93f, 107.0f, 0, 0, false, 0);
+ Actor_Face_Actor(1, 0, true);
+ Actor_Change_Animation_Mode(1, 4);
+ Actor_Says(1, 290, 58);
+ Actor_Says(0, 2130, -1);
+ Actor_Says(1, 300, 59);
+ Actor_Says(0, 2135, -1);
+ Actor_Says(1, 310, 60);
+ Actor_Says(0, 2140, -1);
+ Actor_Says(1, 320, 59);
+ Actor_Says(0, 2145, -1);
+ Actor_Says(1, 330, 58);
+ Actor_Says(1, 340, 58);
+ Actor_Says(1, 350, 58);
+ Actor_Change_Animation_Mode(1, 4);
+ Game_Flag_Set(644);
+ Actor_Set_Goal_Number(1, 402);
+ Actor_Face_Actor(1, actorId, true);
+ Actor_Change_Animation_Mode(1, 6);
+ Delay(500);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ Sound_Play(562, 50, 0, 0, 50);
+ Game_Flag_Set(559);
+ Scene_Exits_Disable();
+ Non_Player_Actor_Combat_Mode_On(1, 3, 1, actorId, 15, 4, 7, 8, 0, 0, 100, 10, 300, 0);
+}
+
+void ScriptHF06::sub_4023E0() {
+ Ambient_Sounds_Add_Sound(87, 20, 80, 20, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(23, 250, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 330, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 340, 5, 90, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 360, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 380, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 510, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 80, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 160, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 280, 5, 70, 7, 10, -50, 50, -101, -101, 1, 1);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/hf07.cpp b/engines/bladerunner/script/hf07.cpp
new file mode 100644
index 0000000000..aa096004b3
--- /dev/null
+++ b/engines/bladerunner/script/hf07.cpp
@@ -0,0 +1,154 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptHF07::InitializeScene() {
+ if (Game_Flag_Query(361) ) {
+ Setup_Scene_Information(-84.0f, 58.43f, -105.0f, 524);
+ } else {
+ Setup_Scene_Information(298.0f, 58.43f, -71.0f, 700);
+ }
+ Scene_Exit_Add_2D_Exit(0, 289, 136, 344, 305, 0);
+ Scene_Exit_Add_2D_Exit(1, 69, 264, 132, 303, 2);
+ Ambient_Sounds_Add_Looping_Sound(108, 100, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(112, 32, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 5, 40, 20, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 40, 20, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 40, 20, 33, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(368) ) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptHF07::SceneLoaded() {
+ Obstacle_Object("BRIMS02", true);
+ Unobstacle_Object("BOX50", true);
+ Unobstacle_Object("BOX60", true);
+}
+
+bool ScriptHF07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptHF07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptHF07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptHF07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptHF07::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 (!Loop_Actor_Walk_To_XYZ(0, 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);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 30, 1, 0);
+ Footstep_Sound_Override_Off();
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(41, 38);
+ }
+ 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 (!Loop_Actor_Walk_To_XYZ(0, -84.0f, 58.43f, -105.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(360);
+ Set_Enter(78, 90);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptHF07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptHF07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptHF07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptHF07::PlayerWalkedIn() {
+ if (Game_Flag_Query(662)) {
+ int actorId = sub_401864();
+ if (Game_Flag_Query(662) && actorId != -1) {
+ Actor_Put_In_Set(actorId, 43);
+ if (Game_Flag_Query(361)) {
+ Actor_Set_At_XYZ(actorId, -73.0f, 58.43f, -7.0f, 224);
+ } else {
+ Actor_Set_At_XYZ(actorId, 235.0f, 58.43f, -100.0f, 512);
+ }
+ }
+ } else if (Game_Flag_Query(359)) {
+ Actor_Set_At_XYZ(0, 267.72f, 329.43f, -86.75f, 940);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 30, 0, 0);
+ Footstep_Sound_Override_Off();
+ }
+ Game_Flag_Reset(359);
+ Game_Flag_Reset(361);
+}
+
+void ScriptHF07::PlayerWalkedOut() {
+}
+
+void ScriptHF07::DialogueQueueFlushed(int a1) {
+}
+
+int ScriptHF07::sub_401864() {
+ if (Global_Variable_Query(45) == 2 && Actor_Query_Goal_Number(3) != 599) {
+ return 3;
+ }
+ if (Global_Variable_Query(45) == 3 && Actor_Query_Goal_Number(6) != 599) {
+ return 6;
+ }
+ return -1;
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/init.cpp b/engines/bladerunner/script/init.cpp
index 6e797fe81c..64136baed0 100644
--- a/engines/bladerunner/script/init.cpp
+++ b/engines/bladerunner/script/init.cpp
@@ -75,35 +75,38 @@ void ScriptInit::Init_Game_Flags() {
for (int i = 0; i != 730; ++i)
Game_Flag_Reset(i);
- if (Random_Query(1, 2) == 1)
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(44);
- if (Random_Query(1, 2) == 1)
+ }
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(45);
- if (Random_Query(1, 2) == 1)
+ }
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(46);
- if (Random_Query(1, 2) == 1)
+ }
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(47);
- if (Random_Query(1, 2) == 1)
+ }
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(48);
- if (Random_Query(1, 2) == 1)
+ }
+ if (Random_Query(1, 2) == 1) {
Game_Flag_Set(560);
-
- if (!Game_Flag_Query(45) && !Game_Flag_Query(46) && !Game_Flag_Query(47))
+ }
+ if (!Game_Flag_Query(45) && !Game_Flag_Query(46) && !Game_Flag_Query(47)) {
Game_Flag_Set(47);
+ }
if (Game_Flag_Query(47)) {
Global_Variable_Set(40, 1);
- } else if (!Game_Flag_Query(45) || Game_Flag_Query(46)) {
- if (Game_Flag_Query(45) || !Game_Flag_Query(46)) {
- if (Random_Query(1, 2) == 1)
- Global_Variable_Set(40, 2);
- else
- Global_Variable_Set(40, 3);
- } else {
- Global_Variable_Set(40, 3);
- }
- } else {
+ } else if (Game_Flag_Query(45) && !Game_Flag_Query(46)) {
Global_Variable_Set(40, 2);
+ } else if (!Game_Flag_Query(45) && Game_Flag_Query(46)) {
+ Global_Variable_Set(40, 3);
+ } else if (Random_Query(1, 2) == 1) {
+ Global_Variable_Set(40, 2);
+ } else {
+ Global_Variable_Set(40, 3);
}
Game_Flag_Set(182);
@@ -111,8 +114,9 @@ void ScriptInit::Init_Game_Flags() {
}
void ScriptInit::Init_Clues() {
- for(int i = 0; i != 288; ++i)
- Actor_Clue_Add_To_Database(0, i, 0, 0, 0, -1);
+ for (int i = 0; i != 288; ++i) {
+ Actor_Clue_Add_To_Database(0, i, 0, false, false, -1);
+ }
}
struct clue_weigth {
@@ -121,89 +125,91 @@ struct clue_weigth {
};
static clue_weigth clues_actor_1[44] = {
- { 222, 100 }, { 227, 100 }, { 223, 100 }, { 224, 100 }, { 226, 100 }, { 228, 100 }, { 231, 100 }, { 162, 100 },
- { 164, 100 }, { 166, 100 }, { 168, 100 }, { 170, 100 }, { 172, 100 }, { 174, 100 }, { 176, 100 }, { 239, 90 },
- { 241, 90 }, { 242, 90 }, { 179, 90 }, { 180, 90 }, { 181, 90 }, { 8, 85 }, { 240, 85 }, { 216, 85 },
- { 217, 85 }, { 178, 80 }, { 5, 65 }, { 9, 65 }, { 215, 65 }, { 218, 65 }, { 219, 65 }, { 220, 65 },
- { 229, 65 }, { 211, 65 }, { 80, 65 }, { 108, 65 }, { 134, 65 }, { 135, 65 }, { 212, 55 }, { 221, 55 },
- { 230, 55 }, { 6, 30 }, { 7, 30 }, { 65, 30 }
+ {222, 100}, {227, 100}, {223, 100}, {224, 100}, {226, 100}, {228, 100}, {231, 100}, {162, 100},
+ {164, 100}, {166, 100}, {168, 100}, {170, 100}, {172, 100}, {174, 100}, {176, 100}, {239, 90},
+ {241, 90}, {242, 90}, {179, 90}, {180, 90}, {181, 90}, {8, 85}, {240, 85}, {216, 85},
+ {217, 85}, {178, 80}, {5, 65}, {9, 65}, {215, 65}, {218, 65}, {219, 65}, {220, 65},
+ {229, 65}, {211, 65}, {80, 65}, {108, 65}, {134, 65}, {135, 65}, {212, 55}, {221, 55},
+ {230, 55}, {6, 30}, {7, 30}, {65, 30}
};
static clue_weigth clues_actor_2[28] = {
- { 227, 70 }, { 240, 65 }, { 241, 70 }, { 242, 95 }, { 212, 70 }, { 213, 70 }, { 214, 70 }, { 215, 70 },
- { 216, 95 }, { 217, 70 }, { 218, 70 }, { 219, 70 }, { 220, 70 }, { 221, 65 }, { 222, 70 }, { 223, 70 },
- { 224, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 }, { 230, 70 }, { 231, 70 }, { 232, 70 }, { 116, 65 },
- { 117, 65 }, { 145, 70 }, { 207, 55 }, { 211, 65 }
+ {227, 70}, {240, 65}, {241, 70}, {242, 95}, {212, 70}, {213, 70}, {214, 70}, {215, 70},
+ {216, 95}, {217, 70}, {218, 70}, {219, 70}, {220, 70}, {221, 65}, {222, 70}, {223, 70},
+ {224, 70}, {226, 70}, {228, 70}, {229, 70}, {230, 70}, {231, 70}, {232, 70}, {116, 65},
+ {117, 65}, {145, 70}, {207, 55}, {211, 65}
};
static clue_weigth clues_actor_3[46] = {
- { 227, 70 }, { 240, 45 }, { 241, 70 }, { 242, 65 }, { 212, 70 }, { 213, 70 }, { 214, 70 }, { 215, 70 },
- { 216, 65 }, { 217, 70 }, { 220, 70 }, { 219, 70 }, { 218, 70 }, { 221, 45 }, { 222, 70 }, { 223, 70 },
- { 224, 70 }, { 225, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 }, { 230, 70 }, { 231, 70 }, { 95, 70 },
- { 232, 70 }, { 239, 65 }, { 19, 65 }, { 25, 55 }, { 60, 60 }, { 69, 60 }, { 70, 60 }, { 92, 70 },
- { 103, 65 }, { 121, 65 }, { 130, 70 }, { 147, 70 }, { 148, 65 }, { 149, 65 }, { 150, 65 }, { 151, 65 },
- { 152, 65 }, { 116, 65 }, { 117, 65 }, { 145, 70 }, { 207, 55 }, { 211, 65 }
+ {227, 70}, {240, 45}, {241, 70}, {242, 65}, {212, 70}, {213, 70}, {214, 70}, {215, 70},
+ {216, 65}, {217, 70}, {220, 70}, {219, 70}, {218, 70}, {221, 45}, {222, 70}, {223, 70},
+ {224, 70}, {225, 70}, {226, 70}, {228, 70}, {229, 70}, {230, 70}, {231, 70}, {95, 70},
+ {232, 70}, {239, 65}, {19, 65}, {25, 55}, {60, 60}, {69, 60}, {70, 60}, {92, 70},
+ {103, 65}, {121, 65}, {130, 70}, {147, 70}, {148, 65}, {149, 65}, {150, 65}, {151, 65},
+ {152, 65}, {116, 65}, {117, 65}, {145, 70}, {207, 55}, {211, 65}
};
static clue_weigth clues_actor_4[23] = {
- { 241, 90 }, { 242, 90 }, { 240, 70 }, { 214, 75 }, { 216, 75 }, { 218, 75 }, { 219, 75 }, { 220, 75 },
- { 215, 70 }, { 217, 70 }, { 222, 70 }, { 223, 70 }, { 224, 70 }, { 226, 70 }, { 228, 70 }, { 230, 70 },
- { 73, 65 }, { 211, 65 }, { 80, 65 }, { 108, 65 }, { 134, 65 }, { 135, 65 }, { 212, 55 }
+ {241, 90}, {242, 90}, {240, 70}, {214, 75}, {216, 75}, {218, 75}, {219, 75}, {220, 75},
+ {215, 70}, {217, 70}, {222, 70}, {223, 70}, {224, 70}, {226, 70}, {228, 70}, {230, 70},
+ {73, 65}, {211, 65}, {80, 65}, {108, 65}, {134, 65}, {135, 65}, {212, 55}
};
static clue_weigth clues_actor_5[46] = {
- { 227, 70 }, { 241, 70 }, { 212, 70 }, { 213, 70 }, { 214, 70 }, { 215, 70 }, { 217, 70 }, { 220, 70 },
- { 219, 70 }, { 218, 70 }, { 222, 70 }, { 223, 70 }, { 224, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 },
- { 230, 70 }, { 232, 70 }, { 130, 70 }, { 147, 70 }, { 145, 70 }, { 242, 65 }, { 216, 65 }, { 239, 65 },
- { 19, 65 }, { 95, 65 }, { 103, 65 }, { 107, 65 }, { 121, 65 }, { 148, 65 }, { 149, 65 }, { 150, 65 },
- { 151, 65 }, { 152, 65 }, { 116, 65 }, { 117, 65 }, { 211, 65 }, { 60, 60 }, { 69, 60 }, { 70, 60 },
- { 92, 60 }, { 25, 55 }, { 133, 55 }, { 207, 55 }, { 240, 45 }, { 221, 45 }
+ {227, 70}, {241, 70}, {212, 70}, {213, 70}, {214, 70}, {215, 70}, {217, 70}, {220, 70},
+ {219, 70}, {218, 70}, {222, 70}, {223, 70}, {224, 70}, {226, 70}, {228, 70}, {229, 70},
+ {230, 70}, {232, 70}, {130, 70}, {147, 70}, {145, 70}, {242, 65}, {216, 65}, {239, 65},
+ {19, 65}, {95, 65}, {103, 65}, {107, 65}, {121, 65}, {148, 65}, {149, 65}, {150, 65},
+ {151, 65}, {152, 65}, {116, 65}, {117, 65}, {211, 65}, {60, 60}, {69, 60}, {70, 60},
+ {92, 60}, {25, 55}, {133, 55}, {207, 55}, {240, 45}, {221, 45}
};
static clue_weigth clues_actor_6[47] = {
- { 227, 70 }, { 240, 45 }, { 241, 70 }, { 242, 65 }, { 212, 70 }, { 213, 70 }, { 214, 70 }, { 215, 70 },
- { 216, 65 }, { 217, 70 }, { 220, 70 }, { 219, 70 }, { 218, 70 }, { 221, 45 }, { 222, 70 }, { 223, 70 },
- { 224, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 }, { 230, 70 }, { 231, 70 }, { 232, 70 }, { 239, 65 },
- { 19, 65 }, { 25, 55 }, { 60, 60 }, { 69, 60 }, { 70, 60 }, { 92, 60 }, { 95, 65 }, { 103, 65 },
- { 107, 65 }, { 121, 55 }, { 130, 70 }, { 133, 70 }, { 147, 70 }, { 148, 65 }, { 149, 65 }, { 150, 65 },
- { 151, 65 }, { 152, 65 }, { 116, 65 }, { 117, 65 }, { 145, 70 }, { 207, 55 }, { 211, 65 }
+ {227, 70}, {240, 45}, {241, 70}, {242, 65}, {212, 70}, {213, 70}, {214, 70}, {215, 70},
+ {216, 65}, {217, 70}, {220, 70}, {219, 70}, {218, 70}, {221, 45}, {222, 70}, {223, 70},
+ {224, 70}, {226, 70}, {228, 70}, {229, 70}, {230, 70}, {231, 70}, {232, 70}, {239, 65},
+ {19, 65}, {25, 55}, {60, 60}, {69, 60}, {70, 60}, {92, 60}, {95, 65}, {103, 65},
+ {107, 65}, {121, 55}, {130, 70}, {133, 70}, {147, 70}, {148, 65}, {149, 65}, {150, 65},
+ {151, 65}, {152, 65}, {116, 65}, {117, 65}, {145, 70}, {207, 55}, {211, 65}
};
static clue_weigth clues_actor_7_and_8[47] = {
- { 227, 70 }, { 240, 45 }, { 241, 70 }, { 242, 65 }, { 212, 70 }, { 213, 70 }, { 214, 70 }, { 215, 70 },
- { 216, 65 }, { 217, 70 }, { 220, 70 }, { 219, 70 }, { 218, 70 }, { 221, 45 }, { 222, 70 }, { 223, 70 },
- { 224, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 }, { 230, 70 }, { 231, 70 }, { 232, 70 }, { 239, 65 },
- { 19, 45 }, { 25, 45 }, { 60, 45 }, { 69, 45 }, { 70, 45 }, { 92, 45 }, { 95, 45 }, { 103, 45 },
- { 107, 45 }, { 121, 45 }, { 130, 45 }, { 133, 45 }, { 147, 70 }, { 148, 70 }, { 149, 70 }, { 150, 70 },
- { 151, 70 }, { 152, 70 }, { 116, 65 }, { 117, 65 }, { 145, 70 }, { 207, 55 }, { 211, 65 }
+ {227, 70}, {240, 45}, {241, 70}, {242, 65}, {212, 70}, {213, 70}, {214, 70}, {215, 70},
+ {216, 65}, {217, 70}, {220, 70}, {219, 70}, {218, 70}, {221, 45}, {222, 70}, {223, 70},
+ {224, 70}, {226, 70}, {228, 70}, {229, 70}, {230, 70}, {231, 70}, {232, 70}, {239, 65},
+ {19, 45}, {25, 45}, {60, 45}, {69, 45}, {70, 45}, {92, 45}, {95, 45}, {103, 45},
+ {107, 45}, {121, 45}, {130, 45}, {133, 45}, {147, 70}, {148, 70}, {149, 70}, {150, 70},
+ {151, 70}, {152, 70}, {116, 65}, {117, 65}, {145, 70}, {207, 55}, {211, 65}
};
static clue_weigth clues_actor_9[49] = {
- { 241, 70 }, { 212, 70 }, { 214, 70 }, { 217, 70 }, { 220, 70 }, { 219, 70 }, { 218, 70 }, { 222, 70 },
- { 223, 70 }, { 224, 70 }, { 226, 70 }, { 228, 70 }, { 229, 70 }, { 230, 70 }, { 231, 70 }, { 130, 70 },
- { 133, 70 }, { 147, 70 }, { 148, 70 }, { 149, 70 }, { 150, 70 }, { 151, 70 }, { 152, 70 }, { 145, 70 },
- { 227, 65 }, { 240, 65 }, { 242, 65 }, { 213, 65 }, { 215, 65 }, { 216, 65 }, { 221, 65 }, { 239, 65 },
- { 95, 65 }, { 103, 65 }, { 107, 65 }, { 121, 65 }, { 116, 65 }, { 117, 65 }, { 211, 65 }, { 99, 65 },
- { 236, 65 }, { 60, 60 }, { 69, 60 }, { 70, 60 }, { 232, 55 }, { 92, 55 }, { 207, 55 }, { 19, 50 },
- { 25, 40 }
+ {241, 70}, {212, 70}, {214, 70}, {217, 70}, {220, 70}, {219, 70}, {218, 70}, {222, 70},
+ {223, 70}, {224, 70}, {226, 70}, {228, 70}, {229, 70}, {230, 70}, {231, 70}, {130, 70},
+ {133, 70}, {147, 70}, {148, 70}, {149, 70}, {150, 70}, {151, 70}, {152, 70}, {145, 70},
+ {227, 65}, {240, 65}, {242, 65}, {213, 65}, {215, 65}, {216, 65}, {221, 65}, {239, 65},
+ {95, 65}, {103, 65}, {107, 65}, {121, 65}, {116, 65}, {117, 65}, {211, 65}, {99, 65},
+ {236, 65}, {60, 60}, {69, 60}, {70, 60}, {232, 55}, {92, 55}, {207, 55}, {19, 50},
+ {25, 40}
};
static clue_weigth clues_actor_10[44] = {
- { 241, 70 }, { 130, 70 }, { 147, 70 }, { 145, 70 }, { 240, 65 }, { 216, 65 }, { 217, 65 }, { 219, 65 },
- { 218, 65 }, { 221, 65 }, { 223, 65 }, { 224, 65 }, { 226, 65 }, { 229, 65 }, { 239, 65 }, { 95, 65 },
- { 121, 65 }, { 148, 65 }, { 149, 65 }, { 150, 65 }, { 152, 65 }, { 116, 65 }, { 117, 65 }, { 214, 60 },
- { 215, 60 }, { 69, 60 }, { 70, 60 }, { 211, 60 }, { 242, 55 }, { 213, 55 }, { 220, 55 }, { 222, 55 },
- { 60, 55 }, { 107, 55 }, { 133, 55 }, { 103, 50 }, { 92, 45 }, { 207, 45 }, { 227, 35 }, { 212, 35 },
- { 230, 35 }, { 232, 35 }, { 19, 30 }, { 25, 30 }
+ {241, 70}, {130, 70}, {147, 70}, {145, 70}, {240, 65}, {216, 65}, {217, 65}, {219, 65},
+ {218, 65}, {221, 65}, {223, 65}, {224, 65}, {226, 65}, {229, 65}, {239, 65}, {95, 65},
+ {121, 65}, {148, 65}, {149, 65}, {150, 65}, {152, 65}, {116, 65}, {117, 65}, {214, 60},
+ {215, 60}, {69, 60}, {70, 60}, {211, 60}, {242, 55}, {213, 55}, {220, 55}, {222, 55},
+ {60, 55}, {107, 55}, {133, 55}, {103, 50}, {92, 45}, {207, 45}, {227, 35}, {212, 35},
+ {230, 35}, {232, 35}, {19, 30}, {25, 30}
};
void ScriptInit::Init_Clues2() {
- for(int i = 0; i != 288; ++i)
- Actor_Clue_Add_To_Database(99, i, 100, 0, 0, -1);
+ for (int i = 0; i != 288; ++i) {
+ Actor_Clue_Add_To_Database(99, i, 100, false, false, -1);
+ }
#define IMPORT_CLUE_TABLE(a, arr) \
- for (int i = 0; i != ARRAYSIZE(arr); ++i) \
- Actor_Clue_Add_To_Database( a, arr[i].clue, arr[i].weight, 0, 0, -1);
+ for (int i = 0; i != ARRAYSIZE(arr); ++i) {\
+ Actor_Clue_Add_To_Database( a, arr[i].clue, arr[i].weight, 0, 0, -1);\
+ }
IMPORT_CLUE_TABLE( 1, clues_actor_1);
IMPORT_CLUE_TABLE( 2, clues_actor_2);
@@ -217,1159 +223,2506 @@ void ScriptInit::Init_Clues2() {
#undef IMPORT_CLUE_TABLE
- Actor_Clue_Add_To_Database(11, 201, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 213, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 212, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 218, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 219, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 225, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 229, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 230, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 232, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 116, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 117, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(11, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 213, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 219, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 222, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 223, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 228, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 124, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(12, 131, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 227, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 214, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 215, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 216, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 217, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 220, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 222, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 224, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 226, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 232, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 25, 30, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 60, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 69, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 70, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 92, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 95, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 19, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 103, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 107, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 121, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 130, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 133, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 147, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 148, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 149, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 150, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 152, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 116, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 117, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 207, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(13, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 5, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 239, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 240, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 241, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 242, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 212, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 215, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 216, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 230, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 0, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 73, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 211, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 108, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 134, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 135, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 66, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 109, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 110, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 111, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(14, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(15, 232, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(16, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 222, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 218, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 219, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 220, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 223, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 224, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 226, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 228, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 230, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 231, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 73, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(17, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 239, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 240, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 242, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 222, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 227, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 216, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 217, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 223, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 224, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 228, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 231, 100, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(18, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 219, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 213, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 229, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 232, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 116, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 117, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(19, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(20, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 214, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 223, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 25, 30, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 147, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 148, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 150, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 152, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 117, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(21, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(22, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 27, 20, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 16, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 17, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 26, 25, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 227, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 219, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 239, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database( 1, 73 , 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(23, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 227, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 219, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 239, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 17, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 16, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 27, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 26, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(24, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(25, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(25, 213, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(25, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 0, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 5, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 8, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 9, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 239, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 240, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 242, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 216, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 217, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(26, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 227, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 241, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 215, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 216, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 217, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 220, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 219, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 218, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 222, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 223, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 224, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 226, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 228, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 230, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 232, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 25, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 60, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 69, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 70, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 92, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 95, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 19, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 103, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 107, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 121, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 130, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 133, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 147, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 148, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 149, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 150, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 151, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 152, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 116, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 117, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 145, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 207, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(27, 211, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 25, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 64, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 69, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 111, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 124, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 219, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 241, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 217, 25, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 221, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 223, 75, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 225, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 222, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(28, 232, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(29, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 126, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 195, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 197, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 198, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 202, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 225, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 222, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 239, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(30, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(31, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 240, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 241, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 212, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 213, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 214, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 221, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 223, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 229, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 230, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 231, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 232, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 239, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 25, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 60, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 69, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 70, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 92, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 19, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 103, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 121, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 207, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(32, 211, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 5, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 8, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 9, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 239, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 240, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 242, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 216, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 217, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(33, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 126, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 195, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 197, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 198, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 202, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 219, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 225, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 222, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 239, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 80, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(34, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 214, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 223, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 25, 30, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 147, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 148, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 150, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 152, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 117, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(35, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 0, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 5, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 8, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 9, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 239, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 240, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 242, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 222, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 216, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 217, 85, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(37, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 227, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 212, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 221, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 224, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 228, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 231, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(42, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 212, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(44, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 227, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 216, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 217, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 221, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 224, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 226, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 214, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 229, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 232, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 145, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(51, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 214, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 223, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 25, 30, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 147, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 148, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 150, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 152, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 117, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(52, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 126, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 162, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 164, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 166, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 168, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 170, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 172, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 176, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 195, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 197, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 198, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 202, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 111, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 219, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 241, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 212, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 230, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 215, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 216, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 218, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 220, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 221, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 225, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 222, 90, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 242, 95, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(53, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 227, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 212, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 219, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 221, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 224, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 228, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 229, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 230, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 231, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 80, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 108, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 134, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 135, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 214, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(55, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 222, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 227, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 240, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 212, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 213, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 216, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 223, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 224, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 229, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 230, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 231, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 232, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 239, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 25, 30, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 60, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 69, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 70, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 92, 25, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 95, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 19, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 103, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 107, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 121, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 130, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 133, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 147, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 149, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 150, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 151, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 152, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 116, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 117, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 145, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 207, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(56, 211, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 241, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 227, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 216, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 217, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 221, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 224, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 226, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 228, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 214, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 229, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 232, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 145, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(57, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(58, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(58, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(58, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(58, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(58, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 227, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 240, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 242, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 212, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 213, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 215, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 216, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 217, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 220, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 219, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 218, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 221, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 222, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 224, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 226, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 228, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 230, 35, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 95, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 232, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 130, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 147, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 148, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 149, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 150, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 151, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 152, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 116, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 117, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 145, 50, 0, 0, -1);
- Actor_Clue_Add_To_Database(59, 211, 60, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 239, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 241, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 222, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 227, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 212, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 215, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 216, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 217, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 218, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 219, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 220, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 221, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 223, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 224, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 226, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 228, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 229, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 230, 45, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 231, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 162, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 164, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 166, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 168, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 170, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 172, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 174, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 176, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 0, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 73, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 211, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 80, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 108, 55, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 134, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(62, 135, 40, 0, 0, -1);
- Actor_Clue_Add_To_Database(66, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(66, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(66, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(66, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(66, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(67, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(67, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(67, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(67, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(67, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(68, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(68, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(68, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(68, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(68, 214, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(69, 240, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(69, 241, 70, 0, 0, -1);
- Actor_Clue_Add_To_Database(69, 242, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(69, 239, 65, 0, 0, -1);
- Actor_Clue_Add_To_Database(69, 214, 65, 0, 0, -1);
+ Actor_Clue_Add_To_Database(11, 201, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 213, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 212, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 218, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 219, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 225, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 229, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 230, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 232, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 116, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 117, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(11, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 213, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 219, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 222, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 223, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 228, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 124, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(12, 131, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 227, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 214, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 215, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 216, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 217, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 220, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 222, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 224, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 226, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 232, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 25, 30, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 60, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 69, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 70, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 92, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 95, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 19, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 103, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 107, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 121, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 130, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 133, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 147, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 148, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 149, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 150, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 152, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 116, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 117, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 207, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(13, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 5, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 239, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 240, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 241, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 242, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 212, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 215, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 216, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 230, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 0, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 73, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 211, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 108, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 134, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 135, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 66, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 109, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 110, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 111, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(14, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(15, 232, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(16, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 222, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 218, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 219, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 220, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 223, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 224, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 226, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 228, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 230, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 231, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 73, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(17, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 239, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 240, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 242, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 222, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 227, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 216, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 217, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 223, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 224, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 228, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 231, 100, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(18, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 219, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 213, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 229, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 232, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 116, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 117, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(19, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(20, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 214, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 223, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 25, 30, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 147, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 148, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 150, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 152, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 117, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(21, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(22, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 27, 20, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 16, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 17, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 26, 25, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 227, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 219, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 239, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(1, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(23, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 227, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 219, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 239, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 17, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 16, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 27, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 26, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(24, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(25, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(25, 213, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(25, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 0, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 5, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 8, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 9, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 239, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 240, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 242, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 216, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 217, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(26, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 227, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 241, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 215, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 216, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 217, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 220, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 219, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 218, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 222, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 223, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 224, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 226, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 228, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 230, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 232, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 25, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 60, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 69, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 70, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 92, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 95, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 19, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 103, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 107, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 121, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 130, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 133, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 147, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 148, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 149, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 150, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 151, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 152, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 116, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 117, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 145, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 207, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(27, 211, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 25, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 64, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 69, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 111, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 124, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 219, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 241, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 217, 25, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 221, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 223, 75, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 225, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 222, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(28, 232, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(29, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 126, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 195, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 197, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 198, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 202, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 225, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 222, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 239, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(30, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(31, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 240, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 241, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 212, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 213, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 214, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 221, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 223, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 229, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 230, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 231, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 232, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 239, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 25, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 60, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 69, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 70, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 92, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 19, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 103, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 121, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 207, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(32, 211, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 5, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 8, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 9, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 239, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 240, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 242, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 216, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 217, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(33, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 126, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 195, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 197, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 198, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 202, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 219, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 225, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 222, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 239, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 80, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(34, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 214, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 223, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 25, 30, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 147, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 148, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 150, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 152, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 117, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(35, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 0, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 5, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 8, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 9, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 239, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 240, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 242, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 222, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 216, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 217, 85, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(37, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 227, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 212, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 221, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 224, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 228, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 231, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(42, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 212, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(44, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 227, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 216, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 217, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 221, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 224, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 226, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 214, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 229, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 232, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 145, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(51, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 214, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 223, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 25, 30, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 147, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 148, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 150, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 152, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 117, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(52, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 126, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 162, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 164, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 166, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 168, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 170, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 172, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 176, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 195, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 197, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 198, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 202, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 111, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 219, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 241, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 212, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 230, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 215, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 216, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 218, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 220, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 221, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 225, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 222, 90, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 242, 95, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(53, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 227, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 212, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 219, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 221, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 224, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 228, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 229, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 230, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 231, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 80, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 108, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 134, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 135, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 214, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(55, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 222, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 227, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 240, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 212, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 213, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 216, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 223, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 224, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 229, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 230, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 231, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 232, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 239, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 25, 30, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 60, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 69, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 70, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 92, 25, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 95, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 19, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 103, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 107, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 121, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 130, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 133, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 147, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 149, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 150, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 151, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 152, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 116, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 117, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 145, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 207, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(56, 211, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 241, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 227, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 216, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 217, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 221, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 224, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 226, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 228, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 214, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 229, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 232, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 145, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(57, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(58, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(58, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(58, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(58, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(58, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 227, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 240, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 242, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 212, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 213, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 215, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 216, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 217, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 220, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 219, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 218, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 221, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 222, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 224, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 226, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 228, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 230, 35, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 95, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 232, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 130, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 147, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 148, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 149, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 150, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 151, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 152, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 116, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 117, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 145, 50, false, false, -1);
+ Actor_Clue_Add_To_Database(59, 211, 60, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 239, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 241, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 222, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 227, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 212, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 215, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 216, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 217, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 218, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 219, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 220, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 221, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 223, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 224, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 226, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 228, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 229, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 230, 45, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 231, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 162, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 164, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 166, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 168, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 170, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 172, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 174, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 176, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 0, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 73, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 211, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 80, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 108, 55, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 134, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(62, 135, 40, false, false, -1);
+ Actor_Clue_Add_To_Database(66, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(66, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(66, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(66, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(66, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(67, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(67, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(67, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(67, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(67, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(68, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(68, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(68, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(68, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(68, 214, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(69, 240, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(69, 241, 70, false, false, -1);
+ Actor_Clue_Add_To_Database(69, 242, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(69, 239, 65, false, false, -1);
+ Actor_Clue_Add_To_Database(69, 214, 65, false, false, -1);
}
void ScriptInit::Init_World_Waypoints() {
-
+ World_Waypoint_Set(0, 7, -676.0f, -0.04f, -94.0f);
+ World_Waypoint_Set(1, 7, -807.0f, -0.04f, 109.0f);
+ World_Waypoint_Set(2, 15, 541.8f, 0.38f, -435.68f);
+ World_Waypoint_Set(3, 66, 561.01f, 0.34f, -606.67f);
+ World_Waypoint_Set(4, 14, -404.09f, -9.23f, 251.95f);
+ World_Waypoint_Set(5, 14, -99.0f, -9.23f, 690.0f);
+ World_Waypoint_Set(6, 14, -374.14f, -8.97f, 240.18f);
+ World_Waypoint_Set(7, 14, -766.02f, -8.82f, 271.44f);
+ World_Waypoint_Set(8, 14, -546.19f, -9.06f, 351.38f);
+ World_Waypoint_Set(9, 14, -522.66f, -8.6f, 1409.29f);
+ World_Waypoint_Set(10, 14, -324.21f, -9.01f, 1428.74f);
+ World_Waypoint_Set(11, 14, 23.72f, -8.87f, 1335.19f);
+ World_Waypoint_Set(12, 69, -132.0f, 6.09f, 91.0f);
+ World_Waypoint_Set(13, 7, 21.4f, 0.22f, -201.68f);
+ World_Waypoint_Set(14, 7, 164.44f, 0.29f, -265.69f);
+ World_Waypoint_Set(15, 7, 279.7f, 7.23f, -888.43f);
+ World_Waypoint_Set(16, 14, 41.35f, -8.98f, 556.2f);
+ World_Waypoint_Set(17, 14, -697.86f, -0.73f, 21.89f);
+ World_Waypoint_Set(18, 14, -678.17f, -0.77f, 1043.62f);
+ World_Waypoint_Set(19, 14, 116.89f, -0.74f, 1581.12f);
+ World_Waypoint_Set(20, 7, -312.92f, 0.17f, -345.2f);
+ World_Waypoint_Set(21, 7, -290.04f, 0.23f, -513.79f);
+ World_Waypoint_Set(22, 7, 6.97f, 0.54f, -759.56f);
+ World_Waypoint_Set(23, 7, 280.48f, 11.58f, -941.15f);
+ World_Waypoint_Set(24, 7, 231.14f, 7.14f, -688.96f);
+ World_Waypoint_Set(25, 7, 54.92f, 0.2f, -171.75f);
+ World_Waypoint_Set(26, 7, -56.77f, 0.18f, -166.99f);
+ World_Waypoint_Set(27, 7, -78.12f, 0.34f, -449.92f);
+ World_Waypoint_Set(28, 69, -30.0f, -625.51f, 366.15f);
+ World_Waypoint_Set(29, 69, -51.81f, -622.47f, 286.93f);
+ World_Waypoint_Set(30, 69, -320.58f, -625.53f, 301.58f);
+ World_Waypoint_Set(31, 66, 421.01f, 0.22f, -566.67f);
+ World_Waypoint_Set(32, 66, 336.0f, 0.22f, -520.0f);
+ World_Waypoint_Set(33, 91, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(34, 92, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(35, 93, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(36, 94, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(37, 95, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(38, 96, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(39, 97, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(40, 98, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(41, 99, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(42, 100, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(43, 4, -427.0f, -6.5f, 1188.0f);
+ World_Waypoint_Set(44, 4, -255.2f, -6.5f, 455.2f);
+ World_Waypoint_Set(45, 27, -247.02f, -145.11f, 32.99f);
+ World_Waypoint_Set(46, 27, -154.83f, -145.11f, 9.39f);
+ World_Waypoint_Set(47, 5, -619.36f, -616.15f, 220.91f);
+ World_Waypoint_Set(48, 5, -82.86f, -621.3f, 769.03f);
+ World_Waypoint_Set(49, 29, -7.31f, -58.23f, 22.44f);
+ World_Waypoint_Set(50, 29, 132.16f, -58.23f, 767.0f);
+ World_Waypoint_Set(51, 5, -335.05f, -618.82f, 312.9f);
+ World_Waypoint_Set(52, 30, 189.7f, -58.23f, -4.72f);
+ World_Waypoint_Set(53, 4, -450.32f, -6.5f, 230.39f);
+ World_Waypoint_Set(54, 4, -70.04f, -6.5f, 150.17f);
+ World_Waypoint_Set(55, 66, 491.0f, 0.0f, -571.0f);
+ World_Waypoint_Set(56, 4, -221.68f, -6.5f, 150.15f);
+ World_Waypoint_Set(57, 69, -291.43f, -0.3f, 277.92f);
+ World_Waypoint_Set(58, 69, -272.91f, -0.3f, 369.1f);
+ World_Waypoint_Set(59, 7, -118.65f, 0.15f, -130.15f);
+ World_Waypoint_Set(60, 7, 22.27f, 0.15f, -69.81f);
+ World_Waypoint_Set(61, 16, -39.0f, -1238.0f, 108284.0f);
+ World_Waypoint_Set(62, 62, -11.0f, -40.0f, -45.0f);
+ World_Waypoint_Set(63, 5, -133.0f, -621.0f, 686.0f);
+ World_Waypoint_Set(64, 4, -360.0f, -6.13f, 380.0f);
+ World_Waypoint_Set(65, 15, 688.0f, 0.37f, -518.0f);
+ World_Waypoint_Set(66, 5, -83.0f, -621.0f, 627.0f);
+ World_Waypoint_Set(67, 4, -212.65f, -2.08f, 513.47f);
+ World_Waypoint_Set(68, 4, -219.43f, -2.08f, 584.8f);
+ World_Waypoint_Set(69, 4, -215.0f, -2.08f, 548.0f);
+ World_Waypoint_Set(71, 69, 210.0f, 5.55f, 146.19f);
+ World_Waypoint_Set(72, 69, -55.27f, 5.55f, 108.34f);
+ World_Waypoint_Set(73, 66, 338.75f, 0.22f, -612.0f);
+ World_Waypoint_Set(74, 66, 338.75f, 0.22f, -560.0f);
+ World_Waypoint_Set(75, 5, -138.45f, -621.3f, 778.52f);
+ World_Waypoint_Set(76, 63, -499.23f, -354.62f, -51.3f);
+ World_Waypoint_Set(77, 63, -903.0f, -354.62f, 676.0f);
+ World_Waypoint_Set(78, 63, -723.0f, -354.62f, -1272.0f);
+ World_Waypoint_Set(79, 67, 207.36f, 0.67f, -96.42f);
+ World_Waypoint_Set(80, 67, -134.43f, 0.43f, -180.46f);
+ World_Waypoint_Set(81, 67, -559.0f, 0.15f, -100.0f);
+ World_Waypoint_Set(82, 63, -1250.07f, -354.0f, -1186.9f);
+ World_Waypoint_Set(83, 16, -55.11f, -1238.89f, 107995.87f);
+ World_Waypoint_Set(84, 27, -161.62f, -145.11f, -53.73f);
+ World_Waypoint_Set(85, 27, -201.62f, -145.11f, -85.73f);
+ World_Waypoint_Set(86, 4, -171.55f, -2.08f, 361.01f);
+ World_Waypoint_Set(87, 4, -523.51f, -9.23f, 1384.76f);
+ World_Waypoint_Set(88, 4, -102.01f, -9.23f, 1375.38f);
+ World_Waypoint_Set(89, 16, 14.54f, -1238.89f, 108280.85f);
+ World_Waypoint_Set(91, 16, 9.68f, -1238.89f, 108427.73f);
+ World_Waypoint_Set(92, 16, -153.29f, -1238.89f, 108473.52f);
+ World_Waypoint_Set(93, 16, -104.0f, -1238.89f, 108413.0f);
+ World_Waypoint_Set(90, 16, 37.59f, -1238.89f, 108449.29f);
+ World_Waypoint_Set(94, 30, 302.32f, -58.23f, 35.14f);
+ World_Waypoint_Set(95, 35, 62.0f, 0.3f, 129.0f);
+ World_Waypoint_Set(96, 35, -134.63f, -0.3f, 171.41f);
+ World_Waypoint_Set(97, 7, -1135.0f, 6.98f, 441.0f);
+ World_Waypoint_Set(98, 7, -1015.0f, 7.18f, 354.75f);
+ World_Waypoint_Set(99, 7, -975.0f, -0.04f, 316.0f);
+ World_Waypoint_Set(100, 4, -334.46f, -6.5f, 500.64f);
+ World_Waypoint_Set(101, 7, -334.46f, -6.5f, 500.64f);
+ World_Waypoint_Set(102, 16, 27.89f, -1238.89f, 108288.73f);
+ World_Waypoint_Set(103, 71, 48.31f, 0.15f, 17.11f);
+ World_Waypoint_Set(104, 71, 4.31f, 0.15f, -39.0f);
+ World_Waypoint_Set(105, 5, -764.58f, -616.31f, 229.6f);
+ World_Waypoint_Set(106, 4, -25.0f, -6.5f, 352.28f);
+ World_Waypoint_Set(107, 71, -3.6f, -621.79f, 164.09f);
+ World_Waypoint_Set(108, 71, 86.03f, -622.47f, 73.21f);
+ World_Waypoint_Set(109, 7, -793.0f, -0.04f, 164.0f);
+ World_Waypoint_Set(110, 7, -665.0f, -0.04f, 304.0f);
+ World_Waypoint_Set(111, 7, -765.0f, -0.04f, 232.0f);
+ World_Waypoint_Set(112, 7, -817.0f, -0.04f, 300.0f);
+ World_Waypoint_Set(113, 7, -907.0f, -0.04f, 304.0f);
+ World_Waypoint_Set(114, 20, -4.0f, 0.0f, 880.0f);
+ World_Waypoint_Set(115, 20, 174.0f, 0.0f, 890.15f);
+ World_Waypoint_Set(116, 20, 69.0f, 0.0f, 695.0f);
+ World_Waypoint_Set(117, 20, 0.0f, 0.0f, 0.0f);
+ World_Waypoint_Set(118, 28, -376.35f, -109.91f, 604.4f);
+ World_Waypoint_Set(119, 28, -375.0f, -109.91f, 750.0f);
+ World_Waypoint_Set(120, 0, -50.81f, 2.5f, 233.0f);
+ World_Waypoint_Set(121, 0, -50.81f, 2.5f, 31.03f);
+ World_Waypoint_Set(122, 0, 28.12f, 2.5f, 100.64f);
+ World_Waypoint_Set(123, 4, -474.28f, -6.5f, 979.59f);
+ World_Waypoint_Set(124, 49, 8.74f, 0.0f, -282.81f);
+ World_Waypoint_Set(125, 49, 978.98f, 0.0f, 145.64f);
+ World_Waypoint_Set(126, 49, 477.18f, 0.0f, -287.21f);
+ World_Waypoint_Set(127, 26, 31.39f, -10.27f, -64.52f);
+ World_Waypoint_Set(128, 26, 7.39f, -10.27f, -136.52f);
+ World_Waypoint_Set(129, 26, -136.61f, -10.27f, -136.52f);
+ World_Waypoint_Set(130, 26, -36.61f, -10.27f, -136.52f);
+ World_Waypoint_Set(131, 24, 435.45f, -9.0f, 166.0f);
+ World_Waypoint_Set(132, 24, 619.45f, -9.0f, 234.0f);
+ World_Waypoint_Set(133, 24, 619.45f, -9.0f, 270.0f);
+ World_Waypoint_Set(134, 22, -80.59f, -60.31f, 256.35f);
+ World_Waypoint_Set(135, 22, -48.0f, -60.31f, 183.0f);;
+ World_Waypoint_Set(136, 22, -24.59f, -60.31f, 64.35f);
+ World_Waypoint_Set(137, 22, 99.41f, -60.31f, 4.35f);
+ World_Waypoint_Set(138, 22, 99.41f, -60.34f, -115.65f);
+ World_Waypoint_Set(139, 22, 147.41f, -60.34f, -115.65f);
+ World_Waypoint_Set(144, 3, -654.56f, 252.59f, -1110.88f);
+ World_Waypoint_Set(145, 3, -578.56f, 252.59f, -1010.88f);
+ World_Waypoint_Set(146, 3, -470.56f, 252.59f, -1070.88f);
+ World_Waypoint_Set(147, 3, -510.56f, 252.59f, -1006.88f);
+ World_Waypoint_Set(148, 3, -646.56f, 252.59f, -1006.88f);
+ World_Waypoint_Set(140, 2, -43.88f, -0.04f, 172.95f);
+ World_Waypoint_Set(141, 2, 78.36f, -0.04f, 80.79f);
+ World_Waypoint_Set(142, 2, 81.74f, -0.04f, -94.0f);
+ World_Waypoint_Set(143, 2, -118.26f, -0.04f, -94.04f);
+ World_Waypoint_Set(149, 8, 647.0f, 1.6f, -81.87f);
+ World_Waypoint_Set(150, 75, -269.0f, 120.16f, -88.0f);
+ World_Waypoint_Set(151, 75, -181.0f, 120.16f, -96.0f);
+ World_Waypoint_Set(152, 75, -133.0f, 84.13f, -108.0f);
+ World_Waypoint_Set(153, 75, -95.0f, 74.87f, -503.0f);
+ World_Waypoint_Set(154, 70, -172.6f, 1.72f, 87.62f);
+ World_Waypoint_Set(155, 0, -284.0f, 0.0f, 296.0f);
+ World_Waypoint_Set(156, 0, -680.0f, 0.0f, -156.0f);
+ World_Waypoint_Set(157, 0, -702.0f, 0.0f, -919.0f);
+ World_Waypoint_Set(158, 0, 140.0f, 0.0f, -1233.0f);
+ World_Waypoint_Set(159, 0, -228.0f, 0.0f, -92.0f);
+ World_Waypoint_Set(160, 0, -274.0f, 0.0f, -627.0f);
+ World_Waypoint_Set(161, 0, -329.27f, 0.0f, -1115.14f);
+ World_Waypoint_Set(162, 8, 815.34f, 0.14f, 165.21f);
+ World_Waypoint_Set(163, 8, -35.0f, 0.14f, 39.0f);
+ World_Waypoint_Set(164, 8, -24.0f, 0.14f, -631.0f);
+ World_Waypoint_Set(165, 8, -125.0f, 0.14f, -221.0f);
+ World_Waypoint_Set(166, 8, 456.82f, 0.14f, 69.0f);
+ World_Waypoint_Set(167, 70, -815.0f, -4.01f, 96.0f);
+ World_Waypoint_Set(168, 70, -235.0f, 1.72f, 92.0f);
+ World_Waypoint_Set(169, 70, 5.0f, 1.72f, 92.0f);
+ World_Waypoint_Set(170, 70, 265.0f, 1.72f, 36.0f);
+ World_Waypoint_Set(171, 70, -639.0f, 1.72f, -124.0f);
+ World_Waypoint_Set(172, 8, -225.0f, 1.0f, 39.0f);
+ World_Waypoint_Set(172, 8, -217.0f, 1.0f, 127.0f);
+ World_Waypoint_Set(174, 70, 326.96f, -4.01f, 383.16f);
+ World_Waypoint_Set(175, 70, 264.43f, -4.01f, 313.73f);
+ World_Waypoint_Set(176, 79, -78.43f, 0.0f, 269.98f);
+ World_Waypoint_Set(177, 79, 19.0f, 0.0f, 269.98f);
+ World_Waypoint_Set(178, 79, 91.0f, 0.0f, 137.6f);
+ World_Waypoint_Set(185, 82, 115.0f, 156.94f, -310.0f);
+ World_Waypoint_Set(186, 82, 153.0f, 156.94f, -294.0f);
+ World_Waypoint_Set(179, 79, 40.14f, 0.0f, 276.62f);
+ World_Waypoint_Set(180, 79, -71.86f, 0.0f, 276.62f);
+ World_Waypoint_Set(181, 79, -112.56f, 0.0f, 228.03f);
+ World_Waypoint_Set(189, 86, 229.0f, 186.04f, -24.0f);
+ World_Waypoint_Set(190, 86, 157.0f, 186.04f, -24.0f);
+ World_Waypoint_Set(191, 86, 157.0f, 128.92f, -148.0f);
+ World_Waypoint_Set(182, 74, 143.45f, -50.13f, -12.22f);
+ World_Waypoint_Set(183, 74, 199.45f, -50.13f, -1400.22f);
+ World_Waypoint_Set(184, 74, -112.55f, -50.13f, -2360.22f);
+ World_Waypoint_Set(187, 86, -295.0f, 12.97f, -148.0f);
+ World_Waypoint_Set(188, 86, 157.0f, 129.0f, -504.0f);
+ World_Waypoint_Set(192, 17, -136.19f, 0.0f, 1580.03f);
+ World_Waypoint_Set(193, 17, -308.0f, -81.46f, 1466.0f);
+ World_Waypoint_Set(194, 21, 82.26f, 60.16f, -124.35f);
+ World_Waypoint_Set(195, 21, 226.1f, 60.16f, -139.84f);
+ World_Waypoint_Set(196, 22, 39.41f, -60.31f, 308.35f);
+ World_Waypoint_Set(197, 22, 99.41f, -60.31f, 220.35f);
+ World_Waypoint_Set(198, 22, 267.41f, -60.31f, 180.35f);
+ World_Waypoint_Set(200, 2, -44.46f, -0.04f, 177.4f);
+ World_Waypoint_Set(201, 2, 137.0f, -0.04f, 17.0f);
+ World_Waypoint_Set(202, 70, -610.0f, -4.01f, 237.11f);
+ World_Waypoint_Set(203, 70, -368.96f, -4.01f, 237.11f);
+ World_Waypoint_Set(204, 8, 19.0f, 0.14f, 83.0f);
+ World_Waypoint_Set(205, 8, -58.36f, 0.14f, 4.4f);
+ World_Waypoint_Set(206, 8, -18.11f, 0.14f, -669.45f);
+ World_Waypoint_Set(207, 8, -18.11f, 0.14f, -669.45f);
+ World_Waypoint_Set(208, 8, -162.25f, 0.14f, -511.93f);
+ World_Waypoint_Set(209, 8, -128.25f, 0.14f, -322.0f);
+ World_Waypoint_Set(210, 8, 714.48f, 0.14f, 14.92f);
+ World_Waypoint_Set(211, 8, 23.0f, 0.14f, -1.0f);
+ World_Waypoint_Set(212, 8, 28.47f, 0.14f, 3.8f);
+ World_Waypoint_Set(213, 8, 36.47f, 0.14f, 55.89f);
+ World_Waypoint_Set(214, 8, 155.75f, 0.14f, 54.0f);
+ World_Waypoint_Set(215, 0, -70.0f, 0.0f, -647.0f);
+ World_Waypoint_Set(216, 0, -270.01f, 0.0f, -441.68f);
+ World_Waypoint_Set(217, 0, -209.98f, 0.0f, -483.05f);
+ World_Waypoint_Set(218, 0, -428.08f, 0.0f, -110.16f);
+ World_Waypoint_Set(219, 0, 256.0f, 0.0f, -298.08f);
+ World_Waypoint_Set(220, 0, -187.18f, 0.0f, -298.08f);
+ World_Waypoint_Set(221, 0, -428.08f, 0.0f, -110.16f);
+ World_Waypoint_Set(222, 0, -466.0f, 0.0f, -635.0f);
+ World_Waypoint_Set(223, 0, -382.0f, 0.0f, -1099.0f);
+ World_Waypoint_Set(224, 0, -227.0f, 0.0f, -1333.0f);
+ World_Waypoint_Set(225, 0, 140.88f, 0.0f, -1362.34f);
+ World_Waypoint_Set(226, 0, -448.18f, 0.0f, -626.38f);
+ World_Waypoint_Set(227, 0, -444.18f, 0.0f, -730.38f);
+ World_Waypoint_Set(228, 20, -198.02f, 9.04f, 487.7f);
+ World_Waypoint_Set(229, 20, -147.4f, 9.04f, 918.08f);
+ World_Waypoint_Set(230, 20, -201.67f, 9.04f, 829.09f);
+ World_Waypoint_Set(231, 20, -177.67f, 9.04f, 829.09f);
+ World_Waypoint_Set(232, 4, -92.52f, -6.5f, 714.44f);
+ World_Waypoint_Set(233, 4, -352.52f, -6.5f, 714.44f);
+ World_Waypoint_Set(234, 4, -352.52f, -6.5f, 666.44f);
+ World_Waypoint_Set(235, 4, -136.41f, -6.5f, 735.26f);
+ World_Waypoint_Set(236, 4, -248.41f, -6.5f, 747.26f);
+ World_Waypoint_Set(237, 4, -352.52f, -6.5f, 252.0f);
+ World_Waypoint_Set(238, 4, -190.25f, -6.5f, 274.58f);
+ World_Waypoint_Set(239, 33, -371.87f, 0.0f, 275.89f);
+ World_Waypoint_Set(240, 33, -371.87f, 0.0f, -60.11f);
+ World_Waypoint_Set(241, 33, 588.5f, 0.0f, 254.19f);
+ World_Waypoint_Set(242, 33, 560.5f, 0.0f, 254.19f);
+ World_Waypoint_Set(243, 7, -153.77f, -0.01f, -1037.98f);
+ World_Waypoint_Set(244, 7, 398.23f, 6.98f, -1037.98f);
+ World_Waypoint_Set(245, 7, 40.78f, 7.22f, -943.72f);
+ World_Waypoint_Set(246, 7, 68.78f, -0.01f, -943.72f);
+ World_Waypoint_Set(247, 7, 96.78f, -0.01f, -973.72f);
+ World_Waypoint_Set(248, 63, -897.38f, -354.62f, 704.77f);
+ World_Waypoint_Set(249, 63, -914.76f, -354.62f, -312.43f);
+ World_Waypoint_Set(250, 63, -457.54f, -354.62f, -820.15f);
+ World_Waypoint_Set(251, 15, 556.72f, 0.37f, -141.26f);
+ World_Waypoint_Set(252, 15, 635.66f, 0.37f, -594.11f);
+ World_Waypoint_Set(253, 67, 130.42f, 0.0f, -79.98f);
+ World_Waypoint_Set(254, 67, -311.15f, 0.0f, -161.06f);
+ World_Waypoint_Set(255, 67, -403.15f, 0.0f, -161.06f);
+ World_Waypoint_Set(256, 67, -487.15f, 0.0f, -137.11f);
+ World_Waypoint_Set(257, 67, -611.15f, 0.0f, -73.06f);
+ World_Waypoint_Set(258, 8, 37.64f, 0.14f, -48.02f);
+ World_Waypoint_Set(259, 8, 109.64f, 0.14f, 91.98f);
+ World_Waypoint_Set(260, 8, -149.0f, 0.14f, 79.0f);
+ World_Waypoint_Set(261, 8, -129.0f, 0.14f, -237.0f);
+ World_Waypoint_Set(262, 8, -1.0f, 0.14f, -671.0f);
+ World_Waypoint_Set(263, 64, -728.0f, -354.0f, 1090.0f);
+ World_Waypoint_Set(264, 10, -8.41f, -144.0f, 343.0f);
+ World_Waypoint_Set(265, 10, -20.81f, -144.0f, 450.0f);
+ World_Waypoint_Set(266, 10, -200.0f, -144.0f, 206.0f);
+ World_Waypoint_Set(267, 10, -17.0f, -144.0f, 178.0f);
+ World_Waypoint_Set(268, 50, -7207.0f, 955.5f, 1852.75f);
+ World_Waypoint_Set(269, 50, -7191.0f, 955.5f, 1700.75f);
+ World_Waypoint_Set(270, 50, 7116.0f, 955.5f, 1871.0f);
+ World_Waypoint_Set(271, 7, -1139.89f, -0.04f, 67.89f);
+ World_Waypoint_Set(272, 7, -690.5f, -0.04f, -210.48f);
+ World_Waypoint_Set(273, 7, -495.89f, -0.04f, -204.11f);
+ World_Waypoint_Set(274, 69, -511.75f, 5.55f, 55.63f);
+ World_Waypoint_Set(275, 69, 296.21f, 5.55f, 59.63f);
+ World_Waypoint_Set(276, 73, -34.57f, 149.42f, -502.83f);
+ World_Waypoint_Set(277, 73, 51.0f, 149.42f, -487.27f);
+ World_Waypoint_Set(278, 73, 82.0f, 149.42f, -519.0f);
+ World_Waypoint_Set(279, 73, 95.97f, 149.42f, -549.51f);
+ World_Waypoint_Set(280, 73, -34.0f, 149.42f, -551.0f);
+ World_Waypoint_Set(281, 7, -2060.99f, -0.04f, -234.8f);
+ World_Waypoint_Set(282, 54, -346.69f, 31.55f, -1476.41f);
+ World_Waypoint_Set(283, 54, -298.69f, 31.55f, -1476.41f);
+ World_Waypoint_Set(284, 54, -298.69f, 31.55f, -1260.41f);
+ World_Waypoint_Set(285, 54, -418.69f, 31.55f, -1260.41f);
+ World_Waypoint_Set(286, 12, -104.24f, 0.0f, 183.16f);
+ World_Waypoint_Set(287, 57, -254.0f, -73.5f, -41.0f);
+ World_Waypoint_Set(288, 6, -125.14f, 0.02f, -176.76f);
+ World_Waypoint_Set(289, 0, -871.15f, 0.0f, -1081.93f);
+ World_Waypoint_Set(290, 0, -411.15f, 0.0f, -1117.93f);
+ World_Waypoint_Set(291, 54, 225.31f, 31.665f, -572.41f);
+ World_Waypoint_Set(292, 12, -127.0f, 0.0f, 178.0f);
+ World_Waypoint_Set(293, 12, 5.0f, 0.0f, 342.0f);
+ World_Waypoint_Set(294, 12, 173.0f, 0.0f, 226.0f);
+ World_Waypoint_Set(295, 12, 13.0f, 0.0f, -50.0f);
+ World_Waypoint_Set(354, 12, 57.0f, 0.0f, 18.0f);
+ World_Waypoint_Set(355, 12, 161.0f, 0.0f, 410.0f);
+ World_Waypoint_Set(358, 12, 33.0f, 0.0f, 198.0f);
+ World_Waypoint_Set(359, 12, 62.92f, 0.16f, 309.72f);
+ World_Waypoint_Set(549, 12, -15.0f, 0.0f, 338.0f);
+ World_Waypoint_Set(445, 12, 129.0f, 0.0f, 418.0f);
+ World_Waypoint_Set(546, 12, 13.0f, 0.0f, 206.0f);
+ World_Waypoint_Set(296, 77, 168.0f, 11.87f, -987.0f);
+ World_Waypoint_Set(297, 77, -178.5f, 23.73f, -2176.05f);
+ World_Waypoint_Set(298, 82, -145.0f, 156.94f, -370.0f);
+ World_Waypoint_Set(299, 82, -37.0f, 156.94f, -506.0f);
+ World_Waypoint_Set(300, 82, 75.0f, 156.94f, -506.0f);
+ World_Waypoint_Set(301, 83, 60.3f, 81.33f, -647.7f);
+ World_Waypoint_Set(302, 83, -271.0f, 81.33f, -647.7f);
+ World_Waypoint_Set(303, 83, -11.7f, 81.33f, -647.7f);
+ World_Waypoint_Set(304, 83, 10.94f, 115.0f, 59.67f);
+ World_Waypoint_Set(305, 83, 0.3f, 115.0f, 404.3f);
+ World_Waypoint_Set(306, 83, -329.38f, 115.0f, -385.84f);
+ World_Waypoint_Set(307, 84, 131.0f, -126.21f, -224.0f);
+ World_Waypoint_Set(308, 84, 103.0f, -126.21f, 152.0f);
+ World_Waypoint_Set(309, 84, 19.0f, -126.21f, 152.0f);
+ World_Waypoint_Set(310, 84, 459.0f, -126.21f, 152.0f);
+ World_Waypoint_Set(311, 84, -29.0f, -126.21f, 556.0f);
+ World_Waypoint_Set(312, 86, -311.0f, 129.0f, -488.0f);
+ World_Waypoint_Set(322, 12, 121.0f, 0.0f, -82.0f);
+ World_Waypoint_Set(323, 8, 600.58f, 0.14f, 32.82f);
+ World_Waypoint_Set(127, 26, 102.98f, -30.89f, -121.02f);
+ World_Waypoint_Set(128, 26, -20.0f, -30.89f, -121.02f);
+ World_Waypoint_Set(313, 26, 102.98f, -31.0f, -149.0f);
+ World_Waypoint_Set(314, 26, 20.0f, -31.0f, -109.0f);
+ World_Waypoint_Set(315, 26, -60.6f, -31.0f, -109.0f);
+ World_Waypoint_Set(316, 26, 87.35f, -31.0f, 74.0f);
+ World_Waypoint_Set(317, 26, 74.0f, -31.0f, 42.0f);
+ World_Waypoint_Set(318, 26, 74.0f, -31.0f, 98.0f);
+ World_Waypoint_Set(319, 26, 115.35f, -31.0f, 302.36f);
+ World_Waypoint_Set(320, 26, 104.38f, -31.0f, 260.0f);
+ World_Waypoint_Set(321, 26, 120.0f, -31.0f, 115.0f);
+ World_Waypoint_Set(336, 57, -110.0f, -73.5f, -169.0f);
+ World_Waypoint_Set(337, 57, -161.0f, -73.5f, -105.0f);
+ World_Waypoint_Set(338, 57, -193.0f, -73.5f, -105.0f);
+ World_Waypoint_Set(350, 54, -416.0f, -31.93f, -841.0f);
+ World_Waypoint_Set(339, 80, 106.0f, -12.21f, -94.0f);
+ World_Waypoint_Set(340, 80, 98.02f, -12.21f, -126.0f);
+ World_Waypoint_Set(341, 80, 106.0f, -21.47f, -278.0f);
+ World_Waypoint_Set(342, 80, 82.0f, -12.19f, -278.0f);
+ World_Waypoint_Set(343, 7, -1847.0f, -0.04f, 82.0f);
+ World_Waypoint_Set(344, 7, -1847.0f, -0.04f, -222.0f);
+ World_Waypoint_Set(345, 7, -1147.0f, -0.04f, -198.0f);
+ World_Waypoint_Set(346, 7, -667.0f, -0.04f, -125.0f);
+ World_Waypoint_Set(347, 7, -471.0f, -0.04f, -110.0f);
+ World_Waypoint_Set(348, 7, -403.0f, -0.04f, -110.0f);
+ World_Waypoint_Set(351, 31, 105.0f, 348.52f, 948.0f);
+ World_Waypoint_Set(352, 33, -426.0f, 9.68f, -33.0f);
+ World_Waypoint_Set(353, 33, -439.0f, 9.68f, -101.0f);
+ World_Waypoint_Set(356, 11, 19.01f, -24.0f, 20.21f);
+ World_Waypoint_Set(357, 11, 22.26f, 12.0f, -31.01f);
+ World_Waypoint_Set(366, 11, -94.21f, 12.0f, -26.15f);
+ World_Waypoint_Set(367, 11, -286.21f, -24.0f, 37.85f);
+ World_Waypoint_Set(368, 19, 176.91f, -40.67f, 225.92f);
+ World_Waypoint_Set(369, 54, -220.0f, 23.88f, -1437.0f);
+ World_Waypoint_Set(370, 54, -392.0f, 31.55f, -1757.0f);
+ World_Waypoint_Set(371, 39, 441.0f, 47.76f, -798.98f);
+ World_Waypoint_Set(372, 39, 185.62f, 47.76f, -867.42f);
+ World_Waypoint_Set(373, 39, 947.0f, 47.76f, -696.0f);
+ World_Waypoint_Set(374, 89, -339.22f, 0.22f, -11.33f);
+ World_Waypoint_Set(375, 11, -299.0f, -24.0f, 322.0f);
+ World_Waypoint_Set(376, 11, -215.0f, -24.0f, 322.0f);
+ World_Waypoint_Set(377, 39, 397.6f, 47.76f, -823.23f);
+ World_Waypoint_Set(378, 39, 461.56f, 47.76f, -757.78f);
+ World_Waypoint_Set(379, 18, -260.15f, 12.0f, -19.16f);
+ World_Waypoint_Set(361, 55, -185.0f, -70.19f, -1046.0f);
+ World_Waypoint_Set(362, 55, -121.0f, -70.19f, -778.0f);
+ World_Waypoint_Set(363, 55, -166.0f, -70.19f, -579.0f);
+ World_Waypoint_Set(364, 55, -160.0f, -70.19f, -164.0f);
+ World_Waypoint_Set(365, 55, 3.0f, -70.19f, -986.0f);
+ World_Waypoint_Set(380, 38, 456.43f, 47.76f, -276.05f);
+ World_Waypoint_Set(381, 70, -160.0f, -4.01f, 496.0f);
+ World_Waypoint_Set(382, 70, 0.0f, 1.72f, 60.0f);
+ World_Waypoint_Set(383, 70, 0.0f, 1.72f, -192.0f);
+ World_Waypoint_Set(384, 70, 260.0f, 1.72f, 52.0f);
+ World_Waypoint_Set(385, 33, 489.0f, 9.68f, 74.0f);
+ World_Waypoint_Set(386, 33, -375.0f, 9.68f, 54.0f);
+ World_Waypoint_Set(387, 33, -359.0f, 0.0f, 302.0f);
+ World_Waypoint_Set(388, 20, 215.0f, 0.0f, -122.0f);
+ World_Waypoint_Set(389, 20, -133.0f, 9.04f, 910.0f);
+ World_Waypoint_Set(390, 7, -655.0f, 6.98f, -364.0f);
+ World_Waypoint_Set(391, 7, -795.0f, 6.98f, -352.0f);
+ World_Waypoint_Set(392, 7, -1103.0f, 6.98f, -384.0f);
+ World_Waypoint_Set(393, 7, -1759.0f, -0.04f, 75.0f);
+ World_Waypoint_Set(394, 53, 476.0f, -162.0f, 196.0f);
+ World_Waypoint_Set(395, 53, 120.0f, -162.0f, 148.0f);
+ World_Waypoint_Set(396, 53, 120.0f, -161.0f, -160.0f);
+ World_Waypoint_Set(397, 53, 148.0f, -161.0f, -160.0f);
+ World_Waypoint_Set(398, 54, 324.0f, 31.0f, -1316.0f);
+ World_Waypoint_Set(399, 54, 236.0f, 31.0f, -1316.0f);
+ World_Waypoint_Set(400, 54, 248.0f, 31.0f, -540.0f);
+ World_Waypoint_Set(401, 54, -287.0f, 31.0f, -480.0f);
+ World_Waypoint_Set(402, 54, -331.0f, 31.0f, -620.0f);
+ World_Waypoint_Set(403, 54, -239.0f, 31.0f, -1436.0f);
+ World_Waypoint_Set(404, 54, -411.0f, 31.0f, -1436.0f);
+ World_Waypoint_Set(405, 74, 90.0f, -50.0f, -42.0f);
+ World_Waypoint_Set(406, 74, -106.0f, -50.0f, -2358.0f);
+ World_Waypoint_Set(407, 83, 0.0f, 81.02f, -512.0f);
+ World_Waypoint_Set(408, 83, 0.0f, 1.15f, 400.0f);
+ World_Waypoint_Set(409, 77, -48.0f, -1.74f, -983.0f);
+ World_Waypoint_Set(411, 78, 80.0f, -16.72f, -4.0f);
+ World_Waypoint_Set(412, 78, -48.0f, -11.0f, -352.0f);
+ World_Waypoint_Set(413, 79, -109.0f, 0.0f, 285.0f);
+ World_Waypoint_Set(414, 79, -109.0f, 0.0f, 125.0f);
+ World_Waypoint_Set(415, 80, 198.0f, -12.0f, -282.0f);
+ World_Waypoint_Set(416, 80, 90.0f, -12.0f, -274.0f);
+ World_Waypoint_Set(417, 80, 10.0f, -12.0f, -282.0f);
+ World_Waypoint_Set(418, 80, -106.0f, -12.0f, -746.0f);
+ World_Waypoint_Set(419, 80, -59.0f, -12.0f, -614.0f);
+ World_Waypoint_Set(420, 81, -496.0f, 0.0f, -168.0f);
+ World_Waypoint_Set(421, 81, -341.0f, 0.0f, 248.0f);
+ World_Waypoint_Set(422, 81, -348.0f, 0.0f, -36.0f);
+ World_Waypoint_Set(423, 85, 60.0f, 52.0f, -544.0f);
+ World_Waypoint_Set(424, 85, -552.0f, 141.0f, -1008.0f);
+ World_Waypoint_Set(425, 86, 245.0f, 186.0f, -24.0f);
+ World_Waypoint_Set(426, 86, -287.0f, 12.0f, -148.0f);
+ World_Waypoint_Set(427, 89, -9.0f, 0.0f, 588.0f);
+ World_Waypoint_Set(428, 89, -669.0f, 0.0f, 37.0f);
+ World_Waypoint_Set(429, 13, -796.08f, 0.0f, -184.09f);
+ World_Waypoint_Set(430, 53, -328.0f, -1.62f, 148.0f);
+ World_Waypoint_Set(431, 79, 75.0f, 0.0f, -71.0f);
+ World_Waypoint_Set(432, 79, 63.0f, 153.0f, -467.0f);
+ World_Waypoint_Set(433, 82, 115.0f, 156.0f, -310.0f);
+ World_Waypoint_Set(434, 82, -57.0f, 156.0f, -306.0f);
+ World_Waypoint_Set(435, 82, -121.0f, 156.0f, -426.0f);
+ World_Waypoint_Set(436, 89, -274.74f, 0.0f, 464.75f);
+ World_Waypoint_Set(437, 41, 271.97f, 40.63f, 18.4f);
+ World_Waypoint_Set(438, 41, 203.97f, 40.63f, 18.4f);
+ World_Waypoint_Set(516, 41, -79.01f, 40.63f, 91.01f);
+ World_Waypoint_Set(439, 13, -1273.27f, 0.32f, 126.92f);
+ World_Waypoint_Set(440, 4, -453.0f, -6.5f, 1176.0f);
+ World_Waypoint_Set(441, 4, -497.0f, -6.5f, 1080.0f);
+ World_Waypoint_Set(442, 4, -623.0f, -6.5f, 787.0f);
+ World_Waypoint_Set(443, 4, -436.0f, -6.5f, 765.0f);
+ World_Waypoint_Set(446, 77, 176.0f, 19.31f, -283.0f);
+ World_Waypoint_Set(447, 77, 40.0f, -1.74f, -247.0f);
+ World_Waypoint_Set(448, 77, 24.0f, -6.71f, -179.0f);
+ World_Waypoint_Set(449, 77, 44.0f, -1.74f, 57.0f);
+ World_Waypoint_Set(450, 74, -74.61f, -50.13f, -802.42f);
+ World_Waypoint_Set(451, 74, 141.39f, -50.13f, -802.92f);
+ World_Waypoint_Set(452, 42, -91.5f, 367.93f, 277.84f);
+ World_Waypoint_Set(453, 42, 32.5f, 367.93f, 277.84f);
+ World_Waypoint_Set(454, 42, 216.5f, 367.93f, 265.84f);
+ World_Waypoint_Set(455, 42, 216.5f, 367.93f, 389.84f);
+ World_Waypoint_Set(456, 60, -100.0f, 0.33f, -272.0f);
+ World_Waypoint_Set(462, 60, -119.0f, 0.33f, 77.0f);
+ World_Waypoint_Set(457, 78, 129.65f, 16.72f, -78.36f);
+ World_Waypoint_Set(458, 78, 44.2f, -11.64f, -390.86f);
+ World_Waypoint_Set(459, 78, 103.36f, -16.72f, -484.49f);
+ World_Waypoint_Set(460, 79, 103.0f, 0.0f, 413.0f);
+ World_Waypoint_Set(461, 79, 103.0f, 0.0f, 349.0f);
+ World_Waypoint_Set(467, 13, -585.67f, 0.0f, 380.58f);
+ World_Waypoint_Set(468, 53, -312.0f, -162.8f, 156.0f);
+ World_Waypoint_Set(469, 53, 68.0f, -162.8f, 144.0f);
+ World_Waypoint_Set(470, 53, 100.0f, -162.8f, -100.0f);
+ World_Waypoint_Set(471, 53, 208.0f, -162.8f, -100.0f);
+ World_Waypoint_Set(472, 53, -16.0f, -162.8f, -100.0f);
+ World_Waypoint_Set(473, 7, -667.39f, -0.04f, -28.38f);
+ World_Waypoint_Set(474, 7, -659.0f, 7.18f, -334.0f);
+ World_Waypoint_Set(475, 7, -659.0f, -0.04f, 242.0f);
+ World_Waypoint_Set(476, 7, -2327.0f, -0.04f, 142.0f);
+ World_Waypoint_Set(477, 75, -97.24f, 84.13f, -69.94f);
+ World_Waypoint_Set(478, 75, -97.24f, 74.87f, -509.94f);
+ World_Waypoint_Set(479, 74, -134.0f, -50.13f, -250.41f);
+ World_Waypoint_Set(480, 74, 17.01f, -50.13f, -2355.41f);
+ World_Waypoint_Set(481, 83, -193.5f, 1.15f, 29.0f);
+ World_Waypoint_Set(482, 83, -329.5f, 1.15f, 29.0f);
+ World_Waypoint_Set(483, 83, -329.5f, 1.15f, -379.0f);
+ World_Waypoint_Set(488, 74, 22.0f, -50.13f, -650.0f);
+ World_Waypoint_Set(489, 74, -14.0f, -50.13f, -2354.0f);
+ World_Waypoint_Set(490, 54, -360.0f, 31.55f, -1457.0f);
+ World_Waypoint_Set(491, 54, 308.0f, 31.66f, -1457.0f);
+ World_Waypoint_Set(492, 54, -72.0f, 23.88f, -1445.0f);
+ World_Waypoint_Set(493, 54, 76.0f, 23.88f, -1333.0f);
+ World_Waypoint_Set(494, 54, -236.0f, 31.55f, -337.0f);
+ World_Waypoint_Set(495, 11, -275.0f, -24.0f, 42.0f);
+ World_Waypoint_Set(496, 11, 185.0f, -24.0f, 42.0f);
+ World_Waypoint_Set(497, 55, -250.0f, -70.19f, -639.0f);
+ World_Waypoint_Set(498, 55, 454.0f, -70.19f, -667.0f);
+ World_Waypoint_Set(499, 13, -573.43f, 0.0f, -635.5f);
+ World_Waypoint_Set(500, 13, -625.43f, 0.0f, -635.5f);
+ World_Waypoint_Set(501, 56, -215.08f, -71.88f, 150.86f);
+ World_Waypoint_Set(502, 56, 60.92f, -71.88f, -29.14f);
+ World_Waypoint_Set(503, 13, -1417.36f, 0.32f, 149.18f);
+ World_Waypoint_Set(504, 13, -1512.0f, 0.32f, 323.0f);
+ World_Waypoint_Set(505, 13, -1813.36f, 0.32f, 325.18f);
+ World_Waypoint_Set(506, 59, -24.78f, 2.84f, -182.43f);
+ World_Waypoint_Set(507, 59, -200.78f, 2.84f, -282.43f);
+ World_Waypoint_Set(508, 37, 579.54f, -0.01f, -380.98f);
+ World_Waypoint_Set(509, 37, 307.54f, 8.0f, -752.98f);
+ World_Waypoint_Set(510, 37, 124.0f, 8.0f, -888.0f);
+ World_Waypoint_Set(511, 37, 124.0f, 8.0f, -244.0f);
+ World_Waypoint_Set(512, 38, -25.54f, 47.76f, -321.98f);
+ World_Waypoint_Set(513, 38, 446.46f, 47.76f, -509.98f);
+ World_Waypoint_Set(514, 39, 567.0f, 47.76f, -884.0f);
+ World_Waypoint_Set(515, 39, 203.0f, 47.76f, -880.0f);
+ World_Waypoint_Set(517, 40, 1246.62f, -0.31f, -171.02f);
+ World_Waypoint_Set(518, 40, -72.89f, -0.31f, -154.77f);
+ World_Waypoint_Set(519, 40, 285.88f, -0.31f, -134.49f);
+ World_Waypoint_Set(520, 40, 231.31f, -0.31f, 266.36f);
+ World_Waypoint_Set(521, 40, 482.02f, -0.31f, -661.24f);
+ World_Waypoint_Set(522, 40, 1183.98f, -0.31f, -176.25f);
+ World_Waypoint_Set(523, 40, -45.0f, -0.34f, -351.0f);
+ World_Waypoint_Set(530, 44, 36.79f, -12.2f, -534.54f);
+ World_Waypoint_Set(531, 44, -279.21f, -12.2f, -594.54f);
+ World_Waypoint_Set(532, 86, -76.51f, 129.0f, -748.49f);
+ World_Waypoint_Set(533, 86, -48.51f, 129.0f, -676.49f);
+ World_Waypoint_Set(534, 86, -176.51f, 129.0f, -504.49f);
+ World_Waypoint_Set(535, 86, 111.49f, 129.0f, -504.49f);
+ World_Waypoint_Set(536, 86, -296.51f, 12.97f, -300.49f);
+ World_Waypoint_Set(537, 86, -220.51f, 12.97f, -184.49f);
+ World_Waypoint_Set(538, 86, -40.51f, 12.97f, -148.49f);
+ World_Waypoint_Set(539, 80, 190.0f, 12.0f, -282.0f);
+ World_Waypoint_Set(540, 9, -934.24f, 0.0f, 807.77f);
+ World_Waypoint_Set(541, 9, -1147.2f, 0.0f, 893.18f);
+ World_Waypoint_Set(542, 9, -1098.4f, 8.26f, -312.12f);
+ World_Waypoint_Set(543, 9, -1046.4f, 8.26f, -312.12f);
+ World_Waypoint_Set(544, 74, 111.72f, -50.13f, -490.46f);
+ World_Waypoint_Set(545, 74, -143.86f, 490.46f, -300.38f);
+ World_Waypoint_Set(550, 9, -785.31f, 0.0f, -237.05f);
+ World_Waypoint_Set(551, 9, -737.31f, 0.0f, -145.05f);
+ World_Waypoint_Set(324, 22, 267.0f, -60.3f, 203.0f);
+ World_Waypoint_Set(325, 22, 84.0f, -60.3f, 337.0f);
+ World_Waypoint_Set(326, 2, -36.0f, 0.0f, 185.0f);
+ World_Waypoint_Set(327, 2, -166.0f, 0.0f, -103.0f);
+ World_Waypoint_Set(328, 3, -556.0f, 252.59f, -1018.11f);
+ World_Waypoint_Set(329, 3, -655.0f, 252.6f, -1012.0f);
+ World_Waypoint_Set(330, 3, -657.0f, 253.0f, -1127.0f);
+ World_Waypoint_Set(331, 102, 163.8f, 0.0f, 67.0f);
+ World_Waypoint_Set(332, 2, -39.0f, 0.0f, 11.5f);
+ World_Waypoint_Set(333, 102, -34.0f, 0.0f, 33.0f);
+ World_Waypoint_Set(334, 22, 3.0f, -60.3f, -144.0f);
+ World_Waypoint_Set(335, 102, -50.0f, 0.0f, 212.0f);
}
void ScriptInit::Init_SDB() {
-
+ SDB_Set_Actor(0, 8);
+ SDB_Set_Sex(0, 1);
+ SDB_Add_MO_Clue(0, 52);
+ SDB_Add_MO_Clue(0, 49);
+ SDB_Add_MO_Clue(0, 48);
+ SDB_Add_MO_Clue(0, 261);
+ SDB_Add_Whereabouts_Clue(0, 45);
+ SDB_Add_Whereabouts_Clue(0, 53);
+ SDB_Add_Whereabouts_Clue(0, 44);
+ SDB_Add_Whereabouts_Clue(0, 67);
+ SDB_Add_Whereabouts_Clue(0, 122);
+ SDB_Add_Replicant_Clue(0, 49);
+ SDB_Add_Replicant_Clue(0, 52);
+ SDB_Add_Replicant_Clue(0, 68);
+ SDB_Add_Replicant_Clue(0, 51);
+ SDB_Add_Replicant_Clue(0, 269);
+ SDB_Add_Replicant_Clue(0, 278);
+ SDB_Add_Replicant_Clue(0, 52);
+ SDB_Add_Non_Replicant_Clue(0, 74);
+ SDB_Add_Non_Replicant_Clue(0, 61);
+ SDB_Add_Non_Replicant_Clue(0, 270);
+ SDB_Add_Other_Clue(0, 180);
+ SDB_Add_Other_Clue(0, 181);
+ SDB_Add_Other_Clue(0, 266);
+ SDB_Add_Other_Clue(0, 47);
+ SDB_Add_Other_Clue(0, 277);
+ SDB_Add_Identity_Clue(0, 266);
+ SDB_Add_Photo_Clue(0, 47, 31);
+ SDB_Add_Photo_Clue(0, 277, 38);
+ SDB_Set_Actor(1, 5);
+ SDB_Set_Sex(1, 1);
+ SDB_Add_MO_Clue(1, 5);
+ SDB_Add_MO_Clue(1, 11);
+ SDB_Add_Whereabouts_Clue(1, 40);
+ SDB_Add_Whereabouts_Clue(1, 29);
+ SDB_Add_Whereabouts_Clue(1, 67);
+ SDB_Add_Replicant_Clue(1, 0);
+ SDB_Add_Replicant_Clue(1, 2);
+ SDB_Add_Replicant_Clue(1, 68);
+ SDB_Add_Replicant_Clue(1, 156);
+ SDB_Add_Replicant_Clue(1, 157);
+ SDB_Add_Replicant_Clue(1, 107);
+ SDB_Add_Other_Clue(1, 243);
+ SDB_Add_Other_Clue(1, 4);
+ SDB_Add_Other_Clue(1, 61);
+ SDB_Add_Other_Clue(1, 266);
+ SDB_Add_Other_Clue(1, 276);
+ SDB_Add_Other_Clue(1, 243);
+ SDB_Add_Other_Clue(1, 77);
+ SDB_Add_Other_Clue(1, 244);
+ SDB_Add_Identity_Clue(1, 61);
+ SDB_Add_Identity_Clue(1, 266);
+ SDB_Add_Identity_Clue(1, 107);
+ SDB_Add_Photo_Clue(1, 276, 37);
+ SDB_Add_Photo_Clue(1, 243, 7);
+ SDB_Add_Photo_Clue(1, 77, 25);
+ SDB_Add_Photo_Clue(1, 244, 8);
+ SDB_Set_Actor(2, 19);
+ SDB_Set_Sex(2, 1);
+ SDB_Add_MO_Clue(2, 0);
+ SDB_Add_MO_Clue(2, 10);
+ SDB_Add_Whereabouts_Clue(2, 40);
+ SDB_Add_Whereabouts_Clue(2, 29);
+ SDB_Add_Replicant_Clue(2, 0);
+ SDB_Add_Replicant_Clue(2, 2);
+ SDB_Add_Replicant_Clue(2, 25);
+ SDB_Add_Replicant_Clue(2, 18);
+ SDB_Add_Replicant_Clue(2, 20);
+ SDB_Add_Replicant_Clue(2, 156);
+ SDB_Add_Replicant_Clue(2, 157);
+ SDB_Add_Non_Replicant_Clue(2, 3);
+ SDB_Add_Non_Replicant_Clue(2, 21);
+ SDB_Add_Non_Replicant_Clue(2, 158);
+ SDB_Add_Other_Clue(2, 16);
+ SDB_Add_Other_Clue(2, 19);
+ SDB_Add_Other_Clue(2, 273);
+ SDB_Add_Identity_Clue(2, 25);
+ SDB_Add_Identity_Clue(2, 18);
+ SDB_Add_Identity_Clue(2, 19);
+ SDB_Add_Identity_Clue(2, 273);
+ SDB_Add_Photo_Clue(2, 20, 33);
+ SDB_Set_Actor(3, 6);
+ SDB_Set_Sex(3, 0);
+ SDB_Add_Whereabouts_Clue(3, 8);
+ SDB_Add_Whereabouts_Clue(3, 9);
+ SDB_Add_Whereabouts_Clue(3, 15);
+ SDB_Add_Whereabouts_Clue(3, 28);
+ SDB_Add_Whereabouts_Clue(3, 84);
+ SDB_Add_Whereabouts_Clue(3, 19);
+ SDB_Add_Replicant_Clue(3, 22);
+ SDB_Add_Replicant_Clue(3, 23);
+ SDB_Add_Replicant_Clue(3, 271);
+ SDB_Add_Replicant_Clue(3, 156);
+ SDB_Add_Replicant_Clue(3, 107);
+ SDB_Add_Replicant_Clue(3, 280);
+ SDB_Add_Non_Replicant_Clue(3, 7);
+ SDB_Add_Non_Replicant_Clue(3, 85);
+ SDB_Add_Non_Replicant_Clue(3, 6);
+ SDB_Add_Non_Replicant_Clue(3, 272);
+ SDB_Add_Non_Replicant_Clue(3, 157);
+ SDB_Add_Other_Clue(3, 13);
+ SDB_Add_Other_Clue(3, 16);
+ SDB_Add_Identity_Clue(3, 22);
+ SDB_Add_Identity_Clue(3, 107);
+ SDB_Add_Photo_Clue(3, 13, 5);
+ SDB_Set_Actor(4, 3);
+ SDB_Add_MO_Clue(4, 252);
+ SDB_Add_Replicant_Clue(4, 162);
+ SDB_Add_Replicant_Clue(4, 92);
+ SDB_Add_Replicant_Clue(4, 91);
+ SDB_Add_Replicant_Clue(4, 107);
+ SDB_Add_Non_Replicant_Clue(4, 163);
+ SDB_Add_Non_Replicant_Clue(4, 96);
+ SDB_Add_Non_Replicant_Clue(4, 97);
+ SDB_Add_Non_Replicant_Clue(4, 98);
+ SDB_Add_Non_Replicant_Clue(4, 94);
+ SDB_Add_Other_Clue(4, 91);
+ SDB_Add_Other_Clue(4, 251);
+ SDB_Add_Other_Clue(4, 260);
+ SDB_Add_Other_Clue(4, 113);
+ SDB_Add_Identity_Clue(4, 96);
+ SDB_Add_Identity_Clue(4, 97);
+ SDB_Add_Identity_Clue(4, 92);
+ SDB_Add_Photo_Clue(4, 251, 21);
+ SDB_Add_Photo_Clue(4, 260, 19);
+ SDB_Set_Actor(5, 2);
+ SDB_Set_Sex(5, 1);
+ SDB_Add_Whereabouts_Clue(5, 102);
+ SDB_Add_Identity_Clue(5, 69);
+ SDB_Add_Identity_Clue(5, 70);
+ SDB_Set_Actor(6, 7);
+ SDB_Set_Sex(6, 1);
+ SDB_Add_Whereabouts_Clue(6, 58);
+ SDB_Add_Whereabouts_Clue(6, 59);
+ SDB_Add_Whereabouts_Clue(6, 181);
+ SDB_Add_Whereabouts_Clue(6, 122);
+ SDB_Add_Replicant_Clue(6, 63);
+ SDB_Add_Other_Clue(6, 180);
+ SDB_Add_Other_Clue(6, 66);
+ SDB_Add_Other_Clue(6, 125);
+ SDB_Add_Other_Clue(6, 121);
+ SDB_Add_Other_Clue(6, 255);
+ SDB_Add_Other_Clue(6, 246);
+ SDB_Add_Other_Clue(6, 247);
+ SDB_Add_Other_Clue(6, 62);
+ SDB_Add_Other_Clue(6, 60);
+ SDB_Add_Identity_Clue(6, 181);
+ SDB_Add_Identity_Clue(6, 58);
+ SDB_Add_Identity_Clue(6, 59);
+ SDB_Add_Identity_Clue(6, 246);
+ SDB_Add_Identity_Clue(6, 247);
+ SDB_Add_Identity_Clue(6, 62);
+ SDB_Add_Identity_Clue(6, 60);
+ SDB_Add_Photo_Clue(6, 255, 26);
+ SDB_Set_Actor(7, 0);
+ SDB_Add_Replicant_Clue(7, 275);
+ SDB_Add_Other_Clue(7, 246);
+ SDB_Add_Other_Clue(7, 247);
+ SDB_Add_Identity_Clue(7, 275);
+ SDB_Add_Photo_Clue(7, 275, 36);
+ SDB_Add_Photo_Clue(7, 246, 17);
+ SDB_Add_Photo_Clue(7, 247, 18);
+ SDB_Set_Actor(8, 4);
+ SDB_Add_Other_Clue(8, 256);
+ SDB_Add_Other_Clue(8, 125);
+ SDB_Add_Other_Clue(8, 126);
+ SDB_Add_Identity_Clue(8, 256);
+ SDB_Add_Identity_Clue(8, 126);
+ SDB_Add_Identity_Clue(8, 125);
+ SDB_Add_Photo_Clue(8, 256, 27);
}
void ScriptInit::Init_CDB() {
-
+ CDB_Set_Crime(0, 0);
+ CDB_Set_Crime(1, 0);
+ CDB_Set_Crime(2, 0);
+ CDB_Set_Crime(3, 0);
+ CDB_Set_Crime(4, 0);
+ CDB_Set_Crime(5, 0);
+ CDB_Set_Crime(6, 0);
+ CDB_Set_Crime(7, 0);
+ CDB_Set_Crime(8, 0);
+ CDB_Set_Crime(9, 0);
+ CDB_Set_Crime(10, 0);
+ CDB_Set_Crime(11, 0);
+ CDB_Set_Crime(12, 0);
+ CDB_Set_Crime(15, 0);
+ CDB_Set_Crime(16, 0);
+ CDB_Set_Crime(17, 0);
+ CDB_Set_Crime(22, 0);
+ CDB_Set_Crime(23, 0);
+ CDB_Set_Crime(24, 0);
+ CDB_Set_Crime(26, 0);
+ CDB_Set_Crime(27, 0);
+ CDB_Set_Crime(28, 0);
+ CDB_Set_Crime(29, 0);
+ CDB_Set_Crime(30, 0);
+ CDB_Set_Crime(37, 0);
+ CDB_Set_Crime(31, 0);
+ CDB_Set_Crime(39, 0);
+ CDB_Set_Crime(243, 0);
+ CDB_Set_Crime(244, 0);
+ CDB_Set_Crime(273, 0);
+ CDB_Set_Crime(113, 0);
+ CDB_Set_Crime(114, 0);
+ CDB_Set_Crime(115, 0);
+ CDB_Set_Crime(19, 0);
+ CDB_Set_Crime(13, 0);
+ CDB_Set_Crime(14, 0);
+ CDB_Set_Crime(20, 0);
+ CDB_Set_Crime(43, 1);
+ CDB_Set_Crime(44, 1);
+ CDB_Set_Crime(45, 1);
+ CDB_Set_Crime(46, 1);
+ CDB_Set_Crime(49, 1);
+ CDB_Set_Crime(50, 1);
+ CDB_Set_Crime(51, 1);
+ CDB_Set_Crime(53, 1);
+ CDB_Set_Crime(54, 1);
+ CDB_Set_Crime(55, 1);
+ CDB_Set_Crime(65, 1);
+ CDB_Set_Crime(278, 1);
+ CDB_Set_Crime(279, 1);
+ CDB_Set_Crime(47, 1);
+ CDB_Set_Crime(262, 1);
+ CDB_Set_Crime(263, 1);
+ CDB_Set_Crime(261, 1);
+ CDB_Set_Crime(259, 1);
+ CDB_Set_Crime(33, 8);
+ CDB_Set_Crime(86, 8);
+ CDB_Set_Crime(275, 8);
+ CDB_Set_Crime(276, 8);
+ CDB_Set_Crime(277, 8);
+ CDB_Set_Crime(271, 8);
+ CDB_Set_Crime(52, 8);
+ CDB_Set_Crime(144, 8);
+ CDB_Set_Crime(178, 5);
+ CDB_Set_Crime(179, 5);
+ CDB_Set_Crime(180, 5);
+ CDB_Set_Crime(181, 5);
+ CDB_Set_Crime(68, 3);
+ CDB_Set_Crime(269, 3);
+ CDB_Set_Crime(270, 3);
+ CDB_Set_Crime(66, 2);
+ CDB_Set_Crime(125, 2);
+ CDB_Set_Crime(121, 2);
+ CDB_Set_Crime(122, 2);
+ CDB_Set_Crime(123, 2);
+ CDB_Set_Crime(124, 2);
+ CDB_Set_Crime(128, 2);
+ CDB_Set_Crime(83, 2);
+ CDB_Set_Crime(125, 2);
+ CDB_Set_Crime(126, 2);
+ CDB_Set_Crime(74, 4);
+ CDB_Set_Crime(266, 4);
+ int i = 0;
+ do {
+ CDB_Set_Clue_Asset_Type(i++, -1);
+ } while (i < 288);
+ CDB_Set_Clue_Asset_Type(0, 2);
+ CDB_Set_Clue_Asset_Type(2, 2);
+ CDB_Set_Clue_Asset_Type(3, 2);
+ CDB_Set_Clue_Asset_Type(4, 2);
+ CDB_Set_Clue_Asset_Type(5, 3);
+ CDB_Set_Clue_Asset_Type(6, 3);
+ CDB_Set_Clue_Asset_Type(7, 3);
+ CDB_Set_Clue_Asset_Type(8, 3);
+ CDB_Set_Clue_Asset_Type(9, 0);
+ CDB_Set_Clue_Asset_Type(10, 2);
+ CDB_Set_Clue_Asset_Type(11, 2);
+ CDB_Set_Clue_Asset_Type(12, 1);
+ CDB_Set_Clue_Asset_Type(13, 0);
+ CDB_Set_Clue_Asset_Type(14, 0);
+ CDB_Set_Clue_Asset_Type(15, 3);
+ CDB_Set_Clue_Asset_Type(16, 2);
+ CDB_Set_Clue_Asset_Type(17, 2);
+ CDB_Set_Clue_Asset_Type(19, 2);
+ CDB_Set_Clue_Asset_Type(20, 0);
+ CDB_Set_Clue_Asset_Type(21, 2);
+ CDB_Set_Clue_Asset_Type(22, 2);
+ CDB_Set_Clue_Asset_Type(23, 2);
+ CDB_Set_Clue_Asset_Type(24, 2);
+ CDB_Set_Clue_Asset_Type(25, 2);
+ CDB_Set_Clue_Asset_Type(26, 2);
+ CDB_Set_Clue_Asset_Type(27, 3);
+ CDB_Set_Clue_Asset_Type(28, 0);
+ CDB_Set_Clue_Asset_Type(29, 0);
+ CDB_Set_Clue_Asset_Type(30, 0);
+ CDB_Set_Clue_Asset_Type(31, 0);
+ CDB_Set_Clue_Asset_Type(32, 3);
+ CDB_Set_Clue_Asset_Type(33, 2);
+ CDB_Set_Clue_Asset_Type(34, -1);
+ CDB_Set_Clue_Asset_Type(35, -1);
+ CDB_Set_Clue_Asset_Type(36, 0);
+ CDB_Set_Clue_Asset_Type(37, 3);
+ CDB_Set_Clue_Asset_Type(39, 2);
+ CDB_Set_Clue_Asset_Type(40, 2);
+ CDB_Set_Clue_Asset_Type(41, 0);
+ CDB_Set_Clue_Asset_Type(43, 2);
+ CDB_Set_Clue_Asset_Type(44, 3);
+ CDB_Set_Clue_Asset_Type(45, 1);
+ CDB_Set_Clue_Asset_Type(46, 2);
+ CDB_Set_Clue_Asset_Type(47, 0);
+ CDB_Set_Clue_Asset_Type(48, 0);
+ CDB_Set_Clue_Asset_Type(49, 3);
+ CDB_Set_Clue_Asset_Type(50, 2);
+ CDB_Set_Clue_Asset_Type(51, 2);
+ CDB_Set_Clue_Asset_Type(52, 2);
+ CDB_Set_Clue_Asset_Type(53, 3);
+ CDB_Set_Clue_Asset_Type(54, 3);
+ CDB_Set_Clue_Asset_Type(55, 3);
+ CDB_Set_Clue_Asset_Type(56, 2);
+ CDB_Set_Clue_Asset_Type(57, 2);
+ CDB_Set_Clue_Asset_Type(58, 2);
+ CDB_Set_Clue_Asset_Type(59, 2);
+ CDB_Set_Clue_Asset_Type(60, 2);
+ CDB_Set_Clue_Asset_Type(61, 2);
+ CDB_Set_Clue_Asset_Type(62, 3);
+ CDB_Set_Clue_Asset_Type(63, 2);
+ CDB_Set_Clue_Asset_Type(64, 2);
+ CDB_Set_Clue_Asset_Type(65, 3);
+ CDB_Set_Clue_Asset_Type(66, 2);
+ CDB_Set_Clue_Asset_Type(67, 2);
+ CDB_Set_Clue_Asset_Type(68, 2);
+ CDB_Set_Clue_Asset_Type(69, 2);
+ CDB_Set_Clue_Asset_Type(70, 2);
+ CDB_Set_Clue_Asset_Type(71, 2);
+ CDB_Set_Clue_Asset_Type(72, 2);
+ CDB_Set_Clue_Asset_Type(74, 2);
+ CDB_Set_Clue_Asset_Type(75, 3);
+ CDB_Set_Clue_Asset_Type(76, 3);
+ CDB_Set_Clue_Asset_Type(77, 0);
+ CDB_Set_Clue_Asset_Type(78, 0);
+ CDB_Set_Clue_Asset_Type(79, 2);
+ CDB_Set_Clue_Asset_Type(80, 3);
+ CDB_Set_Clue_Asset_Type(81, 3);
+ CDB_Set_Clue_Asset_Type(84, 3);
+ CDB_Set_Clue_Asset_Type(85, 3);
+ CDB_Set_Clue_Asset_Type(86, 0);
+ CDB_Set_Clue_Asset_Type(87, 3);
+ CDB_Set_Clue_Asset_Type(88, 0);
+ CDB_Set_Clue_Asset_Type(89, 1);
+ CDB_Set_Clue_Asset_Type(93, 3);
+ CDB_Set_Clue_Asset_Type(94, 2);
+ CDB_Set_Clue_Asset_Type(96, 2);
+ CDB_Set_Clue_Asset_Type(97, 2);
+ CDB_Set_Clue_Asset_Type(98, 3);
+ CDB_Set_Clue_Asset_Type(99, 3);
+ CDB_Set_Clue_Asset_Type(100, 3);
+ CDB_Set_Clue_Asset_Type(101, 2);
+ CDB_Set_Clue_Asset_Type(102, 2);
+ CDB_Set_Clue_Asset_Type(103, 2);
+ CDB_Set_Clue_Asset_Type(104, 2);
+ CDB_Set_Clue_Asset_Type(105, 3);
+ CDB_Set_Clue_Asset_Type(106, 3);
+ CDB_Set_Clue_Asset_Type(107, 2);
+ CDB_Set_Clue_Asset_Type(108, 2);
+ CDB_Set_Clue_Asset_Type(109, 3);
+ CDB_Set_Clue_Asset_Type(110, 3);
+ CDB_Set_Clue_Asset_Type(112, 2);
+ CDB_Set_Clue_Asset_Type(113, 2);
+ CDB_Set_Clue_Asset_Type(114, 2);
+ CDB_Set_Clue_Asset_Type(115, 2);
+ CDB_Set_Clue_Asset_Type(116, 2);
+ CDB_Set_Clue_Asset_Type(117, 2);
+ CDB_Set_Clue_Asset_Type(118, 3);
+ CDB_Set_Clue_Asset_Type(119, 3);
+ CDB_Set_Clue_Asset_Type(120, 2);
+ CDB_Set_Clue_Asset_Type(121, 2);
+ CDB_Set_Clue_Asset_Type(122, 2);
+ CDB_Set_Clue_Asset_Type(123, 2);
+ CDB_Set_Clue_Asset_Type(124, 2);
+ CDB_Set_Clue_Asset_Type(126, 2);
+ CDB_Set_Clue_Asset_Type(127, 3);
+ CDB_Set_Clue_Asset_Type(128, 3);
+ CDB_Set_Clue_Asset_Type(129, 3);
+ CDB_Set_Clue_Asset_Type(131, 3);
+ CDB_Set_Clue_Asset_Type(133, 2);
+ CDB_Set_Clue_Asset_Type(134, 2);
+ CDB_Set_Clue_Asset_Type(135, 2);
+ CDB_Set_Clue_Asset_Type(136, 2);
+ CDB_Set_Clue_Asset_Type(137, 0);
+ CDB_Set_Clue_Asset_Type(138, 0);
+ CDB_Set_Clue_Asset_Type(139, 2);
+ CDB_Set_Clue_Asset_Type(140, 2);
+ CDB_Set_Clue_Asset_Type(141, 2);
+ CDB_Set_Clue_Asset_Type(142, 2);
+ CDB_Set_Clue_Asset_Type(143, 2);
+ CDB_Set_Clue_Asset_Type(144, 2);
+ CDB_Set_Clue_Asset_Type(145, 3);
+ CDB_Set_Clue_Asset_Type(146, 3);
+ CDB_Set_Clue_Asset_Type(178, 2);
+ CDB_Set_Clue_Asset_Type(179, 2);
+ CDB_Set_Clue_Asset_Type(180, 2);
+ CDB_Set_Clue_Asset_Type(181, 2);
+ CDB_Set_Clue_Asset_Type(147, 3);
+ CDB_Set_Clue_Asset_Type(148, 3);
+ CDB_Set_Clue_Asset_Type(149, 3);
+ CDB_Set_Clue_Asset_Type(150, 3);
+ CDB_Set_Clue_Asset_Type(151, 3);
+ CDB_Set_Clue_Asset_Type(152, 3);
+ CDB_Set_Clue_Asset_Type(243, 0);
+ CDB_Set_Clue_Asset_Type(244, 0);
+ CDB_Set_Clue_Asset_Type(245, 0);
+ CDB_Set_Clue_Asset_Type(246, 0);
+ CDB_Set_Clue_Asset_Type(247, 0);
+ CDB_Set_Clue_Asset_Type(248, 0);
+ CDB_Set_Clue_Asset_Type(249, 0);
+ CDB_Set_Clue_Asset_Type(250, 0);
+ CDB_Set_Clue_Asset_Type(251, 0);
+ CDB_Set_Clue_Asset_Type(252, 0);
+ CDB_Set_Clue_Asset_Type(253, 0);
+ CDB_Set_Clue_Asset_Type(254, 0);
+ CDB_Set_Clue_Asset_Type(255, 0);
+ CDB_Set_Clue_Asset_Type(256, 0);
+ CDB_Set_Clue_Asset_Type(257, 1);
+ CDB_Set_Clue_Asset_Type(258, 0);
+ CDB_Set_Clue_Asset_Type(259, 0);
+ CDB_Set_Clue_Asset_Type(260, 0);
+ CDB_Set_Clue_Asset_Type(261, 0);
+ CDB_Set_Clue_Asset_Type(262, 0);
+ CDB_Set_Clue_Asset_Type(263, 0);
+ CDB_Set_Clue_Asset_Type(264, 3);
+ CDB_Set_Clue_Asset_Type(265, 3);
+ CDB_Set_Clue_Asset_Type(269, 2);
+ CDB_Set_Clue_Asset_Type(270, 2);
+ CDB_Set_Clue_Asset_Type(271, 2);
+ CDB_Set_Clue_Asset_Type(272, 2);
+ CDB_Set_Clue_Asset_Type(162, 2);
+ CDB_Set_Clue_Asset_Type(163, 2);
+ CDB_Set_Clue_Asset_Type(164, 2);
+ CDB_Set_Clue_Asset_Type(165, 2);
+ CDB_Set_Clue_Asset_Type(168, 2);
+ CDB_Set_Clue_Asset_Type(169, 2);
+ CDB_Set_Clue_Asset_Type(174, 2);
+ CDB_Set_Clue_Asset_Type(175, 2);
+ CDB_Set_Clue_Asset_Type(273, 2);
+ CDB_Set_Clue_Asset_Type(274, 0);
+ CDB_Set_Clue_Asset_Type(275, 0);
+ CDB_Set_Clue_Asset_Type(276, 0);
+ CDB_Set_Clue_Asset_Type(277, 0);
+ CDB_Set_Clue_Asset_Type(156, 2);
+ CDB_Set_Clue_Asset_Type(157, 2);
+ CDB_Set_Clue_Asset_Type(158, 2);
+ CDB_Set_Clue_Asset_Type(278, 2);
+ CDB_Set_Clue_Asset_Type(279, 2);
+ CDB_Set_Clue_Asset_Type(280, 2);
+ CDB_Set_Clue_Asset_Type(283, 2);
+ CDB_Set_Clue_Asset_Type(284, 2);
+ CDB_Set_Clue_Asset_Type(285, 2);
+ CDB_Set_Clue_Asset_Type(286, 2);
+ CDB_Set_Clue_Asset_Type(287, 2);
+ CDB_Set_Clue_Asset_Type(125, 3);
}
void ScriptInit::Init_Spinner() {
-
+ Spinner_Set_Selectable_Destination_Flag(0, 1);
+ Spinner_Set_Selectable_Destination_Flag(1, 1);
+ Spinner_Set_Selectable_Destination_Flag(2, 1);
+ Spinner_Set_Selectable_Destination_Flag(3, 0);
+ Spinner_Set_Selectable_Destination_Flag(4, 0);
+ Spinner_Set_Selectable_Destination_Flag(5, 0);
+ Spinner_Set_Selectable_Destination_Flag(6, 0);
+ Spinner_Set_Selectable_Destination_Flag(7, 0);
+ Spinner_Set_Selectable_Destination_Flag(8, 0);
+ Spinner_Set_Selectable_Destination_Flag(9, 0);
}
void ScriptInit::Init_Actor_Friendliness() {
-
+ Actor_Set_Friendliness_To_Other(1, 0, 65);
+ Actor_Set_Friendliness_To_Other(1, 4, 60);
+ Actor_Set_Friendliness_To_Other(1, 11, 30);
+ Actor_Set_Friendliness_To_Other(1, 15, 35);
+ Actor_Set_Friendliness_To_Other(1, 23, 65);
+ Actor_Set_Friendliness_To_Other(1, 24, 65);
+ Actor_Set_Friendliness_To_Other(1, 28, 70);
+ Actor_Set_Friendliness_To_Other(1, 30, 65);
+ Actor_Set_Friendliness_To_Other(1, 34, 80);
+ Actor_Set_Friendliness_To_Other(1, 53, 65);
+ Actor_Set_Friendliness_To_Other(2, 1, 45);
+ Actor_Set_Friendliness_To_Other(2, 4, 65);
+ Actor_Set_Friendliness_To_Other(2, 11, 70);
+ Actor_Set_Friendliness_To_Other(2, 12, 75);
+ Actor_Set_Friendliness_To_Other(2, 15, 30);
+ Actor_Set_Friendliness_To_Other(2, 19, 80);
+ Actor_Set_Friendliness_To_Other(2, 23, 40);
+ Actor_Set_Friendliness_To_Other(2, 24, 40);
+ Actor_Set_Friendliness_To_Other(2, 28, 70);
+ Actor_Set_Friendliness_To_Other(2, 53, 40);
+ Actor_Set_Friendliness_To_Other(4, 1, 75);
+ Actor_Set_Friendliness_To_Other(4, 2, 70);
+ Actor_Set_Friendliness_To_Other(4, 11, 40);
+ Actor_Set_Friendliness_To_Other(4, 12, 55);
+ Actor_Set_Friendliness_To_Other(4, 15, 40);
+ Actor_Set_Friendliness_To_Other(4, 19, 45);
+ Actor_Set_Friendliness_To_Other(4, 23, 55);
+ Actor_Set_Friendliness_To_Other(4, 24, 55);
+ Actor_Set_Friendliness_To_Other(4, 28, 60);
+ Actor_Set_Friendliness_To_Other(4, 30, 60);
+ Actor_Set_Friendliness_To_Other(4, 34, 60);
+ Actor_Set_Friendliness_To_Other(4, 53, 65);
+ Actor_Set_Friendliness_To_Other(5, 0, 63);
+ Actor_Set_Friendliness_To_Other(6, 0, 50);
+ Actor_Set_Friendliness_To_Other(11, 1, 30);
+ Actor_Set_Friendliness_To_Other(11, 2, 70);
+ Actor_Set_Friendliness_To_Other(11, 4, 30);
+ Actor_Set_Friendliness_To_Other(11, 12, 55);
+ Actor_Set_Friendliness_To_Other(11, 15, 60);
+ Actor_Set_Friendliness_To_Other(11, 19, 70);
+ Actor_Set_Friendliness_To_Other(11, 23, 30);
+ Actor_Set_Friendliness_To_Other(11, 24, 30);
+ Actor_Set_Friendliness_To_Other(11, 28, 65);
+ Actor_Set_Friendliness_To_Other(11, 53, 30);
+ Actor_Set_Friendliness_To_Other(12, 2, 75);
+ Actor_Set_Friendliness_To_Other(12, 4, 40);
+ Actor_Set_Friendliness_To_Other(12, 11, 35);
+ Actor_Set_Friendliness_To_Other(12, 15, 40);
+ Actor_Set_Friendliness_To_Other(12, 19, 65);
+ Actor_Set_Friendliness_To_Other(12, 23, 40);
+ Actor_Set_Friendliness_To_Other(12, 24, 40);
+ Actor_Set_Friendliness_To_Other(12, 28, 70);
+ Actor_Set_Friendliness_To_Other(12, 53, 45);
+ Actor_Set_Friendliness_To_Other(15, 1, 55);
+ Actor_Set_Friendliness_To_Other(15, 2, 40);
+ Actor_Set_Friendliness_To_Other(15, 4, 40);
+ Actor_Set_Friendliness_To_Other(15, 11, 35);
+ Actor_Set_Friendliness_To_Other(15, 12, 40);
+ Actor_Set_Friendliness_To_Other(15, 19, 40);
+ Actor_Set_Friendliness_To_Other(15, 23, 60);
+ Actor_Set_Friendliness_To_Other(15, 24, 60);
+ Actor_Set_Friendliness_To_Other(15, 28, 65);
+ Actor_Set_Friendliness_To_Other(15, 53, 65);
+ Actor_Set_Friendliness_To_Other(19, 1, 45);
+ Actor_Set_Friendliness_To_Other(19, 2, 90);
+ Actor_Set_Friendliness_To_Other(19, 4, 55);
+ Actor_Set_Friendliness_To_Other(19, 11, 65);
+ Actor_Set_Friendliness_To_Other(19, 12, 60);
+ Actor_Set_Friendliness_To_Other(19, 15, 35);
+ Actor_Set_Friendliness_To_Other(19, 23, 35);
+ Actor_Set_Friendliness_To_Other(19, 24, 35);
+ Actor_Set_Friendliness_To_Other(19, 28, 60);
+ Actor_Set_Friendliness_To_Other(19, 53, 35);
+ Actor_Set_Friendliness_To_Other(23, 1, 75);
+ Actor_Set_Friendliness_To_Other(23, 4, 75);
+ Actor_Set_Friendliness_To_Other(23, 11, 35);
+ Actor_Set_Friendliness_To_Other(23, 12, 45);
+ Actor_Set_Friendliness_To_Other(23, 15, 40);
+ Actor_Set_Friendliness_To_Other(23, 24, 80);
+ Actor_Set_Friendliness_To_Other(23, 28, 70);
+ Actor_Set_Friendliness_To_Other(23, 30, 85);
+ Actor_Set_Friendliness_To_Other(23, 34, 85);
+ Actor_Set_Friendliness_To_Other(23, 53, 85);
+ Actor_Set_Friendliness_To_Other(24, 1, 75);
+ Actor_Set_Friendliness_To_Other(24, 4, 75);
+ Actor_Set_Friendliness_To_Other(24, 11, 35);
+ Actor_Set_Friendliness_To_Other(24, 12, 45);
+ Actor_Set_Friendliness_To_Other(24, 15, 40);
+ Actor_Set_Friendliness_To_Other(24, 23, 80);
+ Actor_Set_Friendliness_To_Other(24, 28, 65);
+ Actor_Set_Friendliness_To_Other(24, 30, 80);
+ Actor_Set_Friendliness_To_Other(24, 34, 85);
+ Actor_Set_Friendliness_To_Other(24, 53, 85);
+ Actor_Set_Friendliness_To_Other(28, 0, 60);
+ Actor_Set_Friendliness_To_Other(28, 1, 60);
+ Actor_Set_Friendliness_To_Other(28, 2, 65);
+ Actor_Set_Friendliness_To_Other(28, 4, 65);
+ Actor_Set_Friendliness_To_Other(28, 12, 65);
+ Actor_Set_Friendliness_To_Other(28, 15, 40);
+ Actor_Set_Friendliness_To_Other(28, 19, 65);
+ Actor_Set_Friendliness_To_Other(28, 23, 70);
+ Actor_Set_Friendliness_To_Other(28, 24, 70);
+ Actor_Set_Friendliness_To_Other(28, 53, 70);
+ Actor_Set_Friendliness_To_Other(30, 1, 70);
+ Actor_Set_Friendliness_To_Other(30, 4, 75);
+ Actor_Set_Friendliness_To_Other(30, 11, 35);
+ Actor_Set_Friendliness_To_Other(30, 23, 70);
+ Actor_Set_Friendliness_To_Other(30, 24, 70);
+ Actor_Set_Friendliness_To_Other(30, 34, 65);
+ Actor_Set_Friendliness_To_Other(30, 53, 70);
+ Actor_Set_Friendliness_To_Other(34, 0, 70);
+ Actor_Set_Friendliness_To_Other(34, 1, 70);
+ Actor_Set_Friendliness_To_Other(34, 4, 80);
+ Actor_Set_Friendliness_To_Other(34, 11, 35);
+ Actor_Set_Friendliness_To_Other(34, 23, 70);
+ Actor_Set_Friendliness_To_Other(34, 24, 70);
+ Actor_Set_Friendliness_To_Other(34, 30, 65);
+ Actor_Set_Friendliness_To_Other(34, 53, 70);
+ Actor_Set_Friendliness_To_Other(53, 1, 70);
+ Actor_Set_Friendliness_To_Other(53, 4, 65);
+ Actor_Set_Friendliness_To_Other(53, 11, 35);
+ Actor_Set_Friendliness_To_Other(53, 15, 35);
+ Actor_Set_Friendliness_To_Other(53, 23, 70);
+ Actor_Set_Friendliness_To_Other(53, 24, 65);
+ Actor_Set_Friendliness_To_Other(53, 28, 80);
+ Actor_Set_Friendliness_To_Other(53, 30, 70);
+ Actor_Set_Friendliness_To_Other(53, 34, 70);
}
void ScriptInit::Init_Actor_Combat_Aggressiveness() {
-
+ Actor_Set_Combat_Aggressiveness(4, 50);
+ Actor_Set_Combat_Aggressiveness(14, 50);
+ Actor_Set_Combat_Aggressiveness(17, 50);
+ Actor_Set_Combat_Aggressiveness(19, 90);
+ Actor_Set_Combat_Aggressiveness(2, 50);
+ Actor_Set_Combat_Aggressiveness(6, 0);
+ Actor_Set_Combat_Aggressiveness(7, 70);
+ Actor_Set_Combat_Aggressiveness(3, 60);
+ Actor_Set_Combat_Aggressiveness(1, 70);
+ Actor_Set_Combat_Aggressiveness(8, 80);
+ Actor_Set_Combat_Aggressiveness(5, 75);
+ Actor_Set_Combat_Aggressiveness(23, 70);
+ Actor_Set_Combat_Aggressiveness(24, 60);
+ Actor_Set_Combat_Aggressiveness(70, 40);
+ Actor_Set_Combat_Aggressiveness(71, 30);
+ Actor_Set_Combat_Aggressiveness(72, 30);
+ Actor_Set_Combat_Aggressiveness(64, 100);
}
void ScriptInit::Init_Actor_Honesty() {
-
+ Actor_Set_Honesty(19, 90);
}
void ScriptInit::Init_Actor_Intelligence() {
-
+ Actor_Set_Intelligence(19, 20);
+ Actor_Set_Intelligence(2, 70);
+ Actor_Set_Intelligence(6, 60);
+ Actor_Set_Intelligence(7, 75);
+ Actor_Set_Intelligence(3, 80);
+ Actor_Set_Intelligence(1, 80);
+ Actor_Set_Intelligence(8, 80);
+ Actor_Set_Intelligence(5, 100);
+ Actor_Set_Intelligence(23, 50);
+ Actor_Set_Intelligence(24, 40);
+ Actor_Set_Intelligence(70, 40);
+ Actor_Set_Intelligence(71, 20);
+ Actor_Set_Intelligence(72, 30);
+ Actor_Set_Intelligence(64, 10);
}
void ScriptInit::Init_Actor_Stability() {
-
+ Actor_Set_Stability(19, 35);
}
void ScriptInit::Init_Actor_Health() {
-
+ Actor_Set_Health(0, 50, 50);
+ Actor_Set_Health(1, 50, 50);
+ Actor_Set_Health(2, 50, 50);
+ Actor_Set_Health(3, 50, 50);
+ Actor_Set_Health(4, 50, 50);
+ Actor_Set_Health(5, 50, 50);
+ Actor_Set_Health(6, 50, 50);
+ Actor_Set_Health(7, 50, 50);
+ Actor_Set_Health(8, 50, 50);
+ Actor_Set_Health(9, 50, 50);
+ Actor_Set_Health(10, 50, 50);
+ Actor_Set_Health(11, 50, 50);
+ Actor_Set_Health(12, 50, 50);
+ Actor_Set_Health(13, 50, 50);
+ Actor_Set_Health(14, 50, 50);
+ Actor_Set_Health(15, 50, 50);
+ Actor_Set_Health(16, 50, 50);
+ Actor_Set_Health(17, 50, 50);
+ Actor_Set_Health(18, 50, 50);
+ Actor_Set_Health(19, 50, 50);
+ Actor_Set_Health(20, 50, 50);
+ Actor_Set_Health(21, 50, 50);
+ Actor_Set_Health(22, 50, 50);
+ Actor_Set_Health(23, 50, 50);
+ Actor_Set_Health(24, 50, 50);
+ Actor_Set_Health(25, 50, 50);
+ Actor_Set_Health(26, 50, 50);
+ Actor_Set_Health(27, 50, 50);
+ Actor_Set_Health(28, 50, 50);
+ Actor_Set_Health(29, 50, 50);
+ Actor_Set_Health(30, 50, 50);
+ Actor_Set_Health(31, 50, 50);
+ Actor_Set_Health(32, 50, 50);
+ Actor_Set_Health(33, 50, 50);
+ Actor_Set_Health(34, 50, 50);
+ Actor_Set_Health(35, 50, 50);
+ Actor_Set_Health(36, 50, 50);
+ Actor_Set_Health(37, 50, 50);
+ Actor_Set_Health(38, 50, 50);
+ Actor_Set_Health(40, 50, 50);
+ Actor_Set_Health(41, 50, 50);
+ Actor_Set_Health(42, 50, 50);
+ Actor_Set_Health(43, 50, 50);
+ Actor_Set_Health(44, 50, 50);
+ Actor_Set_Health(45, 50, 50);
+ Actor_Set_Health(46, 50, 50);
+ Actor_Set_Health(47, 50, 50);
+ Actor_Set_Health(48, 50, 50);
+ Actor_Set_Health(49, 50, 50);
+ Actor_Set_Health(50, 50, 50);
+ Actor_Set_Health(51, 50, 50);
+ Actor_Set_Health(52, 50, 50);
+ Actor_Set_Health(53, 50, 50);
+ Actor_Set_Health(54, 50, 50);
+ Actor_Set_Health(55, 50, 50);
+ Actor_Set_Health(56, 50, 50);
+ Actor_Set_Health(57, 50, 50);
+ Actor_Set_Health(58, 50, 50);
+ Actor_Set_Health(59, 50, 50);
+ Actor_Set_Health(62, 50, 50);
+ Actor_Set_Health(66, 50, 50);
+ Actor_Set_Health(67, 50, 50);
+ Actor_Set_Health(68, 50, 50);
+ Actor_Set_Health(69, 50, 50);
+ Actor_Set_Health(19, 80, 80);
+ Actor_Set_Health(2, 40, 40);
+ Actor_Set_Health(6, 20, 20);
+ Actor_Set_Health(7, 50, 50);
+ Actor_Set_Health(3, 60, 60);
+ Actor_Set_Health(1, 60, 60);
+ Actor_Set_Health(8, 60, 60);
+ Actor_Set_Health(5, 90, 90);
+ Actor_Set_Health(23, 40, 40);
+ Actor_Set_Health(24, 50, 50);
+ Actor_Set_Health(70, 30, 30);
+ Actor_Set_Health(71, 50, 50);
+ Actor_Set_Health(72, 20, 20);
+ Actor_Set_Health(64, 20, 20);
+ Actor_Set_Health(65, 20, 20);
+ if (Game_Flag_Query(45) == 1) {
+ Actor_Set_Health(2, 60, 60);
+ }
+ if (Game_Flag_Query(46) == 1) {
+ Actor_Set_Health(6, 40, 40);
+ }
+ if (Game_Flag_Query(44) == 1) {
+ Actor_Set_Health(7, 65, 65);
+ }
+ if (Game_Flag_Query(47) == 1) {
+ Actor_Set_Health(3, 70, 70);
+ }
+ if (Game_Flag_Query(48) == 1) {
+ Actor_Set_Health(8, 80, 80);
+ }
}
void ScriptInit::Init_Combat_Cover_Waypoints() {
-
+ Combat_Cover_Waypoint_Set_Data(0, 0, 7, 25, -603.0f, 0.0f, 32.0f);
+ Combat_Cover_Waypoint_Set_Data(1, 0, 7, 25, -670.0f, 0.0f, -24.0f);
+ Combat_Cover_Waypoint_Set_Data(2, 0, 7, 25, -604.0f, 0.0f, -96.0f);
+ Combat_Cover_Waypoint_Set_Data(3, 0, 7, 25, -490.0f, 0.0f, -20.0f);
+ Combat_Cover_Waypoint_Set_Data(4, 0, 7, 25, -667.0f, 0.0f, -164.0f);
+ Combat_Cover_Waypoint_Set_Data(5, 0, 7, 25, -606.0f, 0.0f, -222.0f);
+ Combat_Cover_Waypoint_Set_Data(6, 0, 7, 25, -534.0f, 0.0f, -170.0f);
+ Combat_Cover_Waypoint_Set_Data(7, 3, 54, 54, 76.06f, 23.83f, -1058.49f);
+ Combat_Cover_Waypoint_Set_Data(8, 3, 54, 54, -335.94f, 31.55f, -1406.49f);
+ Combat_Cover_Waypoint_Set_Data(9, 15, 42, 39, 286.0f, 367.93f, 330.0f);
+ Combat_Cover_Waypoint_Set_Data(10, 15, 42, 39, -58.0f, 367.93f, 294.0f);
+ Combat_Cover_Waypoint_Set_Data(11, 4, 37, 34, -30.0f, 8.0f, -759.0f);
+ Combat_Cover_Waypoint_Set_Data(12, 4, 37, 34, -93.0f, 8.0f, -693.0f);
+ Combat_Cover_Waypoint_Set_Data(13, 4, 37, 34, -6.0f, 8.0f, -607.0f);
+ Combat_Cover_Waypoint_Set_Data(14, 4, 37, 34, 78.0f, 8.0f, -687.0f);
+ Combat_Cover_Waypoint_Set_Data(15, 4, 37, 34, 262.0f, 8.0f, -683.0f);
+ Combat_Cover_Waypoint_Set_Data(16, 4, 37, 34, 334.0f, 8.0f, -607.0f);
+ Combat_Cover_Waypoint_Set_Data(17, 4, 37, 34, 426.0f, 8.0f, -679.0f);
+ Combat_Cover_Waypoint_Set_Data(18, 5, 4, 24, -318.0f, -6.5f, 1117.0f);
+ Combat_Cover_Waypoint_Set_Data(19, 5, 4, 24, -330.0f, -6.5f, 981.0f);
+ Combat_Cover_Waypoint_Set_Data(20, 5, 4, 24, -294.0f, -6.5f, 725.0f);
+ Combat_Cover_Waypoint_Set_Data(21, 16, 84, 96, 380.0f, -126.21f, 198.0f);
+ Combat_Cover_Waypoint_Set_Data(22, 16, 84, 96, 364.0f, -126.21f, -66.0f);
+ Combat_Cover_Waypoint_Set_Data(23, 18, 70, 80, 8.0f, 1.72f, 8.0f);
+ Combat_Cover_Waypoint_Set_Data(24, 18, 70, 80, 188.0f, 1.72f, 92.0f);
+ Combat_Cover_Waypoint_Set_Data(25, 18, 70, 80, 216.0f, -4.01f, 196.0f);
+ Combat_Cover_Waypoint_Set_Data(26, 18, 70, 80, -420.0f, 1.72f, 100.0f);
+ Combat_Cover_Waypoint_Set_Data(27, 18, 70, 80, -672.0f, 1.72f, -44.0f);
+ Combat_Cover_Waypoint_Set_Data(28, 10, 78, 90, -128.77f, -5.21f, -435.0f);
+ Combat_Cover_Waypoint_Set_Data(29, 10, 78, 90, -20.77f, 0.81f, -199.0f);
+ Combat_Cover_Waypoint_Set_Data(30, 10, 77, 89, -216.0f, 39.15f, -819.0f);
+ Combat_Cover_Waypoint_Set_Data(31, 10, 77, 89, 144.0f, -1.74f, -1015.0f);
+ Combat_Cover_Waypoint_Set_Data(32, 10, 77, 89, 152.0f, 4.14f, -811.0f);
+ Combat_Cover_Waypoint_Set_Data(33, 10, 79, 91, -121.0f, 0.0f, -39.0f);
+ Combat_Cover_Waypoint_Set_Data(34, 10, 80, 92, 86.0f, -12.21f, -278.0f);
+ Combat_Cover_Waypoint_Set_Data(35, 20, 41, 38, 407.82f, 40.63f, 95.25f);
+ Combat_Cover_Waypoint_Set_Data(36, 20, 41, 38, 357.81f, 40.63f, 387.9f);
}
void ScriptInit::Init_Combat_Flee_Waypoints() {
-
+ Combat_Flee_Waypoint_Set_Data(0, 4, 37, 34, 187.0f, 8.0f, -197.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(1, 4, 37, 34, 454.0f, 8.0f, -717.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(2, 4, 38, 35, -10.87f, 47.76f, -141.32f, -1);
+ Combat_Flee_Waypoint_Set_Data(3, 4, 38, 35, 466.0f, 47.76f, -532.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(4, 4, 39, 36, 199.0f, 47.76f, -880.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(5, 4, 39, 36, 594.0f, 47.76f, -1141.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(6, 4, 39, 36, 912.0f, 47.76f, -447.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(7, 4, 39, 36, 492.0f, 47.76f, -459.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(8, 1, 20, 2, 271.0f, 0.0f, 1038.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(9, 1, 20, 2, -175.0f, 9.04f, 8.59f, -1);
+ Combat_Flee_Waypoint_Set_Data(10, 1, 20, 2, -343.05f, 9.04f, 260.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(11, 0, 7, 25, -443.0f, -0.04f, -180.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(12, 0, 7, 26, -1485.0f, 6.98f, -393.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(13, 0, 7, 28, -652.0f, 7.18f, 354.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(14, 6, 49, 48, 25.0f, 0.0f, -314.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(15, 6, 49, 48, 980.0f, 0.0f, 189.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(16, 6, 49, 48, 601.0f, 0.0f, -1641.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(17, 12, 80, 92, 218.0f, -12.21f, -290.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(18, 12, 80, 92, -150.0f, -12.21f, -962.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(19, 13, 81, 93, -524.0f, 0.0f, -172.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(20, 13, 81, 93, -427.0f, 0.0f, 199.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(21, 13, 81, 93, -121.0f, 0.0f, -145.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(22, 14, 83, 95, 2.0f, 1.15f, 412.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(23, 14, 83, 95, -327.0f, 1.15f, -384.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(24, 14, 83, 95, -253.0f, 81.33f, -620.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(25, 5, 28, 17, -518.52f, -109.91f, 312.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(26, 5, 28, 17, 141.0f, -109.91f, 452.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(27, 5, 33, 23, 516.0f, 0.56f, 779.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(28, 5, 33, 23, 388.0f, 9.68f, 190.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(29, 5, 33, 23, -429.0f, 9.68f, -115.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(30, 7, 68, 77, -997.0f, 508.14f, -630.84f, -1);
+ Combat_Flee_Waypoint_Set_Data(31, 7, 68, 77, -416.27f, 508.14f, -574.84f, -1);
+ Combat_Flee_Waypoint_Set_Data(32, 7, 68, 77, -416.0f, 508.14f, -906.84f, -1);
+ Combat_Flee_Waypoint_Set_Data(33, 7, 68, 77, -1168.0f, 508.14f, -1666.84f, -1);
+ Combat_Flee_Waypoint_Set_Data(34, 10, 79, 91, 75.0f, 153.0f, -485.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(35, 10, 79, 91, -18.0f, 0.0f, 321.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(36, 11, 74, 86, -190.0f, -50.13f, -298.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(37, 11, 74, 86, 126.0f, -50.13f, -150.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(38, 11, 74, 86, 187.78f, -50.13f, -1262.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(39, 11, 74, 86, -20.22f, -30.13f, -2338.3f, -1);
+ Combat_Flee_Waypoint_Set_Data(40, 3, 54, 54, -416.0f, 31.55f, -829.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(41, 3, 54, 54, -412.0f, 31.55f, -1357.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(42, 3, 54, 54, -208.0f, 23.0f, -1693.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(43, 3, 54, 54, -64.0f, 23.83f, -2097.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(44, 3, 54, 54, 320.0f, 23.83f, -1058.49f, -1);
+ Combat_Flee_Waypoint_Set_Data(45, 3, 54, 54, 252.0f, 31.65f, -674.49f, -1);
+ Combat_Flee_Waypoint_Set_Data(46, 8, 45, 42, -803.0f, -615.49f, 2619.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(47, 8, 45, 42, -1027.0f, -614.49f, 3151.24f, -1);
+ Combat_Flee_Waypoint_Set_Data(48, 9, 9, 45, -1190.0f, 0.0f, 876.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(49, 9, 9, 45, -687.0f, 0.0f, 910.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(50, 9, 9, 46, -455.0f, 8.26f, -453.26f, -1);
+ Combat_Flee_Waypoint_Set_Data(51, 9, 9, 46, -1127.0f, 8.26f, -705.26f, -1);
+ Combat_Flee_Waypoint_Set_Data(52, 9, 9, 46, -1143.0f, 8.26f, -261.26f, -1);
+ Combat_Flee_Waypoint_Set_Data(53, 9, 9, 46, -703.0f, 8.26f, -157.26f, -1);
+ Combat_Flee_Waypoint_Set_Data(54, 10, 77, 89, 166.0f, 11.87f, -250.8f, -1);
+ Combat_Flee_Waypoint_Set_Data(55, 10, 77, 89, 158.0f, 4.14f, -10.8f, -1);
+ Combat_Flee_Waypoint_Set_Data(56, 10, 77, 89, -310.0f, 39.15f, -822.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(57, 10, 77, 89, -302.0f, -1.74f, -5847.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(58, 10, 78, 90, 4.0f, 1.37f, -3684.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(59, 10, 78, 90, 146.28f, -6.05f, -135.93f, -1);
+ Combat_Flee_Waypoint_Set_Data(60, 7, 53, 53, 212.0f, -162.8f, -108.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(61, 7, 53, 53, -28.0f, -162.8f, -104.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(62, 7, 53, 53, 504.0f, -162.8f, 224.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(63, 7, 53, 53, -301.0f, -162.8f, 275.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(64, 15, 42, 39, 98.0f, 367.93f, -10.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(65, 15, 42, 39, -206.0f, 367.69f, 386.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(66, 5, 4, 24, -190.0f, -6.5f, 789.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(67, 5, 4, 24, 123.0f, -6.5f, 1002.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(68, 5, 4, 24, -573.0f, -6.5f, 1202.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(69, 16, 84, 96, 120.0f, -126.21f, -350.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(70, 16, 84, 96, 524.0f, -126.21f, 158.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(71, 16, 84, 96, 276.0f, -126.21f, 537.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(72, 17, 86, 98, -334.7f, 12.97f, -332.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(73, 18, 70, 80, -672.0f, 1.72f, -96.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(74, 18, 70, 80, -552.0f, -4.01f, 268.0f, -1);
+ Combat_Flee_Waypoint_Set_Data(75, 18, 70, 80, 293.06f, 1.72f, 112.25f, -1);
+ Combat_Flee_Waypoint_Set_Data(76, 20, 41, 38, 435.13f, 37.18f, -292.34f, -1);
}
void ScriptInit::Init_Shadows() {
-
+ int list[] = {440, 37, 38, 83, 874};
+ Disable_Shadows(list, 5);
}
-
-
} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kia.cpp b/engines/bladerunner/script/kia.cpp
new file mode 100644
index 0000000000..c82e80cff4
--- /dev/null
+++ b/engines/bladerunner/script/kia.cpp
@@ -0,0 +1,951 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/kia.h"
+
+#include "bladerunner/bladerunner.h"
+
+namespace BladeRunner {
+
+void ScriptKIA::SCRIPT_KIA_DLL_Play_Clue_Asset_Script(int a1, int clueId) {
+ int v1;
+ switch (clueId) {
+ case 0:
+ KIA_Play_Actor_Dialogue(23, 40);
+ break;
+ case 2:
+ KIA_Play_Actor_Dialogue(23, 0);
+ break;
+ case 3:
+ KIA_Play_Actor_Dialogue(99, 1970);
+ KIA_Play_Actor_Dialogue(99, 1980);
+ KIA_Play_Actor_Dialogue(99, 1990);
+ break;
+ case 4:
+ KIA_Play_Actor_Dialogue(99, 1970);
+ KIA_Play_Actor_Dialogue(99, 1980);
+ KIA_Play_Actor_Dialogue(99, 1990);
+ break;
+ case 5:
+ KIA_Play_Slice_Model(966);
+ KIA_Play_Actor_Dialogue(99, 1960);
+ break;
+ case 6:
+ KIA_Play_Slice_Model(933);
+ break;
+ case 7:
+ KIA_Play_Slice_Model(971);
+ break;
+ case 8:
+ KIA_Play_Slice_Model(937);
+ KIA_Play_Actor_Dialogue(99, 2010);
+ break;
+ case 9:
+ KIA_Play_Photograph(6);
+ KIA_Play_Actor_Dialogue(99, 2020);
+ KIA_Play_Actor_Dialogue(99, 2030);
+ KIA_Play_Actor_Dialogue(99, 2040);
+ break;
+ case 10:
+ KIA_Play_Actor_Dialogue(30, 140);
+ break;
+ case 11:
+ KIA_Play_Actor_Dialogue(30, 50);
+ KIA_Play_Actor_Dialogue(30, 60);
+ KIA_Play_Actor_Dialogue(30, 70);
+ KIA_Play_Actor_Dialogue(30, 80);
+ KIA_Play_Actor_Dialogue(30, 90);
+ break;
+ case 12:
+ KIA_Play_Slice_Model(975);
+ break;
+ case 13:
+ KIA_Play_Photograph(5);
+ break;
+ case 14:
+ KIA_Play_Photograph(4);
+ KIA_Play_Actor_Dialogue(99, 4050);
+ break;
+ case 15:
+ KIA_Play_Slice_Model(964);
+ KIA_Play_Actor_Dialogue(15, 280);
+ KIA_Play_Actor_Dialogue(15, 290);
+ break;
+ case 16:
+ KIA_Play_Actor_Dialogue(23, 100);
+ break;
+ case 17:
+ KIA_Play_Actor_Dialogue(23, 120);
+ KIA_Play_Actor_Dialogue(23, 130);
+ break;
+ case 19:
+ KIA_Play_Actor_Dialogue(0, 380);
+ KIA_Play_Actor_Dialogue(19, 30);
+ KIA_Play_Actor_Dialogue(19, 40);
+ KIA_Play_Actor_Dialogue(0, 410);
+ KIA_Play_Actor_Dialogue(19, 50);
+ break;
+ case 20:
+ KIA_Play_Photograph(33);
+ KIA_Play_Actor_Dialogue(99, 350);
+ break;
+ case 21:
+ KIA_Play_Actor_Dialogue(12, 10);
+ break;
+ case 22:
+ KIA_Play_Actor_Dialogue(15, 40);
+ KIA_Play_Actor_Dialogue(15, 50);
+ KIA_Play_Actor_Dialogue(0, 4565);
+ KIA_Play_Actor_Dialogue(15, 60);
+ break;
+ case 23:
+ KIA_Play_Actor_Dialogue(15, 250);
+ KIA_Play_Actor_Dialogue(15, 270);
+ break;
+ case 24:
+ KIA_Play_Actor_Dialogue(15, 260);
+ KIA_Play_Actor_Dialogue(15, 270);
+ break;
+ case 25:
+ KIA_Play_Actor_Dialogue(0, 295);
+ KIA_Play_Actor_Dialogue(28, 90);
+ KIA_Play_Actor_Dialogue(28, 100);
+ break;
+ case 26:
+ KIA_Play_Actor_Dialogue(99, 1880);
+ KIA_Play_Actor_Dialogue(99, 1890);
+ break;
+ case 27:
+ KIA_Play_Slice_Model(938);
+ break;
+ case 28:
+ KIA_Play_Photograph(11);
+ break;
+ case 29:
+ KIA_Play_Photograph(12);
+ break;
+ case 30:
+ KIA_Play_Photograph(10);
+ break;
+ case 31:
+ KIA_Play_Photograph(9);
+ break;
+ case 32:
+ KIA_Play_Slice_Model(987);
+ KIA_Play_Actor_Dialogue(0, 5870);
+ KIA_Play_Actor_Dialogue(4, 810);
+ KIA_Play_Actor_Dialogue(4, 820);
+ break;
+ case 33:
+ KIA_Play_Actor_Dialogue(53, 20);
+ KIA_Play_Actor_Dialogue(0, 680);
+ KIA_Play_Actor_Dialogue(53, 30);
+ break;
+ case 37:
+ KIA_Play_Slice_Model(952);
+ break;
+ case 39:
+ KIA_Play_Actor_Dialogue(30, 170);
+ KIA_Play_Actor_Dialogue(30, 180);
+ KIA_Play_Actor_Dialogue(30, 190);
+ KIA_Play_Actor_Dialogue(30, 200);
+ break;
+ case 40:
+ KIA_Play_Actor_Dialogue(38, 90);
+ KIA_Play_Actor_Dialogue(38, 100);
+ KIA_Play_Actor_Dialogue(38, 110);
+ KIA_Play_Actor_Dialogue(38, 120);
+ KIA_Play_Actor_Dialogue(38, 130);
+ KIA_Play_Actor_Dialogue(38, 140);
+ KIA_Play_Actor_Dialogue(38, 150);
+ break;
+ case 43:
+ KIA_Play_Actor_Dialogue(4, 30);
+ KIA_Play_Actor_Dialogue(4, 50);
+ KIA_Play_Actor_Dialogue(4, 70);
+ break;
+ case 44:
+ KIA_Play_Slice_Model(940);
+ KIA_Play_Actor_Dialogue(99, 2140);
+ KIA_Play_Actor_Dialogue(99, 2150);
+ KIA_Play_Actor_Dialogue(99, 2160);
+ break;
+ case 45:
+ KIA_Play_Slice_Model(975);
+ break;
+ case 46:
+ KIA_Play_Actor_Dialogue(0, 5140);
+ KIA_Play_Actor_Dialogue(17, 30);
+ KIA_Play_Actor_Dialogue(17, 40);
+ break;
+ case 47:
+ KIA_Play_Photograph(31);
+ KIA_Play_Actor_Dialogue(99, 2140);
+ KIA_Play_Actor_Dialogue(99, 2150);
+ KIA_Play_Actor_Dialogue(99, 2160);
+ break;
+ case 49:
+ KIA_Play_Slice_Model(974);
+ KIA_Play_Actor_Dialogue(99, 2320);
+ if (Game_Flag_Query(48)) {
+ KIA_Play_Actor_Dialogue(99, 2330);
+ KIA_Play_Actor_Dialogue(99, 2340);
+ }
+ KIA_Play_Actor_Dialogue(99, 2350);
+ break;
+ case 50:
+ KIA_Play_Actor_Dialogue(17, 100);
+ KIA_Play_Actor_Dialogue(17, 110);
+ KIA_Play_Actor_Dialogue(17, 120);
+ KIA_Play_Actor_Dialogue(17, 130);
+ break;
+ case 51:
+ KIA_Play_Actor_Dialogue(99, 2170);
+ KIA_Play_Actor_Dialogue(99, 2180);
+ KIA_Play_Actor_Dialogue(99, 2190);
+ KIA_Play_Actor_Dialogue(99, 2200);
+ break;
+ case 52:
+ KIA_Play_Actor_Dialogue(1, 2230);
+ KIA_Play_Actor_Dialogue(1, 2260);
+ KIA_Play_Actor_Dialogue(1, 2270);
+ KIA_Play_Actor_Dialogue(1, 2280);
+ break;
+ case 53:
+ KIA_Play_Slice_Model(955);
+ if (Query_Difficulty_Level() <= 0) {
+ KIA_Play_Actor_Dialogue(99, 4140);
+ } else {
+ KIA_Play_Actor_Dialogue(99, 4150);
+ }
+ break;
+ case 54:
+ KIA_Play_Slice_Model(973);
+ KIA_Play_Actor_Dialogue(99, 4280);
+ KIA_Play_Actor_Dialogue(99, 4290);
+ break;
+ case 55:
+ KIA_Play_Slice_Model(973);
+ KIA_Play_Actor_Dialogue(99, 4280);
+ KIA_Play_Actor_Dialogue(99, 4300);
+ break;
+ case 56:
+ KIA_Play_Actor_Dialogue(16, 90);
+ KIA_Play_Actor_Dialogue(16, 100);
+ KIA_Play_Actor_Dialogue(16, 110);
+ KIA_Play_Actor_Dialogue(16, 120);
+ KIA_Play_Actor_Dialogue(16, 130);
+ break;
+ case 57:
+ KIA_Play_Actor_Dialogue(20, 90);
+ KIA_Play_Actor_Dialogue(20, 100);
+ break;
+ case 58:
+ KIA_Play_Actor_Dialogue(14, 320);
+ KIA_Play_Actor_Dialogue(14, 330);
+ KIA_Play_Actor_Dialogue(14, 340);
+ KIA_Play_Actor_Dialogue(14, 380);
+ KIA_Play_Actor_Dialogue(14, 390);
+ KIA_Play_Actor_Dialogue(14, 400);
+ break;
+ case 59:
+ KIA_Play_Actor_Dialogue(14, 320);
+ KIA_Play_Actor_Dialogue(14, 330);
+ KIA_Play_Actor_Dialogue(14, 410);
+ KIA_Play_Actor_Dialogue(14, 420);
+ KIA_Play_Actor_Dialogue(14, 440);
+ KIA_Play_Actor_Dialogue(14, 450);
+ break;
+ case 60:
+ KIA_Play_Actor_Dialogue(7, 210);
+ KIA_Play_Actor_Dialogue(7, 220);
+ KIA_Play_Actor_Dialogue(7, 240);
+ KIA_Play_Actor_Dialogue(7, 250);
+ break;
+ case 61:
+ KIA_Play_Actor_Dialogue(7, 750);
+ KIA_Play_Actor_Dialogue(7, 760);
+ KIA_Play_Actor_Dialogue(0, 5500);
+ KIA_Play_Actor_Dialogue(7, 780);
+ KIA_Play_Actor_Dialogue(7, 790);
+ break;
+ case 62:
+ KIA_Play_Slice_Model(963);
+ break;
+ case 63:
+ KIA_Play_Actor_Dialogue(14, 560);
+ KIA_Play_Actor_Dialogue(14, 570);
+ KIA_Play_Actor_Dialogue(14, 580);
+ break;
+ case 64:
+ KIA_Play_Actor_Dialogue(29, 120);
+ KIA_Play_Actor_Dialogue(29, 130);
+ break;
+ case 65:
+ KIA_Play_Slice_Model(942);
+ KIA_Play_Actor_Dialogue(99, 4160);
+ break;
+ case 66:
+ KIA_Play_Actor_Dialogue(99, 2430);
+ KIA_Play_Actor_Dialogue(99, 2440);
+ KIA_Play_Actor_Dialogue(99, 2450);
+ break;
+ case 67:
+ KIA_Play_Actor_Dialogue(52, 140);
+ KIA_Play_Actor_Dialogue(52, 150);
+ KIA_Play_Actor_Dialogue(52, 170);
+ KIA_Play_Actor_Dialogue(52, 180);
+ KIA_Play_Actor_Dialogue(52, 190);
+ break;
+ case 68:
+ KIA_Play_Actor_Dialogue(35, 20);
+ KIA_Play_Actor_Dialogue(35, 30);
+ KIA_Play_Actor_Dialogue(35, 40);
+ KIA_Play_Actor_Dialogue(35, 50);
+ break;
+ case 69:
+ KIA_Play_Actor_Dialogue(2, 1010);
+ KIA_Play_Actor_Dialogue(0, 6495);
+ KIA_Play_Actor_Dialogue(2, 1020);
+ KIA_Play_Actor_Dialogue(0, 6500);
+ KIA_Play_Actor_Dialogue(2, 1030);
+ break;
+ case 70:
+ KIA_Play_Actor_Dialogue(2, 1040);
+ KIA_Play_Actor_Dialogue(2, 1050);
+ KIA_Play_Actor_Dialogue(0, 6505);
+ KIA_Play_Actor_Dialogue(2, 1060);
+ KIA_Play_Actor_Dialogue(2, 1070);
+ KIA_Play_Actor_Dialogue(0, 6510);
+ KIA_Play_Actor_Dialogue(2, 1080);
+ break;
+ case 71:
+ KIA_Play_Actor_Dialogue(56, 0);
+ KIA_Play_Actor_Dialogue(56, 10);
+ KIA_Play_Actor_Dialogue(56, 20);
+ KIA_Play_Actor_Dialogue(56, 30);
+ KIA_Play_Actor_Dialogue(56, 40);
+ KIA_Play_Actor_Dialogue(56, 50);
+ break;
+ case 72:
+ KIA_Play_Actor_Dialogue(99, 80);
+ KIA_Play_Actor_Dialogue(99, 90);
+ break;
+ case 74:
+ KIA_Play_Actor_Dialogue(99, 4370);
+ KIA_Play_Actor_Dialogue(99, 4380);
+ KIA_Play_Actor_Dialogue(99, 4390);
+ KIA_Play_Actor_Dialogue(99, 4400);
+ break;
+ case 75:
+ KIA_Play_Slice_Model(956);
+ break;
+ case 76:
+ KIA_Play_Slice_Model(944);
+ KIA_Play_Actor_Dialogue(99, 850);
+ KIA_Play_Actor_Dialogue(99, 860);
+ KIA_Play_Actor_Dialogue(99, 870);
+ KIA_Play_Actor_Dialogue(99, 880);
+ break;
+ case 77:
+ KIA_Play_Photograph(25);
+ break;
+ case 78:
+ KIA_Play_Photograph(20);
+ break;
+ case 79:
+ KIA_Play_Actor_Dialogue(0, 220);
+ KIA_Play_Actor_Dialogue(16, 320);
+ KIA_Play_Actor_Dialogue(0, 225);
+ KIA_Play_Actor_Dialogue(16, 330);
+ KIA_Play_Actor_Dialogue(0, 230);
+ KIA_Play_Actor_Dialogue(16, 340);
+ break;
+ case 80:
+ KIA_Play_Slice_Model(965);
+ break;
+ case 81:
+ KIA_Play_Slice_Model(965);
+ break;
+ case 82:
+ KIA_Play_Actor_Dialogue(4, 520);
+ KIA_Play_Actor_Dialogue(4, 530);
+ KIA_Play_Actor_Dialogue(4, 540);
+ KIA_Play_Actor_Dialogue(4, 550);
+ break;
+ case 84:
+ KIA_Play_Slice_Model(970);
+ break;
+ case 85:
+ KIA_Play_Slice_Model(943);
+ break;
+ case 86:
+ KIA_Play_Photograph(34);
+ break;
+ case 87:
+ KIA_Play_Slice_Model(936);
+ break;
+ case 88:
+ KIA_Play_Photograph(16);
+ break;
+ case 89:
+ KIA_Play_Slice_Model(975);
+ break;
+ case 90:
+ KIA_Play_Actor_Dialogue(16, 290);
+ KIA_Play_Actor_Dialogue(16, 300);
+ break;
+ case 91:
+ KIA_Play_Slice_Model(939);
+ KIA_Play_Actor_Dialogue(99, 4050);
+ break;
+ case 92:
+ KIA_Play_Actor_Dialogue(18, 140);
+ KIA_Play_Actor_Dialogue(18, 150);
+ break;
+ case 93:
+ KIA_Play_Slice_Model(969);
+ break;
+ case 94:
+ KIA_Play_Actor_Dialogue(3, 650);
+ KIA_Play_Actor_Dialogue(3, 660);
+ KIA_Play_Actor_Dialogue(0, 3665);
+ KIA_Play_Actor_Dialogue(3, 670);
+ KIA_Play_Actor_Dialogue(3, 680);
+ KIA_Play_Actor_Dialogue(3, 690);
+ break;
+ case 96:
+ KIA_Play_Actor_Dialogue(3, 580);
+ break;
+ case 97:
+ KIA_Play_Actor_Dialogue(0, 3600);
+ KIA_Play_Actor_Dialogue(3, 550);
+ break;
+ case 98:
+ KIA_Play_Slice_Model(935);
+ break;
+ case 99:
+ KIA_Play_Slice_Model(957);
+ break;
+ case 100:
+ KIA_Play_Slice_Model(961);
+ break;
+ case 101:
+ KIA_Play_Actor_Dialogue(31, 210);
+ KIA_Play_Actor_Dialogue(31, 220);
+ KIA_Play_Actor_Dialogue(22, 140);
+ KIA_Play_Actor_Dialogue(31, 230);
+ break;
+ case 102:
+ KIA_Play_Actor_Dialogue(59, 210);
+ KIA_Play_Actor_Dialogue(59, 260);
+ KIA_Play_Actor_Dialogue(0, 1390);
+ KIA_Play_Actor_Dialogue(59, 300);
+ break;
+ case 103:
+ KIA_Play_Actor_Dialogue(2, 450);
+ KIA_Play_Actor_Dialogue(0, 3280);
+ break;
+ case 104:
+ KIA_Play_Actor_Dialogue(0, 3250);
+ KIA_Play_Actor_Dialogue(2, 540);
+ KIA_Play_Actor_Dialogue(2, 550);
+ break;
+ case 105:
+ KIA_Play_Slice_Model(953);
+ KIA_Play_Actor_Dialogue(99, 350);
+ break;
+ case 106:
+ KIA_Play_Slice_Model(954);
+ break;
+ case 107:
+ KIA_Play_Actor_Dialogue(0, 3860);
+ KIA_Play_Actor_Dialogue(3, 1030);
+ KIA_Play_Actor_Dialogue(3, 1040);
+ KIA_Play_Actor_Dialogue(0, 3865);
+ KIA_Play_Actor_Dialogue(3, 1050);
+ KIA_Play_Actor_Dialogue(3, 1060);
+ break;
+ case 108:
+ KIA_Play_Actor_Dialogue(33, 0);
+ KIA_Play_Actor_Dialogue(33, 10);
+ break;
+ case 109:
+ KIA_Play_Slice_Model(931);
+ break;
+ case 110:
+ KIA_Play_Slice_Model(931);
+ KIA_Play_Actor_Dialogue(99, 4420);
+ break;
+ case 112:
+ KIA_Play_Actor_Dialogue(99, 3780);
+ KIA_Play_Actor_Dialogue(99, 3790);
+ break;
+ case 113:
+ KIA_Play_Actor_Dialogue(99, 3800);
+ KIA_Play_Actor_Dialogue(99, 3810);
+ KIA_Play_Actor_Dialogue(99, 3820);
+ KIA_Play_Actor_Dialogue(99, 3830);
+ break;
+ case 114:
+ KIA_Play_Actor_Dialogue(99, 3840);
+ KIA_Play_Actor_Dialogue(99, 3850);
+ KIA_Play_Actor_Dialogue(99, 3860);
+ KIA_Play_Actor_Dialogue(99, 3870);
+ break;
+ case 115:
+ KIA_Play_Actor_Dialogue(99, 3880);
+ KIA_Play_Actor_Dialogue(99, 3890);
+ KIA_Play_Actor_Dialogue(99, 3900);
+ break;
+ case 116:
+ KIA_Play_Actor_Dialogue(9, 830);
+ KIA_Play_Actor_Dialogue(9, 840);
+ KIA_Play_Actor_Dialogue(9, 850);
+ break;
+ case 118:
+ KIA_Play_Slice_Model(951);
+ break;
+ case 119:
+ KIA_Play_Slice_Model(962);
+ KIA_Play_Actor_Dialogue(99, 3930);
+ KIA_Play_Actor_Dialogue(99, 3940);
+ break;
+ case 120:
+ KIA_Play_Actor_Dialogue(99, 2550);
+ KIA_Play_Actor_Dialogue(99, 2560);
+ KIA_Play_Actor_Dialogue(99, 2570);
+ KIA_Play_Actor_Dialogue(99, 2580);
+ KIA_Play_Actor_Dialogue(99, 2590);
+ break;
+ case 121:
+ KIA_Play_Actor_Dialogue(99, 2470);
+ KIA_Play_Actor_Dialogue(99, 2480);
+ KIA_Play_Actor_Dialogue(99, 2490);
+ KIA_Play_Actor_Dialogue(99, 2500);
+ break;
+ case 122:
+ KIA_Play_Actor_Dialogue(0, 5615);
+ KIA_Play_Actor_Dialogue(12, 170);
+ KIA_Play_Actor_Dialogue(0, 5625);
+ KIA_Play_Actor_Dialogue(12, 180);
+ KIA_Play_Actor_Dialogue(0, 5630);
+ KIA_Play_Actor_Dialogue(12, 190);
+ KIA_Play_Actor_Dialogue(0, 5635);
+ KIA_Play_Actor_Dialogue(12, 200);
+ break;
+ case 123:
+ KIA_Play_Actor_Dialogue(0, 5640);
+ KIA_Play_Actor_Dialogue(12, 230);
+ KIA_Play_Actor_Dialogue(0, 5645);
+ KIA_Play_Actor_Dialogue(12, 240);
+ KIA_Play_Actor_Dialogue(12, 250);
+ KIA_Play_Actor_Dialogue(0, 5650);
+ KIA_Play_Actor_Dialogue(12, 260);
+ break;
+ case 124:
+ KIA_Play_Actor_Dialogue(12, 340);
+ KIA_Play_Actor_Dialogue(12, 350);
+ KIA_Play_Actor_Dialogue(12, 360);
+ KIA_Play_Actor_Dialogue(99, 2710);
+ KIA_Play_Actor_Dialogue(99, 2730);
+ break;
+ case 125:
+ KIA_Play_Slice_Model(946);
+ KIA_Play_Actor_Dialogue(99, 2740);
+ KIA_Play_Actor_Dialogue(99, 2750);
+ KIA_Play_Actor_Dialogue(99, 2760);
+ KIA_Play_Actor_Dialogue(99, 2770);
+ break;
+ case 126:
+ KIA_Play_Actor_Dialogue(99, 3320);
+ break;
+ case 127:
+ KIA_Play_Slice_Model(959);
+ break;
+ case 128:
+ KIA_Play_Slice_Model(958);
+ break;
+ case 129:
+ KIA_Play_Slice_Model(934);
+ break;
+ case 131:
+ KIA_Play_Slice_Model(945);
+ break;
+ case 136:
+ KIA_Play_Actor_Dialogue(10, 240);
+ KIA_Play_Actor_Dialogue(13, 200);
+ KIA_Play_Actor_Dialogue(13, 210);
+ KIA_Play_Actor_Dialogue(10, 260);
+ KIA_Play_Actor_Dialogue(10, 270);
+ break;
+ case 139:
+ KIA_Play_Actor_Dialogue(3, 360);
+ KIA_Play_Actor_Dialogue(3, 380);
+ break;
+ case 140:
+ KIA_Play_Actor_Dialogue(0, 2505);
+ KIA_Play_Actor_Dialogue(3, 430);
+ KIA_Play_Actor_Dialogue(3, 440);
+ KIA_Play_Actor_Dialogue(0, 2530);
+ KIA_Play_Actor_Dialogue(3, 450);
+ KIA_Play_Actor_Dialogue(0, 2535);
+ KIA_Play_Actor_Dialogue(3, 460);
+ KIA_Play_Actor_Dialogue(3, 470);
+ break;
+ case 141:
+ KIA_Play_Actor_Dialogue(6, 590);
+ KIA_Play_Actor_Dialogue(6, 630);
+ break;
+ case 142:
+ KIA_Play_Actor_Dialogue(6, 540);
+ KIA_Play_Actor_Dialogue(6, 550);
+ KIA_Play_Actor_Dialogue(0, 2550);
+ KIA_Play_Actor_Dialogue(6, 560);
+ break;
+ case 143:
+ KIA_Play_Actor_Dialogue(5, 530);
+ KIA_Play_Actor_Dialogue(5, 540);
+ break;
+ case 144:
+ KIA_Play_Actor_Dialogue(1, 700);
+ KIA_Play_Actor_Dialogue(1, 750);
+ KIA_Play_Actor_Dialogue(1, 760);
+ break;
+ case 145:
+ KIA_Play_Slice_Model(960);
+ break;
+ case 146:
+ KIA_Play_Slice_Model(932);
+ break;
+ case 147:
+ case 148:
+ case 149:
+ case 150:
+ case 151:
+ case 152:
+ v1 = Global_Variable_Query(48) - 1;
+ if (v1 == 1) {
+ KIA_Play_Slice_Model(988);
+ } else if (v1 == 2) {
+ KIA_Play_Slice_Model(990);
+ } else if (v1 == 3) {
+ KIA_Play_Slice_Model(991);
+ } else if (v1 == 4) {
+ KIA_Play_Slice_Model(993);
+ }
+ break;
+ case 153:
+ KIA_Play_Slice_Model(950);
+ break;
+ case 154:
+ KIA_Play_Slice_Model(967);
+ break;
+ case 155:
+ KIA_Play_Slice_Model(947);
+ break;
+ case 156:
+ KIA_Play_Actor_Dialogue(19, 230);
+ KIA_Play_Actor_Dialogue(19, 240);
+ break;
+ case 157:
+ KIA_Play_Actor_Dialogue(19, 250);
+ KIA_Play_Actor_Dialogue(19, 260);
+ break;
+ case 158:
+ KIA_Play_Actor_Dialogue(19, 280);
+ KIA_Play_Actor_Dialogue(0, 7350);
+ KIA_Play_Actor_Dialogue(19, 290);
+ KIA_Play_Actor_Dialogue(19, 300);
+ KIA_Play_Actor_Dialogue(19, 310);
+ break;
+ case 162:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 163:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 164:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 165:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 166:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 167:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 168:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 169:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 170:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 171:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 172:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 173:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 174:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 175:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 176:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 177:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 178:
+ KIA_Play_Actor_Dialogue(1, 3310);
+ KIA_Play_Actor_Dialogue(1, 3320);
+ KIA_Play_Actor_Dialogue(1, 3330);
+ KIA_Play_Actor_Dialogue(1, 3350);
+ KIA_Play_Actor_Dialogue(1, 3360);
+ KIA_Play_Actor_Dialogue(1, 3370);
+ KIA_Play_Actor_Dialogue(1, 3380);
+ break;
+ case 179:
+ KIA_Play_Actor_Dialogue(1, 3390);
+ KIA_Play_Actor_Dialogue(1, 3400);
+ KIA_Play_Actor_Dialogue(1, 3410);
+ KIA_Play_Actor_Dialogue(11, 1260);
+ KIA_Play_Actor_Dialogue(1, 3420);
+ KIA_Play_Actor_Dialogue(1, 3430);
+ KIA_Play_Actor_Dialogue(1, 3440);
+ KIA_Play_Actor_Dialogue(11, 1270);
+ KIA_Play_Actor_Dialogue(1, 3450);
+ KIA_Play_Actor_Dialogue(1, 3460);
+ KIA_Play_Actor_Dialogue(11, 1280);
+ KIA_Play_Actor_Dialogue(1, 3470);
+ KIA_Play_Actor_Dialogue(11, 1300);
+ KIA_Play_Actor_Dialogue(11, 1310);
+ KIA_Play_Actor_Dialogue(1, 3480);
+ KIA_Play_Actor_Dialogue(1, 3500);
+ KIA_Play_Actor_Dialogue(11, 1320);
+ KIA_Play_Actor_Dialogue(11, 1330);
+ KIA_Play_Actor_Dialogue(1, 3510);
+ KIA_Play_Actor_Dialogue(11, 1340);
+ KIA_Play_Actor_Dialogue(1, 3520);
+ KIA_Play_Actor_Dialogue(11, 1350);
+ KIA_Play_Actor_Dialogue(1, 3530);
+ KIA_Play_Actor_Dialogue(1, 3540);
+ break;
+ case 180:
+ KIA_Play_Actor_Dialogue(1, 3550);
+ KIA_Play_Actor_Dialogue(11, 1360);
+ KIA_Play_Actor_Dialogue(11, 1370);
+ KIA_Play_Actor_Dialogue(1, 3560);
+ KIA_Play_Actor_Dialogue(1, 3570);
+ break;
+ case 181:
+ KIA_Play_Actor_Dialogue(1, 3580);
+ KIA_Play_Actor_Dialogue(11, 1400);
+ KIA_Play_Actor_Dialogue(1, 3590);
+ KIA_Play_Actor_Dialogue(11, 1410);
+ KIA_Play_Actor_Dialogue(1, 3600);
+ KIA_Play_Actor_Dialogue(11, 1420);
+ KIA_Play_Actor_Dialogue(11, 1430);
+ KIA_Play_Actor_Dialogue(1, 3610);
+ KIA_Play_Actor_Dialogue(11, 1440);
+ KIA_Play_Actor_Dialogue(1, 3620);
+ KIA_Play_Actor_Dialogue(1, 3630);
+ KIA_Play_Actor_Dialogue(11, 1450);
+ KIA_Play_Actor_Dialogue(1, 3640);
+ KIA_Play_Actor_Dialogue(11, 1460);
+ KIA_Play_Actor_Dialogue(1, 3650);
+ break;
+ case 243:
+ KIA_Play_Photograph(7);
+ break;
+ case 244:
+ KIA_Play_Photograph(8);
+ KIA_Play_Actor_Dialogue(99, 4110);
+ break;
+ case 245:
+ KIA_Play_Photograph(15);
+ break;
+ case 246:
+ KIA_Play_Photograph(17);
+ break;
+ case 247:
+ KIA_Play_Photograph(18);
+ break;
+ case 248:
+ KIA_Play_Photograph(1);
+ KIA_Play_Actor_Dialogue(99, 4260);
+ break;
+ case 249:
+ KIA_Play_Photograph(3);
+ KIA_Play_Actor_Dialogue(99, 4230);
+ break;
+ case 250:
+ KIA_Play_Photograph(2);
+ KIA_Play_Actor_Dialogue(99, 4040);
+ break;
+ case 251:
+ KIA_Play_Photograph(21);
+ break;
+ case 252:
+ KIA_Play_Photograph(22);
+ KIA_Play_Actor_Dialogue(99, 4180);
+ break;
+ case 253:
+ KIA_Play_Photograph(23);
+ break;
+ case 254:
+ KIA_Play_Photograph(24);
+ break;
+ case 255:
+ KIA_Play_Photograph(26);
+ break;
+ case 256:
+ KIA_Play_Photograph(27);
+ break;
+ case 257:
+ KIA_Play_Slice_Model(975);
+ break;
+ case 258:
+ KIA_Play_Photograph(0);
+ break;
+ case 259:
+ KIA_Play_Photograph(28);
+ break;
+ case 260:
+ KIA_Play_Photograph(19);
+ break;
+ case 261:
+ KIA_Play_Photograph(32);
+ break;
+ case 262:
+ KIA_Play_Photograph(30);
+ KIA_Play_Actor_Dialogue(99, 4160);
+ break;
+ case 263:
+ KIA_Play_Photograph(29);
+ if (Query_Difficulty_Level() <= 0) {
+ KIA_Play_Actor_Dialogue(99, 4140);
+ } else {
+ KIA_Play_Actor_Dialogue(99, 4150);
+ }
+ break;
+ case 264:
+ KIA_Play_Slice_Model(985);
+ KIA_Play_Actor_Dialogue(99, 1770);
+ KIA_Play_Actor_Dialogue(99, 1150);
+ KIA_Play_Actor_Dialogue(99, 1180);
+ KIA_Play_Actor_Dialogue(99, 1190);
+ break;
+ case 265:
+ KIA_Play_Slice_Model(986);
+ break;
+ case 269:
+ KIA_Play_Actor_Dialogue(99, 730);
+ KIA_Play_Actor_Dialogue(99, 740);
+ KIA_Play_Actor_Dialogue(99, 750);
+ KIA_Play_Actor_Dialogue(99, 760);
+ break;
+ case 270:
+ KIA_Play_Actor_Dialogue(99, 670);
+ KIA_Play_Actor_Dialogue(99, 680);
+ KIA_Play_Actor_Dialogue(99, 700);
+ KIA_Play_Actor_Dialogue(99, 710);
+ KIA_Play_Actor_Dialogue(99, 720);
+ break;
+ case 271:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 430);
+ break;
+ case 272:
+ KIA_Play_Actor_Dialogue(39, 420);
+ KIA_Play_Actor_Dialogue(39, 440);
+ break;
+ case 273:
+ KIA_Play_Actor_Dialogue(0, 1645);
+ KIA_Play_Actor_Dialogue(6, 240);
+ KIA_Play_Actor_Dialogue(6, 250);
+ KIA_Play_Actor_Dialogue(0, 1675);
+ KIA_Play_Actor_Dialogue(6, 260);
+ KIA_Play_Actor_Dialogue(6, 270);
+ break;
+ case 274:
+ KIA_Play_Photograph(35);
+ break;
+ case 275:
+ KIA_Play_Photograph(36);
+ KIA_Play_Actor_Dialogue(99, 4240);
+ break;
+ case 276:
+ KIA_Play_Photograph(37);
+ KIA_Play_Actor_Dialogue(99, 4220);
+ break;
+ case 277:
+ KIA_Play_Photograph(38);
+ break;
+ case 278:
+ KIA_Play_Actor_Dialogue(0, 5365);
+ KIA_Play_Actor_Dialogue(57, 600);
+ KIA_Play_Actor_Dialogue(0, 5370);
+ KIA_Play_Actor_Dialogue(57, 610);
+ break;
+ case 279:
+ KIA_Play_Actor_Dialogue(51, 0);
+ KIA_Play_Actor_Dialogue(51, 10);
+ KIA_Play_Actor_Dialogue(51, 20);
+ KIA_Play_Actor_Dialogue(51, 30);
+ break;
+ case 280:
+ KIA_Play_Actor_Dialogue(15, 630);
+ KIA_Play_Actor_Dialogue(15, 640);
+ KIA_Play_Actor_Dialogue(15, 650);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kia.h b/engines/bladerunner/script/kia.h
new file mode 100644
index 0000000000..d7b5836e8d
--- /dev/null
+++ b/engines/bladerunner/script/kia.h
@@ -0,0 +1,45 @@
+/* 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.
+ *
+ */
+
+#ifndef BLADERUNNER_SCRIPT_KIA_H
+#define BLADERUNNER_SCRIPT_KIA_H
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+class BladeRunnerEngine;
+
+class ScriptKIA : ScriptBase {
+public:
+ ScriptKIA(BladeRunnerEngine *vm)
+ : ScriptBase(vm) {
+ }
+
+ void SCRIPT_KIA_DLL_Play_Clue_Asset_Script(int a1, int clueId);
+
+private:
+};
+
+} // End of namespace BladeRunner
+
+#endif
diff --git a/engines/bladerunner/script/kp01.cpp b/engines/bladerunner/script/kp01.cpp
new file mode 100644
index 0000000000..b4a91e79cf
--- /dev/null
+++ b/engines/bladerunner/script/kp01.cpp
@@ -0,0 +1,171 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP01::InitializeScene() {
+ if (Game_Flag_Query(416)) {
+ Setup_Scene_Information(-125.0f, -12.2f, -61.0f, 400);
+ } else if (Game_Flag_Query(418)) {
+ Setup_Scene_Information(-284.0f, -12.2f, -789.0f, 445);
+ } else {
+ Setup_Scene_Information(239.0f, -12.2f, -146.0f, 820);
+ Game_Flag_Reset(413);
+ if (!Game_Flag_Query(674) && !Game_Flag_Query(653)) {
+ Game_Flag_Set(674);
+ Actor_Set_Goal_Number(1, 420);
+ }
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 150, 0, 200, 276, 0);
+ Scene_Exit_Add_2D_Exit(2, 589, 0, 639, 479, 1);
+ Ambient_Sounds_Add_Looping_Sound(464, 34, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(383, 27, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 90, 1, 1);
+ Ambient_Sounds_Add_Sound(440, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(441, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(442, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptKP01::SceneLoaded() {
+ Unobstacle_Object("TRAINCAR-1", true);
+ Unobstacle_Object("FORE-JUNK-02", true);
+ Obstacle_Object("OBSTACLE1", true);
+ Obstacle_Object("TUBE1", true);
+ Unclickable_Object("OBSTACLE1");
+}
+
+bool ScriptKP01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptKP01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -125.0f, -12.2f, -61.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(415);
+ Set_Enter(47, 44);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -284.0f, -12.2f, -789.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(417);
+ Set_Enter(46, 43);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 239.0f, 12.2f, -146.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(414);
+ Set_Enter(45, 42);
+ }
+ return true;
+ }
+ return false;
+}
+
+
+bool ScriptKP01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP01::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 1) {
+ if (newGoal == 422) {
+ if (Game_Flag_Query(378) == 1) {
+ Delay(500);
+ Actor_Change_Animation_Mode(0, 75);
+ Delay(4500);
+ Actor_Face_Current_Camera(0, true);
+ Actor_Says(0, 510, 3);
+ } else {
+ Delay(3000);
+ }
+ Async_Actor_Walk_To_XYZ(0, 76.56f, -12.2f, -405.48f, 0, false);
+ //return true;
+ } else if (newGoal == 423) {
+ Player_Gains_Control();
+ Actor_Force_Stop_Walking(0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(417);
+ Set_Enter(46, 43);
+ //return true;
+ }
+ }
+ //return false;
+}
+
+void ScriptKP01::PlayerWalkedIn() {
+ if (Game_Flag_Query(416)) {
+ Loop_Actor_Walk_To_XYZ(0, -93.0f, -12.2f, -61.0f, 0, 0, false, 0);
+ Game_Flag_Reset(416);
+ } else if (Game_Flag_Query(418)) {
+ Loop_Actor_Walk_To_XYZ(0, -240.0f, -12.2f, -789.0f, 0, 0, false, 0);
+ Game_Flag_Reset(418);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 211.0f, -12.2f, -146.0f, 0, 0, false, 0);
+ if (!Game_Flag_Query(653)
+ && !Game_Flag_Query(714)
+ && Actor_Query_Goal_Number(1) == 420
+ && Actor_Query_Goal_Number(1) != 599) {
+ Player_Loses_Control();
+ Actor_Set_Goal_Number(1, 421);
+ }
+ }
+}
+
+void ScriptKP01::PlayerWalkedOut() {
+}
+
+void ScriptKP01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp02.cpp b/engines/bladerunner/script/kp02.cpp
new file mode 100644
index 0000000000..08a2b835ac
--- /dev/null
+++ b/engines/bladerunner/script/kp02.cpp
@@ -0,0 +1,147 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP02::InitializeScene() {
+ if (Game_Flag_Query(414)) {
+ Setup_Scene_Information(-884.0f, -615.49f, 3065.0f, 20);
+ } else {
+ Setup_Scene_Information(-1040.0f, -615.49f, 2903.0f, 339);
+ Game_Flag_Reset(412);
+ }
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ Ambient_Sounds_Add_Looping_Sound(464, 34, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(383, 27, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 90, 1, 1);
+ Ambient_Sounds_Add_Sound(440, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(441, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(442, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptKP02::SceneLoaded() {
+ Obstacle_Object("VAN GRATE", true);
+ Clickable_Object("VAN GRATE");
+ Unobstacle_Object("VAN GRATE", true);
+ Unobstacle_Object("BOX05", true);
+ Unobstacle_Object("BOX08", true);
+ Unobstacle_Object("BOX09", true);
+ Unobstacle_Object("BOX01", true);
+ Unclickable_Object("VAN GRATE");
+}
+
+bool ScriptKP02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptKP02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1040.0f, -615.49f, 2903.0f, 0, 1, false, 0)) {
+ if (Actor_Query_Goal_Number(65) == 406 || Actor_Query_Goal_Number(64) == 406) {
+ Non_Player_Actor_Combat_Mode_Off(65);
+ Non_Player_Actor_Combat_Mode_Off(64);
+ Actor_Set_Goal_Number(65, 400);
+ Actor_Set_Goal_Number(64, 400);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(411);
+ Set_Enter(84, 96);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(411);
+ Set_Enter(84, 96);
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -884.0f, -615.49f, 3065.0f, 0, 1, false, 0)) {
+ if (Actor_Query_Goal_Number(65) == 406 || Actor_Query_Goal_Number(64) == 406) {
+ Non_Player_Actor_Combat_Mode_Off(65);
+ Non_Player_Actor_Combat_Mode_Off(64);
+ Actor_Set_Goal_Number(65, 400);
+ Actor_Set_Goal_Number(64, 400);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(413);
+ Set_Enter(44, 41);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(413);
+ Set_Enter(44, 41);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP02::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP02::PlayerWalkedIn() {
+ if (Game_Flag_Query(414)) {
+ Loop_Actor_Walk_To_XYZ(0, -884.0f, -615.49f, 3035.0f, 0, 0, false, 0);
+ Game_Flag_Reset(414);
+ }
+ if (Game_Flag_Query(653) && Actor_Query_Goal_Number(1) != 599) {
+ Actor_Set_Goal_Number(1, 450);
+ }
+ //return false;
+}
+
+void ScriptKP02::PlayerWalkedOut() {
+}
+
+void ScriptKP02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp03.cpp b/engines/bladerunner/script/kp03.cpp
new file mode 100644
index 0000000000..a037ff63e5
--- /dev/null
+++ b/engines/bladerunner/script/kp03.cpp
@@ -0,0 +1,262 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP03::InitializeScene() {
+ if (Game_Flag_Query(420)) {
+ Setup_Scene_Information(1.0f, -36.55f, 111.0f, 200);
+ } else {
+ Setup_Scene_Information(-321.0f, -36.55f, 26.0f, 350);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 287, 104, 367, 255, 0);
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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 (Game_Flag_Query(422)) {
+ Scene_Loop_Set_Default(5);
+ } else if (Game_Flag_Query(484)) {
+ Scene_Loop_Set_Default(7);
+ } else {
+ Scene_Loop_Set_Default(2);
+ Game_Flag_Set(421);
+ }
+ if (Actor_Query_Goal_Number(1) != 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(1, 46);
+ Actor_Set_At_XYZ(1, -300.0f, -36.55f, 26.0f, 350);
+ }
+}
+
+void ScriptKP03::SceneLoaded() {
+ Obstacle_Object("BRACK MID", true);
+ Unobstacle_Object("OBSTACLE_REMOVE", true);
+ Unobstacle_Object("BOX11", true);
+ Unobstacle_Object("OBSTACLE05", true);
+ Clickable_Object("BRACK MID");
+}
+
+bool ScriptKP03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP03::ClickedOn3DObject(const char *objectName, bool a2) {
+ Actor_Face_Object(1, "BRACK MID", true);
+ if (Object_Query_Click("BRACK MID", objectName) && !Game_Flag_Query(422)) {
+ if (a2) {
+ Scene_Loop_Set_Default(5);
+ Scene_Loop_Start_Special(2, 4, 1);
+ Actor_Change_Animation_Mode(0, 39);
+ Actor_Retired_Here(0, 72, 18, 1, -1);
+ Game_Flag_Set(422);
+ Game_Flag_Reset(421);
+ return false;
+ }
+ if (Actor_Query_Goal_Number(1) == 411) {
+ Scene_Exits_Enable();
+ sub_401E54();
+ } else {
+ if (Game_Flag_Query(417)) {
+ Loop_Actor_Walk_To_XYZ(0, -137.0f, -36.55f, 26.0f, 0, 0, true, 0);
+ } else if (Game_Flag_Query(420)) {
+ Loop_Actor_Walk_To_XYZ(0, -50.0f, -36.55f, 78.0f, 0, 0, true, 0);
+ }
+ if (Game_Flag_Query(421)) {
+ Actor_Face_Object(0, "BRACK MID", true);
+ Game_Flag_Set(484);
+ Game_Flag_Reset(421);
+ Scene_Loop_Set_Default(7);
+ Scene_Loop_Start_Special(2, 0, 0);
+ Actor_Voice_Over(1110, 99);
+ Actor_Voice_Over(1120, 99);
+ } else {
+ Actor_Face_Object(0, "BRACK MID", true);
+ Actor_Says(0, 8580, 13);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP03::ClickedOnActor(int actorId) {
+ if (actorId == 1 && Actor_Query_Goal_Number(1) == 411) {
+ Actor_Face_Object(1, "BRACK MID", true);
+ sub_401E54();
+ }
+ return false;
+}
+
+bool ScriptKP03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP03::ClickedOnExit(int exitId) {
+ if (Actor_Query_Goal_Number(1) == 410) {
+ Actor_Set_Goal_Number(1, 418);
+ } else {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1.0f, -36.55f, 111.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Music_Stop(2);
+ Game_Flag_Reset(417);
+ Game_Flag_Reset(420);
+ Game_Flag_Set(419);
+ Set_Enter(9, 45);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -321.0f, -36.55f, 26.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Music_Stop(2);
+ Game_Flag_Reset(417);
+ Game_Flag_Reset(420);
+ Game_Flag_Set(418);
+ Set_Enter(44, 41);
+ }
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptKP03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP03::SceneFrameAdvanced(int frame) {
+ int v1;
+ float x, y, z;
+
+ if (frame == 123) {
+ Ambient_Sounds_Play_Sound(491, 99, -60, 100, 99);
+ }
+ if (Game_Flag_Query(421) && !Game_Flag_Query(484)) {
+ v1 = -1;
+ if (!Game_Flag_Query(422)) {
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (Game_Flag_Query(417) && -130.0f < x || Game_Flag_Query(420) && -130.0f > x) {
+ v1 = 0;
+ }
+ }
+ if (!Game_Flag_Query(422)) { //todo ? same condition as before
+ Actor_Query_XYZ(1, &x, &y, &z);
+ if (Game_Flag_Query(653) && Actor_Query_Which_Set_In(1) == 46) {
+ if (Game_Flag_Query(417) && -130.0f > x || Game_Flag_Query(420) && -130.0f < x) {
+ v1 = 1;
+ }
+ } else if (Game_Flag_Query(417) && -130.0f < x || Game_Flag_Query(420) && -130.0f > x) {
+ v1 = 1;
+ }
+ }
+ if (v1 != -1) {
+ Scene_Loop_Set_Default(5);
+ Scene_Loop_Start_Special(2, 4, 1);
+ Game_Flag_Set(422);
+ Game_Flag_Reset(421);
+ Unclickable_Object("BRACK MID");
+ Scene_Exits_Enable();
+ if (v1 == 1) {
+ Actor_Set_Goal_Number(1, 415);
+ Music_Play(12, 25, 0, 1, -1, 0, 0);
+ if (Actor_Query_Inch_Distance_From_Actor(0, 1) <= 120) {
+ v1 = 0;
+ }
+ }
+ if (v1) {
+ Actor_Change_Animation_Mode(0, 21);
+ } else {
+ Actor_Force_Stop_Walking(0);
+ Actor_Change_Animation_Mode(0, 48);
+ Actor_Retired_Here(0, 72, 18, 1, -1);
+ }
+ }
+ }
+}
+
+void ScriptKP03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP03::PlayerWalkedIn() {
+ if (Game_Flag_Query(420)) {
+ Loop_Actor_Walk_To_XYZ(0, 1.0f, -36.55f, 87.0f, 0, 0, false, 0);
+ }
+ if (Actor_Query_Is_In_Current_Set(1) && Actor_Query_Goal_Number(1) != 419) {
+ if (Game_Flag_Query(653)) {
+ if (Game_Flag_Query(420)) {
+ Actor_Set_Goal_Number(1, 410);
+ }
+ } else if (!Game_Flag_Query(422) && !Game_Flag_Query(484) && Game_Flag_Query(417)) {
+ Scene_Exits_Disable();
+ Delay(1000);
+ Actor_Set_Goal_Number(1, 411);
+ }
+ }
+}
+
+void ScriptKP03::PlayerWalkedOut() {
+}
+
+void ScriptKP03::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptKP03::sub_401E54() {
+ Player_Loses_Control();
+ Actor_Says(0, 2180, 14);
+ Actor_Set_Goal_Number(1, 412);
+ Actor_Says(1, 480, 60);
+ Actor_Face_Object(0, "BRACK MID", true);
+ Actor_Says(0, 2185, 14);
+ Loop_Actor_Walk_To_XYZ(1, -137.0f, -36.55f, 26.0f, 0, 0, false, 0);
+ Actor_Face_Object(1, "BRACK MID", true);
+ Actor_Says(1, 490, 58);
+ Actor_Says(0, 2190, 14);
+ Actor_Says(1, 500, 58);
+ Actor_Says(1, 510, 59);
+ Actor_Says(1, 520, 60);
+ Game_Flag_Set(484);
+ Game_Flag_Reset(421);
+ Scene_Loop_Set_Default(7);
+ Scene_Loop_Start_Special(2, 7, 0);
+ Actor_Set_Goal_Number(1, 413);
+ Actor_Says(0, 2195, 14);
+ Ambient_Sounds_Play_Sound(151, 40, -60, -60, 0);
+ Loop_Actor_Walk_To_XYZ(0, 1.0f, -36.55f, 111.0f, 0, 0, false, 0);
+ Actor_Set_Goal_Number(1, 430);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Reset(417);
+ Game_Flag_Reset(420);
+ Game_Flag_Set(419);
+ Set_Enter(9, 45);
+ Player_Gains_Control();
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp04.cpp b/engines/bladerunner/script/kp04.cpp
new file mode 100644
index 0000000000..cc2ed3fe71
--- /dev/null
+++ b/engines/bladerunner/script/kp04.cpp
@@ -0,0 +1,118 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP04::InitializeScene() {
+ if (Game_Flag_Query(575)) {
+ Setup_Scene_Information(-544.0f, 94.89f, 288.0f, 700);
+ } else {
+ Setup_Scene_Information(-905.0f, 94.89f, 1357.0f, 970);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 455, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 475, 247, 514, 416, 1);
+ Ambient_Sounds_Add_Looping_Sound(464, 34, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(383, 27, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 90, 1, 1);
+ Ambient_Sounds_Add_Sound(440, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(441, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(442, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptKP04::SceneLoaded() {
+ Obstacle_Object("BUILDING04", true);
+ Unobstacle_Object("BOX06", true);
+ Unclickable_Object("BUILDING04");
+}
+
+bool ScriptKP04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP04::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptKP04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -905.0f, 94.89f, 1357.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(416);
+ Set_Enter(44, 41);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -544.0f, 94.89f, 288.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(574);
+ Set_Enter(9, 45);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP04::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP04::PlayerWalkedIn() {
+ if (Game_Flag_Query(575)) {
+ Loop_Actor_Walk_To_XYZ(0, -584.0f, 94.89f, 288.0f, 0, 0, false, 0);
+ Game_Flag_Reset(575);
+ } else {
+ Game_Flag_Reset(415);
+ }
+}
+
+void ScriptKP04::PlayerWalkedOut() {
+}
+
+void ScriptKP04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp05.cpp b/engines/bladerunner/script/kp05.cpp
new file mode 100644
index 0000000000..2e1de932d4
--- /dev/null
+++ b/engines/bladerunner/script/kp05.cpp
@@ -0,0 +1,171 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP05::InitializeScene() {
+ if (Game_Flag_Query(577)) {
+ Setup_Scene_Information(-868.0f, 0.0f, -68.0f, 520);
+ } else if (Game_Flag_Query(574)) {
+ Setup_Scene_Information(-1142.0f, 0.0f, 932.0f, 276);
+ } else {
+ Setup_Scene_Information(-802.0f, 0.0f, 972.0f, 800);
+ }
+ Scene_Exit_Add_2D_Exit(0, 589, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(2, 0, 0, 257, 204, 0);
+ Ambient_Sounds_Add_Looping_Sound(464, 34, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(383, 27, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 90, 1, 1);
+ Ambient_Sounds_Add_Sound(440, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(441, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(442, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptKP05::SceneLoaded() {
+ Unobstacle_Object("OBSTACLEBOX20", true);
+ Clickable_Object("BRIDGE02");
+ Unclickable_Object("BRIDGE02");
+ if (!Actor_Clue_Query(0, 145) && Game_Flag_Query(653)) {
+ Item_Add_To_World(118, 960, 9, -1095.0f, 0.0f, 770.0f, 256, 24, 24, false, true, false, true);
+ }
+}
+
+bool ScriptKP05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP05::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptKP05::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 118) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1058.0f, 0.0f, 852.0f, 0, 1, false, 0)) {
+ Actor_Face_Item(0, 118, true);
+ Actor_Clue_Acquire(0, 145, 1, -1);
+ Item_Remove_From_World(118);
+ Item_Pickup_Spin_Effect(960, 58, 321);
+ }
+ }
+ return false;
+}
+
+bool ScriptKP05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -802.0f, 0.0f, 972.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(420);
+ Set_Enter(46, 43);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1142.0f, 0.0f, 932.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(575);
+ Set_Enter(47, 44);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -868.0f, 0.0f, -68.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(576);
+ Async_Actor_Walk_To_XYZ(0, -868.0f, 0.0f, -216.0f, 0, false);
+ Set_Enter(9, 46);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP05::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP05::PlayerWalkedIn() {
+ if (Game_Flag_Query(577)) {
+ Game_Flag_Reset(577);
+ } else if (Game_Flag_Query(574)) {
+ Loop_Actor_Walk_To_XYZ(0, -1110.0f, 0.0f, 932.0f, 0, 0, false, 0);
+ Game_Flag_Reset(574);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -846.0f, 0.0f, 972.0f, 0, 0, false, 0);
+ Game_Flag_Query(419);
+ }
+ if (Actor_Query_Goal_Number(66) == 411) {
+ Actor_Set_Goal_Number(66, 412);
+ }
+ if (Actor_Query_Goal_Number(1) == 450) {
+ Scene_Exits_Disable();
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says(1, 530, 15);
+ Actor_Says(1, 540, 16);
+ Actor_Face_Actor(0, 1, true);
+ Player_Set_Combat_Mode(true);
+ Actor_Says(0, 2200, 3);
+ Actor_Says(1, 550, 17);
+ Actor_Says(0, 2205, 3);
+ Actor_Says(1, 560, 15);
+ Actor_Says(1, 570, 16);
+ Actor_Says(1, 580, 13);
+ Actor_Says(0, 2210, 3);
+ Actor_Says(1, 590, 13);
+ Actor_Says(0, 2215, 3);
+ Actor_Says(1, 600, 16);
+ Actor_Says(1, 610, 15);
+ Actor_Says(0, 2220, 3);
+ Actor_Says(1, 620, 15);
+ Actor_Says(1, 630, 17);
+ Non_Player_Actor_Combat_Mode_On(1, 0, 1, 0, 9, 4, 7, 8, 0, -1, -1, 20, 240, 0);
+ }
+}
+
+void ScriptKP05::PlayerWalkedOut() {
+}
+
+void ScriptKP05::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp06.cpp b/engines/bladerunner/script/kp06.cpp
new file mode 100644
index 0000000000..094cc257c9
--- /dev/null
+++ b/engines/bladerunner/script/kp06.cpp
@@ -0,0 +1,237 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP06::InitializeScene() {
+ if (Game_Flag_Query(579) ) {
+ Setup_Scene_Information(-755.0f, 8.26f, -665.0f, 640);
+ } else {
+ Setup_Scene_Information(-868.0f, 8.26f, -8.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 270, 445, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 320, 158, 352, 220, 0);
+ Ambient_Sounds_Add_Looping_Sound(464, 34, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(383, 27, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 90, 1, 1);
+ Ambient_Sounds_Add_Sound(440, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(441, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(442, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 5, 180, 50, 100, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 25, 33, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(576) ) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(576);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptKP06::SceneLoaded() {
+ Obstacle_Object("TRASH CAN WITH FIRE", true);
+ Obstacle_Object("MOONBUS", true);
+ Obstacle_Object("STAIR 1", true);
+ Obstacle_Object("COCKPIT FRONT", true);
+ Unobstacle_Object("OBSTACLEBOX28", true);
+ Unobstacle_Object("OBSTACLEBOX32", true);
+ Unclickable_Object("TRASH CAN WITH FIRE");
+}
+
+bool ScriptKP06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP06::ClickedOnActor(int actorId) {
+ if (actorId == 8 && !Game_Flag_Query(714)) {
+ if (Actor_Clue_Query(8, 145)) {
+ Actor_Face_Actor(0, 8, true);
+ Actor_Says(0, 8610, 15);
+ Actor_Says(8, 290, 3);
+ } else if (Actor_Clue_Query(0, 145) ) {
+ Actor_Says(8, 280, 3);
+ Actor_Says(8, 290, 3);
+ Actor_Clue_Acquire(8, 145, 1, 0);
+ } else {
+ Actor_Says(0, 2320, 3);
+ Actor_Says(0, 2325, 3);
+ Actor_Says(8, 300, 3);
+ Actor_Says(8, 310, 3);
+ }
+ }
+ return false;
+}
+
+bool ScriptKP06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -868.0f, 8.26f, -68.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(577);
+ Set_Enter(9, 45);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (Actor_Clue_Query(8, 145) || Actor_Query_Goal_Number(8) != 416) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -731.0f, 8.26f, -657.0f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(653)) {
+ if (!Game_Flag_Query(714)) {
+ Player_Set_Combat_Mode(false);
+ }
+ } else if (Actor_Query_Goal_Number(1) == 433) {
+ Actor_Set_Goal_Number(1, 499);
+ } else {
+ Actor_Set_Goal_Number(53, 499);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(578);
+ Set_Enter(48, 47);
+ }
+ } else if (Actor_Clue_Query(0, 145) ) {
+ Actor_Says(8, 280, 3);
+ Actor_Says(8, 290, 3);
+ Actor_Clue_Acquire(8, 145, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, -731.0f, 8.26f, -657.0f, 0, 0, true, 0);
+ Player_Set_Combat_Mode(false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(578);
+ Set_Enter(48, 47);
+ } else {
+ Actor_Set_Goal_Number(8, 417);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP06::PlayerWalkedIn() {
+ if (!Game_Flag_Query(653) && Game_Flag_Query(579)) {
+ Game_Flag_Reset(579);
+ if (Actor_Query_Goal_Number(1) == 499) {
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says(1, 2530, 13);
+ Actor_Face_Actor(0, 1, true);
+ Actor_Says(0, 6200, 11);
+ Actor_Says(1, 2540, 15);
+ Actor_Says(1, 2550, 12);
+ Actor_Says(0, 6205, 14);
+ if (Actor_Query_Friendliness_To_Other(1, 0) < 50) {
+ Actor_Says(1, 2560, 12);
+ Actor_Says(0, 6210, 14);
+ Actor_Says(1, 2570, 13);
+ Actor_Says(0, 6215, 14);
+ Actor_Says(1, 2580, 15);
+ Actor_Says(1, 2590, 12);
+ }
+ Async_Actor_Walk_To_Waypoint(0, 551, 0, 0);
+ Delay(1000);
+ Actor_Says(0, 6220, -1);
+ Delay(3000);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(25, 0, -1);
+ Game_Over();
+ //return true;
+ return;
+ } else {
+ Actor_Set_Goal_Number(53, 499);
+ Actor_Face_Actor(53, 0, true);
+ Actor_Says(53, 220, 13);
+ Actor_Face_Actor(0, 53, true);
+ Actor_Says(0, 6245, 11);
+ Actor_Says(53, 230, 14);
+ if (Game_Flag_Query(714)) {
+ Actor_Says(0, 6250, 15);
+ Actor_Says(53, 240, 13);
+ Delay(1000);
+ Actor_Says(0, 6255, 17);
+ Actor_Says(53, 250, 14);
+ Delay(1000);
+ }
+ Actor_Says(53, 260, 12);
+ Actor_Says(0, 6260, 15);
+ Actor_Says(53, 270, 13);
+ Actor_Says(53, 280, 15);
+ Actor_Says(0, 6265, 14);
+ Actor_Says(53, 290, 14);
+ Actor_Says(53, 300, 15);
+ Actor_Says(0, 6270, 11);
+ Async_Actor_Walk_To_Waypoint(0, 550, 0, 0);
+ Async_Actor_Walk_To_Waypoint(53, 551, 0, 0);
+ Actor_Says(53, 310, -1);
+ Delay(3000);
+ Outtake_Play(26, 0, -1);
+ Game_Over();
+ //return true;
+ return;
+ }
+ } else {
+ if (Actor_Query_Goal_Number(8) == 414) {
+ Loop_Actor_Walk_To_XYZ(0, -809.0f, 8.26f, -619.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 8, true);
+ Actor_Set_Goal_Number(8, 415);
+ }
+ if (Actor_Query_Goal_Number(1) == 431) {
+ Actor_Set_Goal_Number(1, 432);
+ }
+ //return false;
+ return;
+ }
+}
+
+void ScriptKP06::PlayerWalkedOut() {
+ if (Game_Flag_Query(578) && Actor_Query_Goal_Number(1) == 433) {
+ Actor_Set_Goal_Number(1, 499);
+ }
+}
+
+void ScriptKP06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/kp07.cpp b/engines/bladerunner/script/kp07.cpp
new file mode 100644
index 0000000000..1c9f6a7b3f
--- /dev/null
+++ b/engines/bladerunner/script/kp07.cpp
@@ -0,0 +1,178 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptKP07::InitializeScene() {
+ Setup_Scene_Information(-12.0f, -41.58f, 72.0f, 0);
+ Game_Flag_Reset(578);
+ Scene_Exit_Add_2D_Exit(0, 315, 185, 381, 285, 0);
+ if (Game_Flag_Query(653)) {
+ if (Game_Flag_Query(47) && Actor_Query_Goal_Number(3) < 599) {
+ Actor_Set_Targetable(3, true);
+ Global_Variable_Increment(51, 1);
+ Actor_Put_In_Set(3, 48);
+ Actor_Set_At_XYZ(3, -52.0f, -41.52f, -5.0f, 289);
+ }
+ if (Actor_Query_Goal_Number(19) < 599) {
+ Global_Variable_Increment(51, 1);
+ Actor_Set_Targetable(19, true);
+ Actor_Put_In_Set(19, 48);
+ Actor_Set_At_XYZ(19, -26.0f, -41.52f, -135.0f, 0);
+ }
+ if (Game_Flag_Query(44) && Actor_Query_Goal_Number(7) < 599) {
+ Global_Variable_Increment(51, 1);
+ Actor_Set_Targetable(7, true);
+ Actor_Put_In_Set(7, 48);
+ Actor_Set_At_XYZ(7, -38.0f, -41.52f, -175.0f, 500);
+ }
+ if (Game_Flag_Query(45) && Actor_Query_Goal_Number(2) < 599) {
+ Global_Variable_Increment(51, 1);
+ Actor_Set_Targetable(2, true);
+ Actor_Put_In_Set(2, 48);
+ Actor_Set_At_XYZ(2, 61.0f, -41.52f, -3.0f, 921);
+ }
+ if (Game_Flag_Query(46) && Actor_Query_Goal_Number(6) < 599) {
+ Global_Variable_Increment(51, 1);
+ Actor_Put_In_Set(6, 48);
+ Actor_Set_At_XYZ(6, 78.0f, -41.52f, -119.0f, 659);
+ }
+ if (Actor_Query_Goal_Number(10) < 599) {
+ Global_Variable_Increment(51, 1);
+ Actor_Put_In_Set(10, 48);
+ Actor_Set_At_XYZ(10, -47.0f, 0.0f, 151.0f, 531);
+ }
+ }
+ Ambient_Sounds_Add_Looping_Sound(585, 7, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(586, 52, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(109, 38, 1, 1);
+ if (Game_Flag_Query(582)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptKP07::SceneLoaded() {
+ if (!Game_Flag_Query(653)) {
+ Music_Play(19, 25, 0, 0, -1, 1, 0);
+ }
+ Obstacle_Object("BUNK_TRAY01", true);
+ Unobstacle_Object("BUNK_TRAY01", true);
+ if (Game_Flag_Query(653)) {
+ Player_Set_Combat_Mode(false);
+ Scene_Exits_Disable();
+ }
+}
+
+bool ScriptKP07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptKP07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptKP07::ClickedOnActor(int actorId) {
+ if (actorId == 5) {
+ if (Game_Flag_Query(697) || actorId != 5 || Actor_Query_Goal_Number(5) == 599 || Actor_Query_Goal_Number(5) == 515) {
+ return false;
+ }
+ if (Game_Flag_Query(653)) {
+ Actor_Set_Goal_Number(5, 516);
+ } else {
+ Music_Play(20, 31, 0, 0, -1, 1, 0);
+ Actor_Set_Goal_Number(5, 514);
+ }
+ } else {
+ Actor_Face_Actor(0, actorId, true);
+ Actor_Says(0, 8590, 14);
+ }
+ return true;
+}
+
+bool ScriptKP07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptKP07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -12.0f, -41.58f, 72.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(579);
+ Set_Enter(9, 46);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptKP07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptKP07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptKP07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptKP07::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, 9.0f, -41.88f, -81.0f, 0, 0, false, 0);
+ if (!Game_Flag_Query(658)) {
+ if (Game_Flag_Query(653)) {
+ Actor_Face_Actor(0, 5, true);
+ Actor_Says(5, 1240, 3);
+ Actor_Says(0, 8500, 3);
+ Actor_Says(5, 1250, 3);
+ if (Actor_Query_Goal_Number(8) == 416) {
+ Actor_Put_In_Set(8, 48);
+ Global_Variable_Increment(51, 1);
+ Actor_Set_At_XYZ(8, -12.0f, -41.58f, 72.0f, 0);
+ Actor_Face_Actor(8, 5, true);
+ }
+ } else {
+ Actor_Face_Actor(0, 5, true);
+ Actor_Says(5, 160, 3);
+ Actor_Retired_Here(5, 72, 60, 0, -1);
+ }
+ Game_Flag_Set(658);
+ }
+}
+
+void ScriptKP07::PlayerWalkedOut() {
+ Music_Stop(3);
+}
+
+void ScriptKP07::DialogueQueueFlushed(int a1) {
+ if (Actor_Query_Goal_Number(5) == 515) {
+ Actor_Set_Targetable(5, false);
+ Actor_Change_Animation_Mode(5, 21);
+ Actor_Retired_Here(5, 12, 48, 1, -1);
+ Actor_Set_Goal_Number(5, 599);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma01.cpp b/engines/bladerunner/script/ma01.cpp
new file mode 100644
index 0000000000..482c31ede9
--- /dev/null
+++ b/engines/bladerunner/script/ma01.cpp
@@ -0,0 +1,257 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA01::InitializeScene() {
+ Setup_Scene_Information(381.0f, 0.0f, 54.0f, 992);
+ if (Game_Flag_Query(250)) {
+ Setup_Scene_Information(381.0f, 0.0f, 54.0f, 992);
+ }
+ if (Game_Flag_Query(38)) {
+ Setup_Scene_Information(1446.0f, 0.0f, -725.0f, 660);
+ }
+ Scene_Exit_Add_2D_Exit(0, 328, 132, 426, 190, 0);
+ if (Game_Flag_Query(250)) {
+ Scene_Exit_Add_2D_Exit(1, 234, 240, 398, 328, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(101, 90, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(99, 40, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(100, 40, 100, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(38)) {
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(38);
+ } else {
+ Actor_Set_Invisible(0, true);
+ Game_Flag_Set(273);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ }
+ if (Game_Flag_Query(409)) {
+ Actor_Set_Goal_Number(53, 3);
+ Game_Flag_Reset(409);
+ }
+}
+
+void ScriptMA01::SceneLoaded() {
+ Obstacle_Object("WRENCH", true);
+ Unobstacle_Object("OBSTICLEBOX01", true);
+ Clickable_Object("WRENCH");
+ Unclickable_Object("Y2 PADRIM 01");
+ Unclickable_Object("Y2 PADRIM 02");
+ Unclickable_Object("NGON01");
+}
+
+bool ScriptMA01::MouseClick(int x, int y) {
+ return Region_Check(286, 326, 348, 384);
+}
+
+bool ScriptMA01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptMA01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA01::ClickedOnExit(int exitId) {
+ if (Actor_Query_Goal_Number(19) == 21) {
+ return true;
+ }
+ if (exitId == 0) {
+ if (Actor_Query_Goal_Number(19) == 20) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1446.0f, 0.0f, -725.0f, 72, 1, false, 0)) {
+ Actor_Set_Goal_Number(19, 21);
+ Scene_Exits_Disable();
+ }
+ } else if (!Loop_Actor_Walk_To_XYZ(0, 1446.0f, 0.0f, -725.0f, 12, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(37);
+ Set_Enter(52, 52);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 381.0f, 0.0f, 54.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Face_Heading(0, 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);
+ int spinnerDest = Spinner_Interface_Choose_Dest(3, 0);
+
+ switch (spinnerDest) {
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(250);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ default:
+ Actor_Set_Invisible(0, false);
+ Actor_Face_Heading(0, 736, false);
+ Game_Flag_Set(179);
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA01::SceneFrameAdvanced(int frame) {
+ if (frame == 15) {
+ Ambient_Sounds_Play_Sound(102, 70, -100, 100, 0);
+ }
+ if (frame == 61 || frame == 183) {
+ Ambient_Sounds_Play_Sound(116, 100, 40, 0, 99);
+ }
+ if (frame == 107 || frame == 227) {
+ Ambient_Sounds_Play_Sound(119, 100, 40, 0, 99);
+ }
+ if (frame == 1) {
+ Ambient_Sounds_Play_Sound(118, 40, -60, 20, 99);
+ }
+ if (frame == 241) {
+ Ambient_Sounds_Play_Sound(117, 40, 0, 0, 99);
+ }
+ if (frame == 58) {
+ Sound_Play(122, 17, 20, 20, 50);
+ }
+ if ((frame == 75 || frame == 196) && Game_Flag_Query(273)) {
+ Actor_Face_Heading(0, 736, false);
+ Actor_Change_Animation_Mode(0, 42);
+ Game_Flag_Reset(273);
+ } else {
+ if (frame == 196 && !Game_Flag_Query(273)) {
+ Actor_Change_Animation_Mode(0, 41);
+ //return true;
+ return;
+ }
+ if (frame == 240) {
+ Player_Gains_Control();
+ }
+ }
+ //return true;
+}
+
+void ScriptMA01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA01::PlayerWalkedIn() {
+}
+
+void ScriptMA01::PlayerWalkedOut() {
+ Actor_Set_Invisible(0, false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(37) && Global_Variable_Query(1) == 1) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(37, 1, -1);
+ Outtake_Play(34, 1, -1);
+ Outtake_Play(36, 1, -1);
+ }
+}
+
+void ScriptMA01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma02.cpp b/engines/bladerunner/script/ma02.cpp
new file mode 100644
index 0000000000..6448b93caa
--- /dev/null
+++ b/engines/bladerunner/script/ma02.cpp
@@ -0,0 +1,267 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA02::InitializeScene() {
+ if (Game_Flag_Query(36)) {
+ Setup_Scene_Information(-172.0f, -144.13f, 6.27f, 500);
+ } else {
+ Setup_Scene_Information(23.19f, -144.12f, 378.27f, 750);
+ if (Global_Variable_Query(1) == 4) {
+ Actor_Set_Goal_Number(40, 300);
+ }
+ Game_Flag_Reset(711);
+ }
+ Scene_Exit_Add_2D_Exit(0, 538, 84, 639, 327, 1);
+ Scene_Exit_Add_2D_Exit(1, 56, 98, 150, 260, 0);
+ if (Global_Variable_Query(1) >= 4 && Global_Variable_Query(1) == 5 && Game_Flag_Query(653)) {
+ Actor_Set_Goal_Number(66, 599);
+ Actor_Change_Animation_Mode(66, 88);
+ Actor_Put_In_Set(66, 10);
+ Actor_Set_At_XYZ(66, -35.51f, -144.12f, 428.0f, 0);
+ Actor_Retired_Here(66, 24, 24, 1, -1);
+ }
+ Ambient_Sounds_Add_Looping_Sound(104, 12, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(71, 25, 0, 1);
+ Ambient_Sounds_Add_Sound(72, 5, 30, 5, 5, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 30, 5, 5, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 30, 5, 5, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 60, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 60, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(87, 10, 60, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 14, 14, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 14, 14, 0, 0, -101, -101, 0, 0);
+ if (sub_401F7C()) {
+ Ambient_Sounds_Add_Sound(403, 3, 3, 27, 27, -100, -100, -100, -100, 99, 0);
+ }
+ if (Global_Variable_Query(1) == 5 && Game_Flag_Query(653) && !Actor_Clue_Query(0, 264)) {
+ Overlay_Play("MA02OVER", 0, 1, 0, 0);
+ }
+}
+
+void ScriptMA02::SceneLoaded() {
+ Obstacle_Object("COUCH1", true);
+ Unobstacle_Object("COUCH1", true);
+ Clickable_Object("BAR-MAIN");
+ Clickable_Object("E-ESPER");
+}
+
+bool ScriptMA02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA02::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("E-ESPER", objectName)) {
+ Actor_Face_Object(0, "E-ESPER", true);
+ Delay(1000);
+ ESPER_Flag_To_Activate();
+ return true;
+ }
+ if (Object_Query_Click("BAR-MAIN", objectName) && !Loop_Actor_Walk_To_XYZ(0, -29.0f, -140.4f, 298.0f, 36, 1, false, 0)) {
+ Actor_Face_Object(0, "BAR-MAIN", true);
+ if (Global_Variable_Query(1) < 4) {
+ Actor_Set_Goal_Number(66, 3);
+ } else if (Global_Variable_Query(1) == 5 && Game_Flag_Query(653) && !Actor_Clue_Query(0, 264)) {
+ Overlay_Remove("MA02OVER");
+ Item_Pickup_Spin_Effect(985, 480, 240);
+ Actor_Voice_Over(1150, 99);
+ Actor_Voice_Over(1160, 99);
+ Actor_Voice_Over(1170, 99);
+ Actor_Voice_Over(1180, 99);
+ Actor_Voice_Over(1190, 99);
+ Actor_Voice_Over(1200, 99);
+ Actor_Clue_Acquire(0, 264, 1, -1);
+ } else {
+ Actor_Says(0, 8526, 0);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA02::ClickedOnActor(int actorId) {
+ if (actorId == 66 && Actor_Query_Goal_Number(66) == 599) {
+ if (!Loop_Actor_Walk_To_Actor(0, 66, 30, 1, false)) {
+ Actor_Face_Actor(0, 66, true);
+ Actor_Voice_Over(1140, 99);
+ }
+ }
+ return false;
+}
+
+bool ScriptMA02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 23.19f, -144.12f, 378.27f, 0, 1, false, 0)) {
+ Music_Stop(10);
+ Game_Flag_Set(33);
+ Set_Enter(52, 52);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -168.0f, -144.13f, 10.27f, 0, 1, false, 0)) {
+ Game_Flag_Set(35);
+ Set_Enter(50, 50);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA02::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptMA02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA02::PlayerWalkedIn() {
+ if (Game_Flag_Query(34)) {
+ sub_402044();
+ }
+ if (Game_Flag_Query(36)) {
+ Loop_Actor_Walk_To_XYZ(0, -148.12f, -144.13f, 34.27f, 0, 1, false, 0);
+ }
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(655)) {
+ Game_Flag_Set(623);
+ Game_Flag_Set(655);
+ sub_401E4C();
+ Loop_Actor_Walk_To_XYZ(0, 23.19f, -144.12f, 378.27f, 0, 0, false, 0);
+ Game_Flag_Set(33);
+ Set_Enter(52, 52);
+ // return true;
+ return;
+ }
+ if (Global_Variable_Query(1) == 5 && !Game_Flag_Query(654)) {
+ if (Game_Flag_Query(653)) {
+ Actor_Says(0, 2390, 0);
+ Music_Play(2, 25, 0, 3, -1, 0, 0);
+ } else {
+ Actor_Says(0, 2385, 3);
+ }
+ Game_Flag_Set(654);
+ Autosave_Game(3);
+ }
+ if (Global_Variable_Query(1) < 4 && !Game_Flag_Query(36) && Actor_Query_Goal_Number(66) != 2) {
+ Actor_Set_Goal_Number(66, 1);
+ if (!Game_Flag_Query(60)) {
+ Game_Flag_Set(60);
+ Actor_Face_Actor(0, 66, true);
+ Actor_Voice_Over(1210, 99);
+ if (!Game_Flag_Query(378)) {
+ Actor_Voice_Over(1220, 99);
+ }
+ Actor_Voice_Over(1230, 99);
+ if (!Game_Flag_Query(378)) {
+ Actor_Voice_Over(1240, 99);
+ Actor_Voice_Over(1250, 99);
+ }
+ }
+ }
+ Game_Flag_Reset(36);
+ Game_Flag_Reset(34);
+ //return false;
+ return;
+}
+
+void ScriptMA02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptMA02::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptMA02::sub_401E4C() {
+ Actor_Says(0, 2365, 13);
+ Actor_Says(40, 0, 13);
+ Actor_Says(0, 2370, 13);
+ Actor_Says(40, 10, 13);
+ Actor_Says(0, 2375, 13);
+ Actor_Says(40, 20, 13);
+ Actor_Says(0, 2380, 13);
+ Sound_Play(492, 100, 0, 100, 50);
+ Actor_Says(40, 40, 13);
+ Delay(3000);
+}
+
+bool ScriptMA02::sub_401F7C() {
+ return Global_Variable_Query(1) == 5
+ && !Actor_Clue_Query(0, 143)
+ && !Actor_Clue_Query(0, 144)
+ && !Actor_Clue_Query(0, 139)
+ && !Actor_Clue_Query(0, 140)
+ && !Actor_Clue_Query(0, 141)
+ && !Actor_Clue_Query(0, 142);
+}
+
+void ScriptMA02::sub_402044() {
+ // int v0;
+ // int v1;
+ // int v3[7];
+
+ // v0 = 0;
+
+ int i = 0;
+ int arr[7];
+ if (Global_Variable_Query(1) < 4 && Game_Flag_Query(45)) {
+ // v0 = 1;
+ // v3[0] = 0;
+ arr[i++] = 0;
+ }
+
+ // v1 = v0 + 1;
+ // v3[v0] = 1;
+ arr[i++] = 1;
+ if (Global_Variable_Query(1) >= 3) {
+ // v3[v1] = 2;
+ // v1 = v0 + 2;
+ arr[i++] = 2;
+ }
+ if (Global_Variable_Query(1) >= 2 && Global_Variable_Query(1) <= 4) {
+ // v3[v1++] = 3;
+ arr[i++] = 3;
+ }
+ if (Game_Flag_Query(171) && Game_Flag_Query(170)) {
+ // v3[v1++] = 4;
+ arr[i++] = 4;
+ }
+ //if (v1 <= 0) {
+ if (i == 0) {
+ Global_Variable_Set(52, -1);
+ } else {
+ // Global_Variable_Set(52, v3[Random_Query(0, v1 - 1)]);
+ Global_Variable_Set(52, arr[Random_Query(0, i - 1)]);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma04.cpp b/engines/bladerunner/script/ma04.cpp
new file mode 100644
index 0000000000..3fb4c01752
--- /dev/null
+++ b/engines/bladerunner/script/ma04.cpp
@@ -0,0 +1,567 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA04::InitializeScene() {
+ if (Game_Flag_Query(63)) {
+ Setup_Scene_Information(-7199.0f, 953.97f, 1579.0f, 502);
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ }
+ } else if (Game_Flag_Query(35)) {
+ Setup_Scene_Information(-7099.0f, 954.0f, 1866.0f, 502);
+ } else if (Game_Flag_Query(647)) {
+ Setup_Scene_Information(-7107.0f, 954.0f, 1742.0f, 502);
+ Scene_Loop_Start_Special(0, 4, 0);
+ } else {
+ Setup_Scene_Information(-7143.0f, 954.0f, 1868.0f, 733);
+ }
+ Scene_Exit_Add_2D_Exit(0, 496, 0, 639, 354, 1);
+ Scene_Exit_Add_2D_Exit(1, 33, 63, 113, 258, 0);
+ Scene_Exit_Add_2D_Exit(2, 248, 98, 314, 284, 1);
+ Scene_2D_Region_Add(0, 343, 97, 353, 190);
+ Scene_2D_Region_Add(1, 0, 340, 116, 479);
+ Ambient_Sounds_Add_Looping_Sound(408, 30, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 30, -80, 1);
+ Ambient_Sounds_Add_Looping_Sound(104, 12, 0, 1);
+ Ambient_Sounds_Add_Sound(72, 5, 30, 11, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 30, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 30, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 60, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 60, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(87, 10, 60, 16, 16, -100, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ if (sub_402758()) {
+ Ambient_Sounds_Add_Sound(403, 3, 3, 100, 100, 0, 0, 0, 0, 99, 0);
+ }
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptMA04::SceneLoaded() {
+ Obstacle_Object("BED-DOG DISH", true);
+ Unobstacle_Object("BEDDog BONE", true);
+ Unobstacle_Object("BED-BOOK1", true);
+ Clickable_Object("BED-SHEETS");
+ if (Game_Flag_Query(711)) {
+ Unclickable_Object("BED-TV-1");
+ Unclickable_Object("BED-TV-2");
+ } else {
+ Clickable_Object("BED-TV-1");
+ Clickable_Object("BED-TV-2");
+ }
+}
+
+bool ScriptMA04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA04::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BED-SHEETS", objectName)) {
+ sub_403DA8();
+ return false;
+ }
+ if (Object_Query_Click("BED-TV-1", objectName) || Object_Query_Click("BED-TV-2", objectName)) {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "BED-TV-2", 24, 1, false)) {
+ Game_Flag_Set(711);
+ Unclickable_Object("BED-TV-1");
+ Unclickable_Object("BED-TV-2");
+ Sound_Play(132, 100, 0, 0, 50);
+ sub_403864();
+ return false;
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA04::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -7099.0f, 954.0f, 1866.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(36);
+ Set_Enter(10, 49);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (z <= 1677.0f || !Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1675.0f, 0, 1, false, 0)) {
+ if (sub_402888()) {
+ Overlay_Remove("MA04OVER");
+ }
+ Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1675.0f, 0, 0, false, 1);
+ Game_Flag_Set(62);
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Async_Actor_Walk_To_XYZ(0, -7199.0f, 956.17f, 1568.0f, 0, false);
+ }
+ Set_Enter(51, 51);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -7115.0f, 954.0f, 1742.0f, 0, 1, false, 0)) {
+ int sounds[] = {252, 405, 404, 407, 406};
+ Ambient_Sounds_Play_Sound(sounds[Random_Query(0, 4)], 50, 0, 0, 0);
+ Delay(3000);
+ Loop_Actor_Walk_To_XYZ(0, -7139.0f, 954.0f, 1746.0f, 0, 1, false, 1);
+ }
+ }
+ return false;
+}
+
+bool ScriptMA04::ClickedOn2DRegion(int region) {
+ if (Player_Query_Combat_Mode()) {
+ return false;
+ }
+ if (region == 1) {
+ sub_403DA8();
+ return true;
+ }
+ if (region == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -7176.0f, 954.0f, 1806.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 256, false);
+ if (sub_402758()) {
+ Actor_Says(0, 2680, 0);
+ Ambient_Sounds_Remove_Sound(403, true);
+ Sound_Play(123, 100, 0, 0, 50);
+ Overlay_Remove("MA04OVER");
+ Delay(500);
+ if (Game_Flag_Query(653)) {
+ if (Global_Variable_Query(45) == 2) {
+ sub_4028A8();
+ } else if (Global_Variable_Query(45) == 3) {
+ sub_402F2C();
+ } else {
+ sub_4034D8();
+ }
+ } else {
+ sub_4032A0();
+ }
+ Music_Play(2, 52, 0, 3, -1, 0, 0);
+ return false;
+ }
+ if (Actor_Clue_Query(5, 222) && !Game_Flag_Query(649)) {
+ Sound_Play(123, 100, 0, 0, 50);
+ Overlay_Remove("MA04OVER");
+ Delay(500);
+ Actor_Says(5, 310, 3);
+ Actor_Says(5, 320, 3);
+ if (!Game_Flag_Query(378) && Global_Variable_Query(1) < 3) {
+ Actor_Voice_Over(1300, 99);
+ Actor_Voice_Over(1310, 99);
+ Actor_Voice_Over(1320, 99);
+ }
+ Actor_Says(0, 2445, 13);
+ Sound_Play(123, 100, 0, 0, 50);
+ Game_Flag_Set(649);
+ return true;
+ }
+ if (Actor_Clue_Query(6, 215) && !Game_Flag_Query(650)) {
+ Sound_Play(123, 100, 0, 0, 50);
+ Overlay_Remove("MA04OVER");
+ Delay(500);
+ Actor_Says(6, 500, 3);
+ Actor_Says(6, 510, 3);
+ if (!Game_Flag_Query(378) && Global_Variable_Query(1) < 3) {
+ Actor_Voice_Over(1330, 99);
+ Actor_Voice_Over(1340, 99);
+ Actor_Voice_Over(1350, 99);
+ }
+ Actor_Says(0, 2445, 13);
+ Sound_Play(123, 100, 0, 0, 50);
+ Game_Flag_Set(650);
+ return true;
+ }
+ Actor_Says(0, 2670, 13);
+ if (!Game_Flag_Query(378)) {
+ Actor_Says(0, 2675, 17);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptMA04::SceneFrameAdvanced(int frame) {
+ Set_Fade_Color(0, 0, 0);
+ if (frame >= 91 && frame < 121) {
+ Set_Fade_Density((frame - 91) / 30.0f);
+ } else if (frame >= 121 && frame < 151) {
+ Set_Fade_Density((151 - frame) / 30.0f);
+ } else {
+ Set_Fade_Density(0.0f);
+ }
+ if (frame == 121 && (Game_Flag_Query(40) == 1 || Game_Flag_Query(41) == 1) && !Game_Flag_Query(159)) {
+ Sound_Play(403, 50, 0, 0, 50);
+ }
+}
+
+void ScriptMA04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA04::PlayerWalkedIn() {
+ if (Game_Flag_Query(647)) {
+ Player_Gains_Control();
+ }
+ if (sub_402820() || sub_402758()) {
+ Overlay_Play("MA04OVER", 0, 1, 0, 0);
+ }
+ if (Game_Flag_Query(647)) {
+ Loop_Actor_Walk_To_XYZ(0, -7139.0f, 954.0f, 1746.0f, 0, 1, false, 0);
+ } else if (Game_Flag_Query(35)) {
+ Loop_Actor_Walk_To_XYZ(0, -7143.0f, 954.0f, 1868.0f, 0, 1, false, 0);
+ }
+ Game_Flag_Reset(35);
+ Game_Flag_Reset(63);
+ Game_Flag_Reset(647);
+ if (Game_Flag_Query(61)) {
+ if (Global_Variable_Query(1) == 2 && !Actor_Clue_Query(0, 43)) {
+ Sound_Play(403, 100, 0, 0, 50);
+ Loop_Actor_Walk_To_XYZ(0, -7176.0f, 954.0f, 1806.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 256, true);
+ Actor_Says(0, 2680, 0);
+ Sound_Play(123, 100, 0, 0, 50);
+ Delay(500);
+ Actor_Says(4, 0, 3);
+ Actor_Says(0, 2685, 13);
+ Actor_Says(4, 10, 3);
+ Actor_Says(0, 2690, 17);
+ Actor_Says(4, 30, 3);
+ Actor_Says(0, 2695, 12);
+ Actor_Says(4, 40, 3);
+ Actor_Says(4, 50, 3);
+ Actor_Says(0, 2700, 3);
+ Actor_Says(4, 60, 3);
+ Actor_Says(4, 70, 3);
+ Sound_Play(123, 100, 0, 0, 50);
+ Actor_Clue_Acquire(0, 43, 1, 4);
+ Spinner_Set_Selectable_Destination_Flag(5, 1);
+ Game_Flag_Set(186);
+ if (!Game_Flag_Query(163)) {
+ Game_Flag_Set(163);
+ Item_Remove_From_World(66);
+ }
+ Actor_Set_Goal_Number(23, 99);
+ Actor_Put_In_Set(23, 93);
+ Actor_Set_At_Waypoint(23, 35, 0);
+ Autosave_Game(0);
+ }
+ //return false;
+ return;
+ }
+ if (Game_Flag_Query(40) || Game_Flag_Query(41) && !Game_Flag_Query(146)) {
+ Music_Play(2, 52, 0, 2, -1, 0, 0);
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1677.0f, 0, 1, false, 0);
+ if (sub_402820() || sub_402758()) {
+ Overlay_Remove("MA04OVER");
+ }
+ Loop_Actor_Walk_To_XYZ(0, -7199.0f, 955.0f, 1675.0f, 0, 1, false, 0);
+ Game_Flag_Set(146);
+ Async_Actor_Walk_To_XYZ(0, -7204.0f, 956.17f, 1568.0f, 0, false);
+ Set_Enter(51, 51);
+ //return true;
+ }
+ //return false;
+}
+
+void ScriptMA04::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (Game_Flag_Query(678)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(1, 0, -1);
+ Game_Flag_Reset(678);
+ }
+}
+
+void ScriptMA04::DialogueQueueFlushed(int a1) {
+ Overlay_Remove("MA04OVR2");
+}
+
+bool ScriptMA04::sub_402758() {
+ return Global_Variable_Query(1) == 5 && !Actor_Clue_Query(0, 143) && !Actor_Clue_Query(0, 144) && !Actor_Clue_Query(0, 139) && !Actor_Clue_Query(0, 140) && !Actor_Clue_Query(0, 141) && !Actor_Clue_Query(0, 142);
+}
+
+bool ScriptMA04::sub_402820() {
+ return Actor_Clue_Query(5, 222) && !Game_Flag_Query(649) || Actor_Clue_Query(6, 215) && !Game_Flag_Query(650);
+}
+
+bool ScriptMA04::sub_402888() {
+ return sub_402820() || sub_402758();
+}
+
+void ScriptMA04::sub_4028A8() {
+ int answer;
+ Actor_Says(3, 220, 3);
+ Actor_Says(0, 2460, 0);
+ Actor_Says(3, 230, 3);
+ Actor_Says(3, 240, 3);
+ Actor_Says(0, 2465, 0);
+ Actor_Says(3, 250, 3);
+ Actor_Says_With_Pause(0, 2470, 1.5f, 17);
+ Actor_Says(3, 260, 3);
+ Actor_Says(0, 2475, 15);
+ Actor_Says(3, 270, 3);
+ Actor_Says(0, 2480, 0);
+ Actor_Says(3, 280, 3);
+ Actor_Says(3, 290, 3);
+ Actor_Says(0, 2485, 19);
+ Actor_Says(3, 300, 3);
+ Actor_Says(3, 310, 3);
+ Actor_Says(0, 2490, 0);
+ Actor_Says(3, 330, 3);
+ Actor_Says(0, 2495, 0);
+ Actor_Says(3, 340, 3);
+ Actor_Says(3, 350, 3);
+ if (Game_Flag_Query(165) || Actor_Query_Goal_Number(9) == 2) {
+ answer = 1170;
+ } else {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(1160, 1, 1, 2);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1170, 2, 1, 1);
+ Dialogue_Menu_Appear(320, 240);
+ answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ }
+ if (answer == 1160) {
+ Actor_Says(0, 2500, 19);
+ Actor_Says(3, 360, 3);
+ Actor_Says(0, 2510, 0);
+ Actor_Says(3, 370, 3);
+ Actor_Says(3, 380, 3);
+ Actor_Says(0, 2515, 12);
+ Actor_Says(3, 390, 3);
+ Actor_Says(0, 2520, 13);
+ Actor_Says(3, 400, 3);
+ Actor_Says(3, 410, 3);
+ Actor_Says(0, 2525, 15);
+ Actor_Says(3, 420, 3);
+ Sound_Play(123, 100, 0, 0, 50);
+ Actor_Clue_Acquire(0, 139, 1, -1);
+ } else {
+ Actor_Says_With_Pause(0, 2505, 0.5f, 19);
+ Actor_Says(3, 430, 3);
+ Actor_Says(3, 440, 3);
+ Actor_Says(0, 2530, 0);
+ Actor_Says(3, 450, 3);
+ Actor_Says(0, 2535, 12);
+ Actor_Says(3, 460, 3);
+ Actor_Says_With_Pause(3, 470, 1.0f, 3);
+ Actor_Says(3, 480, 3);
+ Actor_Says(3, 490, 3);
+ Sound_Play(123, 100, 0, 0, 50);
+ Actor_Says(0, 2540, 15);
+ Actor_Clue_Acquire(0, 140, 1, -1);
+ }
+}
+
+void ScriptMA04::sub_402F2C() {
+ Actor_Says(6, 530, 3);
+ Actor_Says(0, 2545, 19);
+ Actor_Says(6, 540, 3);
+ Actor_Says(6, 550, 3);
+ Actor_Says(0, 2550, 13);
+ Actor_Says(6, 560, 3);
+ Actor_Says(0, 2555, 19);
+ Actor_Says(6, 570, 3);
+ Actor_Says(0, 2560, 17);
+ Actor_Says(6, 580, 3);
+ if (Game_Flag_Query(165) || Actor_Query_Goal_Number(9) == 2) {
+ Actor_Says(6, 630, 3);
+ Actor_Says_With_Pause(0, 2575, 0.0f, 15);
+ if (!Game_Flag_Query(378)) {
+ Actor_Says(6, 640, 3);
+ }
+ Actor_Clue_Acquire(0, 142, 1, -1);
+ } else {
+ Actor_Says(6, 590, 3);
+ Actor_Says(0, 2565, 12);
+ Actor_Says(6, 600, 3);
+ Actor_Says(6, 610, 3);
+ Actor_Says(6, 620, 3);
+ Actor_Says(0, 2570, 13);
+ Actor_Says_With_Pause(6, 630, 0.0f, 3);
+ Actor_Says_With_Pause(0, 2575, 0.0f, 15);
+ if (!Game_Flag_Query(378)) {
+ Actor_Says(6, 640, 3);
+ }
+ Actor_Clue_Acquire(0, 141, 1, -1);
+ }
+ Sound_Play(123, 100, 0, 0, 50);
+}
+
+void ScriptMA04::sub_4032A0() {
+ Actor_Says(1, 680, 3);
+ Actor_Says(0, 2630, 17);
+ Actor_Says(1, 690, 3);
+ Actor_Says(0, 2635, 18);
+ Actor_Says(1, 700, 3);
+ Actor_Says(0, 2640, 14);
+ Actor_Says(1, 710, 3);
+ Actor_Says(1, 720, 3);
+ Actor_Says(0, 2645, 13);
+ Actor_Says(1, 740, 3);
+ Actor_Says(1, 750, 3);
+ Actor_Says(0, 2650, 12);
+ Actor_Says(1, 760, 3);
+ Actor_Says(0, 2665, 13);
+ Actor_Says(1, 810, 3);
+ Actor_Says(1, 820, 3);
+ Sound_Play(123, 100, 0, 0, 50);
+ Actor_Clue_Acquire(0, 144, 1, -1);
+}
+
+void ScriptMA04::sub_4034D8() {
+ Actor_Says(5, 330, 3);
+ Actor_Says(0, 2580, 14);
+ Actor_Says(5, 340, 3);
+ Actor_Says(0, 2585, 19);
+ Actor_Says(5, 350, 3);
+ Actor_Says(5, 360, 3);
+ Actor_Says(0, 2590, 18);
+ Actor_Says(5, 370, 3);
+ Actor_Says(0, 2595, 15);
+ Actor_Says(5, 390, 3);
+ Actor_Says(5, 400, 3);
+ Actor_Says(5, 410, 3);
+ Actor_Says(0, 2600, 15);
+ Actor_Says_With_Pause(5, 420, 1.5f, 3);
+ Actor_Says(0, 2605, 17);
+ Actor_Says(5, 430, 3);
+ Actor_Says(5, 440, 3);
+ Actor_Says(0, 2610, 3);
+ Actor_Says(5, 450, 3);
+ Actor_Says(5, 460, 3);
+ Actor_Says(5, 470, 3);
+ Actor_Says(5, 480, 3);
+ Actor_Says(5, 490, 3);
+ Actor_Says(0, 2615, 17);
+ Actor_Says(5, 500, 3);
+ Actor_Says(5, 530, 3);
+ Actor_Says(5, 540, 3);
+ Sound_Play(123, 100, 0, 0, 50);
+ Actor_Clue_Acquire(0, 143, 1, -1);
+}
+
+void ScriptMA04::sub_403864() {
+ Overlay_Play("MA04OVR2", 0, 1, 0, 0);
+ switch (Global_Variable_Query(52)) {
+ case 4:
+ ADQ_Add(61, 230, 3);
+ ADQ_Add(61, 240, 3);
+ break;
+ case 3:
+ ADQ_Add(61, 170, 3);
+ ADQ_Add(61, 180, 3);
+ ADQ_Add(61, 190, 3);
+ ADQ_Add(61, 200, 3);
+ ADQ_Add(61, 210, 3);
+ ADQ_Add(61, 220, 3);
+ ADQ_Add(41, 80, 3);
+ ADQ_Add(41, 90, 3);
+ ADQ_Add(41, 100, 3);
+ ADQ_Add(41, 110, 3);
+ ADQ_Add(41, 120, 3);
+ ADQ_Add(41, 130, 3);
+ break;
+ case 2:
+ if (Actor_Query_Friendliness_To_Other(5, 0) <= Actor_Query_Friendliness_To_Other(1, 0)) {
+ ADQ_Add(61, 90, 3);
+ ADQ_Add(61, 100, 3);
+ ADQ_Add(61, 110, 3);
+ ADQ_Add(4, 1540, 3);
+ ADQ_Add(4, 1550, 3);
+ ADQ_Add(4, 1560, 3);
+ } else {
+ ADQ_Add(61, 120, 3);
+ ADQ_Add(61, 130, 3);
+ ADQ_Add(61, 140, 3);
+ ADQ_Add(61, 150, 3);
+ ADQ_Add(4, 1570, 3);
+ ADQ_Add(4, 1580, 3);
+ ADQ_Add(4, 1590, 3);
+ }
+ break;
+ case 1:
+ ADQ_Add(61, 40, 3);
+ ADQ_Add(61, 50, 3);
+ ADQ_Add(61, 60, 3);
+ ADQ_Add(61, 70, 3);
+ ADQ_Add(61, 80, 3);
+ break;
+ case 0:
+ ADQ_Add(61, 0, 3);
+ ADQ_Add(61, 10, 3);
+ ADQ_Add(61, 20, 3);
+ ADQ_Add(61, 30, 3);
+ ADQ_Add(51, 430, 3);
+ ADQ_Add(51, 440, 3);
+ ADQ_Add(51, 450, 3);
+ ADQ_Add(51, 460, 3);
+ break;
+ }
+}
+
+void ScriptMA04::sub_403DA8() {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "BED-SHEETS", 12, 1, false)) {
+ Actor_Says(0, 8530, 12);
+ Music_Stop(4);
+ if (sub_402820() || sub_402758()) {
+ Overlay_Remove("MA04OVER");
+ }
+ Player_Loses_Control();
+ Game_Flag_Set(647);
+ if ((Game_Flag_Query(40) || Game_Flag_Query(41)) && Global_Variable_Query(1) == 1) {
+ if (Actor_Query_Goal_Number(19) == 599) {
+ Actor_Put_In_Set(19, 91);
+ Actor_Set_At_Waypoint(19, 33, 0);
+ }
+ Game_Flag_Set(678);
+ Global_Variable_Set(1, 2);
+ Chapter_Enter(2, 10, 50);
+ if (Query_Difficulty_Level()) {
+ if (!Game_Flag_Query(723)) {
+ Global_Variable_Increment(2, 200);
+ }
+ }
+ } else {
+ Set_Enter(10, 50);
+ }
+ Scene_Loop_Start_Special(1, 3, 0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma05.cpp b/engines/bladerunner/script/ma05.cpp
new file mode 100644
index 0000000000..9861f903f1
--- /dev/null
+++ b/engines/bladerunner/script/ma05.cpp
@@ -0,0 +1,142 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA05::InitializeScene() {
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Setup_Scene_Information(-7204.0f, 953.97f, 1651.0f, 0);
+ } else {
+ Setup_Scene_Information(-7207.0f, 956.17f, 1564.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 432, 21, 471, 226, 1);
+ Ambient_Sounds_Add_Looping_Sound(101, 90, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(99, 40, -100, 1);
+ Ambient_Sounds_Add_Looping_Sound(103, 50, 60, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 20, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 40, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(60, 50, 10, 260, 27, 47, -100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 100, 25, 50, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 70, 50, 100, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(87, 10, 70, 25, 25, -100, 0, -101, -101, 0, 0);
+ if (sub_401990()) {
+ Ambient_Sounds_Add_Sound(403, 3, 3, 32, 32, 100, 100, -101, -101, 0, 0);
+ }
+ if (Global_Variable_Query(1) != 2 && Global_Variable_Query(1) != 3) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ }
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptMA05::SceneLoaded() {
+ Obstacle_Object("Z-BOX-RAIL03", true);
+ Footstep_Sounds_Set(0, 0);
+ Footstep_Sounds_Set(1, 3);
+}
+
+bool ScriptMA05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA05::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptMA05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -7199.0f, 956.17f, 1579.0f, 0, 0, false, 0)) {
+ Loop_Actor_Walk_To_XYZ(0, -7199.0f, 956.17f, 1579.0f, 0, 0, false, 0);
+ Game_Flag_Set(63);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Async_Actor_Walk_To_XYZ(0, -7199.0f, 953.97f, 1685.0f, 0, false);
+ Set_Enter(50, 50);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA05::SceneFrameAdvanced(int frame) {
+ if (frame == 20) {
+ Sound_Play(102, 70, -100, 100, 50);
+ }
+ //return true;
+}
+
+void ScriptMA05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA05::PlayerWalkedIn() {
+ Music_Play(2, 52, 0, 2, -1, 0, 0);
+ if ((Random_Query(0, 4) == 1 || Game_Flag_Query(146) && !Game_Flag_Query(61)) && Global_Variable_Query(1) == 1) {
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 3, 1);
+ Sound_Play(69, 100, 0, 0, 50);
+ }
+ if (Game_Flag_Query(146) && !Game_Flag_Query(61)) {
+ if (!Game_Flag_Query(378)) {
+ Actor_Voice_Over(1260, 99);
+ Actor_Voice_Over(1270, 99);
+ Actor_Voice_Over(1280, 99);
+ Actor_Voice_Over(1290, 99);
+ }
+ Game_Flag_Set(61);
+ Player_Gains_Control();
+ }
+ //return false;
+}
+
+void ScriptMA05::PlayerWalkedOut() {
+}
+
+void ScriptMA05::DialogueQueueFlushed(int a1) {
+}
+
+bool ScriptMA05::sub_401990() {
+ return Global_Variable_Query(1) == 5
+ && !Actor_Clue_Query(0, 143)
+ && !Actor_Clue_Query(0, 144)
+ && !Actor_Clue_Query(0, 139)
+ && !Actor_Clue_Query(0, 140)
+ && !Actor_Clue_Query(0, 141)
+ && !Actor_Clue_Query(0, 142);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma06.cpp b/engines/bladerunner/script/ma06.cpp
new file mode 100644
index 0000000000..dfe9080f83
--- /dev/null
+++ b/engines/bladerunner/script/ma06.cpp
@@ -0,0 +1,154 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA06::InitializeScene() {
+ Setup_Scene_Information(40.0f, 1.0f, -20.0f, 400);
+ Ambient_Sounds_Add_Looping_Sound(210, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(408, 33, 0, 1);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Sound_Play(209, 100, 50, 50, 100);
+}
+
+void ScriptMA06::SceneLoaded() {
+ Obstacle_Object("PANEL", true);
+ Clickable_Object("PANEL");
+ Player_Loses_Control();
+}
+
+bool ScriptMA06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptMA06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA06::ClickedOnExit(int exitId) {
+ return false;
+}
+
+bool ScriptMA06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptMA06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA06::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, 40.0f, 1.35f, 0.0f, 0, 0, false, 0);
+ Actor_Face_Object(0, "panel", true);
+ Delay(500);
+ sub_4014E4();
+ if (sub_4012C0()) {
+ Sound_Play(114, 25, 0, 0, 50);
+ Delay(4000);
+ }
+ Game_Flag_Reset(37);
+ Game_Flag_Reset(33);
+ Game_Flag_Reset(57);
+ if (Game_Flag_Query(38)) {
+ Set_Enter(49, 48);
+ } else if (Game_Flag_Query(34)) {
+ Set_Enter(10, 49);
+ } else {
+ Set_Enter(53, 53);
+ }
+ Scene_Loop_Start_Special(1, 3, 1);
+ Sound_Play(208, 100, 50, 50, 50);
+ //return true;
+}
+
+void ScriptMA06::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Player_Gains_Control();
+}
+
+void ScriptMA06::DialogueQueueFlushed(int a1) {
+}
+
+bool ScriptMA06::sub_4012C0() {
+ return Game_Flag_Query(37) && !Game_Flag_Query(38) || Game_Flag_Query(33) && !Game_Flag_Query(34) || Game_Flag_Query(57) && !Game_Flag_Query(58);
+}
+
+void ScriptMA06::sub_4014E4() {
+ Game_Flag_Reset(38);
+ Game_Flag_Reset(34);
+ Game_Flag_Reset(58);
+ while (true) {
+ if (Game_Flag_Query(34)) {
+ break;
+ }
+ if (Game_Flag_Query(38)) {
+ break;
+ }
+ if (Game_Flag_Query(58)) {
+ break;
+ }
+ Actor_Says(39, 80, 3);
+ Player_Gains_Control();
+ int v1 = Elevator_Activate(1);
+ Player_Loses_Control();
+ Scene_Loop_Start_Special(2, 1, 1);
+ if (v1 > 1) {
+ Game_Flag_Set(58);
+ } else if (v1 == 1) {
+ if (Game_Flag_Query(250)) {
+ Game_Flag_Set(38);
+ } else {
+ Sound_Play(412, 100, 0, 0, 50);
+ Delay(500);
+ Actor_Says(39, 610, 3);
+ }
+ } else {
+ Actor_Says(0, 2940, 18);
+ if (Global_Variable_Query(1) == 4 && Game_Flag_Query(655)) {
+ Sound_Play(412, 100, 0, 0, 50);
+ Delay(500);
+ Actor_Says(39, 610, 3);
+ Delay(500);
+ Actor_Says(0, 8527, 3);
+ } else {
+ Game_Flag_Set(34);
+ Actor_Says(39, 90, 3);
+ }
+ }
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma07.cpp b/engines/bladerunner/script/ma07.cpp
new file mode 100644
index 0000000000..4222453302
--- /dev/null
+++ b/engines/bladerunner/script/ma07.cpp
@@ -0,0 +1,159 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA07::InitializeScene() {
+ if (Game_Flag_Query(356)) {
+ Setup_Scene_Information(6.75f, -172.43f, 356.0f, 997);
+ Game_Flag_Reset(356);
+ Game_Flag_Set(665);
+ } else if (Game_Flag_Query(673)) {
+ Setup_Scene_Information(-312.0f, -162.8f, 180.0f, 0);
+ } else {
+ Setup_Scene_Information(104.0f, -162.16f, 56.0f, 519);
+ }
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(374, 100, 300, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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(1) > 1) {
+ Scene_Exit_Add_2D_Exit(1, 0, 200, 50, 479, 3);
+ }
+ if (Game_Flag_Query(665)) {
+ Scene_Exit_Add_2D_Exit(2, 176, 386, 230, 426, 2);
+ }
+ Scene_Exit_Add_2D_Exit(0, 270, 216, 382, 306, 0);
+}
+
+void ScriptMA07::SceneLoaded() {
+ Obstacle_Object("BARRICADE", true);
+}
+
+bool ScriptMA07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptMA07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 104.0f, -162.0f, 56.0f, 12, 1, false, 0)) {
+ if (Global_Variable_Query(1) == 4 && Game_Flag_Query(671)) {
+ Actor_Set_Goal_Number(0, 400);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(57);
+ Set_Enter(52, 52);
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -400.0f, -162.8f, 185.08f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(672);
+ Game_Flag_Reset(179);
+ Game_Flag_Set(178);
+ Set_Enter(68, 77);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 8.0f, -172.43f, 356.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(357);
+ Set_Enter(90, 103);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptMA07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptMA07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 53 && newGoal == 302) {
+ Scene_Exits_Enable();
+ }
+}
+
+void ScriptMA07::PlayerWalkedIn() {
+ if (Game_Flag_Query(673)) {
+ Loop_Actor_Walk_To_XYZ(0, -268.0f, -162.8f, 188.0f, 0, 0, false, 0);
+ Game_Flag_Reset(673);
+ }
+ if (Actor_Query_Goal_Number(57) == 300) {
+ Actor_Set_Goal_Number(57, 305);
+ }
+ if (Game_Flag_Query(58)) {
+ Game_Flag_Reset(58);
+ }
+ if (!Game_Flag_Query(648) && Game_Flag_Query(671) && Global_Variable_Query(1) == 4) {
+ Scene_Exits_Disable();
+ Actor_Set_Goal_Number(53, 300);
+ }
+ if (Game_Flag_Query(666)) {
+ Actor_Voice_Over(1360, 99);
+ Actor_Voice_Over(1370, 99);
+ Actor_Voice_Over(1380, 99);
+ Actor_Voice_Over(1390, 99);
+ Actor_Voice_Over(1400, 99);
+ Delay(1000);
+ Game_Flag_Reset(666);
+ Game_Flag_Set(34);
+ Set_Enter(10, 49);
+ }
+ //return false;
+
+}
+
+void ScriptMA07::PlayerWalkedOut() {
+}
+
+void ScriptMA07::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ma08.cpp b/engines/bladerunner/script/ma08.cpp
new file mode 100644
index 0000000000..d2f105af9a
--- /dev/null
+++ b/engines/bladerunner/script/ma08.cpp
@@ -0,0 +1,81 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptMA08::InitializeScene() {
+ Setup_Scene_Information(0, 0, 0, 0);
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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);
+}
+
+void ScriptMA08::SceneLoaded() {
+ Obstacle_Object("(undefined)", true);
+ Clickable_Object("(undefined)");
+}
+
+bool ScriptMA08::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptMA08::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptMA08::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptMA08::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptMA08::ClickedOnExit(int exitId) {
+ return false;
+}
+
+bool ScriptMA08::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptMA08::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptMA08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptMA08::PlayerWalkedIn() {
+}
+
+void ScriptMA08::PlayerWalkedOut() {
+}
+
+void ScriptMA08::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr01.cpp b/engines/bladerunner/script/nr01.cpp
new file mode 100644
index 0000000000..a7ff7b2e3e
--- /dev/null
+++ b/engines/bladerunner/script/nr01.cpp
@@ -0,0 +1,436 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR01::InitializeScene() {
+ if (Game_Flag_Query(617)) {
+ Setup_Scene_Information(-153.86f, 23.88f, -570.21f, 402);
+ } else if (Game_Flag_Query(632)) {
+ Setup_Scene_Information(-416.0f, 31.93f, -841.0f, 200);
+ Actor_Set_Invisible(0, true);
+ Preload(167);
+ } else if (Game_Flag_Query(534)) {
+ Setup_Scene_Information(-416.0f, 31.93f, -841.0f, 200);
+ } else if (Game_Flag_Query(342)) {
+ Setup_Scene_Information(-270.0f, 4.93f, -1096.0f, 500);
+ } else if (Game_Flag_Query(533)) {
+ Setup_Scene_Information(312.0f, 31.66f, -901.0f, 700);
+ } else if (Game_Flag_Query(545)) {
+ Setup_Scene_Information(-170.0f, 24.0f, -574.0f, 768);
+ } else {
+ Setup_Scene_Information(76.0f, 23.88f, -109.0f, 966);
+ }
+ Scene_Exit_Add_2D_Exit(0, 31, 270, 97, 373, 3);
+ if (Global_Variable_Query(1) > 3) {
+ Scene_Exit_Add_2D_Exit(1, 201, 320, 276, 357, 2);
+ }
+ Scene_Exit_Add_2D_Exit(2, 583, 262, 639, 365, 1);
+ if (Game_Flag_Query(255)) {
+ Scene_Exit_Add_2D_Exit(3, 320, 445, 639, 479, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(362, 22, 55, 1);
+ Ambient_Sounds_Add_Sound(361, 10, 10, 20, 20, -70, -70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Ambient_Sounds_Add_Sound(68, 10, 80, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 10, 80, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 10, 80, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(376, 10, 80, 33, 33, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(377, 10, 80, 33, 33, 0, 0, -101, -101, 0, 0);
+ if (Game_Flag_Query(643) && Actor_Query_Goal_Number(1) == 230) {
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(256);
+ }
+ if (Game_Flag_Query(255) && !Game_Flag_Query(247)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Set(247);
+ } else if (Game_Flag_Query(255) && Game_Flag_Query(247)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(4);
+ }
+}
+
+void ScriptNR01::SceneLoaded() {
+ Obstacle_Object("LAMPBASE01", true);
+ Unclickable_Object("LAMPBASE01");
+}
+
+bool ScriptNR01::MouseClick(int x, int y) {
+ if (Actor_Query_Goal_Number(0) == 212) {
+ Global_Variable_Increment(47, 4);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptNR01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -380.0f, 31.93f, -841.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) > 3) {
+ Actor_Says(0, 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, 56);
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -281.0f, 31.93f, -1061.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 45, false);
+ Loop_Actor_Travel_Stairs(0, 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, 91);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 312.0f, 31.66f, -901.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(532);
+ Set_Enter(11, 55);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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);
+ Game_Flag_Reset(255);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(255);
+ Game_Flag_Reset(247);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 3, 1);
+ break;
+ default:
+ Player_Loses_Control();
+ Game_Flag_Set(181);
+ Game_Flag_Set(247);
+ Player_Gains_Control();
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR01::ClickedOn2DRegion(int region) {
+ if (region == 0 && Player_Query_Combat_Mode()) {
+ Sound_Play(517, 100, 0, 0, 50);
+ Actor_Set_Goal_Number(1, 260);
+ Scene_2D_Region_Remove(0);
+ }
+ if (region == 1 && Player_Query_Combat_Mode()) {
+ Sound_Play(517, 100, 0, 0, 50);
+ Actor_Set_Goal_Number(2, 299);
+ Actor_Set_Goal_Number(1, 258);
+ Scene_2D_Region_Remove(1);
+ return true;
+ }
+ return false;
+
+}
+
+void ScriptNR01::SceneFrameAdvanced(int frame) {
+ if (frame == 61) {
+ Sound_Play(118, 40, 0, 0, 50);
+ }
+ if (frame == 184) {
+ Sound_Play(117, 40, 80, 80, 50);
+ }
+ //return 0;
+}
+
+void ScriptNR01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR01::PlayerWalkedIn() {
+ if (Game_Flag_Query(617)) {
+ Actor_Set_Goal_Number(1, 280);
+ Game_Flag_Reset(617);
+ //return true;
+ return;
+ }
+ if (Actor_Query_Goal_Number(1) == 250) {
+ Scene_Exits_Disable();
+ ADQ_Flush();
+ Actor_Set_Goal_Number(1, 251);
+ Scene_2D_Region_Add(0, 450, 316, 464, 333);
+ Scene_2D_Region_Add(1, 233, 321, 240, 362);
+ ADQ_Add(2, 70, 81);
+ ADQ_Add(1, 990, 3);
+ ADQ_Add(2, 80, 82);
+ ADQ_Add(2, 90, 81);
+ ADQ_Add(1, 1010, 3);
+ ADQ_Add(2, 100, 81);
+ ADQ_Add(1, 1020, 3);
+ ADQ_Add(2, 110, 82);
+ ADQ_Add(1, 1030, 3);
+ ADQ_Add(1, 1040, 3);
+ ADQ_Add(2, 120, 82);
+ }
+ if (Game_Flag_Query(604)) {
+ if (Game_Flag_Query(622)) {
+ ADQ_Add(25, 150, 3);
+ Game_Flag_Reset(622);
+ }
+ Game_Flag_Reset(604);
+ Player_Gains_Control();
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(632)) {
+ Delay(3500);
+ Set_Enter(60, 64);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(534)) {
+ Loop_Actor_Walk_To_XYZ(0, -380.0f, 31.73f, -841.0f, 0, 0, false, 0);
+ Game_Flag_Reset(534);
+ } else {
+ if (Game_Flag_Query(342)) {
+ Loop_Actor_Travel_Stairs(0, 3, 1, 0);
+ Game_Flag_Reset(342);
+ if (Actor_Query_Goal_Number(1) == 230) {
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says(1, 1440, 13);
+ Loop_Actor_Walk_To_Actor(0, 1, 48, 0, true);
+ Actor_Says(0, 3145, 13);
+ if (Global_Variable_Query(40) != 3) {
+ Actor_Says(1, 1450, 12);
+ Actor_Says(1, 1460, 13);
+ }
+ Actor_Says(0, 3150, 14);
+ Actor_Says(1, 1470, 12);
+ Actor_Says(1, 1480, 13);
+ Actor_Says(0, 3155, 15);
+ Actor_Says(1, 1500, 16);
+ Actor_Says(0, 3160, 12);
+ if (Game_Flag_Query(643)) {
+ Actor_Says(1, 1330, 12);
+ Actor_Says(1, 1340, 12);
+ Actor_Says(1, 1350, 12);
+ Actor_Says(0, 3120, 15);
+ Actor_Says(1, 1360, 12);
+ Actor_Says(1, 1370, 12);
+ Actor_Says(0, 3125, 15);
+ Actor_Says(1, 1380, 12);
+ Actor_Says(0, 3130, 15);
+ Actor_Says(1, 1390, 12);
+ Actor_Says(1, 1400, 12);
+ Actor_Says(1, 1410, 12);
+ Actor_Says(0, 3135, 15);
+ Actor_Says(1, 1420, 12);
+ Actor_Says(0, 3140, 15);
+ Actor_Says(1, 1430, 12);
+ Actor_Set_Goal_Number(1, 285);
+ } else {
+ int v0 = Global_Variable_Query(40) - 1;
+ if (!v0) {
+ Actor_Says(1, 1510, 15);
+ Actor_Says(1, 1520, 14);
+ Actor_Says(1, 1530, 13);
+ Actor_Says(0, 3170, 13);
+ Actor_Set_Goal_Number(1, 231);
+ } else if (v0 == 1) {
+ Actor_Says(1, 1590, 15);
+ Actor_Says(0, 3195, 14);
+ Actor_Says(1, 1600, 16);
+ Actor_Says(0, 3200, 13);
+ Actor_Says(1, 1610, 17);
+ Actor_Says(1, 1620, 15);
+ Actor_Says(1, 1630, 14);
+ Actor_Says(0, 3205, 12);
+ Actor_Set_Goal_Number(1, 232);
+ } else if (v0 == 2) {
+ Actor_Says(1, 1540, 15);
+ Actor_Says(0, 3175, 13);
+ Actor_Says(1, 1550, 13);
+ Actor_Says(1, 1560, 16);
+ Actor_Says(0, 3180, 15);
+ Actor_Says(1, 1570, 12);
+ Actor_Says(1, 1580, 14);
+ Actor_Says(0, 3190, 12);
+ Actor_Set_Goal_Number(1, 233);
+ }
+ }
+ }
+ } else if (Game_Flag_Query(533)) {
+ Loop_Actor_Walk_To_XYZ(0, 239.0f, 31.66f, -901.0f, 0, 0, false, 0);
+ Game_Flag_Reset(533);
+ if (Actor_Query_Goal_Number(2) == 230) {
+ Scene_Exits_Disable();
+ Actor_Set_Goal_Number(2, 231);
+ Non_Player_Actor_Combat_Mode_On(2, 0, 1, 0, 3, 4, 7, 8, -1, -1, -1, 20, 300, 0);
+ }
+ } else if (Game_Flag_Query(545)) {
+ Game_Flag_Reset(545);
+ Actor_Put_In_Set(25, 54);
+ Actor_Set_At_XYZ(25, -202.0f, 24.0f, -574.0f, 0);
+ Actor_Face_Heading(25, 256, false);
+ Actor_Set_Goal_Number(25, 204);
+ Player_Gains_Control();
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 48.0f, 23.88f, -189.0f, 0, 0, false, 0);
+ }
+ }
+ if (Game_Flag_Query(652)) {
+ Game_Flag_Reset(652);
+ Actor_Voice_Over(950, 99);
+ Actor_Voice_Over(960, 99);
+ Actor_Voice_Over(970, 99);
+ Actor_Voice_Over(980, 99);
+ }
+ if (Actor_Query_Goal_Number(2) == 240) {
+ Scene_Exits_Disable();
+ Actor_Set_Goal_Number(2, 241);
+ if (!Player_Query_Combat_Mode()) {
+ Player_Set_Combat_Mode(true);
+ }
+ }
+ //return false;
+ return;
+}
+
+void ScriptNR01::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(343) && !Game_Flag_Query(532) && !Game_Flag_Query(535) && !Game_Flag_Query(632) && !Game_Flag_Query(722)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(30, 1, -1);
+ Outtake_Play(35, 1, -1);
+ }
+ Game_Flag_Reset(722);
+}
+
+void ScriptNR01::DialogueQueueFlushed(int a1) {
+ if (Actor_Query_Goal_Number(1) == 251 && Actor_Query_Goal_Number(2) != 299 && Actor_Query_Goal_Number(2) != 254 && Actor_Query_Goal_Number(2) != 255) {
+ Actor_Set_Goal_Number(1, 252);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr02.cpp b/engines/bladerunner/script/nr02.cpp
new file mode 100644
index 0000000000..0622161bd7
--- /dev/null
+++ b/engines/bladerunner/script/nr02.cpp
@@ -0,0 +1,215 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR02::InitializeScene() {
+ sub_402134();
+ Setup_Scene_Information(-283.0f, -24.0f, 326.0f, 200);
+ Game_Flag_Reset(532);
+ Scene_Exit_Add_2D_Exit(0, 0, 105, 75, 291, 3);
+ Ambient_Sounds_Add_Looping_Sound(280, 50, 38, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+}
+
+void ScriptNR02::SceneLoaded() {
+ Obstacle_Object("VID PHONE 01", true);
+ Unobstacle_Object("VICTORIAN CHAIR", true);
+ Unobstacle_Object("WALL CANDLES", true);
+ Unobstacle_Object("STAIRS", true);
+ Unobstacle_Object("BOX30", true);
+ Unobstacle_Object("VID CAM COVER", true);
+ Unobstacle_Object("VID CAM COVER01", true);
+ Unobstacle_Object("VID OUTER GLASS", true);
+ Unobstacle_Object("VID OUTER GLASS01", true);
+ Unobstacle_Object("VID MAIN MONITOR", true);
+ Unobstacle_Object("VID MAIN MONITOR01", true);
+ Clickable_Object("VID PHONE 01");
+ Clickable_Object("VID PHONE 02");
+}
+
+bool ScriptNR02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR02::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("VID PHONE 01", objectName) || Object_Query_Click("VID PHONE 02", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -191.9f, -24.0f, 62.15f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 13, false);
+ if (Actor_Clue_Query(0, 125) && Actor_Clue_Query(0, 126) && !Game_Flag_Query(670)) {
+ Actor_Set_Goal_Number(0, 350);
+ Game_Flag_Set(670);
+ } else {
+ Sound_Play(123, 50, 0, 0, 50);
+ Delay(1000);
+ Sound_Play(403, 30, 0, 0, 50);
+ Delay(1500);
+ Sound_Play(403, 30, 0, 0, 50);
+ Delay(1500);
+ Sound_Play(403, 30, 0, 0, 50);
+ Delay(1500);
+ Sound_Play(123, 50, 0, 0, 50);
+ Delay(1000);
+ Actor_Says(0, 170, 14);
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptNR02::ClickedOnActor(int actorId) {
+ if (actorId == 2 && Actor_Query_Goal_Number(2) == 201 && !Loop_Actor_Walk_To_XYZ(0, 67.37f, -24.0f, 389.32f, 0, 1, false, 0)) {
+ Actor_Set_Goal_Number(2, 215);
+ }
+ return false;
+}
+
+bool ScriptNR02::ClickedOnItem(int itemId, bool a2) {
+ if ((itemId == 89 || itemId == 90) && !Loop_Actor_Walk_To_XYZ(0, 109.38f, -24.0f, 420.5f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 423, false);
+ if (itemId == 89) {
+ Item_Remove_From_World(89);
+ Item_Pickup_Spin_Effect(953, 214, 380);
+ Actor_Clue_Acquire(0, 105, 1, -1);
+ }
+ if (itemId == 90) {
+ Item_Remove_From_World(90);
+ Item_Pickup_Spin_Effect(954, 214, 380);
+ Actor_Clue_Acquire(0, 106, 1, -1);
+ }
+ }
+ return false;
+}
+
+bool ScriptNR02::ClickedOnExit(int exitId) {
+ if (!exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -283.0f, -24.0f, 326.0f, 0, 1, false, 0)) {
+ if (Actor_Query_Goal_Number(2) < 230 || Actor_Query_Goal_Number(2) > 250) {
+ Music_Stop(2);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(533);
+ Set_Enter(54, 54);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR02::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing() && (Actor_Query_Goal_Number(2) < 210 || Actor_Query_Goal_Number(2) > 222)) {
+ sub_402134();
+ }
+ //return false;
+}
+
+void ScriptNR02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR02::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(2) == 211) {
+ Actor_Set_Goal_Number(2, 220);
+ }
+ if (Actor_Query_Goal_Number(2) == 204) {
+ Actor_Set_Goal_Number(2, 205);
+ }
+ if (Actor_Query_Goal_Number(2) == 206) {
+ Actor_Set_Goal_Number(2, 205);
+ }
+ Loop_Actor_Walk_To_XYZ(0, -203.0f, -24.0f, 334.0f, 0, 0, false, 0);
+ //return false;
+}
+
+void ScriptNR02::PlayerWalkedOut() {
+ Music_Stop(2);
+ if (Actor_Query_Goal_Number(2) < 210 && Actor_Query_Goal_Number(2) >= 205) {
+ Actor_Set_Goal_Number(2, 204);
+ }
+}
+
+void ScriptNR02::DialogueQueueFlushed(int a1) {
+ if (Player_Query_Current_Scene() == 55 && Actor_Query_Goal_Number(2) == 206) {
+ Sound_Play(575, 50, 0, 0, 50);
+ Sound_Play(321, 50, 0, 0, 50);
+ }
+ if (Player_Query_Current_Scene() == 55 && Actor_Query_Goal_Number(2) == 207) {
+ Sound_Play(576, 50, 0, 0, 50);
+ Sound_Play(323, 50, 0, 0, 50);
+ }
+ if (Player_Query_Current_Scene() == 55 && Actor_Query_Goal_Number(2) == 208) {
+ Sound_Play(579, 50, 0, 0, 50);
+ Sound_Play(324, 50, 0, 0, 50);
+ }
+ if (Player_Query_Current_Scene() == 55 && Actor_Query_Goal_Number(2) > 205 && Actor_Query_Goal_Number(2) < 210) {
+ Actor_Set_Goal_Number(2, 205);
+ //return true;
+ return;
+ } else if (Actor_Query_Goal_Number(2) > 205 && Actor_Query_Goal_Number(2) < 210) {
+ Actor_Set_Goal_Number(2, 204);
+ //return true;
+ return;
+ }
+ //return false;
+}
+
+void ScriptNR02::sub_402134() {
+ int v0 = Global_Variable_Query(50);
+ if (v0 == 0) {
+ Music_Play(8, 41, 0, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(9, 41, 0, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(10, 41, 0, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(50, v0);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr03.cpp b/engines/bladerunner/script/nr03.cpp
new file mode 100644
index 0000000000..f0d2f359b5
--- /dev/null
+++ b/engines/bladerunner/script/nr03.cpp
@@ -0,0 +1,351 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR03::InitializeScene() {
+ if (Game_Flag_Query(537)) {
+ Setup_Scene_Information(-301.98f, -70.19f, -348.58f, 0);
+ } else if (Game_Flag_Query(437)) {
+ Setup_Scene_Information(-161.0f, -70.19f, -1139.0f, 500);
+ Game_Flag_Reset(437);
+ } else {
+ Setup_Scene_Information(410.0f, -70.19f, -715.0f, 690);
+ }
+ Scene_Exit_Add_2D_Exit(0, 561, 0, 639, 216, 1);
+ Scene_Exit_Add_2D_Exit(1, 210, 85, 240, 145, 0);
+ Scene_Exit_Add_2D_Exit(2, 0, 135, 85, 295, 3);
+ Scene_2D_Region_Add(0, 331, 73, 375, 114);
+ Ambient_Sounds_Add_Looping_Sound(280, 50, 38, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 25, 25, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 20, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ if (Game_Flag_Query(573)) {
+ if (Game_Flag_Query(537)) {
+ Scene_Loop_Start_Special(0, 2, 0);
+ Scene_Loop_Set_Default(0);
+ Game_Flag_Reset(537);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+ } else {
+ Actor_Set_Goal_Number(4, 201);
+ Scene_Loop_Start_Special(0, 2, 0);
+ Scene_Loop_Set_Default(0);
+ }
+ if (Actor_Query_Goal_Number(25) > 209 && Actor_Query_Goal_Number(25) < 215) {
+ Actor_Set_Goal_Number(25, 215);
+ }
+}
+
+void ScriptNR03::SceneLoaded() {
+ Obstacle_Object("PG3", true);
+ Obstacle_Object("X2BACKBARBOTTOM01", true);
+ Obstacle_Object("X2BACKSTAGETOP", true);
+ Unclickable_Object("PG3");
+ Unobstacle_Object("X2BACKBARBOTTOM02", true);
+ Unobstacle_Object("NM2", true);
+ Unobstacle_Object("MAN5", true);
+ Unobstacle_Object("MAN7", true);
+ Unobstacle_Object("X2BACKSTAGETOP", true);
+}
+
+bool ScriptNR03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR03::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("PG3", objectName)) {
+ Actor_Face_Object(0, "PG3", true);
+ Actor_Voice_Over(3770, 99);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR03::ClickedOnActor(int actorId) {
+ if (actorId == 25 && !Loop_Actor_Walk_To_Actor(0, 25, 48, 1, false)) {
+ AI_Movement_Track_Pause(25);
+ Actor_Face_Actor(0, 25, true);
+ if (Game_Flag_Query(611)) {
+ Actor_Says(0, 3350, 16);
+ Actor_Says(25, 50, 17);
+ } else {
+ Game_Flag_Set(611);
+ Actor_Says(0, 3340, 3);
+ Actor_Face_Actor(25, 0, true);
+ Actor_Says(25, 30, 13);
+ Actor_Says(0, 3345, 14);
+ Actor_Says(25, 40, 14);
+ }
+ AI_Movement_Track_Unpause(25);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 410.0f, -70.19f, -715.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(534);
+ Set_Enter(54, 54);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -161.0f, -70.19f, -1139.0f, 0, 1, false, 0)) {
+ if (Actor_Query_Which_Set_In(25) == 55) {
+ AI_Movement_Track_Pause(25);
+ Actor_Face_Actor(25, 0, true);
+ Actor_Face_Actor(0, 25, true);
+ int v3 = Global_Variable_Query(44);
+ if (v3 == 0) {
+ Actor_Says(25, 50, 13);
+ AI_Movement_Track_Unpause(25);
+ } else if (v3 == 1) {
+ Actor_Says(25, 210, 15);
+ AI_Movement_Track_Unpause(25);
+ } else if (v3 == 2) {
+ Actor_Set_Goal_Number(25, 220);
+ }
+ }
+ Global_Variable_Increment(44, 1);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(438);
+ Set_Enter(12, 57);
+ }
+
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -151.0f, -70.19f, -476.0f, 12, 1, false, 0)) {
+ if (Actor_Query_Goal_Number(25) == 213 || Actor_Query_Which_Set_In(25) != 55) {
+ Player_Loses_Control();
+ Player_Set_Combat_Mode(false);
+ Loop_Actor_Walk_To_XYZ(0, -229.0f, -70.19f, -469.0f, 0, 0, false, 1);
+ Actor_Face_Heading(0, 656, false);
+ Actor_Change_Animation_Mode(0, 53);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(536);
+ Set_Enter(13, 58);
+ Scene_Loop_Start_Special(1, 2, 0);
+ return true;
+ }
+ Actor_Face_Heading(0, 680, false);
+ Actor_Change_Animation_Mode(0, 12);
+ Delay(150);
+ Actor_Change_Animation_Mode(0, 0);
+ AI_Movement_Track_Pause(25);
+ Actor_Face_Actor(25, 0, true);
+
+ int v1 = Global_Variable_Query(43);
+ if (v1 == 0) {
+ Actor_Says(25, 0, 15);
+ Actor_Face_Actor(0, 25, true);
+ Actor_Says(0, 3335, 13);
+ Actor_Says(25, 10, 16);
+ AI_Movement_Track_Unpause(25);
+ } else if (v1 == 1) {
+ Actor_Face_Actor(0, 25, true);
+ Actor_Says(25, 210, 12);
+ AI_Movement_Track_Unpause(25);
+ } else if (v1 == 2) {
+ Actor_Set_Goal_Number(25, 220);
+ }
+ Global_Variable_Increment(43, 1);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR03::ClickedOn2DRegion(int region) {
+ if (region == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 79.2f, -70.19f, -984.0f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 47, true);
+ int v1 = Random_Query(0, 4);
+ if (v1 == 0) {
+ Actor_Says(0, 1055, 3);
+ } else if (v1 == 1) {
+ Actor_Says(0, 8590, 3);
+ } else if (v1 == 2) {
+ Actor_Says(0, 8930, 3);
+ } else if (v1 == 3) {
+ Actor_Says(0, 7465, 3);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptNR03::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing()) {
+ sub_402994();
+ }
+ if (frame == 72) {
+ Sound_Play(345, 83, -70, -70, 50);
+ }
+ if (frame == 76) {
+ Sound_Play(353, 62, -70, -70, 50);
+ }
+ if (frame > 70 && frame < 110) {
+ sub_40259C(frame);
+ } else {
+ if (frame != 110) {
+ //return false;
+ return;
+ }
+ if (Actor_Query_Goal_Number(4) == 201) {
+ Actor_Set_Goal_Number(4, 200);
+ } else if (!Game_Flag_Query(536)) {
+ Actor_Set_Goal_Number(0, 200);
+ Player_Gains_Control();
+ }
+ }
+ //return true;
+ return;
+}
+
+void ScriptNR03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR03::PlayerWalkedIn() {
+ Player_Set_Combat_Mode(false);
+ if (Game_Flag_Query(573)) {
+ if (Game_Flag_Query(535) ) {
+ Loop_Actor_Walk_To_XYZ(0, 302.0f, -70.19f, -715.0f, 0, 0, false, 0);
+ Game_Flag_Reset(535);
+ }
+ } else {
+ Game_Flag_Set(573);
+ Async_Actor_Walk_To_XYZ(0, 206.0f, -70.19f, -643.0f, 0, false);
+ Game_Flag_Reset(535);
+ Actor_Voice_Over(1490, 99);
+ Actor_Voice_Over(1510, 99);
+ Actor_Voice_Over(1520, 99);
+ }
+ if (Player_Query_Combat_Mode()) {
+ Actor_Set_Goal_Number(25, 220);
+ }
+ //return false;
+}
+
+void ScriptNR03::PlayerWalkedOut() {
+ if (!Game_Flag_Query(438)) {
+ Music_Stop(2);
+ }
+ if (Game_Flag_Query(536)) {
+ Player_Gains_Control();
+ }
+}
+
+void ScriptNR03::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR03::sub_40259C(int frame) {
+ int facing;
+ float angle, invertedAngle;
+
+ angle = cos((frame - 70) * (M_PI / 40.0f)) * M_PI_2;
+ invertedAngle = M_PI - angle;
+ if (!Game_Flag_Query(536) && Actor_Query_Goal_Number(4) != 201) {
+ angle = angle + M_PI;
+ invertedAngle = invertedAngle + M_PI;
+ }
+ float c = cos(invertedAngle);
+ float s = sin(invertedAngle);
+ float x = 36.49f * s - -60.21f * c + -265.49f;
+ float z = -60.21f * s + 36.49f * c + -408.79f;
+
+ if (Actor_Query_Goal_Number(4) == 201) {
+ facing = angle * (1024.0f / (2.0f * M_PI));
+ facing = facing + 144;
+ if (facing < 0) {
+ facing = facing + 1168;
+ }
+ if (facing > 1023) {
+ facing -= 1024;
+ }
+ Actor_Set_At_XYZ(4, x, -70.19f, z, facing);
+ } else {
+ facing = angle * (1024.0f / (2.0f * M_PI));
+ facing = facing + 400;
+ if (facing < 0) {
+ facing = facing + 1424;
+ }
+ if (facing > 1023) {
+ facing -= 1024;
+ }
+
+ Actor_Set_At_XYZ(0, x, -70.19f, z, facing);
+ }
+}
+
+void ScriptNR03::sub_402994() {
+ if (Music_Is_Playing()) {
+ Music_Adjust(51, 0, 2);
+ } else {
+ int v0 = Global_Variable_Query(53);
+ if (v0 == 0) {
+ Music_Play(14, 51, 0, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(13, 51, 0, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(5, 51, 0, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(53, v0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr04.cpp b/engines/bladerunner/script/nr04.cpp
new file mode 100644
index 0000000000..dc1d40d038
--- /dev/null
+++ b/engines/bladerunner/script/nr04.cpp
@@ -0,0 +1,358 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR04::InitializeScene() {
+ Music_Adjust(30, 80, 2);
+ Setup_Scene_Information(53.0f, 0.0f, -110.0f, 569);
+ Scene_Exit_Add_2D_Exit(0, 498, 126, 560, 238, 0);
+ Scene_2D_Region_Add(0, 0, 259, 61, 479);
+ Scene_2D_Region_Add(1, 62, 327, 92, 479);
+ Scene_2D_Region_Add(2, 93, 343, 239, 479);
+ Ambient_Sounds_Add_Looping_Sound(408, 16, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 16, 0, 1);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 9, 9, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 9, 9, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 9, 9, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 9, 9, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(195, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Scene_Loop_Set_Default(0);
+}
+
+void ScriptNR04::SceneLoaded() {
+ Clickable_Object("B.TV01");
+ Clickable_Object("B.TV02");
+ Clickable_Object("B.TV03");
+ Clickable_Object("B.TV05");
+ Clickable_Object("DESK");
+ if (!Game_Flag_Query(605)) {
+ Clickable_Object("TORUS01");
+ }
+ Clickable_Object("BOX12");
+}
+
+bool ScriptNR04::MouseClick(int x, int y) {
+ if (Actor_Query_Animation_Mode(0) == 85 || Actor_Query_Animation_Mode(0) == 29) {
+ return true;
+ }
+ if (Actor_Query_Animation_Mode(0) == 53) {
+ Actor_Change_Animation_Mode(0, 29);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR04::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("B.TV01", objectName) || Object_Query_Click("B.TV02", objectName) || Object_Query_Click("B.TV03", objectName) || Object_Query_Click("B.TV05", objectName) || Object_Query_Click("DESK", objectName)) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 546, 0, 1, false)) {
+ if (!Object_Query_Click("DESK", objectName)) {
+ Actor_Face_Object(0, "B.TV01", true);
+ Actor_Voice_Over(1530, 99);
+ Actor_Voice_Over(1540, 99);
+ Actor_Voice_Over(1550, 99);
+ } else {
+ Actor_Face_Object(0, "DESK", true);
+ if (!Actor_Clue_Query(0, 56)) {
+ Actor_Voice_Over(1600, 99);
+ Actor_Voice_Over(1610, 99);
+ } else if (Actor_Clue_Query(0, 100)) {
+ Actor_Says(0, 8580, 3);
+ } else {
+ Actor_Clue_Acquire(0, 100, 0, -1);
+ Item_Pickup_Spin_Effect(961, 247, 141);
+ Actor_Voice_Over(1560, 99);
+ Actor_Voice_Over(1570, 99);
+ Actor_Voice_Over(1580, 99);
+ Actor_Voice_Over(1590, 99);
+ }
+
+ }
+ }
+ } else if (Object_Query_Click("TORUS01", objectName)
+ && !Loop_Actor_Walk_To_XYZ(0, 18.56f, 0.0f, 38.86f, 0, 1, false, 0)
+ && !Game_Flag_Query(605)) {
+ Unclickable_Object("TORUS01");
+ Scene_Exits_Disable();
+ Player_Loses_Control();
+ Game_Flag_Set(605);
+ Actor_Face_Object(0, "TORUS01", true);
+ Item_Pickup_Spin_Effect(975, 358, 160);
+ Actor_Voice_Over(1620, 99);
+ Actor_Voice_Over(1630, 99);
+ Actor_Clue_Acquire(0, 89, 0, -1);
+ Actor_Set_Goal_Number(18, 201);
+ }
+ return false;
+}
+
+bool ScriptNR04::ClickedOnActor(int actorId) {
+ if (actorId == 18 && Game_Flag_Query(606)) {
+ Actor_Voice_Over(1640, 99);
+ Actor_Voice_Over(1650, 99);
+ Actor_Voice_Over(1660, 99);
+ Actor_Voice_Over(1670, 99);
+ Actor_Voice_Over(1680, 99);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 45.0f, 0.0f, -106.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(437);
+ Set_Enter(55, 56);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR04::ClickedOn2DRegion(int region) {
+ if (region == 0 || region == 1 || region == 2 && Actor_Query_Which_Set_In(18) != 12 && Actor_Query_Animation_Mode(0) != 53 && !Loop_Actor_Walk_To_Waypoint(0, 445, 0, 1, false)) {
+ Actor_Face_Heading(0, 49, false);
+ Actor_Change_Animation_Mode(0, 85);
+ Delay(2500);
+ if (Game_Flag_Query(606) == 1) {
+ return true;
+ }
+ if (Game_Flag_Query(374)) {
+ Player_Loses_Control();
+ Actor_Voice_Over(4180, 99);
+ Actor_Change_Animation_Mode(0, 48);
+ Ambient_Sounds_Play_Sound(555, 90, 99, 0, 0);
+ Delay(350);
+ Actor_Set_At_XYZ(0, 109.0f, 0.0f, 374.0f, 0);
+ Actor_Retired_Here(0, 12, 12, 1, -1);
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptNR04::SceneFrameAdvanced(int frame) {
+ if (frame == 1 && !Music_Is_Playing()) {
+ sub_402960();
+ }
+ if (frame > 60 && frame < 120) {
+ sub_402860(frame);
+ } else if (frame == 120) {
+ Set_Fade_Color(1.0f, 1.0f, 1.0f);
+ Set_Fade_Density(0.0f);
+ }
+ //return false;
+}
+
+void ScriptNR04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 18) {
+ switch (newGoal) {
+ case 214:
+ Actor_Change_Animation_Mode(18, 29);
+ Delay(2500);
+ Actor_Says(18, 290, 3);
+ sub_401DB0();
+ //return true;
+ break;
+ case 213:
+ Actor_Clue_Acquire(0, 88, 0, 18);
+ Item_Pickup_Spin_Effect(984, 200, 160);
+ Actor_Says(18, 200, 30);
+ Actor_Says(18, 210, 30);
+ Actor_Says(18, 220, 30);
+ Actor_Says_With_Pause(0, 3425, 1.5f, 23);
+ Actor_Says(0, 3430, 3);
+ Actor_Says(18, 240, 30);
+ Actor_Says(0, 3435, 3);
+ Actor_Says(18, 250, 30);
+ Actor_Says(0, 3440, 3);
+ Actor_Says(18, 280, 30);
+ Actor_Says(0, 3445, 3);
+ Actor_Set_Goal_Number(18, 214);
+ //return true;
+ break;
+ case 209:
+ Actor_Face_Actor(0, 18, true);
+ Delay(3000);
+ Actor_Says(18, 170, 30);
+ Actor_Says(0, 3415, 3);
+ Actor_Says(18, 180, 30);
+ Actor_Says_With_Pause(0, 3420, 1.5f, 3);
+ Actor_Says(18, 190, 30);
+ Actor_Set_Goal_Number(18, 211);
+ //return true;
+ break;
+ case 207:
+ Loop_Actor_Walk_To_Waypoint(18, 445, 0, 1, false);
+ Actor_Face_Heading(18, 49, false);
+ Actor_Change_Animation_Mode(18, 85);
+ Actor_Face_Actor(0, 18, true);
+ Actor_Set_Goal_Number(18, 208);
+ Actor_Clue_Acquire(0, 92, 0, 18);
+ //return true;
+ break;
+ case 204:
+ Actor_Face_Actor(0, 18, true);
+ Actor_Says(18, 90, 73);
+ Actor_Says(0, 3390, 3);
+ Actor_Face_Actor(18, 0, true);
+ Actor_Says(18, 110, 74);
+ Actor_Says(0, 3385, 3);
+ Actor_Says(18, 120, 74);
+ Actor_Face_Actor(18, 0, true);
+ Actor_Set_Goal_Number(18, 205);
+ //return true;
+ break;
+ case 202:
+ Actor_Face_Actor(18, 0, true);
+ Actor_Face_Actor(0, 18, true);
+ Actor_Says(18, 30, 3);
+ Actor_Says(0, 3375, 3);
+ Actor_Says_With_Pause(18, 50, 1.5f, 3);
+ Actor_Says(18, 60, 3);
+ Actor_Says_With_Pause(0, 3380, 1.0f, 3);
+ Actor_Says(18, 70, 3);
+ Actor_Says(0, 3415, 3);
+ Actor_Says(18, 80, 3);
+ Player_Gains_Control();
+ Actor_Set_Goal_Number(18, 203);
+ //return true;
+ break;
+ }
+ }
+ //return false;
+}
+
+void ScriptNR04::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, 53.0f, 0.0f, -26.0f, 0, 0, false, 0);
+ if (Game_Flag_Query(374)) {
+ Overlay_Play("nr04over", 0, 1, 0, 0);
+ Delay(4000);
+ Overlay_Remove("nr04over");
+ }
+ //return false;
+}
+
+void ScriptNR04::PlayerWalkedOut() {
+}
+
+void ScriptNR04::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR04::sub_401DB0() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List(1530, 10, 5, 3);
+ DM_Add_To_List(1540, 3, 5, 10);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 1530) {
+ Loop_Actor_Walk_To_Actor(18, 0, 36, 0, false);
+ Actor_Change_Animation_Mode(0, 23);
+ Actor_Change_Animation_Mode(18, 23);
+ Delay(1500);
+ Actor_Says(18, 300, 3);
+ Actor_Change_Animation_Mode(0, 0);
+ Actor_Change_Animation_Mode(18, 0);
+ Actor_Says(18, 310, 3);
+ ADQ_Add(0, 3450, 3);
+ Actor_Set_Targetable(18, false);
+ Actor_Set_Goal_Number(18, 217);
+ Actor_Clue_Lose(0, 89);
+ Scene_Exits_Enable();
+ } else if (answer == 1540) {
+ Actor_Says(0, 8512, 15);
+ Actor_Says(18, 320, 12);
+ Actor_Says(0, 3455, 13);
+ Actor_Says(18, 330, 15);
+ Actor_Says(0, 3460, 12);
+ Actor_Says(18, 340, 12);
+ Actor_Says(0, 3465, 12);
+ Actor_Says(18, 350, 16);
+ Actor_Set_Targetable(18, false);
+ Actor_Set_Goal_Number(18, 217);
+ Scene_Exits_Enable();
+ }
+}
+
+void ScriptNR04::sub_402860(int frame) {
+ float colorMap[] = {
+ 1.0f, 1.0f, 1.0f,
+ 1.0f, 0.0f, 0.0f,
+ 0.8f, 0.4f, 0.0f,
+ 0.7f, 0.7f, 0.0f,
+ 0.0f, 1.0f, 0.0f,
+ 0.0f, 0.0f, 1.0f,
+ 0.5f, 0.0f, 0.8f};
+
+ float v3 = (frame - 60) / 10;
+ float v4 = (frame % 10) * 0.1f;
+ float coef = 1.0f;
+ if (frame > 100) {
+ coef = 1.0f - (frame - 100) / 20.0f;
+ }
+ int index = 3 * v3;
+ int nextIndex = 3 * v3 + 3;
+ float r = ((colorMap[nextIndex + 0] - colorMap[index + 0]) * v4 + colorMap[index + 0]) * coef;
+ float g = ((colorMap[nextIndex + 1] - colorMap[index + 1]) * v4 + colorMap[index + 1]) * coef;
+ float b = ((colorMap[nextIndex + 2] - colorMap[index + 2]) * v4 + colorMap[index + 2]) * coef;
+ Set_Fade_Color(r, g, b);
+ if (frame >= 90) {
+ Set_Fade_Density(0.75f);
+ } else {
+ Set_Fade_Density((frame - 60) / 45.0f);
+ }
+}
+
+void ScriptNR04::sub_402960() {
+ int v0 = Global_Variable_Query(53);
+ if (!v0) {
+ Music_Play(14, 11, 80, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(13, 11, 80, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(5, 11, 80, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(53, v0);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr05.cpp b/engines/bladerunner/script/nr05.cpp
new file mode 100644
index 0000000000..a62052bdfd
--- /dev/null
+++ b/engines/bladerunner/script/nr05.cpp
@@ -0,0 +1,369 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR05::InitializeScene() {
+ if (Game_Flag_Query(547)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(-777.56f, 0.0f, -166.86f, 0);
+ } else if (Game_Flag_Query(536)) {
+ Setup_Scene_Information(-456.0f, 0.0f, -611.0f, 0);
+ } else {
+ Setup_Scene_Information(-527.0f, 1.57f, -406.0f, 649);
+ }
+ Scene_Exit_Add_2D_Exit(0, 459, 147, 639, 290, 1);
+ if (Game_Flag_Query(620)) {
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ }
+ Ambient_Sounds_Add_Looping_Sound(280, 50, 38, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 20, 20, -30, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 25, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(570, 5, 70, 11, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(571, 5, 70, 11, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(572, 5, 70, 11, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(573, 5, 70, 11, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ if (Game_Flag_Query(547)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(536)) {
+ Scene_Loop_Start_Special(0, 3, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(536);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptNR05::SceneLoaded() {
+ Obstacle_Object("NM1-1+", true);
+ Clickable_Object("NM1-1+");
+ Unclickable_Object("NM1-1+");
+}
+
+bool ScriptNR05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR05::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptNR05::ClickedOnActor(int actorId) {
+ if (actorId == 42) {
+ if (!Loop_Actor_Walk_To_Actor(0, 42, 120, 1, false)) {
+ sub_4020B4();
+ }
+ return true;
+ }
+ if (actorId == 18) {
+ Actor_Set_Goal_Number(18, 229);
+ if (!Loop_Actor_Walk_To_Actor(0, 18, 36, 1, false)) {
+ sub_4022DC();
+ }
+ Actor_Set_Goal_Number(18, 221);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -444.0f, 0.0f, -451.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Music_Stop(2);
+ Player_Set_Combat_Mode(false);
+ Actor_Face_Heading(0, 1021, false);
+ Actor_Change_Animation_Mode(0, 53);
+ Game_Flag_Set(537);
+ Set_Enter(55, 56);
+ Scene_Loop_Start_Special(1, 3, 0);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -777.56f, 0.0f, -166.86f, 0, 1, false, 0)) {
+ Game_Flag_Set(546);
+ Set_Enter(13, 61);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR05::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing()) {
+ sub_402B9C();
+ }
+ if (frame == 78) {
+ Sound_Play(345, 83, 70, 70, 50);
+ }
+ if (frame == 86) {
+ Sound_Play(353, 62, 70, 70, 50);
+ }
+ sub_402A48(48);
+ sub_402A48(0);
+ if (Actor_Query_Goal_Number(18) == 224) {
+ Actor_Set_Goal_Number(18, 225);
+ if (Player_Query_Current_Scene() == 58) {
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ }
+ }
+ if (frame > 77 && frame <= 134) {
+ sub_401F74(frame - 13);
+ if (frame == 134 && !Game_Flag_Query(537)) {
+ Actor_Set_Goal_Number(0, 200);
+ }
+ //return true;
+ return;
+ } else {
+ //return false;
+ return;
+ }
+
+}
+
+void ScriptNR05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR05::PlayerWalkedIn() {
+ if (Game_Flag_Query(547)) {
+ Music_Stop(2);
+ Loop_Actor_Walk_To_XYZ(0, -697.56f, 0.0f, -174.86f, 0, 1, false, 0);
+ Game_Flag_Reset(547);
+ }
+ // return false;
+}
+
+void ScriptNR05::PlayerWalkedOut() {
+ if (Game_Flag_Query(537)) {
+ Music_Stop(2);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptNR05::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR05::sub_401F74(int frame) {
+ float angle = cos((frame - 65) * (M_PI / 57.0f)) * M_PI_2;
+ float invertedAngle = M_PI - angle;
+ if (!Game_Flag_Query(537)) {
+ angle = angle + M_PI;
+ invertedAngle = invertedAngle + M_PI;
+ }
+ float c = cos(invertedAngle);
+ float s = sin(invertedAngle);
+ float x = 6.0f * s - 80.0f * c + -450.0f;
+ float z = 80.0f * s + 6.0f * c + -531.0f;
+
+ int facing = angle * (1024.0f / (2.0f * M_PI));
+ facing = facing + 765;
+ if (facing < 0) {
+ facing = facing + 1789;
+ }
+ if (facing > 1023) {
+ facing -= 1024;
+ }
+ Actor_Set_At_XYZ(0, x, 0.0f, z, facing);
+}
+
+void ScriptNR05::sub_4020B4() {
+ Actor_Face_Actor(0, 42, true);
+ Actor_Face_Actor(42, 0, true);
+ if (Game_Flag_Query(588)) {
+ if (Game_Flag_Query(589)) {
+ Actor_Says(0, 3480, 19);
+ Actor_Says(42, 30, 12);
+ Actor_Says(0, 3485, 3);
+ Actor_Says(42, 40, 13);
+ Actor_Change_Animation_Mode(42, 23);
+ Actor_Change_Animation_Mode(0, 75);
+ Global_Variable_Increment(42, 1);
+ } else {
+ Actor_Says(0, 3475, 17);
+ Actor_Says(42, 20, 23);
+ Game_Flag_Set(589);
+ Actor_Change_Animation_Mode(0, 75);
+ Global_Variable_Increment(42, 1);
+ }
+ } else {
+ Actor_Says(42, 0, 13);
+ Actor_Says(0, 3470, 3);
+ Actor_Says(42, 10, 23);
+ Game_Flag_Set(588);
+ Actor_Change_Animation_Mode(0, 75);
+ Global_Variable_Increment(42, 1);
+ }
+}
+
+void ScriptNR05::sub_4022DC() {
+ if (Actor_Query_Goal_Number(18) == 220) {
+ Actor_Set_Goal_Number(18, 221);
+ }
+ Actor_Face_Actor(0, 18, true);
+ Actor_Face_Actor(18, 0, true);
+ if (!Game_Flag_Query(590)) {
+ Actor_Says(0, 8513, 3);
+ Actor_Says(18, 360, 3);
+ Actor_Says(0, 3495, 11);
+ Actor_Says(18, 370, 15);
+ Actor_Says(0, 3500, 17);
+ Actor_Says(18, 380, 13);
+ Game_Flag_Set(590);
+ return;
+ }
+ Dialogue_Menu_Clear_List();
+ if (Actor_Query_Friendliness_To_Other(18, 0) >= 48) {
+ if (Actor_Clue_Query(0, 90) || Actor_Clue_Query(0, 100)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(890, -1, 4, 8);
+ }
+ if (Actor_Clue_Query(0, 13)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(900, 5, 6, 5);
+ }
+ if (Actor_Clue_Query(0, 88)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(910, 5, 5, 5);
+ }
+ }
+ if (!Dialogue_Menu_Query_List_Size()) {
+ Actor_Says(0, 3520, 3);
+ Actor_Says(18, 730, 3);
+ Actor_Face_Heading(18, 849, false);
+ return;
+ }
+ Dialogue_Menu_Add_DONE_To_List(100);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 890) {
+ Actor_Says(0, 3505, 3);
+ Actor_Modify_Friendliness_To_Other(18, 0, -1);
+ Actor_Says(18, 420, 12);
+ Actor_Says(18, 430, 13);
+ Actor_Says(0, 3530, 15);
+ Actor_Says(18, 440, 15);
+ Actor_Says(0, 3535, 13);
+ Actor_Says(18, 460, 16);
+ Actor_Says(0, 3540, 15);
+ Actor_Says(18, 490, 16);
+ Actor_Says(18, 500, 13);
+ Actor_Says(0, 3545, 15);
+ Actor_Says(18, 520, 12);
+ Actor_Face_Heading(18, 849, false);
+ } else if (answer == 900) {
+ Actor_Says(0, 3510, 15);
+ Actor_Modify_Friendliness_To_Other(18, 0, -1);
+ Actor_Says_With_Pause(18, 530, 1.2f, 3);
+ Actor_Says(18, 540, 15);
+ Actor_Says(0, 3550, 13);
+ Actor_Says(18, 560, 14);
+ Actor_Says(18, 570, 13);
+ Actor_Says(0, 3555, 12);
+ Actor_Face_Heading(18, 849, false);
+ } else if (answer == 910) {
+ Actor_Says(0, 3515, 14);
+ Actor_Modify_Friendliness_To_Other(18, 0, -1);
+ if (Actor_Clue_Query(0, 99)) {
+ Actor_Says(18, 580, 12);
+ Actor_Says(0, 3560, 13);
+ Actor_Says(18, 590, 16);
+ Actor_Says(0, 3565, 16);
+ Actor_Says(18, 600, 13);
+ Actor_Says(0, 3570, 14);
+ Actor_Says(18, 620, 15);
+ Actor_Says(0, 3575, 13);
+ } else {
+ Actor_Says(18, 640, 13);
+ Actor_Says(0, 3580, 15);
+ Actor_Says(18, 660, 12);
+ }
+ Actor_Face_Heading(18, 849, false);
+ }
+}
+
+void ScriptNR05::sub_402A48(int actorId) {
+ int animationMode = Actor_Query_Animation_Mode(actorId);
+ if (animationMode == 1 || animationMode == 2 || animationMode == 7 || animationMode == 8) {
+ return;
+ }
+ float x, y, z;
+ Actor_Query_XYZ(actorId, &x, &y, &z);
+ if ((x - -542.0f) * (x - -542.0f) + (z - -195.0f) * (z - -195.0f) < 8464.0f) {
+ float s = sin(M_PI / 128.0f);
+ float c = cos(M_PI / 128.0f);
+ float newX = x * c - z * s + -542.0f;
+ float newZ = x * s + z * c + -195.0f;
+ int newFacing = (Actor_Query_Facing_1024(actorId) + 4) % 1024;
+ Actor_Set_At_XYZ(actorId, newX, y, newZ, newFacing);
+ }
+}
+
+void ScriptNR05::sub_402B9C() {
+ if (Music_Is_Playing()) {
+ Music_Adjust(51, 0, 2);
+ } else {
+ int v0 = Global_Variable_Query(54);
+ if (v0 == 0) {
+ Music_Play(16, 61, -80, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(15, 41, -80, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(7, 41, -80, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(54, v0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr06.cpp b/engines/bladerunner/script/nr06.cpp
new file mode 100644
index 0000000000..e21bb49bbc
--- /dev/null
+++ b/engines/bladerunner/script/nr06.cpp
@@ -0,0 +1,162 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR06::InitializeScene() {
+ sub_401BAC();
+ if (Game_Flag_Query(442)) {
+ Setup_Scene_Information(48.0f, -71.88f, -26.0f, 782);
+ } else {
+ Setup_Scene_Information(-36.0f, 0.37f, -373.0f, 592);
+ }
+ Scene_Exit_Add_2D_Exit(0, 533, 234, 592, 414, 1);
+ Scene_Exit_Add_2D_Exit(1, 238, 137, 337, 322, 0);
+ Ambient_Sounds_Add_Looping_Sound(111, 25, 0, 1);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 8, 12, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 8, 8, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(195, 5, 70, 8, 8, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptNR06::SceneLoaded() {
+ Obstacle_Object("CHAIR01", true);
+ Unobstacle_Object("LOFT04", true);
+ Unobstacle_Object("LINE02", true);
+ Unobstacle_Object("WALL01", true);
+ Unclickable_Object("CHAIR01");
+}
+
+bool ScriptNR06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptNR06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 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, 60);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -137.0f, -71.88f, -243.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 95, false);
+ Loop_Actor_Travel_Stairs(0, 8, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, -36.0f, 0.37f, -373.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(439);
+ Set_Enter(13, 61);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR06::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing()) {
+ sub_401BAC();
+ }
+ //return false;
+}
+
+void ScriptNR06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR06::PlayerWalkedIn() {
+ if (Game_Flag_Query(442)) {
+ Loop_Actor_Walk_To_XYZ(0, -3.0f, -71.88f, -26.0f, 0, 0, false, 0);
+ Game_Flag_Reset(442);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -81.72f, 0.12f, -323.49f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 600, false);
+ Loop_Actor_Travel_Stairs(0, 8, 0, 0);
+ Game_Flag_Reset(440);
+ }
+ //return false;
+}
+
+void ScriptNR06::PlayerWalkedOut() {
+ if (Game_Flag_Query(441)) {
+ Music_Stop(2);
+ }
+}
+
+void ScriptNR06::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR06::sub_401BAC() {
+ if (Music_Is_Playing()) {
+ Music_Adjust(31, 80, 2);
+ } else {
+ int v0 = Global_Variable_Query(54);
+ if (v0 == 0) {
+ Music_Play(16, 61, -80, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(15, 41, -80, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(7, 41, -80, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(54, v0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr07.cpp b/engines/bladerunner/script/nr07.cpp
new file mode 100644
index 0000000000..99b7aff2b1
--- /dev/null
+++ b/engines/bladerunner/script/nr07.cpp
@@ -0,0 +1,379 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR07::InitializeScene() {
+ Setup_Scene_Information(-110.0f, -73.5f, -193.0f, 554);
+ Scene_Exit_Add_2D_Exit(0, 429, 137, 506, 251, 0);
+ Ambient_Sounds_Add_Looping_Sound(111, 25, 0, 1);
+}
+
+void ScriptNR07::SceneLoaded() {
+ Obstacle_Object("VANITY", true);
+ Clickable_Object("VASE");
+}
+
+bool ScriptNR07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR07::ClickedOn3DObject(const char *objectName, bool a2) {
+ Actor_Set_Goal_Number(25, 201);
+ if (Object_Query_Click("VASE", objectName)) {
+ sub_401C60();
+ }
+ Actor_Set_Goal_Number(25, 200);
+ return false;
+}
+
+bool ScriptNR07::ClickedOnActor(int actorId) {
+ if (actorId == 3) {
+ if (Actor_Query_Goal_Number(33) <= 239) {
+ Actor_Set_Goal_Number(25, 201);
+ Actor_Face_Actor(0, 3, true);
+ Dialogue_Menu_Clear_List();
+ if (Game_Flag_Query(638)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1100, -1, 3, 8);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1110, 8, -1, -1);
+ if (Actor_Clue_Query(0, 95)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1120, 3, 6, 7);
+ }
+ if (Actor_Clue_Query(0, 113)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1130, 3, 5, 7);
+ }
+ if (Game_Flag_Query(510)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1140, 1, 4, 7);
+ }
+ } else {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1080, 3, 5, 7);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1090, 7, 5, 4);
+ }
+ Dialogue_Menu_Add_DONE_To_List(1150);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 1140:
+ sub_4028FC();
+ break;
+ case 1130:
+ sub_402738();
+ break;
+ case 1120:
+ sub_402614();
+ break;
+ case 1110:
+ sub_402510();
+ break;
+ case 1100:
+ sub_402284();
+ break;
+ case 1090:
+ Actor_Says(0, 3650, 13);
+ Actor_Says(3, 630, 30);
+ Actor_Says(0, 3655, 16);
+ Actor_Says(3, 640, 31);
+ break;
+ case 1080:
+ sub_401EF4();
+ break;
+ default:
+ break;
+ }
+ Actor_Set_Goal_Number(25, 200);
+ return false;;
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -102.0f, -73.5f, -233.0f, 0, 1, false, 0)) {
+ Actor_Set_Goal_Number(25, 201);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(442);
+ Set_Enter(56, 59);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptNR07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR07::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, -110.0f, -73.5f, -169.0f, 0, 0, false, 0);
+ if (Actor_Query_In_Set(3, 57)) {
+ if (Game_Flag_Query(508)) {
+ Actor_Modify_Friendliness_To_Other(3, 0, -2);
+ Actor_Says(3, 530, 31);
+ } else {
+ Game_Flag_Set(508);
+ if (!Actor_Clue_Query(3, 214)) {
+ Actor_Modify_Friendliness_To_Other(3, 0, 5);
+ } else if (Actor_Clue_Query(0, 216) || Actor_Clue_Query(0, 217)) {
+ Actor_Modify_Friendliness_To_Other(3, 0, 10);
+ }
+ Actor_Says(3, 500, 30);
+ Actor_Says(0, 3585, 14);
+ Actor_Says(3, 510, 30);
+ Actor_Start_Speech_Sample(0, 3590);
+ Loop_Actor_Walk_To_XYZ(0, -112.0f, -73.0f, -89.0f, 525, 0, false, 0);
+ Actor_Says(3, 520, 53);
+ }
+ Actor_Set_Goal_Number(25, 200);
+ }
+ //return false;
+}
+
+void ScriptNR07::PlayerWalkedOut() {
+
+}
+
+void ScriptNR07::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR07::sub_4018D4() {
+ Actor_Set_Goal_Number(25, 201);
+ Player_Loses_Control();
+ Actor_Set_At_XYZ(3, -136.0f, -73.0f, -18.0f, 300);
+ Actor_Change_Animation_Mode(3, 71);
+ Actor_Change_Animation_Mode(0, 21);
+ Loop_Actor_Walk_To_XYZ(3, -102.0f, -73.5f, -233.0f, 0, 0, true, 0);
+ if (Game_Flag_Query(47)) {
+ Actor_Set_Goal_Number(3, 245);
+ } else {
+ Actor_Set_Goal_Number(3, 295);
+ Game_Flag_Set(591);
+ Actor_Put_In_Set(3, 91);
+ Actor_Set_At_Waypoint(3, 33, 0);
+ }
+ Player_Gains_Control();
+}
+
+void ScriptNR07::sub_401A10() {
+ Scene_Exits_Disable();
+ Actor_Set_Goal_Number(25, 201);
+ Actor_Says_With_Pause(3, 930, 1.0f, 30);
+ Actor_Says_With_Pause(3, 910, 1.0f, 30);
+ Actor_Face_Object(3, "VANITY", true);
+ Actor_Says(3, 940, 31);
+ Actor_Says(0, 3770, 19);
+ Async_Actor_Walk_To_XYZ(0, -193.0f, -73.5f, -13.0f, 0, false);
+ Actor_Says(3, 950, 31);
+ Actor_Face_Actor(3, 0, true);
+ Actor_Change_Animation_Mode(3, 4);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Says(0, 3760, 19);
+ Actor_Says(3, 960, 53);
+ Actor_Says(3, 920, 53);
+ Actor_Says(0, 3780, 0);
+ Actor_Says(3, 970, 53);
+ Actor_Voice_Over(1710, 99);
+ Actor_Voice_Over(1720, 99);
+ Actor_Voice_Over(1730, 99);
+ Actor_Set_Goal_Number(33, 240);
+}
+
+void ScriptNR07::sub_401C60() {
+ Loop_Actor_Walk_To_XYZ(0, -109.0f, -73.0f, -89.0f, 0, 0, false, 0);
+ Actor_Face_Object(0, "VASE", true);
+ if (Actor_Query_Is_In_Current_Set(3)) {
+ if (!Actor_Clue_Query(0, 97)) {
+ Actor_Clue_Acquire(0, 97, 1, -1);
+ int v0 = Actor_Query_Friendliness_To_Other(3, 0);
+ if (v0 > 50) {
+ Actor_Modify_Friendliness_To_Other(3, 0, 2);
+ } else if (v0 <= 50) {
+ Actor_Modify_Friendliness_To_Other(3, 0, -2);
+ }
+ Actor_Says(0, 3600, 19);
+ Actor_Says(3, 550, 30);
+ Actor_Says(0, 3605, 19);
+ Actor_Says(3, 560, 31);
+ Actor_Says(0, 3610, 19);
+ }
+ } else if (Actor_Clue_Query(0, 98)) {
+ Actor_Says(0, 8585, 14);
+ } else {
+ Actor_Clue_Acquire(0, 98, 1, -1);
+ Loop_Actor_Walk_To_Scene_Object(0, "VASE", 100, 1, false);
+ Actor_Change_Animation_Mode(0, 23);
+ Item_Pickup_Spin_Effect(935, 526, 268);
+ Actor_Voice_Over(1690, 99);
+ Actor_Voice_Over(1700, 99);
+ }
+}
+
+void ScriptNR07::sub_401EF4() {
+ Actor_Clue_Acquire(0, 96, 1, -1);
+ Actor_Says(0, 3625, 19);
+ Actor_Says(3, 570, 30);
+ Actor_Says_With_Pause(3, 580, 1.0f, 31);
+ Actor_Says(0, 3630, 13);
+ Actor_Says_With_Pause(3, 590, 1.0f, 30);
+ Actor_Says(3, 600, 30);
+ Actor_Start_Speech_Sample(0, 3640);
+ Loop_Actor_Walk_To_XYZ(0, -109.0f, -73.0f, -89.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Face_Actor(3, 0, true);
+ Game_Flag_Set(638);
+ Actor_Clue_Acquire(0, 91, 1, 3);
+ int v0 = Actor_Query_Friendliness_To_Other(3, 0);
+ if (!Game_Flag_Query(47) && v0 < 40) {
+ sub_4018D4();
+ return;
+ }
+ if (v0 < 36) {
+ sub_401A10();
+ return;
+ }
+ sub_4020F0();
+}
+
+void ScriptNR07::sub_4020F0() {
+ if (Actor_Clue_Query(3, 213) && Actor_Clue_Query(3, 214)) {
+ Actor_Modify_Friendliness_To_Other(3, 0, -1);
+ }
+ Actor_Says(3, 610, 31);
+ Actor_Says(0, 3645, 12);
+ Actor_Says(3, 620, 30);
+ int v0 = Actor_Query_Friendliness_To_Other(3, 0);
+ if (!Game_Flag_Query(47) && v0 < 40) {
+ sub_4018D4();
+ return;
+ }
+ if (v0 < 36) {
+ sub_401A10();
+ return;
+ }
+ Actor_Face_Object(3, "VANITY", true);
+}
+
+void ScriptNR07::sub_402284() {
+ Actor_Clue_Acquire(0, 94, 1, -1);
+ Actor_Start_Speech_Sample(0, 3660);
+ Loop_Actor_Walk_To_XYZ(0, -109.0f, -73.0f, -89.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Says(3, 650, 30);
+ Actor_Says(3, 660, 31);
+ Actor_Says(0, 3665, 18);
+ Actor_Face_Actor(3, 0, true);
+ Actor_Says(3, 670, 31);
+ Actor_Says(3, 680, 30);
+ Actor_Says(3, 690, 31);
+ Actor_Says(0, 3670, 17);
+ Actor_Says(3, 700, 30);
+ Actor_Says(0, 3675, 19);
+ Actor_Says(3, 710, 30);
+ Actor_Says(0, 3680, 19);
+ Actor_Says(3, 720, 30);
+ Actor_Says(3, 730, 30);
+ Actor_Says(0, 3685, 13);
+ Voight_Kampff_Activate(3, 40);
+ if (Game_Flag_Query(47)) {
+ sub_401A10();
+ } else {
+ sub_4018D4();
+ }
+}
+
+void ScriptNR07::sub_402510() {
+ Actor_Says(0, 3690, 14);
+ Actor_Start_Speech_Sample(3, 750);
+ Loop_Actor_Walk_To_XYZ(0, -109.0f, -73.0f, -89.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Face_Actor(3, 0, true);
+ Actor_Says(0, 3695, 15);
+ Actor_Modify_Friendliness_To_Other(3, 0, 5);
+ if (Game_Flag_Query(47)) {
+ sub_401A10();
+ } else {
+ sub_4018D4();
+ }
+}
+
+void ScriptNR07::sub_402614() {
+ Actor_Says(0, 3705, 19);
+ Actor_Says(3, 760, 53);
+ if (Game_Flag_Query(47)) {
+ Actor_Modify_Friendliness_To_Other(3, 0, -5);
+ Actor_Says(0, 3710, 18);
+ sub_401A10();
+ } else {
+ Actor_Modify_Friendliness_To_Other(3, 0, -3);
+ Actor_Start_Speech_Sample(0, 3710);
+ Loop_Actor_Walk_To_XYZ(0, -109.0f, -73.0f, -89.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 3, true);
+ sub_4018D4();
+ }
+}
+
+void ScriptNR07::sub_402738() {
+ Actor_Modify_Friendliness_To_Other(3, 0, -3);
+ Actor_Says(0, 3615, 16);
+ Actor_Says(3, 770, 30);
+ Actor_Says(0, 3720, 15);
+ Actor_Says_With_Pause(3, 780, 2.0f, 30);
+ Actor_Says(3, 790, 31);
+ Actor_Says(0, 3725, 18);
+ Actor_Says(3, 800, 30);
+ Actor_Says_With_Pause(0, 3730, 2.0f, 13);
+ Actor_Says_With_Pause(3, 810, 1.0f, 53);
+ Actor_Says(3, 820, 30);
+ Actor_Says(0, 3735, 14);
+ Actor_Says(3, 830, 31);
+ Actor_Says(0, 3740, 19);
+}
+
+void ScriptNR07::sub_4028FC() {
+ Actor_Says(0, 3620, 19);
+ Actor_Says(3, 840, 30);
+ Actor_Says(0, 3745, 9);
+ Actor_Says_With_Pause(3, 850, 1.0f, 30);
+ Actor_Says(3, 860, 30);
+ Actor_Says(3, 870, 53);
+ Actor_Says(0, 3750, 11);
+ Actor_Says(3, 880, 30);
+ Actor_Says(0, 3755, 16);
+ Actor_Says(3, 890, 31);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr08.cpp b/engines/bladerunner/script/nr08.cpp
new file mode 100644
index 0000000000..62bf3c7bfd
--- /dev/null
+++ b/engines/bladerunner/script/nr08.cpp
@@ -0,0 +1,242 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR08::InitializeScene() {
+ if (Actor_Query_Goal_Number(1) == 231) {
+ Setup_Scene_Information(-1174.1f, 0.32f, 303.9f, 435);
+ } else if (Game_Flag_Query(546)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(-1102.88f, 0.0f, 107.43f, 0);
+ if (Actor_Query_Goal_Number(3) == 210) {
+ Music_Stop(1);
+ }
+ } else if (Game_Flag_Query(439)) {
+ Setup_Scene_Information(-724.7f, 0.0f, 384.24f, 1000);
+ Game_Flag_Reset(439);
+ } else if (Game_Flag_Query(615)) {
+ Setup_Scene_Information(-1663.33f, 0.65f, 342.84f, 330);
+ Game_Flag_Reset(615);
+ }
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ if (Actor_Query_Goal_Number(3) != 210) {
+ Scene_Exit_Add_2D_Exit(1, 0, 309, 30, 398, 3);
+ Scene_Exit_Add_2D_Exit(2, 520, 330, 556, 386, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(280, 50, 38, 0);
+ Ambient_Sounds_Add_Sound(252, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(254, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(255, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(256, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(257, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(258, 3, 60, 14, 14, 60, 90, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(259, 3, 60, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(260, 3, 60, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(261, 3, 60, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(262, 3, 60, 16, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 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);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptNR08::SceneLoaded() {
+ Obstacle_Object("BOX283", true);
+ Unobstacle_Object("BOX283", true);
+ if (Actor_Query_Goal_Number(3) == 210) {
+ Actor_Change_Animation_Mode(3, 79);
+ }
+}
+
+bool ScriptNR08::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR08::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptNR08::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR08::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR08::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1102.88f, 0.0f, 107.43f, 0, 1, false, 0)) {
+ Game_Flag_Set(547);
+ Set_Enter(13, 58);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -724.7f, 0.0f, 384.24f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 505, false);
+ Loop_Actor_Travel_Stairs(0, 4, 1, 0);
+ Game_Flag_Set(440);
+ Set_Enter(56, 59);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1663.33f, 0.65f, 342.84f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 831, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 6, 1, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Set(614);
+ Set_Enter(58, 62);
+ }
+ }
+ return false;
+}
+
+bool ScriptNR08::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR08::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing()) {
+ sub_4021B4();
+ }
+ Set_Fade_Color(0, 0, 0);
+ if (frame >= 76 && frame < 91) {
+ Set_Fade_Density((frame - 76) / 14.0f);
+ Music_Stop(3);
+ Ambient_Sounds_Play_Sound(566, 27, 0, 99, 0);
+ } else if (frame >= 91 && frame < 120) {
+ Actor_Set_Invisible(0, true);
+ Set_Fade_Density(1.0f);
+ } else if (frame >= 120 && frame < 135) {
+ Set_Fade_Density((134 - frame) / 14.0f);
+ Music_Play(7, 61, 0, 1, -1, 0, 0);
+ } else {
+ Actor_Set_Invisible(0, false);
+ Set_Fade_Density(0.0f);
+ }
+ if (Game_Flag_Query(651) && !Game_Flag_Query(636)) {
+ Game_Flag_Set(636);
+ Scene_Exits_Disable();
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 3, 1);
+ }
+ if (frame == 95) {
+ Actor_Put_In_Set(3, 91);
+ Actor_Set_At_Waypoint(3, 33, 0);
+ Actor_Change_Animation_Mode(3, 0);
+ Actor_Set_Goal_Number(3, 200);
+ Scene_Exit_Add_2D_Exit(1, 0, 309, 30, 398, 3);
+ Scene_Exit_Add_2D_Exit(2, 520, 330, 556, 386, 0);
+ }
+ if (frame == 130) {
+ Scene_Exits_Enable();
+ }
+ //return false;
+}
+
+void ScriptNR08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR08::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(3) != 210 || Game_Flag_Query(729)) {
+ Music_Adjust(51, 0, 2);
+ } else {
+ Game_Flag_Set(729);
+ Ambient_Sounds_Play_Sound(566, 27, 0, 99, 0);
+ Outtake_Play(40, 1, -1);
+ }
+ if (Actor_Query_Goal_Number(3) == 245) {
+ Actor_Face_Heading(3, 790, false);
+ Loop_Actor_Travel_Stairs(3, 8, 1, 0);
+ Actor_Set_Goal_Number(3, 246);
+ }
+ if (Actor_Query_Goal_Number(1) == 231) {
+ Actor_Says(1, 1640, 12);
+ if (!Game_Flag_Query(378)) {
+ Actor_Says(0, 3790, 13);
+ Actor_Says(1, 1650, 14);
+ }
+ Actor_Says(1, 1660, 12);
+ Actor_Says(0, 3795, 16);
+ Actor_Says(1, 1670, 13);
+ Actor_Says(1, 1680, 14);
+ Actor_Says(1, 1690, 15);
+ Actor_Set_Goal_Number(1, 235);
+ //return true;
+ return;
+ } else {
+ if (Game_Flag_Query(546)) {
+ Loop_Actor_Walk_To_XYZ(0, -1090.88f, 0.0f, 147.43f, 0, 1, false, 0);
+ Game_Flag_Reset(546);
+ }
+ //return false;
+ return;
+ }
+}
+
+void ScriptNR08::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(547)) {
+ Music_Stop(2);
+ }
+}
+
+void ScriptNR08::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR08::sub_4021B4() {
+ if (Music_Is_Playing()) {
+ Music_Adjust(51, 0, 2);
+ } else if (Actor_Query_Goal_Number(3) == 210) {
+ Music_Play(6, 61, 0, 1, -1, 0, 0);
+ } else {
+ int v0 = Global_Variable_Query(54);
+ if (v0 == 0) {
+ Music_Play(16, 61, -80, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(15, 41, -80, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(7, 41, -80, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(54, v0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr09.cpp b/engines/bladerunner/script/nr09.cpp
new file mode 100644
index 0000000000..8453fa3420
--- /dev/null
+++ b/engines/bladerunner/script/nr09.cpp
@@ -0,0 +1,145 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR09::InitializeScene() {
+ if (Game_Flag_Query(476)) {
+ if (!Game_Flag_Query(640)) {
+ Ambient_Sounds_Adjust_Looping_Sound(452, 22, 100, 2);
+ }
+ Game_Flag_Reset(476);
+ Setup_Scene_Information(-556.07f, 0.35f, 399.04f, 440);
+ } else {
+ if (!Game_Flag_Query(640)) {
+ Ambient_Sounds_Add_Looping_Sound(452, 22, 100, 1);
+ }
+ Setup_Scene_Information(-704.07f, 0.35f, 663.04f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 400, 100, 440, 280, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ Ambient_Sounds_Add_Looping_Sound(205, 22, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(71, 33, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptNR09::SceneLoaded() {
+ Obstacle_Object("X2NEWSPAPER", true);
+ Unobstacle_Object("X2NEWSPAPER", true);
+ Unclickable_Object("X2NEWSPAPER");
+}
+
+bool ScriptNR09::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR09::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptNR09::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR09::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR09::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -564.07f, 0.35f, 399.04f, 0, 1, false, 0)) {
+ Game_Flag_Set(475);
+ Set_Enter(59, 63);
+ return true;
+ }
+ }
+ if (exitId == 1) {
+ int v1 = Loop_Actor_Walk_To_XYZ(0, -704.07f, 0.35f, 663.04f, 0, 1, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!v1) {
+ Game_Flag_Set(615);
+ Set_Enter(13, 61);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptNR09::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR09::SceneFrameAdvanced(int frame) {
+ if (!Music_Is_Playing()) {
+ sub_40172C();
+ }
+}
+
+void ScriptNR09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR09::PlayerWalkedIn() {
+ if (Game_Flag_Query(614)) {
+ Loop_Actor_Walk_To_XYZ(0, -704.07001f, 0.35f, 623.04f, 0, 0, false, 0);
+ Game_Flag_Reset(614);
+ }
+ //return false;
+}
+
+void ScriptNR09::PlayerWalkedOut() {
+ if (Game_Flag_Query(475)) {
+ Music_Stop(2);
+ }
+}
+
+void ScriptNR09::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR09::sub_40172C() {
+ if (Music_Is_Playing()) {
+ Music_Adjust(31, -80, 2);
+ } else {
+ int v0 = Global_Variable_Query(54);
+ if (v0 == 0) {
+ Music_Play(16, 61, -80, 2, -1, 0, 0);
+ } else if (v0 == 1) {
+ Music_Play(15, 41, -80, 2, -1, 0, 0);
+ } else if (v0 == 2) {
+ Music_Play(7, 41, -80, 2, -1, 0, 0);
+ }
+ v0++;
+ if (v0 > 2) {
+ v0 = 0;
+ }
+ Global_Variable_Set(54, v0);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr10.cpp b/engines/bladerunner/script/nr10.cpp
new file mode 100644
index 0000000000..f52d80889d
--- /dev/null
+++ b/engines/bladerunner/script/nr10.cpp
@@ -0,0 +1,164 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR10::InitializeScene() {
+ if (Game_Flag_Query(475)) {
+ Game_Flag_Reset(475);
+ Setup_Scene_Information(-136.78f, 2.84f, -234.43f, 320);
+ } else {
+ Game_Flag_Reset(477);
+ Setup_Scene_Information(19.22f, 2.84f, -250.43f, 540);
+ }
+ Scene_Exit_Add_2D_Exit(0, 144, 163, 194, 318, 3);
+ Scene_Exit_Add_2D_Exit(1, 475, 95, 568, 230, 0);
+ Ambient_Sounds_Add_Looping_Sound(205, 22, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(71, 33, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(640)) {
+ Scene_Loop_Set_Default(0);
+ } else {
+ Ambient_Sounds_Adjust_Looping_Sound(452, 31, 0, 1);
+ Scene_Loop_Set_Default(2);
+ }
+}
+
+void ScriptNR10::SceneLoaded() {
+ Obstacle_Object("HOOK 01", true);
+ Unobstacle_Object("BOX21", true);
+ Unobstacle_Object("BOX23", true);
+ Unclickable_Object("BOX18");
+}
+
+bool ScriptNR10::MouseClick(int x, int y) {
+ return Game_Flag_Query(642);
+}
+
+bool ScriptNR10::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("BOX18", objectName) && a2 && Game_Flag_Query(642)) {
+ Actor_Set_Goal_Number(3, 250);
+ Game_Flag_Set(640);
+ Game_Flag_Reset(642);
+ Actor_Set_Invisible(0, false);
+ Actor_Set_Invisible(3, false);
+ Ambient_Sounds_Remove_Looping_Sound(452, true);
+ Sound_Play(453, 52, 0, 0, 50);
+ Scene_Loop_Set_Default(0);
+ Scene_Loop_Start_Special(2, 0, 1);
+ Un_Combat_Target_Object("BOX18");
+ Scene_Exits_Enable();
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR10::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR10::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR10::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -152.78f, 2.84f, -238.43f, 0, 1, false, 0)) {
+ Game_Flag_Set(476);
+ Set_Enter(58, 62);
+ return true;
+ }
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 11.5f, 2.84f, -304.46f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 55, false);
+ Loop_Actor_Travel_Ladder(0, 8, 1, 0);
+ Game_Flag_Set(641);
+ Set_Enter(60, 64);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptNR10::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR10::SceneFrameAdvanced(int frame) {
+ if (frame == 122) {
+ Game_Flag_Set(642);
+ Actor_Set_Invisible(0, true);
+ Actor_Set_Invisible(3, true);
+ Combat_Target_Object("BOX18");
+ //return true;
+ return;
+ }
+ if (frame == 61 && Game_Flag_Query(642)) {
+ Game_Flag_Reset(642);
+ Player_Set_Combat_Mode(false);
+ Actor_Set_Invisible(0, false);
+ Actor_Set_Goal_Number(3, 247);
+ //return true;
+ return;
+ }
+ //return false;
+}
+
+void ScriptNR10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR10::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(3) == 246) {
+ Player_Set_Combat_Mode(true);
+ //return true;
+ return;
+ }
+ if (Actor_Query_Goal_Number(1) == 236) {
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says(1, 150, 13);
+ Actor_Face_Actor(0, 1, true);
+ Actor_Says(0, 1580, 14);
+ Actor_Says(1, 160, 15);
+ Actor_Says(0, 1585, 16);
+ Actor_Says(1, 1160, 16);
+ Delay(1000);
+ Actor_Says(1, 1290, 14);
+ Actor_Set_Goal_Number(1, 275);
+ }
+ // return false;
+}
+
+void ScriptNR10::PlayerWalkedOut() {
+}
+
+void ScriptNR10::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/nr11.cpp b/engines/bladerunner/script/nr11.cpp
new file mode 100644
index 0000000000..40d7478d2e
--- /dev/null
+++ b/engines/bladerunner/script/nr11.cpp
@@ -0,0 +1,382 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptNR11::InitializeScene() {
+ Setup_Scene_Information(100.0f, 1.75f, -4.0f, 0);
+ Scene_Exit_Add_2D_Exit(0, 450, 305, 565, 345, 2);
+ if (!Game_Flag_Query(640)) {
+ Ambient_Sounds_Adjust_Looping_Sound(452, 22, 0, 1);
+ }
+ Ambient_Sounds_Add_Looping_Sound(205, 22, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(71, 33, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 2, 50, 7, 17, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(632)) {
+ Scene_Loop_Set_Default(3);
+ Ambient_Sounds_Add_Looping_Sound(381, 83, 0, 1);
+ } else if (Game_Flag_Query(634)) {
+ Scene_Loop_Set_Default(5);
+ Ambient_Sounds_Add_Looping_Sound(381, 83, 0, 1);
+ } else {
+ Scene_Loop_Set_Default(0);
+ Overlay_Play("NR11OVER", 0, 1, 0, 0);
+ }
+}
+
+void ScriptNR11::SceneLoaded() {
+ Obstacle_Object("COATRACK", true);
+ Unobstacle_Object("BOX13", true);
+ Clickable_Object("LOFT04");
+ Unclickable_Object("LOFT04");
+ if (Actor_Query_Goal_Number(3) == 250) {
+ Clickable_Object("CLOTHING02");
+ Clickable_Object("BOX27");
+ Clickable_Object("BOX39");
+ Clickable_Object("BOX44");
+ Clickable_Object("DRESS");
+ Clickable_Object("COATRACK");
+ Clickable_Object("COLUMN3 DETS");
+ Clickable_Object("COLUMN PIPE01");
+ Clickable_Object("RECTANGLE02");
+ Clickable_Object("COLUMN04");
+ Clickable_Object("COATRACK01");
+ Clickable_Object("SHIRT");
+ Clickable_Object("SKIRT 02");
+ Clickable_Object("CLOTHING B 03");
+ Clickable_Object("BUST BUST");
+ Combat_Target_Object("CLOTHING02");
+ Combat_Target_Object("BOX27");
+ Combat_Target_Object("BOX39");
+ Combat_Target_Object("BOX44");
+ Combat_Target_Object("DRESS");
+ Combat_Target_Object("COATRACK");
+ Combat_Target_Object("COLUMN3 DETS");
+ Combat_Target_Object("COLUMN PIPE01");
+ Combat_Target_Object("RECTANGLE02");
+ Combat_Target_Object("COLUMN04");
+ Combat_Target_Object("COATRACK01");
+ Combat_Target_Object("SHIRT");
+ Combat_Target_Object("SKIRT 02");
+ Combat_Target_Object("CLOTHING B 03");
+ Combat_Target_Object("BUST BUST");
+ } else {
+ Unclickable_Object("CLOTHING02");
+ Unclickable_Object("BOX27");
+ Unclickable_Object("BOX39");
+ Unclickable_Object("BOX44");
+ Unclickable_Object("DRESS");
+ Unclickable_Object("COATRACK");
+ Unclickable_Object("COLUMN3 DETS");
+ Unclickable_Object("COLUMN PIPE01");
+ Unclickable_Object("RECTANGLE02");
+ Unclickable_Object("COLUMN04");
+ Unclickable_Object("COATRACK01");
+ Unclickable_Object("SHIRT");
+ Unclickable_Object("SKIRT 02");
+ Unclickable_Object("CLOTHING B 03");
+ Unclickable_Object("BUST BUST");
+ }
+}
+
+bool ScriptNR11::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptNR11::ClickedOn3DObject(const char *objectName, bool a2) {
+
+ if (Object_Query_Click("CLOTHING02", objectName) || Object_Query_Click("BOX27", objectName) || Object_Query_Click("BOX39", objectName) || Object_Query_Click("BOX44", objectName) || Object_Query_Click("DRESS", objectName) || Object_Query_Click("COATRACK", objectName) || Object_Query_Click("COLUMN3 DETS", objectName) || Object_Query_Click("COLUMN PIPE01", objectName) || Object_Query_Click("RECTANGLE02", objectName) || Object_Query_Click("COLUMN04", objectName) || Object_Query_Click("COATRACK01", objectName) || Object_Query_Click("SHIRT", objectName) || Object_Query_Click("SKIRT 02", objectName) || Object_Query_Click("CLOTHING B 03", objectName) || Object_Query_Click("BUST BUST", objectName)) {
+ if (a2) {
+ Actor_Set_Goal_Number(1, 211);
+ Scene_Exits_Disable();
+ sub_4028EC();
+ Player_Loses_Control();
+ if (!Player_Query_Combat_Mode()) {
+ Player_Set_Combat_Mode(true);
+ }
+ Actor_Set_Goal_Number(0, 230);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ } else if (Actor_Query_Goal_Number(3) == 250) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 24.0f, 0.33f, 0.0f, 0, 1, false, 0)) {
+ Actor_Face_XYZ(0, -180.0f, 0.0f, -170.0f, true);
+ sub_4028EC();
+ Actor_Set_Goal_Number(1, 211);
+ if (Actor_Query_Friendliness_To_Other(3, 0) < 30) {
+ Actor_Set_At_XYZ(3, 0.5f, 0.33f, -162.0f, 0);
+ Loop_Actor_Walk_To_XYZ(3, -24.0f, 0.33f, -35.4f, 0, 0, true, 0);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Change_Animation_Mode(3, 71);
+ Delay(500);
+ Actor_Change_Animation_Mode(0, 48);
+ Delay(2000);
+ Actor_Set_Goal_Number(0, 231);
+ } else {
+ Actor_Says(0, 3840, 18);
+ Delay(1000);
+ if (Actor_Query_Friendliness_To_Other(3, 0) > 59 && !Global_Variable_Query(45)) {
+ Music_Play(21, 35, 0, 3, -1, 0, 0);
+ }
+ Loop_Actor_Walk_To_XYZ(3, -135.0f, 0.33000001f, -267.0f, 0, 0, false, 0);
+ Actor_Face_Actor(3, 0, true);
+ Actor_Face_Actor(0, 3, true);
+ Actor_Clue_Acquire(0, 107, 1, 3);
+ Actor_Says(3, 990, 13);
+ Actor_Says(3, 1000, 14);
+ Loop_Actor_Walk_To_Actor(3, 0, 108, 0, false);
+ Actor_Says(0, 3845, 13);
+ Actor_Says(0, 3850, 15);
+ Actor_Says(3, 1010, 14);
+ Actor_Says(0, 3855, 13);
+ Actor_Says(3, 1020, 12);
+ Actor_Says(0, 3860, 12);
+ Actor_Says_With_Pause(3, 1030, 1.0f, 14);
+ Actor_Says(3, 1040, 13);
+ Actor_Says(0, 3865, 15);
+ Actor_Says_With_Pause(3, 1050, 0.80000001f, 14);
+ Actor_Says(3, 1060, 13);
+ Actor_Says(0, 3870, 3);
+ Actor_Says(3, 1070, 14);
+ Actor_Modify_Friendliness_To_Other(3, 0, 5);
+ if (Actor_Query_Friendliness_To_Other(3, 0) > 55 && !Global_Variable_Query(45)) {
+ Global_Variable_Set(45, 2);
+ Actor_Says(3, 1130, 17);
+ Actor_Says(0, 6365, 12);
+ Actor_Says(3, 1140, 14);
+ Actor_Says(0, 6370, 14);
+ Actor_Says(3, 1150, 12);
+ Actor_Says(3, 1160, 16);
+ }
+ Actor_Says(3, 1080, 13);
+ Actor_Says(0, 3875, 14);
+ Actor_Says(3, 1090, 17);
+ Music_Stop(4);
+ Actor_Set_Goal_Number(3, 260);
+ if (Global_Variable_Query(40) == 1) {
+ Actor_Set_Goal_Number(1, 236);
+ }
+ Game_Flag_Set(591);
+ }
+ } else {
+ if (Random_Query(1, 2) == 1) {
+ Actor_Says(0, 8575, 14);
+ } else {
+ Actor_Says(0, 8580, 14);
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptNR11::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptNR11::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptNR11::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 100.0f, 1.75f, -8.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(477);
+ Set_Enter(59, 63);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptNR11::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptNR11::SceneFrameAdvanced(int frame) {
+ if (frame == 62) {
+ Ambient_Sounds_Play_Sound(449, 40, 100, 100, 10);
+ }
+ if (frame == 67) {
+ Ambient_Sounds_Play_Sound(449, 30, 90, 90, 10);
+ }
+ if (frame == 74) {
+ Ambient_Sounds_Play_Sound(450, 50, 83, 83, 10);
+ }
+ if (frame == 80) {
+ Ambient_Sounds_Play_Sound(449, 60, 65, 65, 10);
+ }
+ if (frame == 92) {
+ Ambient_Sounds_Play_Sound(450, 30, 50, 50, 10);
+ }
+ if (frame == 97) {
+ Ambient_Sounds_Play_Sound(449, 50, -40, -40, 10);
+ }
+ if (frame == 103) {
+ Ambient_Sounds_Play_Sound(450, 40, -27, -27, 10);
+ }
+ if (frame == 109) {
+ Ambient_Sounds_Play_Sound(449, 60, -20, -20, 10);
+ }
+ if (frame == 62) {
+ Ambient_Sounds_Play_Sound(122, 80, 100, 100, 15);
+ }
+ if (Game_Flag_Query(659)) {
+ Game_Flag_Reset(659);
+ Overlay_Remove("NR11OVER");
+ Overlay_Play("NR11OVER", 1, 0, 1, 0);
+ }
+ if (Game_Flag_Query(635)) {
+ sub_4028EC();
+ Player_Loses_Control();
+ if (!Player_Query_Combat_Mode()) {
+ Player_Set_Combat_Mode(true);
+ }
+ Actor_Set_Goal_Number(0, 230);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ Game_Flag_Reset(635);
+ } else {
+ if (frame < 61 || frame > 120) {
+ //return false;
+ return;
+ }
+ sub_4027D0(0, frame);
+ if (Actor_Query_Goal_Number(1) == 215) {
+ sub_4027D0(1, frame);
+ }
+ if (frame == 120) {
+ Actor_Set_Goal_Number(0, 0);
+ Player_Gains_Control();
+ if (Actor_Query_Goal_Number(1) == 215) {
+ Actor_Set_Goal_Number(1, 216);
+ }
+ Actor_Set_Goal_Number(3, 269);
+ }
+ }
+ //return true;
+}
+
+void ScriptNR11::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptNR11::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(3) == 250) {
+ Player_Set_Combat_Mode(true);
+ if (Game_Flag_Query(47)) {
+ Actor_Set_Goal_Number(1, 210);
+ }
+ }
+ if (Game_Flag_Query(632)) {
+ Game_Flag_Reset(632);
+ Game_Flag_Set(634);
+ Actor_Put_In_Set(3, 99);
+ Actor_Set_At_Waypoint(3, 41, 0);
+ Actor_Set_Invisible(0, false);
+ Player_Set_Combat_Mode(false);
+ Player_Gains_Control();
+ if (Game_Flag_Query(47)) {
+ if (Actor_Query_Goal_Number(1) == 211) {
+ Actor_Set_At_XYZ(0, -37.41f, 0.33f, -86.0f, 26);
+ Delay(500);
+ Actor_Face_Current_Camera(0, true);
+ Delay(750);
+ Actor_Says(0, 5290, 12);
+ Delay(1000);
+ Actor_Set_Goal_Number(1, 212);
+ Actor_Face_Actor(0, 1, true);
+ } else {
+ Actor_Set_At_XYZ(0, -15.53f, 0.33f, 73.49f, 954);
+ Actor_Modify_Friendliness_To_Other(1, 0, 3);
+ Delay(1500);
+ Actor_Says(0, 3805, 12);
+ Actor_Face_Actor(0, 1, true);
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says_With_Pause(1, 1720, 0.3f, 16);
+ Actor_Says(0, 3810, 16);
+ Actor_Says_With_Pause(1, 1730, 0.2f, 14);
+ Actor_Says(1, 1740, 15);
+ Actor_Set_Goal_Number(3, 599);
+ Actor_Put_In_Set(3, 99);
+ Actor_Set_At_Waypoint(3, 41, 0);
+ Actor_Set_Goal_Number(1, 275);
+ }
+ } else {
+ Actor_Set_Goal_Number(0, 500);
+ }
+ }
+ // return true;
+}
+
+void ScriptNR11::PlayerWalkedOut() {
+
+}
+
+void ScriptNR11::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptNR11::sub_4027D0(int actorId, signed int frame) {
+ float x;
+ float y;
+ float z;
+ float coef;
+
+ if (frame < 80) {
+ coef = (frame - 60) / 20.0f;
+ x = -106.66f * coef + 126.0f;
+ y = 57.79f * coef + 0.85f;
+ z = 42.0f * coef + -151.0f;
+ } else {
+ coef = (frame - 80) / 40.0f;
+ x = -97.87f * coef + -150.0f;
+ y = -10.8f * coef + 52.0f;
+ z = 57.0f * coef + -232.0f;
+ }
+ Actor_Face_XYZ(actorId, x, y, z, true);
+}
+
+void ScriptNR11::sub_4028EC() {
+ Un_Combat_Target_Object("CLOTHING02");
+ Un_Combat_Target_Object("BOX27");
+ Un_Combat_Target_Object("BOX39");
+ Un_Combat_Target_Object("BOX44");
+ Un_Combat_Target_Object("DRESS");
+ Un_Combat_Target_Object("COATRACK");
+ Un_Combat_Target_Object("COLUMN3 DETS");
+ Un_Combat_Target_Object("COLUMN PIPE01");
+ Un_Combat_Target_Object("RECTANGLE02");
+ Un_Combat_Target_Object("COLUMN04");
+ Un_Combat_Target_Object("COATRACK01");
+ Un_Combat_Target_Object("SHIRT");
+ Un_Combat_Target_Object("SKIRT 02");
+ Un_Combat_Target_Object("CLOTHING B 03");
+ Un_Combat_Target_Object("BUST BUST");
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps01.cpp b/engines/bladerunner/script/ps01.cpp
new file mode 100644
index 0000000000..1af1b93ed7
--- /dev/null
+++ b/engines/bladerunner/script/ps01.cpp
@@ -0,0 +1,277 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS01::InitializeScene() {
+ Setup_Scene_Information(1872.0f, 16592.0f, -2975.0f, 200);
+ Scene_Exit_Add_2D_Exit(0, 36, 194, 138, 326, 0);
+ if (Game_Flag_Query(251)) {
+ Scene_Exit_Add_2D_Exit(1, 344, 288, 584, 384, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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 (Game_Flag_Query(130)) {
+ if (Game_Flag_Query(251)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(5);
+ }
+ } else {
+ Actor_Set_Invisible(0, true);
+ Game_Flag_Set(273);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Player_Loses_Control();
+ }
+}
+
+void ScriptPS01::SceneLoaded() {
+ Obstacle_Object("TUBE81", true);
+ if (Game_Flag_Query(251)) {
+ Unobstacle_Object("Barrier Obstacle", true);
+ }
+ Unobstacle_Object("BOX38", true);
+ Unobstacle_Object("TUBE81", true);
+}
+
+bool ScriptPS01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS01::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1920.0f, 16581.0f, -2653.0f, 12, 1, false, 0)) {
+ Game_Flag_Set(718);
+ Set_Enter(62, 66);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1877.9f, 16592.0f, -2975.0f, 0, 1, false, 0)) {
+ Actor_Set_At_XYZ(0, 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);
+ switch (spinnerDest) {
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(251);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ Scene_Loop_Start_Special(1, 4, 1);
+ break;
+ default:
+ Actor_Face_Heading(0, 870, false);
+ Game_Flag_Set(178);
+ Game_Flag_Set(273);
+ Player_Loses_Control();
+ Scene_Loop_Start_Special(2, 3, 1);
+ break;
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS01::SceneFrameAdvanced(int frame) {
+ if (frame == 71 || frame == 188) {
+ Sound_Play(116, 100, 40, 0, 50);
+ }
+ if (frame == 108 || frame == 228) {
+ Sound_Play(119, 100, 40, 0, 50);
+ }
+ if (frame == 1) {
+ Sound_Play(118, 40, 0, 0, 50);
+ }
+ if (frame == 76) {
+ Sound_Play(121, 50, 0, 0, 50);
+ }
+ if (frame == 192) {
+ Sound_Play(120, 50, 0, 0, 50);
+ }
+ if (frame == 59) {
+ Sound_Play(122, 15, 0, 0, 50);
+ }
+ if (frame == 275) {
+ Sound_Play(117, 40, 0, 0, 50);
+ }
+ if (!Game_Flag_Query(273)) {
+ switch (frame) {
+ case 196:
+ Actor_Face_Heading(0, 870, false);
+ Actor_Set_Frame_Rate_FPS(0, -1);
+ Actor_Change_Animation_Mode(0, 41);
+ break;
+ case 220:
+ Actor_Set_Frame_Rate_FPS(0, 0);
+ break;
+ case 240:
+ Actor_Set_Frame_Rate_FPS(0, -2);
+ break;
+ }
+ //return true;
+ return;
+ }
+ if (frame == 75) {
+ Actor_Face_Heading(0, 870, false);
+ Actor_Change_Animation_Mode(0, 42);
+ //return true;
+ return;
+ }
+ if (frame == 119) {
+ Game_Flag_Reset(273);
+ Player_Gains_Control();
+ //return true;
+ return;
+ }
+ if (frame > 195) {
+ if (frame == 239) {
+ Game_Flag_Reset(273);
+ Player_Gains_Control();
+ }
+ //return true;
+ return;
+ }
+ if (frame == 181) {
+ Actor_Face_Heading(0, 870, false);
+ Actor_Change_Animation_Mode(0, 42);
+ } else if (frame == 182) {
+ Actor_Set_Frame_Rate_FPS(0, 0);
+ } else if (frame == 195) {
+ Actor_Set_Frame_Rate_FPS(0, -2);
+ }
+ //return true;
+ return;
+}
+
+void ScriptPS01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS01::PlayerWalkedIn() {
+ if (Game_Flag_Query(130)) {
+ Actor_Set_At_XYZ(0, 1920.0f, 16581.0f, -2653.0f, 150);
+ Game_Flag_Reset(130);
+ }
+ //return false;
+}
+
+void ScriptPS01::PlayerWalkedOut() {
+ Actor_Set_Invisible(0, false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(718) && Global_Variable_Query(1) == 1) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(38, 1, -1);
+ }
+}
+
+void ScriptPS01::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps02.cpp b/engines/bladerunner/script/ps02.cpp
new file mode 100644
index 0000000000..3ca56e1550
--- /dev/null
+++ b/engines/bladerunner/script/ps02.cpp
@@ -0,0 +1,177 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS02::InitializeScene() {
+ Player_Loses_Control();
+ Setup_Scene_Information(-13.31f, -40.28f, -48.12f, 30);
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 240, 479, 3);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(386, 20, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(210, 20, 1, 1);
+ Ambient_Sounds_Add_Sound(0, 3, 20, 12, 16, 0, 0, -101, -101, 0, 0);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptPS02::SceneLoaded() {
+ Obstacle_Object("E.DOOR01", true);
+ Obstacle_Object("E.DOOR02", true);
+ Clickable_Object("E.DOOR01");
+ Clickable_Object("E.DOOR02");
+}
+
+bool ScriptPS02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS02::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("E.DOOR01", objectName) || Object_Query_Click("E.D00R02", objectName)) {
+ if (Game_Flag_Query(130) ) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -5.0f, -40.0f, -15.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ } else if (Game_Flag_Query(22) ) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -5.0f, -40.0f, -15.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(15, 69);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ } else if (Game_Flag_Query(131) ) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -5.0f, -40.0f, -15.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(66, 71);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ } else if (Game_Flag_Query(132) ) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -5.0f, -40.0f, -15.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(63, 67);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ } else if (Game_Flag_Query(133) && !Loop_Actor_Walk_To_XYZ(0, -5.0f, -40.0f, -15.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(67, 72);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ }
+ return false;
+}
+
+bool ScriptPS02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS02::ClickedOnExit(int exitId) {
+ return false;
+}
+
+bool ScriptPS02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS02::SceneFrameAdvanced(int frame) {
+ if (frame == 1) {
+ Ambient_Sounds_Play_Sound(208, 45, 0, 0, 0);
+ }
+ if (frame == 91) {
+ Ambient_Sounds_Play_Sound(209, 45, 0, 0, 0);
+ }
+ //return true;
+}
+
+void ScriptPS02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS02::PlayerWalkedIn() {
+ Game_Flag_Reset(718);
+ Actor_Face_XYZ(0, 0, 0, 450.0f, true);
+ Player_Gains_Control();
+ sub_4018BC();
+ Player_Loses_Control();
+ if (Game_Flag_Query(130) ) {
+ Set_Enter(61, 65);
+ Scene_Loop_Start_Special(1, 3, 1);
+ } else if (Game_Flag_Query(22) ) {
+ Set_Enter(15, 69);
+ Scene_Loop_Start_Special(1, 3, 1);
+ } else if (Game_Flag_Query(131) ) {
+ Set_Enter(66, 71);
+ Scene_Loop_Start_Special(1, 3, 1);
+ } else if (Game_Flag_Query(132) ) {
+ Set_Enter(63, 67);
+ Scene_Loop_Start_Special(1, 3, 1);
+ } else if (Game_Flag_Query(133) ) {
+ Set_Enter(67, 72);
+ Scene_Loop_Start_Special(1, 3, 1);
+ }
+ //return true;
+}
+
+void ScriptPS02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Player_Gains_Control();
+}
+
+void ScriptPS02::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS02::sub_4018BC() {
+ Scene_Exits_Disable();
+ switch (Elevator_Activate(2)) {
+ case 7:
+ Game_Flag_Set(133);
+ break;
+ case 6:
+ Game_Flag_Set(132);
+ break;
+ case 5:
+ Game_Flag_Set(22);
+ break;
+ case 4:
+ Game_Flag_Set(130);
+ break;
+ case 3:
+ Game_Flag_Set(131);
+ break;
+ default:
+ break;
+ }
+ Scene_Exits_Enable();
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps03.cpp b/engines/bladerunner/script/ps03.cpp
new file mode 100644
index 0000000000..e3835d04db
--- /dev/null
+++ b/engines/bladerunner/script/ps03.cpp
@@ -0,0 +1,134 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS03::InitializeScene() {
+ if (Game_Flag_Query(39)) {
+ Actor_Set_At_XYZ(0, -674.0f, -354.0f, 550.0f, 900);
+ Setup_Scene_Information(-674.0f, -354.62f, 550.0f, 900);
+ Game_Flag_Reset(39);
+ } else if (Game_Flag_Query(135)) {
+ Setup_Scene_Information(-875.0f, -354.62f, -1241.0f, 450);
+ Game_Flag_Reset(135);
+ } else {
+ Setup_Scene_Information(-569.54f, -354.62f, -1076.15f, 475);
+ Game_Flag_Reset(132);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 449, 273, 508, 329, 0);
+ if (Global_Variable_Query(1) > 1) {
+ Scene_Exit_Add_2D_Exit(2, 358, 245, 411, 288, 0);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(45, 35, 0, 1);
+ Ambient_Sounds_Add_Sound(90, 5, 50, 7, 7, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(91, 5, 50, 7, 7, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(92, 5, 60, 33, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(93, 5, 60, 33, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(94, 5, 60, 33, 33, -100, 100, -101, -101, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptPS03::SceneLoaded() {
+ Obstacle_Object("TABLE05", true);
+ Unclickable_Object("COP1PS03");
+ Unclickable_Object("COP2PS03");
+}
+
+bool ScriptPS03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -674.0f, -354.0f, 550.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(42);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(64, 68);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -569.54f, -354.62f, -1076.15f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(62, 66);
+ Game_Flag_Reset(478);
+ if (Global_Variable_Query(1) < 4) {
+ Actor_Set_Goal_Number(4, 100);
+ }
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -875.0f, -354.0f, -1241.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(134);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(68, 77);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS03::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS03::PlayerWalkedIn() {
+ if (!Game_Flag_Query(478)) {
+ Game_Flag_Set(478);
+ //return true;
+ }
+ //return false;
+}
+
+void ScriptPS03::PlayerWalkedOut() {
+}
+
+void ScriptPS03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps04.cpp b/engines/bladerunner/script/ps04.cpp
new file mode 100644
index 0000000000..8ed76dc614
--- /dev/null
+++ b/engines/bladerunner/script/ps04.cpp
@@ -0,0 +1,304 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS04::InitializeScene() {
+ AI_Movement_Track_Pause(4);
+ if (Game_Flag_Query(42)) {
+ Game_Flag_Reset(42);
+ }
+ Setup_Scene_Information(-668.0f, -354.0f, 974.0f, 475);
+ if (Global_Variable_Query(1) == 1) {
+ Actor_Put_In_Set(4, 64);
+ Actor_Set_At_XYZ(4, -728.0f, -354.0f, 1090.0f, 150);
+ Actor_Change_Animation_Mode(4, 53);
+ }
+ Scene_Exit_Add_2D_Exit(0, 347, 113, 469, 302, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(45, 16, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(46, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(47, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(48, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(49, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(50, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(51, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(52, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(53, 9, 40, 20, 20, 0, 0, -101, -101, 0, 0);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptPS04::SceneLoaded() {
+ Obstacle_Object("CHAIR07", true);
+ Unobstacle_Object("GOOD B.WALL", true);
+ Unobstacle_Object("B.DOOR", true);
+ Unobstacle_Object("B.CHAIR01", true);
+ Unclickable_Object("CHAIR07");
+ if (Global_Variable_Query(1) == 2 && !Actor_Clue_Query(0, 80) && !Game_Flag_Query(727)) {
+ Item_Add_To_World(111, 958, 64, -643.5f, -318.82f, 1148.87f, 525, 16, 12, false, true, false, true);
+ Game_Flag_Set(727);
+ }
+ if (Actor_Query_Is_In_Current_Set(4)) {
+ Actor_Change_Animation_Mode(4, 53);
+ }
+}
+
+bool ScriptPS04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS04::ClickedOnActor(int actorId) {
+ if (actorId == 4) {
+ if (!Loop_Actor_Walk_To_Actor(0, 4, 36, 1, false)) {
+ Actor_Face_Actor(0, 4, true);
+ Actor_Face_Actor(4, 0, true);
+ sub_4017E4();
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptPS04::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 111 && Actor_Query_Is_In_Current_Set(4)) {
+ Actor_Says(4, 560, 30);
+ } else if (!Actor_Clue_Query(0, 80)) {
+ Item_Remove_From_World(111);
+ Item_Pickup_Spin_Effect(958, 464, 362);
+ Actor_Says(0, 4485, 3);
+ Actor_Clue_Acquire(0, 80, 1, 0);
+ }
+ return false;
+}
+
+bool ScriptPS04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -668.0f, -350.85f, 962.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(39);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(63, 67);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS04::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS04::PlayerWalkedIn() {
+ if (Actor_Query_Which_Set_In(4) == 64) {
+ Actor_Face_Actor(0, 4, true);
+ }
+ //return false;
+}
+
+void ScriptPS04::PlayerWalkedOut() {
+ AI_Movement_Track_Unpause(4);
+}
+
+void ScriptPS04::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS04::sub_4017E4() {
+ Dialogue_Menu_Clear_List();
+ if (Global_Variable_Query(1) > 1) {
+ if (Actor_Clue_Query(0, 51)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(110, 5, 7, 4);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(120, 1, -1, -1);
+ if (Actor_Clue_Query(0, 110)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(150, 7, 6, 5);
+ }
+ }
+ if (Game_Flag_Query(169) == 1) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(140, 3, -1, -1);
+ }
+ DM_Add_To_List(130, 1, 1, 1);
+ Dialogue_Menu_Add_DONE_To_List(160);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 130:
+ if (Game_Flag_Query(40) && !Game_Flag_Query(159)) {
+ Actor_Says(0, 3920, 13);
+ Actor_Says(4, 140, 30);
+ Actor_Face_Current_Camera(4, true);
+ Actor_Says(4, 150, 31);
+ Actor_Says(4, 160, 32);
+ Actor_Says(0, 3925, 18);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Says(4, 170, 33);
+ Loop_Actor_Walk_To_XYZ(0, -716.0f, -354.85f, 1042.0f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 3930, 13);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Says(4, 180, 34);
+ Actor_Says(0, 3935, 13);
+ Actor_Says(4, 190, 30);
+ Actor_Says(0, 3940, 16);
+ Actor_Says(4, 200, 31);
+ Actor_Says(4, 210, 33);
+ Actor_Says(4, 220, 34);
+ Actor_Says(0, 3945, 17);
+ Actor_Says(4, 230, 32);
+ Actor_Says(4, 240, 31);
+ Actor_Says(0, 3950, 13);
+ Actor_Says(4, 250, 34);
+ Actor_Says(4, 260, 33);
+ Actor_Says(4, 270, 32);
+ Game_Flag_Set(159);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Increment(2, 200);
+ }
+ Game_Flag_Set(723);
+ } else if (Game_Flag_Query(41) && !Game_Flag_Query(160)) {
+ Actor_Says(0, 3955, 13);
+ Actor_Says(4, 280, 30);
+ Actor_Says(0, 3960, 18);
+ Actor_Says(4, 290, 32);
+ Actor_Says(4, 300, 31);
+ Actor_Says(0, 3965, 13);
+ Actor_Says(4, 310, 33);
+ Actor_Says(4, 320, 34);
+ Game_Flag_Set(160);
+ } else if ((Actor_Clue_Query(0, 8) || Actor_Clue_Query(0, 9)) && Actor_Clue_Query(0, 22) && Actor_Query_Friendliness_To_Other(4, 0) < 50 && !Game_Flag_Query(161)) {
+ Actor_Says(0, 3970, 18);
+ Actor_Says(4, 330, 30);
+ Actor_Says(4, 340, 32);
+ Actor_Says(0, 3975, 13);
+ Actor_Says(4, 350, 31);
+ Actor_Says(4, 360, 34);
+ Actor_Says(0, 3980, 13);
+ Actor_Says(4, 370, 33);
+ Actor_Says(4, 380, 32);
+ Actor_Says(4, 390, 31);
+ Actor_Says(0, 3985, 18);
+ Actor_Says(4, 400, 34);
+ Actor_Says(4, 410, 31);
+ Game_Flag_Set(161);
+ } else if ((Actor_Clue_Query(0, 8) || Actor_Clue_Query(0, 9))
+ && Actor_Clue_Query(0, 22)
+ && !Game_Flag_Query(162)) {
+ Actor_Says(0, 3920, 13);
+ Actor_Says(4, 570, 32);
+ Actor_Says(0, 4070, 13);
+ Game_Flag_Set(162);
+ } else if (Actor_Query_Friendliness_To_Other(4, 0) >= 50) {
+ Actor_Says(0, 4020, 13);
+ Actor_Says(4, 580, 34);
+ Actor_Says(0, 4075, 16);
+ Actor_Says(4, 590, 33);
+ } else {
+ Actor_Says(0, 4020, 18);
+ Actor_Says(4, 130, 30);
+ Actor_Face_Current_Camera(4, true);
+ Actor_Says(0, 3915, 13);
+ }
+ break;
+ case 110:
+ Actor_Says(0, 3990, 19);
+ Actor_Says(0, 3995, 17);
+ Actor_Says(4, 440, 31);
+ Actor_Says(0, 4035, 13);
+ Actor_Says(4, 450, 34);
+ Actor_Says(4, 460, 33);
+ Actor_Says(0, 4040, 17);
+ Game_Flag_Set(625);
+ break;
+ case 120:
+ Actor_Says(0, 4000, 18);
+ Actor_Clue_Acquire(0, 82, 1, 4);
+ Actor_Says(4, 520, 33);
+ Actor_Says(0, 4055, 13);
+ Actor_Says(4, 530, 31);
+ Actor_Says(0, 4060, 13);
+ Actor_Says(4, 540, 31);
+ Actor_Says(4, 550, 32);
+ Actor_Says(0, 4065, 18);
+ Actor_Says(4, 560, 34);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Increment(2, 100);
+ }
+ break;
+ case 140:
+ Actor_Says(0, 4010, 12);
+ Actor_Says(4, 600, 31);
+ Actor_Says(0, 4080, 18);
+ Actor_Says(4, 610, 33);
+ Actor_Face_Heading(4, 400, false);
+ Actor_Says(4, 620, 32);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Says(4, 700, 34);
+ Actor_Says(0, 4100, 13);
+ Actor_Says(4, 710, 31);
+ Actor_Says(4, 720, 34);
+ Actor_Says(0, 4105, 18);
+ Loop_Actor_Walk_To_XYZ(0, -668.0f, -350.85f, 962.0f, 0, 0, false, 0);
+ Actor_Says(4, 730, 32);
+ Actor_Face_Actor(0, 4, true);
+ Loop_Actor_Walk_To_XYZ(0, -716.0f, -354.85f, 1042.0f, 0, 0, false, 0);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Says(4, 740, 31);
+ Actor_Says(4, 750, 32);
+ Actor_Says(4, 760, 33);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 4110, 13);
+ Actor_Says(4, 770, 32);
+ Actor_Says(4, 780, 31);
+ break;
+ case 150:
+ Actor_Says(0, 4015, 16);
+ Actor_Says(4, 630, 34);
+ Actor_Says(0, 4085, 19);
+ Actor_Says(0, 4090, 18);
+ Actor_Says(4, 640, 31);
+ Actor_Says(4, 650, 32);
+ Actor_Says(4, 670, 34);
+ Actor_Says(0, 4095, 17);
+ Actor_Says(4, 680, 32);
+ Actor_Says(4, 690, 31);
+ break;
+ default:
+ //TODO: what is this for?
+ //answer != 160;
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps05.cpp b/engines/bladerunner/script/ps05.cpp
new file mode 100644
index 0000000000..0636daf163
--- /dev/null
+++ b/engines/bladerunner/script/ps05.cpp
@@ -0,0 +1,273 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS05::InitializeScene() {
+ if (Game_Flag_Query(21)) {
+ Setup_Scene_Information(547.59f, 0.18f, -216.84f, 334);
+ } else if (Game_Flag_Query(22)) {
+ Setup_Scene_Information(635.0f, 0.0f, -598.0f, 475);
+ } else {
+ Setup_Scene_Information(630.72f, 0.38f, -469.26f, 400);
+ }
+ Scene_Exit_Add_2D_Exit(0, 218, 98, 280, 246, 3);
+ Scene_Exit_Add_2D_Exit(1, 330, 90, 436, 198, 0);
+ Scene_Exit_Add_2D_Exit(2, 476, 96, 524, 240, 1);
+ Scene_2D_Region_Add(0, 519, 107, 537, 122);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(384, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(141, 80, 0, 1);
+ Ambient_Sounds_Add_Sound(385, 5, 50, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(156, 5, 20, 30, 30, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(157, 5, 20, 30, 30, -70, 70, -101, -101, 0, 0);
+ 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);
+}
+
+void ScriptPS05::SceneLoaded() {
+ Obstacle_Object("WATER FOUNTAIN", true);
+ Clickable_Object("WATER FOUNTAIN");
+ Clickable_Object("ASHTRAY");
+ Clickable_Object("FIRE EXTINGISHER");
+ Clickable_Object("CUP");
+ Clickable_Object("WIRE BASKET");
+ Clickable_Object("WANTED POSTERS");
+ Unclickable_Object("WATER FOUNTAIN");
+ Unclickable_Object("CUP");
+}
+
+bool ScriptPS05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS05::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("WATER FOUNTAIN", objectName) && !Loop_Actor_Walk_To_Scene_Object(0, "WATER FOUNTAIN", 12, 1, false)) {
+ Actor_Face_Object(0, "WATER FOUNTAIN", true);
+ Actor_Says(0, 3490, 18);
+ }
+ if (Object_Query_Click("ASHTRAY", objectName) && !Loop_Actor_Walk_To_XYZ(0, 662.0f, 0.37f, -180.0f, 0, 1, false, 0)) {
+ Actor_Face_Object(0, "ASHTRAY", true);
+ Actor_Voice_Over(1770, 99);
+ Actor_Voice_Over(1780, 99);
+ Actor_Voice_Over(1790, 99);
+ }
+ if (Object_Query_Click("WIRE BASKET", objectName) && !Loop_Actor_Walk_To_Scene_Object(0, "WIRE BASKET", 12, 1, false)) {
+ Actor_Face_Object(0, "WIRE BASKET", true);
+ Actor_Voice_Over(1810, 99);
+ Actor_Voice_Over(1820, 99);
+ }
+ if (Object_Query_Click("WANTED POSTERS", objectName) && !Loop_Actor_Walk_To_Scene_Object(0, "WANTED POSTERS", 12, 1, false)) {
+ Actor_Face_Object(0, "WANTED POSTERS", true);
+ Actor_Voice_Over(1800, 99);
+ }
+ return false;
+}
+
+bool ScriptPS05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS05::ClickedOnItem(int itemId, bool a2) {
+ if (Game_Flag_Query(23)) {
+ Actor_Set_At_XYZ(0, 718.72f, 0.37f, -461.26f, 600);
+ } else if (Game_Flag_Query(22)) {
+ sub_401B34();
+ sub_401C30();
+ }
+ Game_Flag_Reset(22);
+ Game_Flag_Reset(23);
+ Game_Flag_Reset(21);
+ Game_Flag_Reset(204);
+ return false;
+}
+
+bool ScriptPS05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 2, 24, 1, false)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(101, 119);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 635.0f, 0.0f, -598.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(62, 66);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 742.52002f, 0.37f, -457.69f, 0, 1, false, 0)) {
+ Game_Flag_Set(136);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(65, 70);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS05::ClickedOn2DRegion(int region) {
+ if (region == 0 && !Loop_Actor_Walk_To_XYZ(0, 694.78f, 0.37f, -321.05f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 130, false);
+ View_Score_Board();
+ }
+ return false;
+}
+
+void ScriptPS05::SceneFrameAdvanced(int frame) {
+ if (frame == 1 || frame == 16 || frame == 31 || frame == 46) {
+ Sound_Play(149, Random_Query(10, 10), 70, 70, 50);
+ }
+ //return true;
+}
+
+void ScriptPS05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS05::PlayerWalkedIn() {
+}
+
+void ScriptPS05::PlayerWalkedOut() {
+}
+
+void ScriptPS05::DialogueQueueFlushed(int a1) {
+ Overlay_Remove("PS05OVER");
+}
+
+void ScriptPS05::sub_401B34() {
+ int v0;
+ int v1;
+ int v3[7];
+
+ v0 = 0;
+ if (Global_Variable_Query(1) < 4 && Game_Flag_Query(45)) {
+ v0 = 1;
+ v3[0] = 0;
+ }
+ v1 = v0 + 1;
+ v3[v0] = 1;
+ if (Global_Variable_Query(1) >= 3) {
+ v3[v1] = 2;
+ v1 = v0 + 2;
+ }
+ if (Global_Variable_Query(1) >= 2 && Global_Variable_Query(1) <= 4) {
+ v3[v1++] = 3;
+ }
+ if (Game_Flag_Query(171) && Game_Flag_Query(170)) {
+ v3[v1++] = 4;
+ }
+ if (v1 <= 0) {
+ Global_Variable_Set(52, -1);
+ } else {
+ Global_Variable_Set(52, v3[Random_Query(0, v1 - 1)]);
+ }
+}
+
+void ScriptPS05::sub_401C30() {
+ switch (Global_Variable_Query(52)) {
+ case 4:
+ if (!Game_Flag_Query(692)) {
+ Overlay_Play("PS05OVER", 0, 1, 0, 0);
+ ADQ_Add(61, 230, 3);
+ ADQ_Add(61, 240, 3);
+ Game_Flag_Set(692);
+ }
+ break;
+ case 3:
+ if (!Game_Flag_Query(691)) {
+ Overlay_Play("PS05OVER", 0, 1, 0, 0);
+ ADQ_Add(61, 170, 3);
+ ADQ_Add(61, 180, 3);
+ ADQ_Add(61, 190, 3);
+ ADQ_Add(61, 200, 3);
+ ADQ_Add(61, 210, 3);
+ ADQ_Add(61, 220, 3);
+ ADQ_Add(41, 80, 3);
+ ADQ_Add(41, 90, 3);
+ ADQ_Add(41, 100, 3);
+ ADQ_Add(41, 110, 3);
+ ADQ_Add(41, 120, 3);
+ ADQ_Add(41, 130, 3);
+ Game_Flag_Set(691);
+ }
+ break;
+ case 2:
+ if (!Game_Flag_Query(690)) {
+ Overlay_Play("PS05OVER", 0, 1, 0, 0);
+ if (Actor_Query_Friendliness_To_Other(5, 0) > Actor_Query_Friendliness_To_Other(1, 0)) {
+ ADQ_Add(61, 120, 3);
+ ADQ_Add(61, 130, 3);
+ ADQ_Add(61, 140, 3);
+ ADQ_Add(61, 150, 3);
+ ADQ_Add(4, 1570, 3);
+ ADQ_Add(4, 1580, 3);
+ ADQ_Add(4, 1590, 3);
+ } else {
+ ADQ_Add(61, 90, 3);
+ ADQ_Add(61, 100, 3);
+ ADQ_Add(61, 110, 3);
+ ADQ_Add(4, 1540, 3);
+ ADQ_Add(4, 1550, 3);
+ ADQ_Add(4, 1560, 3);
+ }
+ Game_Flag_Set(690);
+ }
+ break;
+ case 1:
+ if (!Game_Flag_Query(689)) {
+ Overlay_Play("PS05OVER", 0, 1, 0, 0);
+ ADQ_Add(61, 40, 3);
+ ADQ_Add(61, 50, 3);
+ ADQ_Add(61, 60, 3);
+ ADQ_Add(61, 70, 3);
+ ADQ_Add(61, 80, 3);
+ Game_Flag_Set(689);
+ }
+ break;
+ case 0:
+ if (!Game_Flag_Query(688)) {
+ Overlay_Play("PS05OVER", 0, 1, 0, 0);
+ ADQ_Add(61, 0, 3);
+ ADQ_Add(61, 10, 3);
+ ADQ_Add(61, 20, 3);
+ ADQ_Add(61, 30, 3);
+ ADQ_Add(51, 430, 3);
+ ADQ_Add(51, 440, 3);
+ ADQ_Add(51, 450, 3);
+ ADQ_Add(51, 460, 3);
+ Game_Flag_Set(688);
+ }
+ break;
+ default:
+ return;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps06.cpp b/engines/bladerunner/script/ps06.cpp
new file mode 100644
index 0000000000..a3a1bdfc0a
--- /dev/null
+++ b/engines/bladerunner/script/ps06.cpp
@@ -0,0 +1,137 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS06::InitializeScene() {
+ Setup_Scene_Information(11257.26f, 707.3f, -4778.31f, 120);
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(388, 50, 1, 1);
+
+}
+
+void ScriptPS06::SceneLoaded() {
+ Obstacle_Object("E.SCREEN02", true);
+ Clickable_Object("E.SCREEN02");
+ Clickable_Object("E.MONITOR1");
+ Clickable_Object("E.SCREEN03");
+ Clickable_Object("E.MONITOR3");
+}
+
+bool ScriptPS06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS06::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("E.MONITOR1", objectName)) {
+ ESPER_Flag_To_Activate();
+ return true;
+ }
+ if (Object_Query_Click("E.SCREEN03", objectName) || Object_Query_Click("E.MONITOR3", objectName)) {
+ Actor_Says(39, 330, 3);
+ if (!Actor_Clue_Query(0, 111) || Actor_Clue_Query(0, 113) || Actor_Clue_Query(0, 114) || Actor_Clue_Query(0, 115)) {
+ Actor_Clues_Transfer_New_To_Mainframe(0);
+ Ambient_Sounds_Play_Sound(587, 50, 0, 0, 99);
+ Delay(2000);
+ Actor_Says(39, 340, 3);
+ Actor_Clues_Transfer_New_From_Mainframe(0);
+ Ambient_Sounds_Play_Sound(587, 50, 0, 0, 99);
+ Delay(2000);
+ Ambient_Sounds_Play_Sound(588, 80, 0, 0, 99);
+ Actor_Says(39, 350, 3);
+ return true;
+ } else {
+ Delay(2000);
+ Actor_Voice_Over(3780, 99);
+ Actor_Voice_Over(3790, 99);
+ if (Game_Flag_Query(47)) {
+ Actor_Voice_Over(3800, 99);
+ Actor_Voice_Over(3810, 99);
+ Actor_Voice_Over(3820, 99);
+ Actor_Voice_Over(3830, 99);
+ Actor_Clue_Acquire(0, 113, 1, -1);
+ } else if (Game_Flag_Query(45)) {
+ Actor_Voice_Over(3840, 99);
+ Actor_Voice_Over(3850, 99);
+ Actor_Voice_Over(3860, 99);
+ Actor_Voice_Over(3870, 99);
+ Actor_Clue_Acquire(0, 114, 1, -1);
+ } else {
+ Actor_Voice_Over(3880, 99);
+ Actor_Voice_Over(3890, 99);
+ Actor_Voice_Over(3900, 99);
+ Actor_Voice_Over(3910, 99);
+ Actor_Clue_Acquire(0, 115, 1, -1);
+ }
+ Actor_Clues_Transfer_New_To_Mainframe(0);
+ Actor_Clues_Transfer_New_From_Mainframe(0);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptPS06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ Game_Flag_Set(23);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(15, 69);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS06::PlayerWalkedIn() {
+ if (Game_Flag_Query(136)) {
+ Game_Flag_Reset(136);
+ }
+}
+
+void ScriptPS06::PlayerWalkedOut() {
+}
+
+void ScriptPS06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps07.cpp b/engines/bladerunner/script/ps07.cpp
new file mode 100644
index 0000000000..6708041544
--- /dev/null
+++ b/engines/bladerunner/script/ps07.cpp
@@ -0,0 +1,189 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS07::InitializeScene() {
+ Setup_Scene_Information(609.07f, 0.22f, -598.67f, 768);
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(141, 80, 0, 1);
+ Ambient_Sounds_Add_Sound(142, 5, 20, 5, 10, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(146, 5, 30, 5, 10, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(147, 2, 20, 5, 10, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(148, 2, 10, 10, 20, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(149, 2, 10, 10, 20, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(150, 2, 10, 10, 20, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(151, 2, 10, 10, 20, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(152, 2, 30, 10, 15, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(153, 2, 20, 10, 15, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(154, 5, 20, 10, 15, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(145, 5, 30, 5, 8, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptPS07::SceneLoaded() {
+ Obstacle_Object("RICE BOX01", true);
+ Unobstacle_Object("RICE BOX01", true);
+}
+
+bool ScriptPS07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS07::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("L.MOUSE", objectName)) {
+ Sound_Play(155, 70, 0, 0, 50);
+ if (Actor_Query_Goal_Number(30) < 4 && Actor_Query_Goal_Number(30) > 0) {
+ Actor_Face_Actor(0, 30, true);
+ Actor_Set_Goal_Number(30, 3);
+ Actor_Modify_Friendliness_To_Other(30, 0, -3);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS07::ClickedOnActor(int actorId) {
+ if (actorId == 30) {
+ Actor_Face_Actor(0, 30, true);
+ Actor_Set_Goal_Number(30, 3);
+ if (!Game_Flag_Query(111)) {
+ Actor_Says(0, 4115, 13);
+ }
+ if (!Game_Flag_Query(111) && Game_Flag_Query(125) || Game_Flag_Query(126) || Game_Flag_Query(127) || Game_Flag_Query(128)) {
+ Actor_Face_Actor(30, 0, true);
+ Actor_Says(30, 30, 12);
+ Game_Flag_Set(111);
+ } else {
+ if (Game_Flag_Query(111)) {
+ Actor_Says(0, 4130, 18);
+ }
+ }
+ if (Game_Flag_Query(125) && !Game_Flag_Query(12)) {
+ Game_Flag_Set(12);
+ Actor_Clue_Acquire(0, 11, 0, 30);
+ Actor_Says(30, 50, 16);
+ Actor_Says(0, 4135, 13);
+ Actor_Says(30, 60, 15);
+ Actor_Says(30, 70, 12);
+ Actor_Says(0, 4140, 18);
+ Actor_Says(30, 80, 14);
+ Actor_Says(30, 90, 14);
+ Actor_Set_Goal_Number(30, 1);
+ return true;
+ }
+ if (Game_Flag_Query(126) && !Game_Flag_Query(13)) {
+ Game_Flag_Set(13);
+ Actor_Clue_Acquire(0, 10, 0, 30);
+ sub_401D60();
+ Actor_Set_Goal_Number(30, 1);
+ return true;
+ }
+ if (Game_Flag_Query(127) && !Game_Flag_Query(104)) {
+ Game_Flag_Set(104);
+ Actor_Clue_Acquire(0, 39, 0, 30);
+ Actor_Says(30, 170, 14);
+ Actor_Says(0, 4180, 13);
+ Actor_Says(30, 180, 12);
+ Actor_Says(30, 190, 13);
+ Actor_Says(30, 200, 16);
+ Actor_Says(0, 4185, 18);
+ Actor_Says(30, 210, 12);
+ Actor_Modify_Friendliness_To_Other(30, 0, -12);
+ Actor_Set_Goal_Number(30, 1);
+ return true;
+ }
+ if (Game_Flag_Query(128) && !Game_Flag_Query(105)) {
+ Game_Flag_Set(105);
+ Actor_Says(30, 220, 12);
+ Actor_Says(0, 4190, 13);
+ Actor_Says(30, 230, 14);
+ Actor_Set_Goal_Number(30, 1);
+ return true;
+ }
+ Actor_Says(30, 0, 13);
+ Actor_Set_Goal_Number(30, 1);
+ return true;
+ }
+ return false;
+
+}
+
+bool ScriptPS07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 609.07f, 0.22f, -598.67f, 0, 0, false, 0)) {
+ Set_Enter(62, 66);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS07::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, 561.07f, 0.34f, -606.67f, 6, 0, false, 0);
+ Game_Flag_Reset(131);
+ //return false;
+}
+
+void ScriptPS07::PlayerWalkedOut() {
+ if (!Game_Flag_Query(138) && Global_Variable_Query(1) == 1) {
+ Actor_Set_Goal_Number(30, 0);
+ }
+}
+
+void ScriptPS07::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS07::sub_401D60() {
+ Actor_Says(30, 100, 13);
+ Actor_Says(0, 4145, 13);
+ Actor_Says(30, 110, 12);
+ Actor_Says(0, 4150, 13);
+ Actor_Says(30, 120, 14);
+ Actor_Says(0, 4155, 17);
+ Actor_Says(30, 130, 15);
+ Actor_Says(0, 4160, 13);
+ Actor_Says(30, 140, 16);
+ Actor_Says(0, 4165, 18);
+ Actor_Says(30, 160, 13);
+ Actor_Says(0, 4170, 19);
+ Actor_Says(0, 4175, 19);
+ Actor_Modify_Friendliness_To_Other(30, 0, 3);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps09.cpp b/engines/bladerunner/script/ps09.cpp
new file mode 100644
index 0000000000..4977056a54
--- /dev/null
+++ b/engines/bladerunner/script/ps09.cpp
@@ -0,0 +1,354 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS09::InitializeScene() {
+ if (Game_Flag_Query(465)) {
+ Setup_Scene_Information(-410.0f, 0.26f, -200.0f, 512);
+ } else {
+ Setup_Scene_Information(-559.0f, 0.0f, -85.06f, 250);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(138, 50, 0, 0);
+ Ambient_Sounds_Add_Looping_Sound(137, 30, 0, 0);
+ Ambient_Sounds_Add_Looping_Sound(124, 30, 0, 0);
+ 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(11, 67);
+ Actor_Set_At_XYZ(11, -417.88f, 0.0f, -200.74f, 512);
+ Game_Flag_Set(55);
+ }
+ if (Game_Flag_Query(465)) {
+ Actor_Put_In_Set(11, 94);
+ Actor_Set_At_XYZ(11, 0.0f, 0.0f, 0.0f, 512);
+ }
+ if (Game_Flag_Query(164) ) {
+ Actor_Put_In_Set(7, 67);
+ Actor_Set_At_XYZ(7, -476.0f, 0.2f, -225.0f, 518);
+ }
+ if (Game_Flag_Query(165) ) {
+ Actor_Put_In_Set(9, 67);
+ Actor_Set_At_XYZ(9, -290.0f, 0.33f, -235.0f, 207);
+ }
+}
+
+void ScriptPS09::SceneLoaded() {
+ Obstacle_Object("OFFICE DOOR", true);
+ Unobstacle_Object("OFFICE DOOR", true);
+ Unclickable_Object("OFFICE DOOR");
+}
+
+bool ScriptPS09::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS09::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS09::ClickedOnActor(int actorId) {
+ if (actorId == 11 && !Loop_Actor_Walk_To_XYZ(0, -381.11f, 0.0f, -135.55f, 0, 1, false, 0)) {
+ Actor_Face_Actor(0, 11, true);
+ Actor_Face_Actor(11, 0, true);
+ if (!Game_Flag_Query(49)) {
+ Actor_Says(11, 0, 12);
+ Actor_Says(0, 4235, 18);
+ Actor_Says(11, 10, 13);
+ Game_Flag_Set(49);
+ return true;
+ }
+ if (Game_Flag_Query(49) && !Game_Flag_Query(54) && !Actor_Clue_Query(0, 179) && !Actor_Clue_Query(0, 180) && !Actor_Clue_Query(0, 181)) {
+ Actor_Says(0, 4245, 14);
+ Actor_Says(11, 20, 14);
+ Game_Flag_Set(54);
+ return true;
+ }
+ if ((!Game_Flag_Query(53) && Game_Flag_Query(49) && Actor_Clue_Query(0, 179) ) || Actor_Clue_Query(0, 180) || Actor_Clue_Query(0, 181) || Actor_Clue_Query(0, 99) ) {
+ Game_Flag_Set(53);
+ Actor_Says(0, 4240, 13);
+ Actor_Says(11, 550, 15);
+ Actor_Says(11, 480, 16);
+ sub_402090();
+ return true;
+ }
+ if (Game_Flag_Query(51) ) {
+ Actor_Says(0, 4270, 18);
+ Actor_Says(11, 30, 14);
+ Actor_Says(11, 40, 13);
+ return true;
+ }
+ if (Game_Flag_Query(53) && Game_Flag_Query(49) && (Actor_Clue_Query(0, 179) || Actor_Clue_Query(0, 180) || Actor_Clue_Query(0, 99) )) {
+ sub_402090();
+ return true;
+ }
+ Actor_Says(0, 4270, 18);
+ Actor_Says(11, 30, 14);
+ Actor_Says(11, 40, 13);
+ return true;
+ }
+ if (actorId == 7 && !Loop_Actor_Walk_To_XYZ(0, -473.0f, 0.2f, -133.0f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 7, true);
+ Actor_Face_Actor(7, 0, true);
+ if (!Game_Flag_Query(167)) {
+ Actor_Says(0, 4200, 14);
+ Actor_Says(7, 570, 3);
+ Actor_Says(0, 4205, 18);
+ Game_Flag_Set(167);
+ return true;
+ }
+ if (Game_Flag_Query(167) && !Game_Flag_Query(168)) {
+ Actor_Says(0, 4210, 18);
+ Actor_Says(7, 580, 3);
+ Actor_Says(0, 4215, 14);
+ Actor_Says(7, 590, 3);
+ Actor_Says(7, 600, 3);
+ Actor_Says(0, 4220, 18);
+ Actor_Says(7, 610, 3);
+ Actor_Says(0, 4225, 19);
+ Actor_Says(7, 620, 3);
+ Actor_Says(0, 4230, 14);
+ Game_Flag_Set(168);
+ return true;
+ }
+ Actor_Says(0, 4200, 13);
+ }
+ if (actorId == 9 && !Loop_Actor_Walk_To_XYZ(0, -295.0f, 0.34f, -193.0f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 9, true);
+ Actor_Face_Actor(9, 0, true);
+ //TODO: cleanup
+ if (Game_Flag_Query(166) || (Actor_Says(0, 4415, 18) , Actor_Says(9, 1090, 3) , Actor_Says(0, 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(0, 4425, 18);
+ Actor_Says(9, 1160, 3);
+ return true;
+ } else {
+ Actor_Says(0, 4425, 18);
+ Actor_Says(9, 1100, 3);
+ Actor_Says(0, 4430, 19);
+ Actor_Says(9, 1110, 3);
+ Game_Flag_Set(175);
+ return true;
+ }
+ } else {
+ Actor_Face_Actor(11, 9, true);
+ Actor_Says(11, 420, 14);
+ Actor_Face_Actor(9, 11, true);
+ Actor_Says(9, 1120, 3);
+ Actor_Face_Actor(0, 11, true);
+ Actor_Says(0, 4435, 14);
+ Actor_Says(11, 430, 16);
+ Actor_Says(9, 1130, 3);
+ Game_Flag_Set(56);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptPS09::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS09::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -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, 66);
+ Game_Flag_Reset(211);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS09::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS09::SceneFrameAdvanced(int frame) {
+ if (frame == 1 || frame == 15 || frame == 20 || frame == 31 || frame == 33 || frame == 35 || frame == 52 || frame == 54) {
+ Sound_Play(97, Random_Query(50, 33), 10, 10, 50);
+ }
+ //return true;
+}
+
+void ScriptPS09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS09::PlayerWalkedIn() {
+ if (Game_Flag_Query(465)) {
+ Player_Loses_Control();
+ Delay(2000);
+ Actor_Retired_Here(0, 6, 6, 1, -1);
+ //return true;
+ return;
+ }
+ if (!Game_Flag_Query(211)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -491.15f, 0.0f, -73.06f, 0, 0, false, 0);
+ Player_Gains_Control();
+ Game_Flag_Set(211);
+ }
+ if (Game_Flag_Query(133) ) {
+ Game_Flag_Reset(133);
+ //return true;
+ return;
+ }
+ //return false;
+}
+
+void ScriptPS09::PlayerWalkedOut() {
+}
+
+void ScriptPS09::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS09::sub_402090() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 179) || Actor_Clue_Query(0, 180) || Actor_Clue_Query(0, 181) ) {
+ 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(0, 99) && (Actor_Clue_Query(0, 179) || Actor_Clue_Query(0, 180) || Actor_Clue_Query(0, 181) )) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(190, 5, 6, -1);
+ }
+ Dialogue_Menu_Add_To_List(210);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 170:
+ Actor_Says(0, 4270, 13);
+ Actor_Says(0, 4250, 18);
+ Actor_Says(11, 50, 13);
+ Actor_Says(0, 4275, 18);
+ Actor_Says(0, 4280, 19);
+ if (Game_Flag_Query(44) ) {
+ Actor_Says(11, 60, 14);
+ Actor_Says(0, 4285, 13);
+ Actor_Says(11, 70, 12);
+ Actor_Says(0, 4290, 13);
+ Actor_Says(11, 80, 13);
+ Actor_Says(11, 90, 13);
+ Actor_Says(0, 4295, 18);
+ Actor_Says(11, 110, 14);
+ Actor_Says(0, 4300, 17);
+ return;
+ }
+ if (!Game_Flag_Query(44)) {
+ Actor_Says(11, 130, 15);
+ Actor_Says(11, 140, 13);
+ Actor_Says(0, 4305, 13);
+ Actor_Says(11, 150, 14);
+ Actor_Says(11, 160, 12);
+ Actor_Says(0, 4310, 13);
+ Actor_Says(11, 170, 15);
+ Actor_Says(11, 180, 16);
+ Actor_Says(0, 4315, 18);
+ Actor_Says(11, 200, 13);
+ return;
+ }
+ break;
+ case 180:
+ Actor_Says(0, 4270, 18);
+ Actor_Says(0, 4255, 3);
+ Actor_Says(11, 210, 12);
+ Actor_Says(11, 220, 13);
+ Actor_Says(11, 230, 14);
+ Actor_Says(0, 4320, 14);
+ Actor_Says(11, 240, 16);
+ Actor_Says(11, 250, 15);
+ Actor_Says(0, 4330, 13);
+ Actor_Says(11, 260, 13);
+ Actor_Says(11, 270, 12);
+ Actor_Says(0, 4335, 18);
+ Actor_Says(11, 290, 15);
+ Actor_Says(0, 4340, 13);
+ Actor_Modify_Friendliness_To_Other(11, 0, -5);
+ if (Game_Flag_Query(165)) {
+ Actor_Says(11, 300, 12);
+ Actor_Face_Actor(9, 11, true);
+ Actor_Says(9, 1010, 3);
+ Actor_Face_Actor(11, 9, true);
+ Actor_Says(11, 310, 16);
+ Actor_Face_Actor(0, 9, true);
+ Actor_Says(0, 4345, 14);
+ Actor_Face_Actor(9, 0, true);
+ Actor_Says(9, 1020, 3);
+ Actor_Says(0, 4350, 18);
+ Actor_Says(9, 1030, 3);
+ Actor_Says(0, 4355, 19);
+ Actor_Says(9, 1040, 3);
+ Actor_Says(0, 4360, 16);
+ Actor_Says(0, 4365, 14);
+ Actor_Says(9, 1050, 3);
+ Actor_Says(9, 1060, 3);
+ Actor_Says(0, 4370, 14);
+ Actor_Says(9, 1070, 3);
+ Actor_Says(9, 1080, 3);
+ }
+ else {
+ Actor_Says(11, 320, 13);
+ Actor_Says(11, 340, 14);
+ Actor_Says(11, 350, 12);
+ Actor_Says(0, 4375, 18);
+ }
+ break;
+ case 190:
+ Actor_Says(0, 4270, 18);
+ Actor_Says(0, 4260, 3);
+ Actor_Says(11, 360, 16);
+ Actor_Says(0, 4380, 19);
+ Actor_Says(0, 4385, 19);
+ Actor_Says(11, 370, 13);
+ Actor_Says(0, 4390, 19);
+ Actor_Says(0, 4395, 18);
+ Actor_Says(11, 380, 14);
+ Actor_Says(11, 390, 12);
+ Actor_Modify_Friendliness_To_Other(11, 0, -5);
+ break;
+ case 200:
+ Actor_Says(0, 4265, 14);
+ Actor_Says(11, 400, 13);
+ Actor_Says(0, 4400, 13);
+ Actor_Says(11, 410, 16);
+ Actor_Says(0, 4405, 14);
+ Actor_Says(0, 4410, 15);
+ Voight_Kampff_Activate(11, 20);
+ Actor_Modify_Friendliness_To_Other(11, 0, -10);
+ break;
+ case 210:
+ Actor_Says(0, 8600, 18);
+ Actor_Says(11, 20, 15);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps10.cpp b/engines/bladerunner/script/ps10.cpp
new file mode 100644
index 0000000000..0135bffade
--- /dev/null
+++ b/engines/bladerunner/script/ps10.cpp
@@ -0,0 +1,248 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS10::InitializeScene() {
+ Police_Maze_Set_Pause_State(1);
+ if (Game_Flag_Query(15)) {
+ float x = World_Waypoint_Query_X(4);
+ float y = World_Waypoint_Query_Y(4);
+ float z = World_Waypoint_Query_Z(4);
+ Setup_Scene_Information(x, y, z, 280);
+ } else {
+ Setup_Scene_Information(-87.08f, -9.23f, 941.9f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 20, 479, 3);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(387, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(1, 10, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(389, 5, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(390, 6, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+}
+
+static int track_data_0[] = {-26, 10, 20, -18, 10, 20, -9, 0, -9, 1,-5, 989, -1, 0, -15, 0, 1, -15, 1, 1,-23, 0, -7, 3000, 5000, -8, 0, -10, 159, 100,-2, 14, -3, 1000, -6, 740, 80, -22, 0, -3,0, -6, 488, 80, -3, 1000, -24, 27, 33, -3, 0, -6, 740, 80, -11, 1, -9, 0, -8, 1, -12, 0, -1, 0, -4};
+static int track_data_1[] = {-5, 740, -1, 0, -22, 1, -2, 69, -3, 500, -9, 1, -11, 4, -12, 1, -1, 0, -4};
+static int track_data_2[] = {-26, 10, 20, -18, 10, 20, -9, 2, -5, 993, -1, 0, -7, 3000, 5000, -8, 2, -10, 159, 100, -15, 2, 1, -23, 2, -2, 5, -3, 1000, -22, 2, -6, 233, 80, -3, 0, -6, 491, 80, -3, 500, -24, 27, 33, -3, 500, -6, 233, 80, -3, 0, -6, 993, 80, -10, 34, 33, -2, 0, -9, 2, -4};
+static int track_data_3[] = {-26, 10, 20, -18, 10, 20, -9, 3, -5, 993, -1, 0, -7, 3000, 6000, -8, 3, -10, 159, 100, -15, 3, 1, -23, 3, -2, 34, -3, 500, -6, 491, 80, -2, 0, -25, -9, 3, -11, 7, -12, 3, -4};
+static int track_data_4[] = {-26, 10, 20, -18, 10, 20, -9, 4, -5, 0, -1, 0, -7, 4000, 6000, -8, 4, -10, 159, 100, -15, 4, 1, -23, 4, -2, 5, -3, 1000, -6, 512, 100, -3, 2000, -6, 0, -100, -10, 34, 33, -2, 0, -25, -9, 4, -11, 0, -12, 4, -4};
+static int track_data_5[] = {-26, 10, 20, -18, 10, 20, -9, 5, -5, 999, -1, 0, -7, 4000, 6000, -8, 5, -10, 159, 100, -15, 5, 1, -23, 5, -2, 7, -3, 500, -22, 5, -6, 750, 80, -3, 0, -6, 500, 80, -3, 1000, -24, 27, 33, -3, 0, -6, 750, 80, -3, 0, -6, 999, 80, -10, 34, 33, -2, 0, -9, 5, -11, 6, -11, 8, -12, 5, -4};
+static int track_data_6[] = {-26, 10, 20, -18, 10, 20, -9, 6, -5, 264, -1, 0, -7, 3000, 6000, -15, 6, 1, -23, 6, -8, 6, -2, 89, -7, 4000, 8000, -5, 776, -2, 0, -25, -9, 6, -12, 6, -4};
+static int track_data_7[] = {-26, 10, 20, -18, 10, 20, -9, 7, -5, 993, -1, 0, -7, 4000, 6000, -8, 7, -10, 159, 100, -15, 7, 1, -23, 7, -2, 34, -3, 500, -22, 7, -6, 491, 80, -2, 20, -3, 0, -24, 27, 33, -2, 0, -9, 7, -11, 3, -12, 7, -4};
+static int track_data_8[] = {-26, 10, 20, -18, 10, 20, -9, 8, -5, 738, -1, 0, -7, 2000, 5000, -15, 8, 1, -22, 8, -8, 8, -10, 0, 33, -2, 23, -10, 0, 33, -3, 200, -10, 32, 33, -6, 498, 100, -10, 0, 33, -3, 100, -24, 27, 33, -10, 32, 33, -2, 35, -10, 32, 33, -3, 100, -24, 27, 33, -10, 0, 33, -2, 23, -10, 32, 33, -3, 100, -24, 27, 33, -10, 32, 33, -6, 758, 100, -10, 32, 33, -2, 89, -10, 0, 33, -7, 4000, 6000, -15, 8, 1, -22, 8, -5, 216, -10, 32, 33, -2, 69, -3, 100, -10, 32, 33, -6, 498, 100, -3, 100, -24, 27, 33, -10, 0, 33, -6, 216, 100, -10, 32, 33, -2, 0, -9, 8, -12, 8, -4};
+
+void ScriptPS10::SceneLoaded() {
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("PARKMETR03", true);
+ Obstacle_Object("PARKMETR07", true);
+ Obstacle_Object("PARKMETR08", true);
+ Obstacle_Object("PARKMETR10", true);
+ Obstacle_Object("PARKMETR11", true);
+ Obstacle_Object("PARKMETR15", true);
+ Obstacle_Object("PARKMETR16", true);
+ Obstacle_Object("TUBE14", true);
+ Unclickable_Object("PARKMETR01");
+ Unclickable_Object("PARKMETR02");
+ Unclickable_Object("PARKMETR03");
+ Unclickable_Object("PARKMETR07");
+ Unclickable_Object("PARKMETR08");
+ Unclickable_Object("PARKMETR10");
+ Unclickable_Object("PARKMETR11");
+ Unclickable_Object("PARKMETR15");
+ Unclickable_Object("PARKMETR16");
+ Unobstacle_Object("E.SM.WIRE01", true);
+ if (!Query_System_Currently_Loading_Game()) {
+ Item_Add_To_World(0, 443, 14, -240.0f, -80.74f, 145.0f, 989, 72, 36, true, false, false, true);
+ Item_Add_To_World(1, 443, 14, -240.0f, -8.74f, 145.0f, 740, 72, 36, true, false, false, true);
+ Item_Add_To_World(2, 445, 14, -165.0f, 111.53f, -10.0f, 993, 72, 36, true, false, false, true);
+ Item_Add_To_World(3, 447, 14, -125.0f, 160.0f, -10.0f, 993, 72, 36, true, false, false, true);
+ Item_Add_To_World(4, 441, 14, -246.71f, 205.51f, -20.0f, 0, 72, 36, true, false, false, true);
+ Item_Add_To_World(5, 445, 14, -27.69f, -86.92f, 434.0f, 999, 72, 36, true, false, false, true);
+ Item_Add_To_World(6, 441, 14, -347.15f, 7.68f, -20.0f, 264, 72, 36, true, false, false, true);
+ Item_Add_To_World(7, 449, 14, -51.0f, 160.0f, -10.0f, 993, 72, 36, true, false, false, true);
+ Item_Add_To_World(8, 445, 14, 39.0f, 9.16f, -20.0f, 738, 72, 36, true, false, false, true);
+ }
+
+ Police_Maze_Target_Track_Add(0, -240.0f, -80.74f, 145.0f, -240.0f, -8.74f, 145.0f, 15, track_data_0, false);
+ Police_Maze_Target_Track_Add(1, -240.0f, -8.74f, 145.0f, -450.0f, -8.74f, 145.0f, 70, track_data_1, false);
+ Police_Maze_Target_Track_Add(2, -165.0f, 111.53f, -10.0f, -165.0f, 167.53f, -10.0f, 6, track_data_2, true);
+ Police_Maze_Target_Track_Add(3, -125.0f, 160.0f, -10.0f, -51.0f, 160.0f, -10.0f, 35, track_data_3, false);
+ Police_Maze_Target_Track_Add(4, -246.71f, 205.51f, -20.0f, -246.71f, 241.51f, -20.0f, 6, track_data_4, true);
+ Police_Maze_Target_Track_Add(5, -27.69f, -86.92f, 434.0f, -27.69f, -18.92f, 434.0f, 8, track_data_5, true);
+ Police_Maze_Target_Track_Add(6, -347.15f, 7.68f, -20.0f, 39.0f, 9.16f, -20.0f, 90, track_data_6, false);
+ Police_Maze_Target_Track_Add(7, -51.0f, 160.0f, -10.0f, -125.0f, 160.0f, -10.0f, 35, track_data_7, true);
+ Police_Maze_Target_Track_Add(8, 39.0f, 9.16f, -20.0f, -347.15f, 7.68f, -20.0f, 90, track_data_8, false);
+ Preload(441);
+ Preload(442);
+ Preload(443);
+ Preload(444);
+ Preload(445);
+ Preload(446);
+ Preload(447);
+ Preload(448);
+ Preload(449);
+ Preload(450);
+}
+
+bool ScriptPS10::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS10::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS10::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS10::ClickedOnItem(int itemId, bool a2) {
+ if (Player_Query_Combat_Mode()) {
+ switch (itemId) {
+ case 3:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 4:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ case 6:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ default:
+ Sound_Play(2, 12, 0, 0, 50);
+ break;
+ }
+ Item_Spin_In_World(itemId);
+ if (itemId == 0) {
+ Item_Flag_As_Non_Target(0);
+ Item_Flag_As_Non_Target(1);
+ }
+ if (itemId == 1) {
+ Item_Flag_As_Non_Target(0);
+ Item_Flag_As_Non_Target(1);
+ }
+ if (itemId == 2) {
+ Item_Flag_As_Non_Target(2);
+ }
+ if (itemId == 3) {
+ Item_Flag_As_Non_Target(3);
+ }
+ if (itemId == 4) {
+ Item_Flag_As_Non_Target(4);
+ }
+ if (itemId == 5) {
+ Item_Flag_As_Non_Target(5);
+ }
+ if (itemId == 6) {
+ Item_Flag_As_Non_Target(6);
+ }
+ if (itemId == 7) {
+ Item_Flag_As_Non_Target(7);
+ }
+ if (itemId == 8) {
+ Item_Flag_As_Non_Target(8);
+ } else {
+ Item_Flag_As_Non_Target(itemId);
+ }
+ return true;
+ }
+
+ return false;
+}
+
+bool ScriptPS10::ClickedOnExit(int exitId) {
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 6, 12, 1, false)) {
+ Game_Flag_Set(14);
+ sub_402238();
+ Global_Variable_Decrement(9, 20 - Global_Variable_Query(10));
+ Global_Variable_Set(10, 20);
+ Set_Enter(14, 74);
+ }
+ return true;
+ }
+
+ return false;
+}
+
+bool ScriptPS10::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS10::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS10::PlayerWalkedIn() {
+ if (Game_Flag_Query(15)) {
+ Loop_Actor_Walk_To_XYZ(0, -352.09f, -9.23f, 267.95f, 0, 0, true, 0);
+ Police_Maze_Set_Pause_State(0);
+ Game_Flag_Reset(15);
+ //return true;
+ return;
+ } else {
+ Player_Set_Combat_Mode(true);
+ Loop_Actor_Walk_To_Waypoint(0, 5, 0, 0, true);
+ Actor_Says(39, 280, 3);
+ Actor_Says(39, 290, 3);
+ Actor_Says(39, 300, 3);
+ Police_Maze_Set_Pause_State(0);
+ //return true;
+ return;
+ }
+}
+
+void ScriptPS10::PlayerWalkedOut() {
+}
+
+void ScriptPS10::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS10::sub_402238() {
+ Item_Remove_From_World(0);
+ Item_Remove_From_World(1);
+ Item_Remove_From_World(2);
+ Item_Remove_From_World(3);
+ Item_Remove_From_World(4);
+ Item_Remove_From_World(5);
+ Item_Remove_From_World(6);
+ Item_Remove_From_World(7);
+ Item_Remove_From_World(8);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps11.cpp b/engines/bladerunner/script/ps11.cpp
new file mode 100644
index 0000000000..d979619480
--- /dev/null
+++ b/engines/bladerunner/script/ps11.cpp
@@ -0,0 +1,285 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS11::InitializeScene() {
+ if (Game_Flag_Query(14)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(14);
+ Setup_Scene_Information(World_Waypoint_Query_X(6), World_Waypoint_Query_Y(6), World_Waypoint_Query_Z(6), 840);
+ } else {
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(World_Waypoint_Query_X(7), World_Waypoint_Query_Y(7), World_Waypoint_Query_Z(7), 132);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 20, 479, 3);
+}
+
+static int track_data_9[] = {-26, 11, 20, -18, 11, 20, -9, 9, -5, 50, -1, 0, -7, 5000, 5000, -8, 9, -10, 31, 33, -15, 9, 1, -22, 9, -2, 7, -3, 1000, -24, 27, 33, -10, 34, 33, -2, 0, -3, 500, -9, 9, -13, 15, 10, -12, 9, -4};
+static int track_data_10[] = {-26, 11, 20, -18, 11, 20, -9, 10, -9, 11, -15, 10, 1, -15, 11, 1, -5, 860, -1, 0, -7, 3000, 6000, -23, 10, -8, 10, -10, 33, 33, -2, 14, -3, 500, -11, 11, -9, 10, -8, 11, -12, 10, -1, 0, -4};
+static int track_data_11[] = {-5, 860, -1, 0, -23, 11, -8, 11, -2, 25, -3, 500, -22, 11, -10, 32, 33, -6, 644, 80, -3, 0, -6, 388, 80, -3, 1000, -24, 12, 33, -2, 79, -9, 11, -13, 15, 9, -12, 11, -1, 0, -5, 860, -4};
+static int track_data_12[] = {-26, 11, 20, -18, 11, 20, -9, 12, -5, 725, -1, 0, -3, 2000, -15, 12, 1, -23, 12, -8, 12, -2, 82, -25, -3, 1000, -6, 570, 80, -3, 0, -6, 462, 80, -3, 0, -6, 213, 80, -3, 1000, -2, 0, -6, 725, 80, -2, 99, -9, 12, -11, 27, -12, 12, -1, 0, -4};
+static int track_data_13[] = {-26, 11, 20, -18, 11, 20, -9, 13, -5, 340, -1, 0, -7, 4000, 8000, -8, 13, -10, 33, 33, -15, 13, 1, -22, 13, -2, 4, -3, 0, -6, 435, 80, -3, 0, -6, 530, 80, -3, 100, -6, 435, 80, -3, 0, -6, 340, 80, -3, 0, -6, 260, 80, -3, 0, -6, 180, 80, -3, 100, -6, 260, 80, -3, 0, -6, 340, 80, -3, 200, -24, 27, 33, -10, 34, 33, -2, 0, -9, 13, -13, 14, 18, -12, 13, -4};
+static int track_data_14[] = {-26, 11, 20, -18, 11, 20, -9, 14, -15, 14, 1, -23, 14, -5, 900, -1, 0, -7, 3000, 6000, -8, 14, -10, 33, 33, -2, 5, -3, 500, -22, 14, -6, 644, 80, -3, 0, -6, 388, 80, -3, 1000, -24, 27, 33, -10, 34, 33, -2, 0, -9, 14, -13, 18, 13, -12, 14, -4};
+static int track_data_15[] = {-26, 11, 20, -18, 11, 20, -9, 15, -9, 16, -15, 15, 1, -15, 16, 1, -5, 860, -1, 0, -7, 3000, 7000, -8, 15, -10, 29, 33, -23, 15, -2, 14, -25, -3, 1000, -11, 16, -9, 15, -8, 16, -12, 15, -1, 0, -4};
+static int track_data_16[] = {-5, 860, -1, 0, -8, 16, -23, 16, -2, 25, -3, 500, -10, 32, 33, -6, 644, 100, -3, 0, -6, 388, 200, -3, 500, -2, 79, -25, -9, 16, -13, 10, 9, -12, 16, -1, 0, -5, 860, -4};
+static int track_data_17[] = {-26, 11, 20, -18, 11, 20, -5, 310, -1, 0, -8, 17, -15, 17, 1, -22, 17, -7, 4000, 8000, -10, 32, 33, -2, 10, -3, 0, -24, 27, 33, -2, 0, -15, 17, 1, -22, 17, -2, 24, -15, 17, 1, -22, 17, -2, 10, -3, 0, -24, 27, 33, -2, 24, -3, 1000, -9, 17, -13, 23, 22, -12, 17, -1, 0, -4};
+static int track_data_18[] = {-26, 11, 20, -18, 11, 20, -9, 18, -9, 19, -5, 900, -1, 0, -15, 18, 1, -15, 19, 1, -23, 18, -7, 4000, 6000, -8, 18, -2, 5, -10, 19, 33, -10, 3, 33, -3, 1000, -25, -6, 700, 80, -22, 18, -3, 0, -6, 512, 200, -3, 1000, -24, 12, 33, -11, 19, -9, 18, -8, 19, -12, 18, -1, 0, -4};
+static int track_data_19[] = {-5, 512, -1, 0, -22, 19, -2, 8, -3, 4000, -15, 19, 1, -22, 19, -2, 2, -10, 32, 33, -3, 1000, -24, 12, 33, -2, 19, -3, 500, -9, 19, -13, 13, 14, -12, 19, -1, 0, -4};
+static int track_data_20[] = {-26, 11, 20, -18, 11, 20, -9, 20, -5, 280, -1, 0, -7, 5000, 7000, -15, 20, 1, -22, 20, -8, 20, -2, 9, -10, 32, 33, -3, 1000, -24, 27, 33, -2, 0, -9, 20, -13, 21, 12, -12, 20, -1, 0, -4};
+static int track_data_21[] = {-26, 11, 20, -18, 11, 20, -9, 21, -5, 280, -1, 0, -7, 5000, 8000, -15, 21, 1, -23, 21, -8, 21, -2, 5, -25, -3, 1000, -2, 0, -9, 21, -13, 20, 12, -12, 21, -1, 0, -4};
+static int track_data_22[] = {-26, 11, 20, -18, 11, 20, -9, 22, -5, 255, -1, 0, -15, 22, 1, -22, 22, -7, 5000, 5000, -8, 22, -2, 7, -10, 32, 33, -3, 1000, -24, 12, 33, -2, 0, -9, 22, -13, 23, 17, -12, 22, -1, 0, -4};
+static int track_data_23[] = {-26, 11, 20, -18, 11, 20, -9, 23, -5, 310, -1, 0, -7, 3000, 6000, -15, 23, 1, -23, 23, -8, 23, -3, 1000, -2, 24, -3, 1000, -2, 0, -25, -9, 23, -13, 22, 17, -12, 23, -1, 0, -4};
+static int track_data_27[] = {-26, 11, 20, -18, 11, 20, -9, 27, -5, 346, -1, 0, -3, 0, -15, 27, 1, -22, 27, -8, 27, -2, 14, -3, 1000, -24, 12, 33, -2, 0, -9, 27, -13, 21, 20, -12, 27, -1, 0, -4};
+
+void ScriptPS11::SceneLoaded() {
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("PARKMETR03", true);
+ Obstacle_Object("PARKMETR07", true);
+ Obstacle_Object("PARKMETR08", true);
+ Obstacle_Object("PARKMETR10", true);
+ Obstacle_Object("PARKMETR11", true);
+ Obstacle_Object("PARKMETR15", true);
+ Obstacle_Object("PARKMETR16", true);
+ Unclickable_Object("PARKMETR01");
+ Unclickable_Object("PARKMETR02");
+ Unclickable_Object("PARKMETR03");
+ Unclickable_Object("PARKMETR07");
+ Unclickable_Object("PARKMETR08");
+ Unclickable_Object("PARKMETR10");
+ Unclickable_Object("PARKMETR11");
+ Unclickable_Object("PARKMETR15");
+ Unclickable_Object("PARKMETR16");
+ if (!Query_System_Currently_Loading_Game()) {
+ Item_Add_To_World(9, 449, 14, -450.0f, -7.5f, 335.0f, 50, 72, 36, true, false, false, true);
+ Item_Add_To_World(10, 449, 14, -740.0f, 27.0f, -30.0f, 860, 72, 36, true, false, false, true);
+ Item_Add_To_World(11, 449, 14, -740.0f, 99.0f, -30.0f, 860, 72, 36, true, false, false, true);
+ Item_Add_To_World(12, 441, 14, -400.0f, -9.23f, -75.0f, 725, 72, 36, true, false, false, true);
+ Item_Add_To_World(13, 443, 14, -803.72f, -72.7f, 60.22f, 340, 72, 36, true, false, false, true);
+ Item_Add_To_World(14, 443, 14, -853.0f, -70.0f, 195.0f, 900, 72, 36, true, false, false, true);
+ Item_Add_To_World(15, 447, 14, -740.0f, 27.0f, -30.0f, 860, 72, 36, true, false, false, true);
+ Item_Add_To_World(16, 447, 14, -740.0f, 99.0f, -30.0f, 860, 72, 36, true, false, false, true);
+ Item_Add_To_World(17, 445, 14, -888.0f, 155.0f, 100.0f, 310, 72, 36, true, false, false, true);
+ Item_Add_To_World(18, 443, 14, -430.0f, 164.0f, 11.0f, 900, 72, 36, true, false, false, true);
+ Item_Add_To_World(19, 443, 14, -430.0f, -0.86f, 11.0f, 512, 72, 36, true, false, false, true);
+ Item_Add_To_World(20, 443, 14, -891.0f, 3.1f, 90.0f, 280, 72, 36, true, false, false, true);
+ Item_Add_To_World(21, 447, 14, -891.0f, 3.1f, 90.0f, 280, 72, 36, true, false, false, true);
+ Item_Add_To_World(22, 445, 14, -891.0f, 171.0f, 190.0f, 255, 72, 36, true, false, false, true);
+ Item_Add_To_World(23, 441, 14, -888.0f, 155.0f, 30.0f, 310, 72, 36, true, false, false, true);
+ Item_Add_To_World(27, 445, 14, -800.0f, -9.23f, -75.0f, 346, 72, 36, true, false, false, true);
+ }
+
+ Police_Maze_Target_Track_Add(9, -450.0f, -7.5f, 335.0f, -450.0f, -7.5f, 295.0f, 8, track_data_9, true);
+ Police_Maze_Target_Track_Add(10, -740.0f, 27.0f, -30.0f, -740.0f, 99.0f, -30.0f, 15, track_data_10, false);
+ Police_Maze_Target_Track_Add(11, -740.0f, 99.0f, -30.0f, -200.0f, 99.0f, -30.0f, 80, track_data_11, false);
+ Police_Maze_Target_Track_Add(12, -400.0f, -9.23f, -75.0f, -800.0f, -9.23f, -75.0f, 100, track_data_12, false);
+ Police_Maze_Target_Track_Add(13, -803.72f, -72.7f, 60.22f, -803.72f, -0.7f, 60.22f, 6, track_data_13, true);
+ Police_Maze_Target_Track_Add(14, -853.0f, -70.0f, 195.0f, -853.0f, 2.0f, 195.0f, 6, track_data_14, false);
+ Police_Maze_Target_Track_Add(15, -740.0f, 27.0f, -30.0f, -740.0f, 99.0f, -30.0f, 15, track_data_15, false);
+ Police_Maze_Target_Track_Add(16, -740.0f, 99.0f, -30.0f, -200.0f, 99.0f, -30.0f, 80, track_data_16, false);
+ Police_Maze_Target_Track_Add(17, -888.0f, 155.0f, 100.0f, -888.0f, 155.0f, 30.0f, 25, track_data_17, false);
+ Police_Maze_Target_Track_Add(18, -430.0f, 164.0f, 11.0f, -430.0f, -0.86f, 11.0f, 6, track_data_18, false);
+ Police_Maze_Target_Track_Add(19, -430.0f, -0.86f, 11.0f, -300.0f, -0.86f, -80.0f, 20, track_data_19, false);
+ Police_Maze_Target_Track_Add(20, -891.0f, 3.1f, 90.0f, -891.0f, 3.1f, 105.0f, 10, track_data_20, true);
+ Police_Maze_Target_Track_Add(21, -891.0f, 3.1f, 90.0f, -891.0f, 3.1f, 105.0f, 6, track_data_21, false);
+ Police_Maze_Target_Track_Add(22, -891.0f, 171.0f, 190.0f, -891.0f, 171.0f, 147.0f, 8, track_data_22, false);
+ Police_Maze_Target_Track_Add(23, -888.0f, 155.0f, 30.0f, -888.0f, 155.0f, 100.0f, 25, track_data_23, true);
+ Police_Maze_Target_Track_Add(27, -800.0f, -9.23f, -75.0f, -740.0f, -9.23f, -75.0f, 15, track_data_27, false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(387, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(1, 10, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(389, 5, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(390, 6, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+}
+
+bool ScriptPS11::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS11::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS11::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS11::ClickedOnItem(int itemId, bool a2) {
+ if (Player_Query_Combat_Mode()) {
+ switch (itemId) {
+ case 15:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 16:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 21:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 23:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ case 12:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ default:
+ Sound_Play(2, 12, 0, 0, 50);
+ break;
+ }
+ Item_Spin_In_World(itemId);
+ if (itemId == 9) {
+ Item_Flag_As_Non_Target(9);
+ }
+ if (itemId == 10) {
+ Item_Flag_As_Non_Target(10);
+ Item_Flag_As_Non_Target(11);
+ }
+ if (itemId == 11) {
+ Item_Flag_As_Non_Target(10);
+ Item_Flag_As_Non_Target(11);
+ }
+ if (itemId == 12) {
+ Item_Flag_As_Non_Target(12);
+ }
+ if (itemId == 13) {
+ Item_Flag_As_Non_Target(13);
+ }
+ if (itemId == 14) {
+ Item_Flag_As_Non_Target(14);
+ }
+ if (itemId == 15) {
+ Item_Flag_As_Non_Target(15);
+ Item_Flag_As_Non_Target(16);
+ }
+ if (itemId == 16) {
+ Item_Flag_As_Non_Target(15);
+ Item_Flag_As_Non_Target(16);
+ }
+ if (itemId == 17) {
+ Item_Flag_As_Non_Target(17);
+ }
+ if (itemId == 18) {
+ Item_Flag_As_Non_Target(18);
+ Item_Flag_As_Non_Target(19);
+ }
+ if (itemId == 19) {
+ Item_Flag_As_Non_Target(18);
+ Item_Flag_As_Non_Target(19);
+ }
+ if (itemId == 20) {
+ Item_Flag_As_Non_Target(20);
+ }
+ if (itemId == 21) {
+ Item_Flag_As_Non_Target(21);
+ }
+ if (itemId == 22) {
+ Item_Flag_As_Non_Target(22);
+ }
+ if (itemId == 23) {
+ Item_Flag_As_Non_Target(23);
+ }
+ if (itemId == 27) {
+ Item_Flag_As_Non_Target(27);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS11::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 6, 12, 1, false)) {
+ Game_Flag_Set(15);
+ sub_402744();
+ Set_Enter(14, 73);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 8, 12, 1, false)) {
+ Game_Flag_Set(16);
+ sub_402744();
+ Global_Variable_Decrement(9, 20 - Global_Variable_Query(11));
+ Global_Variable_Set(11, 20);
+ Set_Enter(14, 75);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS11::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS11::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS11::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS11::PlayerWalkedIn() {
+ Police_Maze_Set_Pause_State(0);
+}
+
+void ScriptPS11::PlayerWalkedOut() {
+}
+
+void ScriptPS11::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS11::sub_402744() {
+ Item_Remove_From_World(9);
+ Item_Remove_From_World(10);
+ Item_Remove_From_World(11);
+ Item_Remove_From_World(12);
+ Item_Remove_From_World(13);
+ Item_Remove_From_World(14);
+ Item_Remove_From_World(15);
+ Item_Remove_From_World(16);
+ Item_Remove_From_World(17);
+ Item_Remove_From_World(18);
+ Item_Remove_From_World(19);
+ Item_Remove_From_World(20);
+ Item_Remove_From_World(21);
+ Item_Remove_From_World(22);
+ Item_Remove_From_World(23);
+ Item_Remove_From_World(27);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps12.cpp b/engines/bladerunner/script/ps12.cpp
new file mode 100644
index 0000000000..b99eafd2fc
--- /dev/null
+++ b/engines/bladerunner/script/ps12.cpp
@@ -0,0 +1,302 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS12::InitializeScene() {
+ Police_Maze_Set_Pause_State(1);
+ if (Game_Flag_Query(16)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(World_Waypoint_Query_X(8), World_Waypoint_Query_Y(8), World_Waypoint_Query_Z(8), 512);
+ } else {
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(World_Waypoint_Query_X(9), World_Waypoint_Query_Y(9), World_Waypoint_Query_Z(9), 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 0, 5, 110, 196, 3);
+}
+
+static int track_data_29[] = {-26, 12, 20, -18, 12, 20, -9, 29, -5, 200, -1, 0, -7, 4000, 10000, -8, 29, -10, 33, 33, -15, 29, 1, -22, 29, -2, 5, -3, 500, -24, 27, 33, -10, 34, 33, -2, 0, -9, 29, -13, 44, 42, -12, 29, -4};
+static int track_data_30[] = {-26, 12, 20, -18, 12, 20, -9, 30, -5, 67, -1, 0, -7, 3000, 9000, -8, 30, -10, 33, 33, -15, 30, 1, -22, 30, -2, 5, -3, 500, -24, 27, 33, -10, 34, 33, -2, 0, -9, 30, -13, 41, 39, -12, 30, -15, 30, 0, -4};
+static int track_data_31[] = {-26, 12, 20, -18, 12, 20, -15, 31, 1, -23, 31, -9, 31, -5, 480, -1, 0, -7, 3000, 10000, -8, 31, -2, 5, -10, 29, 33, -3, 1000, -6, 968, 100, -10, 29, 33, -3, 500, -2, 0, -10, 29, 33, -25, -9, 31, -14, 40, 32, 33, -12, 31, -4};
+static int track_data_32[] = {-26, 12, 20, -18, 12, 20, -9, 32, -5, 1010, -1, 0, -7, 3000, 10000, -8, 32, -10, 33, 33, -15, 32, 1, -22, 32, -2, 5, -3, 500, -24, 27, 33, -6, 498, 80, -10, 29, 33, -3, 500, -2, 0, -9, 32, -14, 33, 31, 40, -12, 32, -4};
+static int track_data_33[] = {-26, 12, 20, -18, 12, 20, -9, 33, -5, 540, -1, 0, -7, 4000, 10000, -8, 33, -15, 33, 1, -23, 33, -2, 5, -10, 29, 33, -3, 1000, -6, 284, 80, -3, 0, -6, 28, 80, -10, 29, 33, -3, 1000, -2, 0, -25, -9, 33, -14, 40, 31, 32, -12, 33, -4};
+static int track_data_34[] = {-26, 12, 20, -18, 12, 20, -9, 34, -9, 35, -9, 36, -5, 469, -1, 0, -15, 34, 1, -15, 35, 1, -15, 36, 1, -7, 3000, 10000, -8, 34, -22, 34, -22, 35, -22, 36, -2, 5, -10, 29, 33, -3, 1000, -6, 376, 80, -3, 0, -6, 168, 80, -10, 29, 33, -2, 9, -6, 33, 80, -3, 0, -6, 15, 80, -10, 29, 33, -3, 500, -24, 27, 33, -2, 5, -10, 29, 33, -6, 168, 80, -3, 0, -6, 376, 80, -3, 0, -6, 469, 80, -10, 29, 33, -3, 500, -15, 34, 1, -15, 35, 1, -15, 36, 1, -22, 34, -22, 35, -22, 36, -6, 376, 80, -3, 0, -6, 168, 80, -2, 9, -6, 33, 80, -3, 0, -6, 15, 80, -10, 29, 33, -3, 500, -24, 27, 33, -2, 5, -10, 29, 33, -3, 0, -6, 469, 80, -3, 500, -6, 198, 80, -10, 29, 33, -3, 0, -2, 19, -10, 29,33, -3, 0, -9, 34, -11, 35, -12, 34, -1, 0, -4};
+static int track_data_35[] = {-8, 35, -5, 198, -1, 0, -6, 469, 80, -2, 9, -3, 0, -9, 35, -11, 36, -12, 35, -5, 198, -8, 35, -1, 0, -4};
+static int track_data_36[] = {-8, 36, -5, 469, -1, 0, -8, 36, -2, 9, -10, 29, 33, -3, 1000, -9, 34, -9, 35, -9, 36, -11, 37, -12, 36, -5, 469, -8, 36, -1, 0, -4};
+static int track_data_37[] = {-26, 12, 20, -18, 12, 20, -9, 37, -7, 3000, 6000, -11, 38, -5, 1010, -1, 0, -3, 2000, -8, 37, -10, 33, 33, -15, 37, 1, -23, 37, -2, 9, -3, 3000, -10, 34, 33, -2, 0, -25, -9, 37, -12, 37, -1, 0, -4};
+static int track_data_38[] = {-9, 38, -5, 990, -1, 0, -3, 3000, -8, 38, -10, 33, 33, -15, 38, 1, -22, 38, -2, 9, -3, 1000, -24, 12, 33, -10, 34, 33, -2, 0, -9, 38, -11, 34, -12, 38, -1, 0, -4};
+static int track_data_39[] = {-26, 12, 20, -18, 12, 20, -9, 39, -5, 513, -1, 0, -7, 5000, 5000, -8, 39, -10, 33, 33, -15, 39, 1, -2, 5, -3, 1000, -22, 39, -6, 1010, 80, -10, 29, 33, -3, 500, -24, 27, 33, -10, 34, 33, -2, 0, -9, 39, -13, 41, 30, -12, 39, -4};
+static int track_data_40[] = {-26, 12, 20, -18, 12, 20, -9, 40, -5, 480, -1, 0, -7, 4000, 8000, -8, 40, -10, 29, 33, -15, 40, 1, -2, 5, -10, 29, 33, -3, 500, -22, 40, -6, 968, 80, -10, 29, 33, -3, 1000, -24, 27, 33, -2, 0, -9, 40, -14, 31, 32, 33, -12, 40, -4};
+static int track_data_41[] = {-26, 12, 20, -18, 12, 20, -9, 41, -5, 513, -1, 0, -7, 4000, 6000, -8, 41, -10, 33, 33, -15, 41, 1, -23, 41, -2, 5, -3, 500, -6, 1010, 80, -10, 29, 33, -3, 1000, -2, 0, -10, 34, 33, -25, -9, 41, -13, 39, 30, -12, 41, -4};
+static int track_data_42[] = {-9, 42, -5, 109, -1, 0, -7, 2000, 5000, -8, 42, -10, 29, 33, -15, 42, 1, -22, 42, -2, 5, -10, 29, 33, -3, 1000, -24, 27, 33, -2, 0, -9, 42, -13, 44, 29, -12, 42, -4};
+static int track_data_43[] = {-26, 12, 20, -18, 12, 20, -9, 43, -5, 540, -1, 0, -7, 5000, 7000, -8, 43, -10, 33, 33, -15, 43, 1, -23, 43, -2, 9, -3, 2000, -6, 284, 80, -3, 0, -6, 28, 80, -10, 29, 33, -3, 2000, -10, 34, 33, -2, 0, -25, -9, 43, -11, 45, -12, 43, -4};
+static int track_data_44[] = {-26, 12, 20, -18, 12, 20, -9, 44, -5, 109, -1, 0, -7, 5000, 5000, -8, 44, -10, 29, 33, -15, 44, 1, -23, 44, -2, 5, -7, 2000, 2000, -10, 29, 33, -2, 0, -25, -9, 44, -13, 42, 29, -12, 44, -4};
+static int track_data_45[] = {-26, 12, 20, -18, 12, 20, -9, 45, -5, 540, -1, 0, -7, 3000, 10000, -8, 45, -10, 33, 33, -15, 45, 1, -2, 9, -3, 1000, -22, 45, -6, 284, 80, -3, 0, -6, 28, 80, -3, 1000, -24, 27, 33, -10, 34, 33, -2, 0, -9, 45, -11, 43, -12, 45, -4};
+
+void ScriptPS12::SceneLoaded() {
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("PARKMETR03", true);
+ Obstacle_Object("PARKMETR07", true);
+ Obstacle_Object("PARKMETR08", true);
+ Obstacle_Object("PARKMETR10", true);
+ Obstacle_Object("PARKMETR11", true);
+ Obstacle_Object("PARKMETR15", true);
+ Obstacle_Object("PARKMETR16", true);
+ Unclickable_Object("PARKMETR01");
+ Unclickable_Object("PARKMETR02");
+ Unclickable_Object("PARKMETR03");
+ Unclickable_Object("PARKMETR07");
+ Unclickable_Object("PARKMETR08");
+ Unclickable_Object("PARKMETR10");
+ Unclickable_Object("PARKMETR11");
+ Unclickable_Object("PARKMETR15");
+ Unclickable_Object("PARKMETR16");
+ if (!Query_System_Currently_Loading_Game()) {
+ Item_Add_To_World(29, 449, 14, -691.8f, -9.06f, 587.67f, 200, 72, 36, true, false, false, true);
+ Item_Add_To_World(30, 445, 14, -679.6f, -45.4f, 721.05f, 67, 72, 36, true, false, false, true);
+ Item_Add_To_World(31, 447, 14, -414.04f, -8.98f, 711.91f, 480, 72, 36, true, false, false, true);
+ Item_Add_To_World(32, 443, 14, -440.0f, -8.97f, 1137.0f, 1010, 72, 36, true, false, false, true);
+ Item_Add_To_World(33, 441, 14, -764.92f, -0.84f, 950.22f, 540, 72, 36, true, false, false, true);
+ Item_Add_To_World(34, 449, 14, -696.0f, -5.7f, 1185.0f, 469, 72, 36, true, false, false, true);
+ Item_Add_To_World(35, 449, 14, -635.0f, -5.7f, 1165.0f, 198, 72, 36, true, false, false, true);
+ Item_Add_To_World(36, 449, 14, -620.0f, -8.63f, 1366.0f, 469, 72, 36, true, false, false, true);
+ Item_Add_To_World(37, 447, 14, -584.0f, -79.4f, 775.0f, 1010, 72, 36, true, false, false, true);
+ Item_Add_To_World(38, 445, 14, -578.0f, -79.4f, 810.0f, 990, 72, 36, true, false, false, true);
+ Item_Add_To_World(39, 443, 14, -400.0f, -12.0f, 1110.0f, 513, 72, 36, true, false, false, true);
+ Item_Add_To_World(40, 449, 14, -414.04f, -8.98f, 711.91f, 480, 72, 36, true, false, false, true);
+ Item_Add_To_World(41, 447, 14, -400.0f, -12.0f, 1110.0f, 513, 72, 36, true, false, false, true);
+ Item_Add_To_World(42, 449, 14, -731.0f, 93.66f, 788.0f, 109, 72, 36, true, false, false, true);
+ Item_Add_To_World(43, 441, 14, -580.0f, -80.0f, 925.0f, 540, 72, 36, true, false, false, true);
+ Item_Add_To_World(44, 441, 14, -731.0f, 93.66f, 788.0f, 109, 72, 36, true, false, false, true);
+ Item_Add_To_World(45, 443, 14, -580.0f, -80.0f, 925.0f, 540, 72, 36, true, false, false, true);
+ }
+ Police_Maze_Target_Track_Add(29, -691.8f, -9.06f, 587.67f, -649.11f, -9.06f, 587.71f, 6, track_data_29, true);
+ Police_Maze_Target_Track_Add(30, -679.6f, -45.4f, 721.05f, -679.6f, -1.4f, 721.05f, 6, track_data_30, true);
+ Police_Maze_Target_Track_Add(31, -414.04f, -8.98f, 711.917f, -459.54f, -8.99f, 707.81f, 6, track_data_31, false);
+ Police_Maze_Target_Track_Add(32, -440.0f, -8.97f, 1137.0f, -430.0f, -8.97f, 921.0f, 6, track_data_32, false);
+ Police_Maze_Target_Track_Add(33, -764.92f, -0.84f, 950.21997f, -722.92f, -0.84f, 950.22f, 6, track_data_33, false);
+ Police_Maze_Target_Track_Add(34, -696.0f, -5.7f, 1185.0f, -635.0f, -5.7f, 1185.0f, 20, track_data_34, false);
+ Police_Maze_Target_Track_Add(35, -635.0f, -5.7f, 1165.0f, -620.0f, -8.63f, 1366.0f, 10, track_data_35, false);
+ Police_Maze_Target_Track_Add(36, -620.0f, -8.63f, 1366.0f, -595.0f, -8.63f, 1366.0f, 10, track_data_36, false);
+ Police_Maze_Target_Track_Add(37, -584.0f, -79.4f, 775.0f, -584.0f, -27.4f, 775.0f, 10, track_data_37, true);
+ Police_Maze_Target_Track_Add(38, -578.0f, -79.4f, 810.0f, -578.0f, -27.4f, 810.0f, 10, track_data_38, false);
+ Police_Maze_Target_Track_Add(39, -400.0f, -12.0f, 1110.0f, -400.0f, 60.0f, 1110.0f, 6, track_data_39, false);
+ Police_Maze_Target_Track_Add(40, -414.04f, -8.98f, 711.91f, -459.54f, -8.99f, 707.81f, 6, track_data_40, true);
+ Police_Maze_Target_Track_Add(41, -400.0f, -12.0f, 1110.0f, -400.0f, 60.0f, 1110.0f, 6, track_data_41, false);
+ Police_Maze_Target_Track_Add(42, -731.0f, 93.66f, 788.0f, -702.0f, 93.66f, 788.0f, 6, track_data_42, false);
+ Police_Maze_Target_Track_Add(43, -580.0f, -80.0f, 925.0f, -580.0f, -8.0f, 925.0f, 10, track_data_43, true);
+ Police_Maze_Target_Track_Add(44, -731.0f, 93.66f, 788.0f, -702.0f, 93.66f, 788.0f, 6, track_data_44, false);
+ Police_Maze_Target_Track_Add(45, -580.0f, -80.0f, 925.0f, -580.0f, -8.0f, 925.0f, 10, track_data_45, false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(387, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(1, 10, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(389, 5, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(390, 6, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+}
+
+bool ScriptPS12::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS12::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS12::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS12::ClickedOnItem(int itemId, bool a2) {
+ if (Player_Query_Combat_Mode()) {
+ switch (itemId) {
+ case 31:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 37:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 41:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 33:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ case 43:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ case 44:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ default:
+ Sound_Play(2, 12, 0, 0, 50);
+ break;
+ }
+ Item_Spin_In_World(itemId);
+ Item_Flag_As_Non_Target(itemId);
+ if (itemId == 29) {
+ Item_Flag_As_Non_Target(29);
+ }
+ if (itemId == 30) {
+ Item_Flag_As_Non_Target(30);
+ }
+ if (itemId == 31) {
+ Item_Flag_As_Non_Target(31);
+ }
+ if (itemId == 32) {
+ Item_Flag_As_Non_Target(32);
+ }
+ if (itemId == 33) {
+ Item_Flag_As_Non_Target(33);
+ }
+ if (itemId == 34) {
+ Item_Flag_As_Non_Target(34);
+ Item_Flag_As_Non_Target(35);
+ Item_Flag_As_Non_Target(36);
+ }
+ if (itemId == 35) {
+ Item_Flag_As_Non_Target(34);
+ Item_Flag_As_Non_Target(35);
+ Item_Flag_As_Non_Target(36);
+ }
+ if (itemId == 36) {
+ Item_Flag_As_Non_Target(34);
+ Item_Flag_As_Non_Target(35);
+ Item_Flag_As_Non_Target(36);
+ }
+ if (itemId == 37) {
+ Item_Flag_As_Non_Target(37);
+ }
+ if (itemId == 38) {
+ Item_Flag_As_Non_Target(38);
+ }
+ if (itemId == 39) {
+ Item_Flag_As_Non_Target(39);
+ }
+ if (itemId == 40) {
+ Item_Flag_As_Non_Target(40);
+ }
+ if (itemId == 41) {
+ Item_Flag_As_Non_Target(41);
+ }
+ if (itemId == 42) {
+ Item_Flag_As_Non_Target(42);
+ }
+ if (itemId == 43) {
+ Item_Flag_As_Non_Target(43);
+ }
+ if (itemId == 44) {
+ Item_Flag_As_Non_Target(44);
+ }
+ if (itemId == 45) {
+ Item_Flag_As_Non_Target(45);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS12::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 8, 12, 1, false)) {
+ Game_Flag_Set(17);
+ sub_4028C4();
+ Set_Enter(14, 74);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 9, 12, 1, false)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_Waypoint(0, 10, 12, 0, false);
+ Player_Gains_Control();
+ Game_Flag_Set(18);
+ sub_4028C4();
+ Global_Variable_Decrement(9, 20 - Global_Variable_Query(12));
+ Global_Variable_Set(12, 20);
+ Set_Enter(14, 76);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS12::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS12::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS12::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS12::PlayerWalkedIn() {
+ if (Game_Flag_Query(16)) {
+ Loop_Actor_Walk_To_XYZ(0, -546.0f, -9.06f, 570.0f, 0, 1, false, 0);
+ Game_Flag_Reset(16);
+ }
+ Police_Maze_Set_Pause_State(0);
+}
+
+void ScriptPS12::PlayerWalkedOut() {
+}
+
+void ScriptPS12::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS12::sub_4028C4() {
+ Item_Remove_From_World(29);
+ Item_Remove_From_World(30);
+ Item_Remove_From_World(31);
+ Item_Remove_From_World(32);
+ Item_Remove_From_World(33);
+ Item_Remove_From_World(34);
+ Item_Remove_From_World(35);
+ Item_Remove_From_World(36);
+ Item_Remove_From_World(37);
+ Item_Remove_From_World(38);
+ Item_Remove_From_World(39);
+ Item_Remove_From_World(40);
+ Item_Remove_From_World(41);
+ Item_Remove_From_World(42);
+ Item_Remove_From_World(43);
+ Item_Remove_From_World(44);
+ Item_Remove_From_World(45);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps13.cpp b/engines/bladerunner/script/ps13.cpp
new file mode 100644
index 0000000000..5b5ac20eb8
--- /dev/null
+++ b/engines/bladerunner/script/ps13.cpp
@@ -0,0 +1,285 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS13::InitializeScene() {
+ Police_Maze_Set_Pause_State(1);
+ if (Game_Flag_Query(18)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Reset(18);
+ Setup_Scene_Information(World_Waypoint_Query_X(10), World_Waypoint_Query_Y(10), World_Waypoint_Query_Z(10), 200);
+ } else {
+ Scene_Loop_Set_Default(1);
+ Setup_Scene_Information(World_Waypoint_Query_X(11), World_Waypoint_Query_Y(11), World_Waypoint_Query_Z(11), 840);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 20, 479, 3);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(387, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(1, 10, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(389, 5, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(390, 6, 50, 16, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(443, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(444, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(445, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(446, 2, 100, 14, 16, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 100, 17, 27, -100, 100, -101, -101, 0, 0);
+}
+
+static int track_data_46[] = {-26, 13, 20, -18, 13, 20, -9, 46, -5, 960, -1, 0, -3, 2000, -8, 46, -10, 33, 33, -15, 46, 1, -22, 46, -3, 1000, -2, 5, -3, 500, -24, 27, 33, -3, 500, -2, 0, -9, 46, -13, 62, 63, -12, 46, -4};
+static int track_data_47[] = {-26, 13, 20, -18, 13, 20, -9, 47, -5, 823, -1, 0, -7, 5000, 5000, -8, 47, -10, 33, 33, -15, 47, 1, -22, 47, -2, 9, -3, 2000, -24, 27, 33, -2, 0, -9, 47, -13, 50, 52, -12, 47, -4};
+static int track_data_48[] = {-26, 13, 20, -18, 13, 20, -9, 48, -5, 823, -1, 0, -7, 2000, 2000, -8, 48, -10, 33, 33, -15, 48, 1, -23, 48, -2, 9, -3, 2000, -25, -2, 0, -9, 48, -13, 53, 51, -12, 48, -4};
+static int track_data_49[] = {-26, 13, 20, -18, 13, 20, -9, 49, -5, 922, -1, 0, -7, 3000, 3000, -8, 49, -10, 33, 33, -15, 49, 1, -22, 49, -2, 9, -3, 1000, -24, 27, 33, -2, 0, -9, 49, -13, 54, 55, -12, 49, -1, 0, -4};
+static int track_data_50[] = {-26, 13, 20, -18, 13, 20, -9, 50, -5, 823, -1, 0, -7, 3000, 5000, -8, 50, -10, 33, 33, -15, 50, 1, -23, 50, -2, 9, -3, 2000, -2, 0, -25, -9, 50, -13, 47, 52, -12, 50, -4};
+static int track_data_51[] = {-26, 13, 20, -18, 13, 20, -9, 51, -5, 823, -1, 0, -7, 2000, 2000, -8, 51, -10, 33, 33, -15, 51, 1, -22, 51, -2, 9, -3, 1000, -24, 27, 33, -3, 500, -2, 0, -9, 51, -13, 53, 48, -12, 51, -4};
+static int track_data_52[] = {-26, 13, 20, -18, 13, 20, -9, 52, -5, 305, -1, 0, -7, 5000, 10000, -8, 52, -10, 33, 33, -15, 52, 1, -23, 52, -2, 9, -3, 500, -22, 52, -6, 555, 80, -3, 0, -6, 833, 80, -3, 1000, -24, 27, 33, -2, 0, -9, 52, -13, 47, 50, -12, 52, -4};
+static int track_data_53[] = {-26, 13, 20, -18, 13, 20, -9, 53, -5, 356, -1, 0, -7, 3000, 3000, -8, 53, -10, 33, 33, -15, 53, 1, -23, 53, -2, 5, -22, 53, -6, 868, 200, -3, 1000, -24, 27, 33, -6, 356, 60, -3, 1000, -2, 0, -9, 53, -13, 48, 51, -12, 53, -4};
+static int track_data_54[] = {-26, 13, 20, -18, 13, 20, -9, 54, -5, 512, -1, 0, -7, 10000, 20000, -8, 54, -10, 33, 33, -15, 54, 1, -23, 54, -2, 3, -3, 500, -22, 54, -6, 768, 80, -3, 1000, -24, 27, 33, -2, 0, -9, 54, -13, 58, 55, -12, 54, -4};
+static int track_data_55[] = {-26, 13, 20, -18, 13, 20, -9, 55, -9, 56, -9, 57, -15, 55, 1, -15, 56, 1, -15, 57, 1, -5, 327, -1, 0, -7, 1000, 1000, -10, 33, 33, -23, 55, -8, 55, -2, 14, -3, 1000, -11, 56, -9, 55, -8, 56, -12, 55, -1, 0, -4};
+static int track_data_56[] = {-5, 327, -1, 0, -8, 56, -23, 56, -2, 14, -3, 1000, -11, 57, -9, 56, -8, 57, -12, 56, -1, 0, -4};
+static int track_data_57[] = {-22, 57, -5, 327, -1, 0, -8, 57, -6, 516, 80, -3, 0, -6, 843, 80, -3, 1000, -24, 27, 33, -3, 500, -2, 14, -9, 57, -13, 58, 54, -12, 57, -1, 0, -4};
+static int track_data_58[] = {-26, 13, 20, -18, 13, 20, -9, 58, -5, 922, -1, 0, -7, 3000, 3000, -8, 58, -10, 33, 33, -15, 58, 1, -23, 58, -2, 9, -3, 200, -2, 0, -25, -15, 58, 1, -23, 58, -3, 200, -2, 9, -3, 200, -2, 0, -25, -9, 58, -11, 49, -12, 58, -1, 0, -4};
+static int track_data_62[] = {-26, 13, 20, -18, 13, 20, -9, 62, -5, 465, -1, 0, -7, 3000, 3000, -8, 62, -10, 33, 33, -15, 62, 1, -23, 62, -2, 14, -3, 1000, -22, 62, -6, 650, 80, -3, 0, -6, 937, 80, -3, 1000, -24, 27, 33, -3, 500, -6, 650, 80, -3, 0, -6, 465, 80, -2, 0, -9, 62, -13, 46, 63, -12, 62, -4};
+static int track_data_63[] = {-26, 13, 20, -18, 13, 20, -9, 63, -5, 465, -1, 0, -3, 3000, -8, 63, -10, 33, 33, -15, 63, 1, -23, 63, -2, 9, -3, 1000, -22, 63, -6, 710, 80, -3, 0, -6, 960, 80, -3, 1000, -24, 27, 33, -3, 500, -6, 710, 80, -3, 0, -6, 460, 80, -2, 0, -9, 63, -13, 46, 62, -12, 63, -4};
+
+void ScriptPS13::SceneLoaded() {
+ Obstacle_Object("PARKMETR01", true);
+ Obstacle_Object("PARKMETR02", true);
+ Obstacle_Object("PARKMETR03", true);
+ Obstacle_Object("PARKMETR07", true);
+ Obstacle_Object("PARKMETR08", true);
+ Obstacle_Object("PARKMETR10", true);
+ Obstacle_Object("PARKMETR11", true);
+ Obstacle_Object("PARKMETR15", true);
+ Obstacle_Object("PARKMETR16", true);
+ Unclickable_Object("PARKMETR01");
+ Unclickable_Object("PARKMETR02");
+ Unclickable_Object("PARKMETR03");
+ Unclickable_Object("PARKMETR07");
+ Unclickable_Object("PARKMETR08");
+ Unclickable_Object("PARKMETR10");
+ Unclickable_Object("PARKMETR11");
+ Unclickable_Object("PARKMETR15");
+ Unclickable_Object("PARKMETR16");
+ if (!Query_System_Currently_Loading_Game()) {
+ Item_Add_To_World(46, 443, 14, -372.0f, -9.0f, 1509.0f, 960, 72, 36, true, false, false, true);
+ Item_Add_To_World(47, 443, 14, 291.61f, -0.66f, 1610.3f, 823, 72, 36, true, false, false, true);
+ Item_Add_To_World(48, 447, 14, -25.0f, 102.0f, 1625.0f, 823, 72, 36, true, false, false, true);
+ Item_Add_To_World(49, 449, 14, -45.51f, -8.8f, 1676.0f, 922, 72, 36, true, false, false, true);
+ Item_Add_To_World(50, 447, 14, 291.61f, -0.66f, 1610.3f, 823, 72, 36, true, false, false, true);
+ Item_Add_To_World(51, 443, 14, -24.0f, 102.0f, 1625.0f, 823, 72, 36, true, false, false, true);
+ Item_Add_To_World(52, 449, 14, 180.0f, -72.7f, 1605.0f, 305, 72, 36, true, false, false, true);
+ Item_Add_To_World(53, 443, 14, 127.79f, 14.56f, 1703.03f, 356, 72, 36, true, false, false, true);
+ Item_Add_To_World(54, 443, 14, 136.37f, -6.84f, 1425.4301f, 512, 72, 36, true, false, false, true);
+ Item_Add_To_World(55, 441, 14, 77.83f, -79.8f, 1520.5f, 327, 72, 36, true, false, false, true);
+ Item_Add_To_World(56, 441, 14, 77.83f, -7.8f, 1520.5f, 327, 72, 36, true, false, false, true);
+ Item_Add_To_World(57, 443, 14, -88.0f, -8.8f, 1520.5f, 327, 72, 36, true, false, false, true);
+ Item_Add_To_World(58, 447, 14, -45.51f, -8.8f, 1676.0f, 922, 72, 36, true, false, false, true);
+ Item_Add_To_World(62, 445, 14, -300.0f, -79.75f, 1543.0f, 465, 72, 36, true, false, false, true);
+ Item_Add_To_World(63, 449, 14, -325.0f, -7.75f, 1543.0f, 465, 72, 36, true, false, false, true);
+ }
+ Police_Maze_Target_Track_Add(46, -372.0f, -9.0f, 1509.0f, -345.0f, -9.0f, 1509.0f, 6, track_data_46, true);
+ Police_Maze_Target_Track_Add(47, 291.61f, -0.66f, 1610.3f, 238.83f, 1.03f, 1557.03f, 10, track_data_47, true);
+ Police_Maze_Target_Track_Add(48, -25.0f, 102.0f, 1625.0f, -25.0f, 138.0f, 1625.0f, 10, track_data_48, true);
+ Police_Maze_Target_Track_Add(49, -45.51f, -8.8f, 1676.0f, 15.51f, -8.8f, 1679.0f, 10, track_data_49, false);
+ Police_Maze_Target_Track_Add(50, 291.61f, -0.66f, 1610.3f, 238.83f, 1.03f, 1557.03f, 10, track_data_50, false);
+ Police_Maze_Target_Track_Add(51, -24.0f, 102.0f, 1625.0f, -24.0f, 138.0f, 1625.0f, 10, track_data_51, false);
+ Police_Maze_Target_Track_Add(52, 180.0f, -72.7f, 1605.0f, 180.0f, -0.7f, 1605.0f, 10, track_data_52, false);
+ Police_Maze_Target_Track_Add(53, 127.79f, 14.56f, 1703.03f, -56.07f, 1.89f, 1589.04f, 6, track_data_53, false);
+ Police_Maze_Target_Track_Add(54, 136.37f, -6.84f, 1425.4301f, 117.55f, -6.84f, 1442.09f, 4, track_data_54, false);
+ Police_Maze_Target_Track_Add(55, 77.83f, -79.8f, 1520.5f, 77.83f, -7.8f, 1520.5f, 15, track_data_55, false);
+ Police_Maze_Target_Track_Add(56, 77.83f, -7.8f, 1520.5f, -88.0f, -8.8f, 1520.5f, 15, track_data_56, false);
+ Police_Maze_Target_Track_Add(57, -88.0f, -8.8f, 1520.5f, -88.0f, -80.8f, 1520.5f, 15, track_data_57, false);
+ Police_Maze_Target_Track_Add(58, -45.51f, -8.8f, 1676.0f, 15.51f, -8.8f, 1679.0f, 10, track_data_58, true);
+ Police_Maze_Target_Track_Add(62, -300.0f, -79.75f, 1543.0f, -300.0f, -14.75f, 1543.0f, 15, track_data_62, false);
+ Police_Maze_Target_Track_Add(63, -325.0f, -7.75f, 1543.0f, -300.0f, -7.75f, 1543.0f, 10, track_data_63, false);
+}
+
+bool ScriptPS13::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS13::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS13::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS13::ClickedOnItem(int itemId, bool a2) {
+ if (Player_Query_Combat_Mode()) {
+ switch (itemId) {
+ case 48:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 50:
+ Sound_Play(4, 50, 0, 0, 50);
+ break;
+ case 55:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ case 56:
+ Sound_Play(555, 50, 0, 0, 50);
+ break;
+ default:
+ Sound_Play(2, 12, 0, 0, 50);
+ break;
+ }
+ Item_Spin_In_World(itemId);
+ Item_Flag_As_Non_Target(itemId);
+ if (itemId == 46) {
+ Item_Flag_As_Non_Target(46);
+ }
+ if (itemId == 47) {
+ Item_Flag_As_Non_Target(47);
+ }
+ if (itemId == 48) {
+ Item_Flag_As_Non_Target(48);
+ }
+ if (itemId == 49) {
+ Item_Flag_As_Non_Target(49);
+ }
+ if (itemId == 50) {
+ Item_Flag_As_Non_Target(50);
+ }
+ if (itemId == 51) {
+ Item_Flag_As_Non_Target(51);
+ }
+ if (itemId == 52) {
+ Item_Flag_As_Non_Target(52);
+ }
+ if (itemId == 53) {
+ Item_Flag_As_Non_Target(53);
+ }
+ if (itemId == 54) {
+ Item_Flag_As_Non_Target(54);
+ }
+ if (itemId == 55) {
+ Item_Flag_As_Non_Target(55);
+ Item_Flag_As_Non_Target(56);
+ Item_Flag_As_Non_Target(57);
+ }
+ if (itemId == 56) {
+ Item_Flag_As_Non_Target(55);
+ Item_Flag_As_Non_Target(56);
+ Item_Flag_As_Non_Target(57);
+ }
+ if (itemId == 57) {
+ Item_Flag_As_Non_Target(55);
+ Item_Flag_As_Non_Target(56);
+ Item_Flag_As_Non_Target(57);
+ }
+ if (itemId == 58) {
+ Item_Flag_As_Non_Target(58);
+ }
+ if (itemId == 62) {
+ Item_Flag_As_Non_Target(62);
+ }
+ if (itemId == 63) {
+ Item_Flag_As_Non_Target(63);
+ }
+ return true;
+ }
+ return false;
+
+}
+
+bool ScriptPS13::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 10, 12, 1, false)) {
+ Game_Flag_Set(19);
+ sub_40267C();
+ Set_Enter(14, 75);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_Waypoint(0, 11, 12, 1, false)) {
+ Game_Flag_Set(21);
+ Player_Set_Combat_Mode(false);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ sub_40267C();
+ Global_Variable_Decrement(9, 20 - Global_Variable_Query(13));
+ Set_Score(0, Global_Variable_Query(9));
+ Global_Variable_Reset(10);
+ Global_Variable_Reset(11);
+ Global_Variable_Reset(12);
+ Global_Variable_Reset(13);
+ Global_Variable_Reset(9);
+ Set_Enter(15, 69);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS13::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS13::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS13::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS13::PlayerWalkedIn() {
+ Police_Maze_Set_Pause_State(0);
+}
+
+void ScriptPS13::PlayerWalkedOut() {
+}
+
+void ScriptPS13::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptPS13::sub_40267C() {
+ Item_Remove_From_World(46);
+ Item_Remove_From_World(47);
+ Item_Remove_From_World(48);
+ Item_Remove_From_World(49);
+ Item_Remove_From_World(50);
+ Item_Remove_From_World(51);
+ Item_Remove_From_World(52);
+ Item_Remove_From_World(53);
+ Item_Remove_From_World(54);
+ Item_Remove_From_World(55);
+ Item_Remove_From_World(56);
+ Item_Remove_From_World(57);
+ Item_Remove_From_World(58);
+ Item_Remove_From_World(62);
+ Item_Remove_From_World(63);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps14.cpp b/engines/bladerunner/script/ps14.cpp
new file mode 100644
index 0000000000..e68460252f
--- /dev/null
+++ b/engines/bladerunner/script/ps14.cpp
@@ -0,0 +1,127 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS14::InitializeScene() {
+ if (Game_Flag_Query(134)) {
+ Setup_Scene_Information(-1119.61f, 508.14f, -1208.22f, 315);
+ Game_Flag_Reset(134);
+ } else {
+ Setup_Scene_Information(-785.45f, 508.14f, -1652.0f, 315);
+ }
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 46, 51, 125, 192, 0);
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(374, 100, 300, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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);
+}
+
+void ScriptPS14::SceneLoaded() {
+ Obstacle_Object("CABLES UPPER RIGHT", true);
+ Unobstacle_Object("CYLINDER63", true);
+ Clickable_Object("CABLES UPPER RIGHT");
+ Unclickable_Object("CABLES UPPER RIGHT");
+}
+
+bool ScriptPS14::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS14::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS14::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptPS14::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptPS14::ClickedOnExit(int exitId) {
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -2101.0f, 508.14f, -1361.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 819, false);
+ Loop_Actor_Travel_Stairs(0, 3, 1, 0);
+ if (Global_Variable_Query(1) == 4 && Game_Flag_Query(671)) {
+ if (Actor_Clue_Query(0, 32)) {
+ Game_Flag_Set(666);
+ Actor_Set_Goal_Number(0, 400);
+ } else {
+ Actor_Set_Goal_Number(0, 500);
+ }
+ } else if (Global_Variable_Query(1) > 3) {
+ Actor_Says(0, 8522, 12);
+ Actor_Face_Heading(0, 307, false);
+ Loop_Actor_Travel_Stairs(0, 3, 0, 0);
+ } else {
+ Game_Flag_Set(135);
+ Set_Enter(63, 67);
+ }
+ }
+ return true;
+ }
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -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, 53);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS14::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS14::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptPS14::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS14::PlayerWalkedIn() {
+ if (Game_Flag_Query(672)) {
+ Loop_Actor_Walk_To_XYZ(0, -801.45f, 508.14f, -1596.68f, 0, 0, false, 0);
+ Game_Flag_Reset(672);
+ }
+ //return false;
+}
+
+void ScriptPS14::PlayerWalkedOut() {
+}
+
+void ScriptPS14::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ps15.cpp b/engines/bladerunner/script/ps15.cpp
new file mode 100644
index 0000000000..464efe9406
--- /dev/null
+++ b/engines/bladerunner/script/ps15.cpp
@@ -0,0 +1,175 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptPS15::InitializeScene() {
+ Setup_Scene_Information(-360.0f, -113.43f, 50.0f, 0);
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 20, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 620, 0, 639, 479, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 20, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(141, 80, 0, 1);
+ Ambient_Sounds_Add_Sound(385, 5, 50, 8, 8, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(156, 5, 20, 30, 30, -70, 70, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(157, 5, 20, 30, 30, -70, 70, -101, -101, 0, 0);
+ 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(34, 101);
+ Actor_Set_At_XYZ(34, -265.4f, -113.43f, -31.29f, 623);
+}
+
+void ScriptPS15::SceneLoaded() {
+ Obstacle_Object("E.ARCH", true);
+ if (Global_Variable_Query(1) == 2) {
+ Item_Add_To_World(110, 983, 101, -208.0f, -113.43f, 30.28f, 750, 16, 12, false, true, false, true);
+ }
+}
+
+bool ScriptPS15::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptPS15::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptPS15::ClickedOnActor(int actorId) {
+ if (actorId == 34) {
+ if (Actor_Clue_Query(0, 80) || Actor_Clue_Query(0, 83) && !Actor_Clue_Query(0, 81)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -256.0f, -113.43f, 43.51f, 0, 1, false, 0)) {
+ Actor_Face_Actor(0, 34, true);
+ Actor_Face_Actor(34, 0, true);
+ Actor_Says(0, 4470, 17);
+ Actor_Says(34, 130, 12);
+ Actor_Says(0, 4475, 18);
+ Actor_Says(0, 4480, 13);
+ Actor_Says(34, 140, 16);
+ Item_Pickup_Spin_Effect(965, 211, 239);
+ Actor_Says(34, 150, 14);
+ Actor_Clue_Acquire(0, 81, 1, 34);
+ if (!Game_Flag_Query(727)) {
+ Item_Remove_From_World(111);
+ }
+ }
+ } else {
+ Actor_Face_Actor(0, 34, true);
+ Actor_Says(0, 8600, 15);
+ Actor_Says(34, 190, 12);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS15::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 110) {
+ if (Actor_Clue_Query(0, 80) && Actor_Clue_Query(0, 83)) {
+ Actor_Says(0, 8570, 14);
+ } else {
+ Actor_Face_Actor(0, 34, true);
+ Actor_Face_Actor(34, 0, true);
+ Actor_Says(0, 4485, 17);
+ Actor_Says(34, 160, 14);
+ Actor_Says(0, 4490, 12);
+ Actor_Says(34, 170, 13);
+ Actor_Clue_Acquire(0, 80, 1, 0);
+ Actor_Clue_Acquire(0, 83, 1, 0);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS15::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -360.0f, -113.43f, 50.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(204);
+ Set_Enter(15, 69);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -183.58f, -113.43f, 91.7f, 0, 1, false, 0)) {
+ Actor_Says(0, 4440, 18);
+ Actor_Says(34, 150, 17);
+ Sound_Play(155, 90, 0, 0, 50);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(14, 73);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptPS15::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptPS15::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptPS15::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptPS15::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, -326.93f, -113.43f, 101.42f, 0, 0, false, 0);
+ if (!Game_Flag_Query(43)) {
+ Actor_Face_Actor(0, 34, true);
+ Actor_Face_Actor(34, 0, true);
+ Actor_Says(34, 0, 12);
+ Actor_Says(0, 4445, 18);
+ Actor_Says(34, 10, 12);
+ Actor_Says(0, 4450, 18);
+ Actor_Says(34, 60, 13);
+ Actor_Says(34, 70, 12);
+ Actor_Says(0, 4460, 15);
+ Actor_Says(34, 80, 13);
+ Actor_Says(0, 4465, 16);
+ Actor_Says(34, 90, 13);
+ Actor_Says(34, 100, 14);
+ Actor_Says(34, 110, 15);
+ Actor_Says(34, 120, 15);
+ Actor_Says(0, 4555, 14);
+ Game_Flag_Set(43);
+ //return true;
+ return;
+ } else {
+ //return false;
+ return;
+ }
+}
+
+void ScriptPS15::PlayerWalkedOut() {
+
+}
+
+void ScriptPS15::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/rc01.cpp b/engines/bladerunner/script/rc01.cpp
index fa1e42de2e..7b00b5f550 100644
--- a/engines/bladerunner/script/rc01.cpp
+++ b/engines/bladerunner/script/rc01.cpp
@@ -22,42 +22,38 @@
#include "bladerunner/script/script.h"
-#include "bladerunner/ambient_sounds.h"
-#include "bladerunner/audio_player.h"
-#include "bladerunner/bladerunner.h"
-
-#include "common/debug.h"
-
namespace BladeRunner {
void ScriptRC01::InitializeScene() {
- // Game_Flag_Set(24);
+ //TODO: not part of game, remove
+ Game_Flag_Set(24); // force skip intro
+ // Game_Flag_Set(9); // Force flag 9 so McCoy will be in view
+
if (!Game_Flag_Query(24)) {
Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
Ambient_Sounds_Remove_All_Looping_Sounds(1);
- Outtake_Play(28, 1); // WSTLGO_E.VQA
- Outtake_Play(41, 1); // BRLOGO_E.VQA
- Outtake_Play( 0, 0); // INTRO_E.VQA
- Outtake_Play(33, 1); // DSCENT_E.VQA
+ Outtake_Play(28, 1, -1); // WSTLGO_E.VQA
+ Outtake_Play(41, 1, -1); // BRLOGO_E.VQA
+ Outtake_Play(0, 0, -1); // INTRO_E.VQA
+ Outtake_Play(33, 1, -1); // DSCENT_E.VQA
}
-
- // Game_Flag_Set(9); // Force flag 9 so McCoy will be in view
if (Game_Flag_Query(9)) {
- Setup_Scene_Information(-171.16, 5.55, 27.28, 616);
+ Setup_Scene_Information(-171.16f, 5.55f, 27.28f, 616);
} else if (Game_Flag_Query(114)) {
- Setup_Scene_Information(-471.98, -0.30, 258.15, 616);
+ Setup_Scene_Information(-471.98f, -0.30f, 258.15f, 616);
} else {
- Setup_Scene_Information( -10.98, -0.30, 318.15, 616);
+ Setup_Scene_Information(-10.98f, -0.30f, 318.15f, 616);
}
- // Setup_Scene_Information(-151.98, -0.30, 318.15, 616);
-
Scene_Exit_Add_2D_Exit(0, 314, 145, 340, 255, 0);
- if (Game_Flag_Query(249))
+ if (Game_Flag_Query(249)) {
Scene_Exit_Add_2D_Exit(1, 482, 226, 639, 280, 2);
- if (Global_Variable_Query(1) > 1 && Game_Flag_Query(710))
+ }
+ if (Global_Variable_Query(1) > 1 && Game_Flag_Query(710)) {
Scene_Exit_Add_2D_Exit(2, 0, 0, 10, 479, 3);
- if (!Game_Flag_Query(186))
+ }
+ if (!Game_Flag_Query(186)) {
Scene_2D_Region_Add(0, 0, 294, 296, 479);
+ }
Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
Ambient_Sounds_Add_Looping_Sound(54, 30, 0, 1); // CTRAIN1.AUD
@@ -80,22 +76,25 @@ void ScriptRC01::InitializeScene() {
}
Ambient_Sounds_Add_Looping_Sound(81, 60, 100, 1); // RCAMBR1.AUD
- Ambient_Sounds_Add_Sound(82, 5, 30, 30, 50, -100, 100, -101, -101, 0, 0); // RCCARBY1.AUD
- Ambient_Sounds_Add_Sound(83, 5, 30, 30, 55, -100, 100, -101, -101, 0, 0); // RCCARBY2.AUD
- Ambient_Sounds_Add_Sound(84, 5, 30, 30, 50, -100, 100, -101, -101, 0, 0); // RCCARBY3.AUD
+ Ambient_Sounds_Add_Sound(82, 5, 30, 30, 50, -100, 100, -101, -101, 0, 0); // RCCARBY1.AUD
+ Ambient_Sounds_Add_Sound(83, 5, 30, 30, 55, -100, 100, -101, -101, 0, 0); // RCCARBY2.AUD
+ Ambient_Sounds_Add_Sound(84, 5, 30, 30, 50, -100, 100, -101, -101, 0, 0); // RCCARBY3.AUD
Ambient_Sounds_Add_Sound(67, 10, 50, 30, 50, -100, 100, -101, -101, 0, 0); // SPIN2A.AUD
Ambient_Sounds_Add_Sound(87, 20, 80, 20, 40, -100, 100, -101, -101, 0, 0); // SIREN2.AUD
if (Game_Flag_Query(186)) {
- if (!Game_Flag_Query(9) && !Game_Flag_Query(114))
+ if (!Game_Flag_Query(9) && !Game_Flag_Query(114)) {
Scene_Loop_Start_Special(0, 5, 0);
- if (Game_Flag_Query(249))
+ }
+ if (Game_Flag_Query(249)) {
Scene_Loop_Set_Default(6);
- else
+ } else {
Scene_Loop_Set_Default(10);
+ }
} else {
- if (!Game_Flag_Query(9) && !Game_Flag_Query(114))
+ if (!Game_Flag_Query(9) && !Game_Flag_Query(114)) {
Scene_Loop_Start_Special(0, 0, 0);
+ }
Scene_Loop_Set_Default(1);
}
@@ -122,15 +121,15 @@ void ScriptRC01::InitializeScene() {
}
void ScriptRC01::SceneLoaded() {
- Obstacle_Object("HYDRANT02", 1);
- Obstacle_Object("PARKING METER 04", 1);
- Obstacle_Object("CHEVY PROP", 1);
- Obstacle_Object("PARKING METER 01", 1);
- Obstacle_Object("T-CAN01", 1);
- Obstacle_Object("BARICADE01", 1);
- Obstacle_Object("BARICADE02", 1);
- Obstacle_Object("DOOR LEFT", 1);
- Unobstacle_Object("BOX06", 1);
+ Obstacle_Object("HYDRANT02", true);
+ Obstacle_Object("PARKING METER 04", true);
+ Obstacle_Object("CHEVY PROP", true);
+ Obstacle_Object("PARKING METER 01", true);
+ Obstacle_Object("T-CAN01", true);
+ Obstacle_Object("BARICADE01", true);
+ Obstacle_Object("BARICADE02", true);
+ Obstacle_Object("DOOR LEFT", true);
+ Unobstacle_Object("BOX06", true);
Clickable_Object("DOORWAY01");
Clickable_Object("DOOR LEFT");
Clickable_Object("HYDRANT02");
@@ -146,7 +145,7 @@ void ScriptRC01::SceneLoaded() {
Unclickable_Object("SPINNER BODY");
Unclickable_Object("HORSE01");
Unclickable_Object("DOORWAY01");
- Unobstacle_Object("DOORWAY01", 1);
+ Unobstacle_Object("DOORWAY01", true);
if (Game_Flag_Query(186)) {
Unclickable_Object("70_1");
@@ -157,16 +156,16 @@ void ScriptRC01::SceneLoaded() {
Unclickable_Object("BARICADE01");
Unclickable_Object("BARICADE03");
Unclickable_Object("BARICADE04");
- Unobstacle_Object("70_1", 1);
- Unobstacle_Object("70_2", 1);
- Unobstacle_Object("70_3", 1);
- Unobstacle_Object("70_5", 1);
- Unobstacle_Object("70_6", 1);
- Unobstacle_Object("BARICADE01", 1);
- Unobstacle_Object("BARICADE02", 1);
- Unobstacle_Object("BARICADE03", 1);
- Unobstacle_Object("BARICADE04", 1);
- Unobstacle_Object("BARICADE05", 1);
+ Unobstacle_Object("70_1", true);
+ Unobstacle_Object("70_2", true);
+ Unobstacle_Object("70_3", true);
+ Unobstacle_Object("70_5", true);
+ Unobstacle_Object("70_6", true);
+ Unobstacle_Object("BARICADE01", true);
+ Unobstacle_Object("BARICADE02", true);
+ Unobstacle_Object("BARICADE03", true);
+ Unobstacle_Object("BARICADE04", true);
+ Unobstacle_Object("BARICADE05", true);
}
if (!Game_Flag_Query(186)) {
@@ -177,13 +176,12 @@ void ScriptRC01::SceneLoaded() {
Preload(589);
}
- /*
- if (!Game_Flag_Query(163))
- Item_Add_To_World(66, 938, 69, -148.60f, -0.30f, 225.15f, 256, 24, 24, 0, 1, 0, 1);
- */
+ if (!Game_Flag_Query(163)) {
+ Item_Add_To_World(66, 938, 69, -148.60f, -0.30f, 225.15f, 256, 24, 24, false, true, false, true);
+ }
if (!Game_Flag_Query(24)) {
- // ADQ_Flush();
+ ADQ_Flush();
Actor_Voice_Over(1830, 99);
Actor_Voice_Over(1850, 99);
if (!Game_Flag_Query(378)) {
@@ -195,44 +193,29 @@ void ScriptRC01::SceneLoaded() {
}
}
-void ScriptRC01::sub_403850()
-{
- if (Game_Flag_Query(186))
- return;
-
- if (Loop_Actor_Walk_To_Scene_Object(0, "BARICADE03", 36, 1, 0))
- return;
-
- Actor_Set_Goal_Number(23, 0);
- Actor_Face_Object(0, "BARICADE03", 1);
- // Loop_Actor_Walk_To_Actor(23, 0, 36, 1, 0);
- Actor_Face_Actor(23, 0, 1);
- Actor_Says(0, 4500, 14);
- I_Sez("MG: We don't want any of that abstract art oozing out onto the street.");
- Actor_Says(23, 10, 14);
- Actor_Set_Goal_Number(23, 1);
+bool ScriptRC01::MouseClick(int x, int y) {
+ return y >= 430;
}
-bool ScriptRC01::ClickedOn3DObject(const char *objectName) {
+bool ScriptRC01::ClickedOn3DObject(const char *objectName, bool a2) {
if (Object_Query_Click("BARICADE01", objectName)
- || Object_Query_Click("BARICADE03", objectName)
- || Object_Query_Click("BARICADE04", objectName)
- || Object_Query_Click("70_1", objectName)
- || Object_Query_Click("70_2", objectName)
- || Object_Query_Click("70_3", objectName)
- || Object_Query_Click("70_5", objectName)
- || Object_Query_Click("70_6", objectName))
- {
+ || Object_Query_Click("BARICADE03", objectName)
+ || Object_Query_Click("BARICADE04", objectName)
+ || Object_Query_Click("70_1", objectName)
+ || Object_Query_Click("70_2", objectName)
+ || Object_Query_Click("70_3", objectName)
+ || Object_Query_Click("70_5", objectName)
+ || Object_Query_Click("70_6", objectName)) {
sub_403850();
return true;
}
if (Object_Query_Click("HYDRANT02", objectName)) {
- if (Loop_Actor_Walk_To_Scene_Object(0, "HYDRANT02", 60, 1, 0) == 0) {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "HYDRANT02", 60, 1, false)) {
if (Actor_Clue_Query(0, 26)) {
Actor_Says(0, 6975, 3);
} else {
- Actor_Face_Object(0, "HYDRANT02", 1);
+ Actor_Face_Object(0, "HYDRANT02", true);
Actor_Voice_Over(1880, 99);
Actor_Voice_Over(1890, 99);
I_Sez("JM: That McCoy--he's one funny guy! Jet-black fire truck, hehehehe...");
@@ -242,33 +225,26 @@ bool ScriptRC01::ClickedOn3DObject(const char *objectName) {
return true;
}
- if (Object_Query_Click("DOOR LEFT", objectName))
- {
- if (!Loop_Actor_Walk_To_Scene_Object(0, "DOOR LEFT", 48, 1, 0))
- {
- Actor_Face_Object(0, "DOOR LEFT", 1);
- if (Actor_Clue_Query(0, 2) || !Actor_Query_In_Set(23, 69) || Global_Variable_Query(1) != 1)
- {
- Actor_Says(0, 8570, 14);
- }
- else
- {
+ if (Object_Query_Click("DOOR LEFT", objectName)) {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "DOOR LEFT", 48, 1, false)) {
+ Actor_Face_Object(0, "DOOR LEFT", true);
+ if (!Actor_Clue_Query(0, 2) && Actor_Query_In_Set(23, 69) && Global_Variable_Query(1)) {
Actor_Set_Goal_Number(23, 0);
- Actor_Face_Actor(23, 0, 1);
+ Actor_Face_Actor(23, 0, true);
Actor_Says(23, 0, 12);
Actor_Says(0, 4495, 13);
Actor_Clue_Acquire(0, 2, 1, 23);
+ } else {
+ Actor_Says(0, 8570, 14);
}
Actor_Clue_Acquire(0, 1, 1, -1);
}
return true;
}
- if (Object_Query_Click("T-CAN01", objectName))
- {
- if (!Loop_Actor_Walk_To_Scene_Object(0, "T-CAN01", 24, 1, 0))
- {
- Actor_Face_Object(0, "T-CAN01", 1);
+ if (Object_Query_Click("T-CAN01", objectName)) {
+ if (!Loop_Actor_Walk_To_Scene_Object(0, "T-CAN01", 24, 1, false)) {
+ Actor_Face_Object(0, "T-CAN01", true);
Actor_Voice_Over(1810, 99);
Actor_Voice_Over(1820, 99);
}
@@ -278,64 +254,340 @@ bool ScriptRC01::ClickedOn3DObject(const char *objectName) {
return false;
}
+bool ScriptRC01::ClickedOnActor(int actorId) {
+ if (actorId == 23 && Global_Variable_Query(1) == 1) {
+ if (!Loop_Actor_Walk_To_Actor(0, 23, 36, 1, false)) {
+ Actor_Face_Actor(0, 23, true);
+ Actor_Face_Actor(23, 0, true);
+ if (Actor_Query_Goal_Number(23) == 1) {
+ Actor_Set_Goal_Number(23, 0);
+ }
+ if (Game_Flag_Query(3)) {
+ Actor_Says(0, 4535, 13);
+ Game_Flag_Set(392);
+ if (Actor_Clue_Query(23, 16) && !Actor_Clue_Query(0, 16)) {
+ Actor_Face_Object(23, "70_1", true);
+ Actor_Says(23, 100, 15);
+ Actor_Face_Actor(23, 0, true);
+ Actor_Clue_Acquire(0, 16, 1, 23);
+ Game_Flag_Reset(392);
+ } else if (Actor_Clue_Query(23, 17) && !Actor_Clue_Query(0, 17)) {
+ Actor_Face_Object(23, "70_5", true);
+ Actor_Says(23, 120, 19);
+ Actor_Face_Actor(23, 0, true);
+ Actor_Says(23, 130, 14);
+ I_Sez("JM: Did it have a huge, ugly piece of chrome on it?");
+ Actor_Clue_Acquire(0, 17, 1, 23);
+ Game_Flag_Reset(392);
+ } else {
+ Actor_Says(23, 90, 16);
+ I_Sez("JM: This officer has a talent for vivid metaphors.");
+ if (!Game_Flag_Query(397)) {
+ I_Sez("DL: What is that supposed to mean? I didn't write this line...");
+ Actor_Says(0, 4540, 16);
+ Game_Flag_Set(397);
+ }
+ Game_Flag_Reset(392);
+ }
+ } else {
+ I_Sez("MG: Hey, leave that officer alone.Can't you see he's busy?");
+ I_Sez("JM: (...mmm, donuts...");
+ Game_Flag_Set(3);
+ Actor_Clue_Acquire(0, 0, 1, 23);
+ Actor_Says(0, 4515, 13);
+ Game_Flag_Set(392);
+ Actor_Says(23, 40, 13);
+ if (!Game_Flag_Query(1)) {
+ Actor_Says(23, 50, 14);
+ Actor_Says(23, 60, 15);
+ I_Sez("MG: It's all fun and games until someone loses a tiger cub");
+ Actor_Says(0, 4520, 18);
+ Actor_Says(23, 70, 16);
+ Actor_Says(0, 4525, 14);
+ Actor_Says(23, 80, 18);
+ Actor_Says(0, 4530, 15);
+ }
+ Game_Flag_Reset(392);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC01::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 66) {
+ Actor_Set_Goal_Number(23, 0);
+ if (!Loop_Actor_Walk_To_Item(0, 66, 36, 1, false)) {
+ Actor_Face_Item(0, 66, true);
+ Actor_Clue_Acquire(0, 27, 1, -1);
+ Actor_Face_Actor(23, 0, true);
+ Actor_Says(23, 20, 12);
+ Game_Flag_Set(163);
+ Item_Remove_From_World(66);
+ Item_Pickup_Spin_Effect(938, 426, 316);
+ I_Sez("JM: Chrome...is that what that is?");
+ Actor_Says(0, 4505, 13);
+ ADQ_Flush();
+ ADQ_Add(23, 30, -1);
+ ADQ_Add(0, 4510, 13);
+ I_Sez("JM: It's hard to imagine that thing on either a car or a horse.");
+ I_Sez("MG: McCoy! What a witty chap...");
+ I_Sez("JM: He keeps me chuckling non-stop!\n");
+ Loop_Actor_Walk_To_Actor(23, 0, 36, 0, false);
+ }
+ return true;
+ }
+ return false;
+
+}
+
+void ScriptRC01::sub_4037AC() {
+ Player_Loses_Control();
+ Game_Flag_Set(182);
+ Actor_Set_Immunity_To_Obstacles(0, true);
+ Loop_Actor_Walk_To_XYZ(0, -151.98f, -0.3f, 318.15f, 0, 0, false, 0);
+ Actor_Set_Immunity_To_Obstacles(0, false);
+ Player_Gains_Control();
+}
+
+bool ScriptRC01::ClickedOnExit(int exitId) {
+
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -174.77f, 5.55f, 25.95f, 12, 1, false, 0)) {
+ if (Game_Flag_Query(705)) {
+ Actor_Says(0, 8522, 14);
+ } else {
+ switch (Global_Variable_Query(1)) {
+ case 1:
+ case 4:
+ Game_Flag_Set(8);
+ Set_Enter(16, 79);
+ break;
+ case 2:
+ case 3:
+ case 5:
+ Actor_Says(0, 8522, 12);
+ break;
+ default:
+ return true;
+ }
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (Game_Flag_Query(486)) {
+ Spinner_Set_Selectable_Destination_Flag(6, 1);
+ }
+ I_Sez("MG: Leaving already? The fun is just beginning!");
+ if (!Loop_Actor_Walk_To_XYZ(0, -151.98f, -0.3f, 318.15f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Actor_Set_Immunity_To_Obstacles(0, true);
+ Loop_Actor_Walk_To_XYZ(0, -151.98f, -0.3f, 318.15f, 0, 0, false, 0);
+ if (Game_Flag_Query(486) && !Game_Flag_Query(660)) {
+ Actor_Voice_Over(4310, 99);
+ Actor_Voice_Over(4320, 99);
+ Actor_Voice_Over(4330, 99);
+ Actor_Voice_Over(4340, 99);
+ Actor_Voice_Over(4350, 99);
+ Game_Flag_Set(660);
+ }
+ Actor_Set_Immunity_To_Obstacles(0, false);
+ Player_Gains_Control();
+ Game_Flag_Reset(176);
+ Game_Flag_Reset(182);
+ Game_Flag_Reset(179);
+ Game_Flag_Reset(178);
+ int spinnerDest;
+ if (Game_Flag_Query(186)) {
+ spinnerDest = Spinner_Interface_Choose_Dest(8, 1);
+ } else {
+ spinnerDest = Spinner_Interface_Choose_Dest(3, 1);
+ }
+ if (spinnerDest) {
+ switch (spinnerDest) {
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 5:
+ Game_Flag_Set(261);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(307);
+ Set_Enter(17, 82);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ break;
+ default:
+ sub_4037AC();
+ break;
+ }
+ } else {
+ Game_Flag_Set(178);
+ Game_Flag_Reset(249);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ if (Game_Flag_Query(186)) {
+ Scene_Loop_Start_Special(1, 9, 1);
+ } else {
+ Scene_Loop_Start_Special(1, 4, 1);
+ }
+ }
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -471.98f, -0.3f, 258.15f, 4, 1, false, 0)) {
+ Game_Flag_Set(115);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Set_Enter(70, 80);
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptRC01::sub_403850() {
+ if (!Game_Flag_Query(186) && !Loop_Actor_Walk_To_Scene_Object(0, "BARICADE03", 36, 1, false)) {
+ Actor_Set_Goal_Number(23, 0);
+ Actor_Face_Object(0, "BARICADE03", true);
+ Loop_Actor_Walk_To_Actor(23, 0, 36, 1, false);
+ Actor_Face_Actor(23, 0, true);
+ Actor_Says(0, 4500, 14);
+ I_Sez("MG: We don't want any of that abstract art oozing out onto the street.");
+ Actor_Says(23, 10, 14);
+ Actor_Set_Goal_Number(23, 1);
+ }
+}
+
bool ScriptRC01::ClickedOn2DRegion(int region) {
if (region == 0) {
sub_403850();
- return 1;
+ return true;
}
-
- return 0;
+ return false;
}
-
void ScriptRC01::SceneFrameAdvanced(int frame) {
- if (frame == 1)
- Sound_Play(118, 40, 0, 0, 50); // CARDOWN3.AUD
-
- if (frame == 61 || frame == 362)
+ if (frame == 1) {
+ Sound_Play(118, 40, 0, 0, 50); // CARDOWN3.AUD
+ }
+ if (frame == 61 || frame == 362) {
Sound_Play(116, 100, 80, 80, 50); // SPINOPN4.AUD
-
- if (frame == 108 || frame == 409)
+ }
+ if (frame == 108 || frame == 409) {
Sound_Play(119, 100, 80, 80, 50); // SPINCLS1.AUD
-
- if (frame == 183 || frame == 484)
+ }
+ if (frame == 183 || frame == 484) {
Sound_Play(116, 100, 80, 80, 50); // SPINOPN4.AUD
-
- if (frame == 228 || frame == 523)
+ }
+ if (frame == 228 || frame == 523) {
Sound_Play(119, 100, 80, 80, 50); // SPINCLS1.AUD
-
- if (frame == 243 || frame == 545)
- Sound_Play(117, 40, 80, 80, 50); // CARUP3.AUD
-
- if (frame == 315)
- Sound_Play(118, 40, 80, 80, 50); // CARDOWN3.AUD
+ }
+ if (frame == 243 || frame == 545) {
+ Sound_Play(117, 40, 80, 80, 50); // CARUP3.AUD
+ }
+ if (frame == 315) {
+ Sound_Play(118, 40, 80, 80, 50); // CARDOWN3.AUD
+ }
}
-void ScriptRC01::SceneActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+void ScriptRC01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
}
-void ScriptRC01::PlayerWalkedIn()
-{
+void ScriptRC01::PlayerWalkedIn() {
if (Game_Flag_Query(249) && !Game_Flag_Query(9) && !Game_Flag_Query(114)) {
- // Extract to sub_4037AC():
- Player_Loses_Control();
- Game_Flag_Set(182);
- Actor_Set_Immunity_To_Obstacles(0, true);
- Loop_Actor_Walk_To_XYZ(0, -151.98, -0.30, 318.15, 0, 0, 0, 0);
- Actor_Set_Immunity_To_Obstacles(0, false);
- Player_Gains_Control();
+ sub_4037AC();
}
if (Game_Flag_Query(114)) {
Player_Loses_Control();
- Loop_Actor_Walk_To_XYZ(0, -415.98, -0.30, 262.15, 0, 0, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -415.98f, -0.30f, 262.15f, 0, 0, false, 0);
Player_Gains_Control();
Game_Flag_Reset(114);
}
if (Game_Flag_Query(9)) {
Player_Loses_Control();
- Loop_Actor_Walk_To_XYZ(0, -203.45, 5.55, 85.05, 0, 0, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -203.45f, 5.55f, 85.05f, 0, 0, false, 0);
Player_Gains_Control();
Game_Flag_Reset(9);
@@ -345,7 +597,23 @@ void ScriptRC01::PlayerWalkedIn()
Actor_Voice_Over(1930, 99);
Game_Flag_Set(4);
}
+ //return true;
}
+ //return false;
+}
+
+void ScriptRC01::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (!Game_Flag_Query(8) && !Game_Flag_Query(115) && Global_Variable_Query(1)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(31, 1, -1);
+ }
+ // return 1;
+}
+
+void ScriptRC01::DialogueQueueFlushed(int a1) {
}
} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/rc02.cpp b/engines/bladerunner/script/rc02.cpp
new file mode 100644
index 0000000000..7a387c2583
--- /dev/null
+++ b/engines/bladerunner/script/rc02.cpp
@@ -0,0 +1,392 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptRC02::InitializeScene() {
+ if (Game_Flag_Query(8)) {
+ Setup_Scene_Information(-103.0f, -1238.89f, 108603.04f, 1007);
+ } else {
+ Setup_Scene_Information(-20.2f, -1238.89f, 108100.73f, 539);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ if (Game_Flag_Query(141)) {
+ Scene_Exit_Add_2D_Exit(1, 265, 58, 346, 154, 0);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(0);
+ Ambient_Sounds_Add_Looping_Sound(71, 50, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(75, 75, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(105, 30, 100, 1);
+ Ambient_Sounds_Add_Sound(73, 5, 20, 10, 10, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 20, 10, 10, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(76, 5, 40, 6, 6, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(77, 5, 40, 6, 6, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(78, 5, 40, 6, 6, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(79, 5, 40, 6, 6, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(23, 250, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(23, 330, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 380, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(24, 510, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 80, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Speech_Sound(38, 160, 10, 60, 5, 5, 100, 100, -101, -101, 1, 1);
+ Ambient_Sounds_Add_Sound(87, 20, 80, 10, 20, 100, 100, -101, -101, 0, 0);
+}
+
+void ScriptRC02::SceneLoaded() {
+ Obstacle_Object("TABLETOP", true);
+ Obstacle_Object("DRAPE01", true);
+ Obstacle_Object("DRAPE03", true);
+ Obstacle_Object("DRAPE04", true);
+ Obstacle_Object("DRAPE05", true);
+ Obstacle_Object("DRAPE06", true);
+ Obstacle_Object("DRAPE07", true);
+ Obstacle_Object("OUTR_DESK", true);
+ Obstacle_Object("CAGE_BASE", true);
+ Obstacle_Object("POLE_ROP01", true);
+ Unobstacle_Object("LEGS", true);
+ Unobstacle_Object("SLATS01", true);
+ Unobstacle_Object("DRAPE07", true);
+ Clickable_Object("SCRTY CA03");
+ Unclickable_Object("GRL_DSKLEG");
+ Unclickable_Object("CURTAIN");
+ Unclickable_Object("DRAPE01");
+ Unclickable_Object("DRAPE02");
+ Unclickable_Object("DRAPE03");
+ Unclickable_Object("DRAPE05");
+ Unclickable_Object("DRAPE06");
+ Unclickable_Object("DRAPE07");
+ if (Actor_Clue_Query(0, 12) || Global_Variable_Query(1) > 1) {
+ Unclickable_Object("SCRTY CA03");
+ }
+ if (!Game_Flag_Query(190)) {
+ Item_Add_To_World(100, 966, 16, -52.88f, -1238.89f, 108467.74f, 256, 6, 6, false, true, false, true);
+ Item_Add_To_World(101, 966, 16, -37.16f, -1238.89f, 108456.59f, 512, 6, 6, false, true, false, true);
+ Item_Add_To_World(102, 966, 16, -62.86f, -1238.89f, 108437.52f, 625, 6, 6, false, true, false, true);
+ }
+}
+
+bool ScriptRC02::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptRC02::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("SCRTY CA03", objectName) && !Actor_Clue_Query(0, 12)) {
+ if (Actor_Clue_Query(0, 22) && Actor_Query_Is_In_Current_Set(15)) {
+ AI_Movement_Track_Pause(15);
+ Actor_Face_Actor(0, 15, true);
+ Actor_Says(0, 4545, 14);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 0, 14);
+ Actor_Says(15, 10, 16);
+ Actor_Says(0, 4550, 13);
+ Actor_Says(15, 20, 13);
+ Loop_Actor_Walk_To_Waypoint(15, 89, 0, 0, false);
+ Actor_Face_Actor(0, 15, true);
+ Loop_Actor_Walk_To_Waypoint(15, 102, 0, 0, false);
+ Actor_Face_Actor(0, 15, true);
+ Actor_Face_Heading(15, 539, false);
+ Delay(2000);
+ Loop_Actor_Walk_To_Waypoint(15, 89, 0, 0, false);
+ Loop_Actor_Walk_To_Actor(15, 0, 24, 0, false);
+ Item_Pickup_Spin_Effect(975, 357, 228);
+ Actor_Face_Actor(0, 15, true);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 30, 23);
+ Actor_Says(0, 4555, 18);
+ Actor_Clue_Acquire(0, 12, 1, 15);
+ Unclickable_Object("SCRTY CA03");
+ AI_Movement_Track_Unpause(15);
+ return true;
+ } else {
+ Actor_Face_Object(0, "SCRTY CA03", true);
+ Actor_Voice_Over(2000, 99);
+ return true;
+ }
+ }
+ return false;
+}
+
+void ScriptRC02::sub_402A7C() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(0, 5, 6, 2);
+ DM_Add_To_List_Never_Repeat_Once_Selected(10, 5, 4, 8);
+ if (Actor_Clue_Query(0, 23) || (Actor_Clue_Query(0, 24))) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(20, 6, 4, 5);
+ }
+ Dialogue_Menu_Add_DONE_To_List(30);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer) {
+ switch (answer) {
+ case 10:
+ Actor_Says(0, 4585, 13);
+ Actor_Face_Actor(15, 0, true);
+ if (Game_Flag_Query(46)) {
+ Actor_Says(15, 250, 13);
+ Actor_Says(15, 270, 13);
+ Actor_Clue_Acquire(0, 23, 1, 15);
+ } else {
+ Actor_Says(15, 260, 14);
+ Actor_Says(15, 270, 13);
+ Actor_Clue_Acquire(0, 24, 1, 15);
+ }
+ Actor_Says(0, 4645, 13);
+ Actor_Says(15, 280, 13);
+ Actor_Says(15, 290, 13);
+ Actor_Says(0, 4650, 18);
+ Actor_Says(15, 320, 13);
+ Actor_Says(0, 4665, 13);
+ Actor_Face_Object(15, "CURTAIN", true);
+ Actor_Says(15, 350, 13);
+ Actor_Face_Actor(15, 0, true);
+ Scene_Exit_Add_2D_Exit(1, 265, 58, 346, 154, 0);
+ Game_Flag_Set(141);
+ break;
+ case 20:
+ Actor_Says(0, 4590, 19);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 360, 13);
+ Loop_Actor_Walk_To_Waypoint(15, 89, 0, 0, false);
+ Loop_Actor_Walk_To_Waypoint(15, 102, 0, 0, false);
+ Actor_Face_Actor(0, 15, true);
+ Actor_Face_Heading(15, 539, false);
+ Delay(2000);
+ Loop_Actor_Walk_To_Waypoint(15, 89, 0, 0, false);
+ Actor_Face_Actor(0, 15, true);
+ Loop_Actor_Walk_To_Actor(15, 0, 24, 0, false);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Face_Actor(0, 15, true);
+ Item_Pickup_Spin_Effect(964, 357, 228);
+ Actor_Says(15, 1700, 13);
+ Actor_Clue_Acquire(0, 15, 1, 15);
+ break;
+ case 30:
+ Actor_Says(0, 4595, 14);
+ break;
+ }
+ } else {
+ Actor_Says(0, 4580, 13);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 110, 18);
+ Actor_Says(15, 120, 17);
+ Actor_Says(15, 130, 19);
+ Actor_Says(0, 4605, 13);
+ Actor_Says(15, 140, 16);
+ Game_Flag_Set(187);
+ }
+}
+
+bool ScriptRC02::ClickedOnActor(int actorId) {
+ if (actorId != 15) {
+ return false;
+ }
+
+ if (Global_Variable_Query(1) == 4) {
+ Actor_Face_Actor(0, 15, true);
+ if (Actor_Query_Goal_Number(15) == 599) {
+ if (Random_Query(1, 2) == 1) {
+ Actor_Says(0, 8715, 17);
+ } else {
+ Actor_Says(0, 8720, 17);
+ }
+ } else if (Game_Flag_Query(705) || Game_Flag_Query(706)) {
+ Actor_Says(0, 4805, 11);
+ Actor_Face_Actor(15, 0, true);
+ if (Game_Flag_Query(706)) {
+ Actor_Says(15, 720, 15);
+ } else {
+ Actor_Says(15, 730, 14);
+ }
+ Actor_Face_Heading(15, 1007, false);
+ } else {
+ Actor_Says(0, 4690, 11);
+ Actor_Says(0, 4695, 13);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 1610, 14);
+ if (Actor_Clue_Query(0, 76)) {
+ Actor_Says(0, 4700, 12);
+ Actor_Says(0, 4705, 13);
+ Actor_Says(15, 1620, 12);
+ Actor_Says(0, 4710, 15);
+ Actor_Says(0, 4715, 11);
+ Delay(2000);
+ Actor_Says(0, 4720, 16);
+ Actor_Says(0, 4725, 17);
+ Actor_Says(15, 430, 16);
+ Actor_Face_Heading(15, 1007, false);
+ }
+ Game_Flag_Set(706);
+ }
+ return true;
+ }
+ AI_Movement_Track_Pause(15);
+ Loop_Actor_Walk_To_Actor(0, 15, 48, 1, false);
+ Actor_Face_Actor(0, 15, true);
+ if (!Game_Flag_Query(6)) {
+ Actor_Says(0, 4560, 13);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 40, 16);
+ Actor_Says(15, 50, 15);
+ Actor_Says(0, 4565, 13);
+ Actor_Says(15, 60, 14);
+ Actor_Says(0, 4570, 18);
+ Actor_Says(15, 70, 13);
+ Game_Flag_Set(6);
+ Actor_Clue_Acquire(0, 22, 1, 15);
+ AI_Movement_Track_Unpause(15);
+ return true;
+ }
+ if (Game_Flag_Query(187)) {
+ if (Player_Query_Agenda() == 0) {
+ Game_Flag_Reset(0);
+ sub_402A7C();
+ AI_Movement_Track_Unpause(15);
+ return true;
+ }
+
+ Actor_Says(0, 4610, 19);
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 150, 15);
+ Actor_Says(0, 4615, 13);
+ Actor_Says(15, 160, 14);
+ Actor_Says(15, 170, 15);
+ Actor_Says(15, 180, 13);
+
+ if (Player_Query_Agenda() == 2) {
+ Actor_Says(0, 4620, 19);
+ Actor_Says(15, 190, 14);
+ Actor_Says(0, 4625, 13);
+ Actor_Says(15, 210, 13);
+ Actor_Says(0, 4630, 18);
+ Actor_Says(15, 220, 14);
+ Actor_Says(15, 230, 13);
+ Actor_Says(0, 4635, 19);
+ Actor_Says(15, 240, 16);
+ Actor_Says(0, 4640, 17);
+ }
+ Game_Flag_Reset(187);
+ AI_Movement_Track_Unpause(15);
+ return true;
+ }
+ sub_402A7C();
+ AI_Movement_Track_Unpause(15);
+ return true;
+}
+
+bool ScriptRC02::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 100 || itemId == 101 || itemId == 102) {
+ if (!Loop_Actor_Walk_To_Item(0, 100, 24, 1, false)) {
+ Actor_Face_Item(0, 100, true);
+ Actor_Clue_Acquire(0, 5, 1, -1);
+ Game_Flag_Set(190);
+ Item_Remove_From_World(100);
+ Item_Remove_From_World(101);
+ Item_Remove_From_World(102);
+ Item_Pickup_Spin_Effect(966, 395, 352);
+ Actor_Voice_Over(1960, 99);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -71.51f, -1238.89f, 108587.15f, 0, 1, false, 0)) {
+ Game_Flag_Set(9);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_Looping_Sound(71, true);
+ Ambient_Sounds_Remove_Looping_Sound(75, true);
+ Ambient_Sounds_Adjust_Looping_Sound(85, 100, -101, 1);
+ Actor_Set_Goal_Number(15, 0);
+ Set_Enter(69, 78);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -20.2f, -1238.73f, 108152.73f, 0, 1, false, 0)) {
+ Async_Actor_Walk_To_XYZ(0, -8.87f, -1238.89f, 108076.27f, 0, false);
+ Set_Enter(16, 107);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptRC02::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptRC02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptRC02::PlayerWalkedIn() {
+ Player_Set_Combat_Mode(false);
+ if (Game_Flag_Query(8)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -72.2f, -1238.89f, 108496.73f, 0, 0, false, 0);
+ Player_Gains_Control();
+ Game_Flag_Reset(8);
+ if (!Game_Flag_Query(1)) {
+ Actor_Voice_Over(1970, 99);
+ Actor_Voice_Over(1980, 99);
+ Actor_Voice_Over(1990, 99);
+ Actor_Clue_Acquire(0, 3, 1, -1);
+ Actor_Clue_Acquire(0, 4, 1, -1);
+ Game_Flag_Set(1);
+ }
+ if (Actor_Query_Which_Set_In(15) == 16 && Actor_Query_Goal_Number(15) < 300) {
+ Actor_Set_Goal_Number(15, 1);
+ }
+ if (Actor_Query_Goal_Number(15) == 300 && !Game_Flag_Query(704)) {
+ Actor_Face_Actor(15, 0, true);
+ Actor_Says(15, 370, 12);
+ Actor_Says(15, 380, 14);
+ Actor_Face_Actor(0, 15, true);
+ Actor_Says(0, 4670, 15);
+ Actor_Says(15, 390, 13);
+ Actor_Says(0, 4675, 14);
+ Actor_Face_Heading(15, 1007, false);
+ Actor_Says(15, 400, 13);
+ Actor_Says(15, 410, 12);
+ Game_Flag_Set(704);
+ }
+ } else {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, -20.2f, -1238.89f, 108152.73f, 0, 0, false, 0);
+ Player_Gains_Control();
+ }
+}
+
+void ScriptRC02::PlayerWalkedOut() {
+}
+
+void ScriptRC02::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/rc03.cpp b/engines/bladerunner/script/rc03.cpp
new file mode 100644
index 0000000000..92074a8af9
--- /dev/null
+++ b/engines/bladerunner/script/rc03.cpp
@@ -0,0 +1,301 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptRC03::InitializeScene() {
+ if (Game_Flag_Query(115) ) {
+ Setup_Scene_Information(298.0f, -4.0f, 405.0f, 800);
+ Game_Flag_Reset(115);
+ } else if (Game_Flag_Query(117) ) {
+ Setup_Scene_Information(-469.0f, -4.0f, 279.0f, 250);
+ } else if (Game_Flag_Query(119) ) {
+ Setup_Scene_Information(147.51f, -4.0f, 166.48f, 500);
+ if (!Game_Flag_Query(151)) {
+ Game_Flag_Set(151);
+ }
+ } else if (Game_Flag_Query(107) ) {
+ Setup_Scene_Information(-487.0f, 1.0f, 116.0f, 400);
+ } else if (Game_Flag_Query(121) ) {
+ Setup_Scene_Information(-22.0f, 1.0f, -63.0f, 400);
+ } else {
+ Setup_Scene_Information(0.0f, 0.0f, 0.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 0, 0, 30, 479, 3);
+ if (Game_Flag_Query(151) ) {
+ Scene_Exit_Add_2D_Exit(2, 524, 350, 573, 359, 2);
+ }
+ Scene_Exit_Add_2D_Exit(3, 85, 255, 112, 315, 0);
+ Scene_Exit_Add_2D_Exit(4, 428, 260, 453, 324, 0);
+ Ambient_Sounds_Add_Looping_Sound(54, 50, 0, 1);
+ Ambient_Sounds_Add_Sound(82, 5, 30, 40, 70, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(83, 5, 30, 40, 75, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(84, 5, 30, 40, 70, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Speech_Sound(60, 0, 10, 260, 17, 24, -100, 100, -101, -101, 1, 1);
+ 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);
+ Ambient_Sounds_Add_Sound(68, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(69, 60, 180, 16, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(375, 60, 180, 50, 100, 0, 0, -101, -101, 0, 0);
+ 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);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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);
+ if (Game_Flag_Query(107) && Actor_Query_Goal_Number(7) != 102) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ }
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptRC03::SceneLoaded() {
+ Obstacle_Object("Box-Streetlight01", true);
+ Obstacle_Object("Box-Streetlight02", true);
+ Obstacle_Object("Parking Meter 01", true);
+ Obstacle_Object("Parking Meter 02", true);
+ Obstacle_Object("Parking Meter 03", true);
+ Obstacle_Object("Trash can with fire", true);
+ Obstacle_Object("Baricade01", true);
+ Obstacle_Object("Foreground Junk01", true);
+ Obstacle_Object("Steam01", true);
+ Obstacle_Object("Steam02", true);
+ Obstacle_Object("Box-BBcolumn01", true);
+ Obstacle_Object("Box-BBcolumn02", true);
+ Obstacle_Object("Box-BBcolumn03", true);
+ Obstacle_Object("Box-BBcolumn04", true);
+ Obstacle_Object("Box-BBbuilding01", true);
+ Obstacle_Object("Box-BBbuilding02", true);
+ Obstacle_Object("Box-BBbuilding03", true);
+ Obstacle_Object("Box-BBbuilding04", true);
+ Unclickable_Object("BOX-BBBUILDING01");
+ Unclickable_Object("BOX-BBBUILDING02");
+ Unclickable_Object("BOX-BBBUILDING03");
+ Unclickable_Object("BOX-BBBUILDING04");
+ Unclickable_Object("BOX-STREETLIGHT01");
+ Unclickable_Object("BOX-STREETLIGHT02");
+ Unclickable_Object("BOX-BBCOLUMN01");
+ Unclickable_Object("BOX-BBCOLUMN02");
+ Unclickable_Object("BOX-BBCOLUMN03");
+ Unclickable_Object("BOX-BBCOLUMN04");
+ Unclickable_Object("PARKING METER 02");
+ Unclickable_Object("PARKING METER 03");
+ Unclickable_Object("TRASH CAN WITH FIRE");
+ Unclickable_Object("BARICADE01");
+ Unclickable_Object("FOREGROUND JUNK01");
+}
+
+bool ScriptRC03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptRC03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptRC03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptRC03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptRC03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 298.0f, -4.0f, 405.0f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(289)) {
+ Game_Flag_Set(702);
+ }
+ Game_Flag_Set(114);
+ Set_Enter(69, 78);
+ Actor_Set_Goal_Number(3, 100);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -469.0f, -4.0f, 279.0f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(289)) {
+ Game_Flag_Set(702);
+ }
+ Game_Flag_Set(116);
+ Game_Flag_Reset(182);
+ Game_Flag_Set(180);
+ Set_Enter(0, 1);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 147.51f, -4.0f, 166.48f, 0, 1, false, 0)) {
+ Game_Flag_Set(118);
+ Game_Flag_Reset(182);
+ Game_Flag_Set(259);
+ if (Game_Flag_Query(289)) {
+ Game_Flag_Set(702);
+ }
+ Set_Enter(74, 86);
+ Actor_Set_Goal_Number(3, 100);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -487.0f, 1.0f, 116.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(108);
+ Game_Flag_Reset(182);
+ Game_Flag_Set(479);
+ if (Game_Flag_Query(289)) {
+ Game_Flag_Set(702);
+ }
+ Set_Enter(8, 106);
+ Actor_Set_Goal_Number(3, 100);
+ }
+ return true;
+ }
+ if (exitId == 4) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -22.0f, 1.0f, -63.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) == 3 || Global_Variable_Query(1) == 5 || Game_Flag_Query(702)) {
+ Actor_Says(0, 8522, 14);
+ } else {
+ Game_Flag_Set(120);
+ Set_Enter(71, 81);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptRC03::SceneFrameAdvanced(int frame) {
+ if (frame == 1) {
+ Sound_Play(286, Random_Query(33, 33), 100, -100, 50);
+ }
+ if (frame == 15) {
+ Sound_Play(287, Random_Query(50, 50), -100, 100, 50);
+ }
+}
+
+void ScriptRC03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptRC03::sub_402834() {
+ Actor_Face_Actor(1, 0, true);
+ Actor_Says(1, 1820, 3);
+ Actor_Face_Actor(0, 1, true);
+ Actor_Says(0, 4815, 14);
+ Actor_Says(1, 1830, 3);
+ Actor_Says(1, 1840, 3);
+ Actor_Says(0, 4820, 12);
+ Actor_Says(1, 1850, 3);
+ Actor_Says(1, 1950, 3);
+ Actor_Says(0, 4835, 14);
+ Actor_Says(1, 1960, 3);
+ Actor_Says(1, 1980, 3);
+ Actor_Says(0, 4840, 15);
+ Actor_Says(1, 1990, 3);
+ Actor_Says(1, 2000, 3);
+}
+
+void ScriptRC03::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(7) == 102) {
+ Scene_Exits_Disable();
+ if (Game_Flag_Query(119) ) {
+ Player_Set_Combat_Mode(false);
+ Player_Loses_Control();
+ Actor_Set_At_XYZ(0, 147.51f, -4.0f, 166.48f, 500);
+ Actor_Put_In_Set(7, 70);
+ Actor_Set_At_XYZ(7, 196.0f, -4.0f, 184.0f, 775);
+ Actor_Face_Actor(7, 0, true);
+ Actor_Face_Actor(0, 7, true);
+ Actor_Change_Animation_Mode(7, 4);
+ Actor_Says_With_Pause(7, 630, 0, -1);
+ Actor_Says_With_Pause(7, 640, 0, -1);
+ Actor_Says_With_Pause(7, 650, 0, -1);
+ if (Game_Flag_Query(44) ) {
+ Actor_Set_Goal_Number(1, 100);
+ }
+ Actor_Change_Animation_Mode(0, 20);
+ Loop_Actor_Walk_To_XYZ(7, 180.0f, -4.0f, 184.0f, 0, 0, false, 0);
+ Actor_Change_Animation_Mode(7, 6);
+ if (!Game_Flag_Query(44)) {
+ Actor_Set_Goal_Number(1, 100);
+ }
+ Player_Gains_Control();
+ } else {
+ Actor_Put_In_Set(7, 70);
+ Actor_Set_At_XYZ(7, -226.0f, 1.72f, 86.0f, 0);
+ Actor_Set_Targetable(7, true);
+ Actor_Set_Goal_Number(7, 110);
+ }
+ }
+ if (Actor_Query_Goal_Number(7) == 103) {
+ Player_Loses_Control();
+ Actor_Set_Goal_Number(1, 200);
+ Actor_Put_In_Set(1, 70);
+ if (Game_Flag_Query(119) || Game_Flag_Query(121) ) {
+ Actor_Set_At_Waypoint(1, 175, 0);
+ } else {
+ Actor_Set_At_Waypoint(1, 203, 0);
+ }
+ sub_402834();
+ Async_Actor_Walk_To_Waypoint(1, 174, 0, 0);
+ Actor_Set_Goal_Number(7, 200);
+ Player_Gains_Control();
+ }
+ Game_Flag_Reset(119);
+ Game_Flag_Reset(117);
+ Game_Flag_Reset(107);
+ Game_Flag_Reset(121);
+ if (Global_Variable_Query(1) == 1 || Global_Variable_Query(1) == 2) {
+ Actor_Set_Goal_Number(3, 103);
+ }
+}
+
+void ScriptRC03::PlayerWalkedOut() {
+ if (Actor_Query_Goal_Number(7) == 199) {
+ Actor_Set_Goal_Number(7, 198);
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptRC03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/rc04.cpp b/engines/bladerunner/script/rc04.cpp
new file mode 100644
index 0000000000..b0ac2f7fc9
--- /dev/null
+++ b/engines/bladerunner/script/rc04.cpp
@@ -0,0 +1,420 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptRC04::InitializeScene() {
+ Setup_Scene_Information(45.0f, 0.15f, 68.0f, 1018);
+ Game_Flag_Reset(120);
+ Scene_Exit_Add_2D_Exit(0, 225, 47, 359, 248, 0);
+ if (!Game_Flag_Query(289)) {
+ Actor_Put_In_Set(14, 71);
+ Actor_Set_At_XYZ(14, -60.0f, -11.0f, 62.0f, 12);
+ }
+ if (Game_Flag_Query(289)) {
+ Actor_Change_Animation_Mode(14, 88);
+ }
+ Ambient_Sounds_Add_Looping_Sound(381, 100, 1, 1);
+ Ambient_Sounds_Add_Sound(82, 5, 30, 10, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(83, 5, 30, 10, 20, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(84, 5, 30, 10, 20, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptRC04::SceneLoaded() {
+ Obstacle_Object("Door New 01", true);
+ Obstacle_Object("GRNDNEON05", true);
+ Obstacle_Object("GRNDNEON06", true);
+ Obstacle_Object("GRNDNEON07", true);
+ Unobstacle_Object("DisplayTrim", true);
+ Unobstacle_Object("Display01", true);
+ Actor_Set_Goal_Number(67, 200);
+}
+
+bool ScriptRC04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptRC04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+void ScriptRC04::sub_401DF4() {
+ Dialogue_Menu_Clear_List();
+ if (Actor_Clue_Query(0, 11) && !Actor_Clue_Query(0, 62)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(580, -1, 4, 9);
+ }
+ if (Actor_Clue_Query(0, 5) && !Actor_Clue_Query(0, 11) && !Actor_Clue_Query(0, 62)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(590, 6, 5, 3);
+ }
+ if (Actor_Clue_Query(0, 57)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(600, -1, 3, 7);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1310, -1, 2, 8);
+ }
+ if (Actor_Clue_Query(0, 62) && !Actor_Clue_Query(0, 63)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(610, 4, 5, 6);
+ }
+ if (!Game_Flag_Query(305)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1280, 1, 2, 3);
+ }
+ if (Actor_Clue_Query(0, 110) && !Actor_Clue_Query(14, 110)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(620, 1, -1, -1);
+ }
+ Dialogue_Menu_Add_DONE_To_List(630);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+
+ switch (answer) {
+ case 580:
+ Actor_Says(0, 4955, 30);
+ Actor_Says(14, 210, 37);
+ Actor_Says(14, 220, 37);
+ Actor_Says(14, 230, 37);
+ Actor_Says(14, 240, 37);
+ Actor_Says(0, 4990, 16);
+ Actor_Says(0, 4995, 11);
+ Actor_Says(14, 270, 31);
+ Actor_Says(0, 5005, 16);
+ Actor_Says(14, 280, 32);
+ Actor_Says(14, 290, 30);
+ Actor_Says(14, 300, 33);
+ Actor_Says(14, 310, 31);
+ Actor_Says(0, 5010, 11);
+ Actor_Says(14, 320, 30);
+ Actor_Says(14, 330, 33);
+ Actor_Says(14, 340, 37);
+ Actor_Says(0, 5015, 11);
+ if (Game_Flag_Query(44)) {
+ Actor_Says(14, 350, 32);
+ Actor_Says(14, 360, 33);
+ Actor_Says(14, 370, 30);
+ Actor_Says(0, 5020, 16);
+ Actor_Says(14, 380, 37);
+ Actor_Says(14, 390, 11);
+ Actor_Says(14, 400, 37);
+ Actor_Clue_Acquire(0, 58, 1, 0);
+ } else {
+ Actor_Says(14, 410, 11);
+ Actor_Says(14, 420, 37);
+ Actor_Says(0, 5025, 16);
+ Actor_Says(14, 430, 30);
+ Actor_Says(14, 440, 31);
+ Actor_Says(14, 450, 32);
+ Actor_Says(0, 5030, 16);
+ Actor_Says(14, 460, 37);
+ Actor_Clue_Acquire(0, 59, 1, 0);
+ }
+ return;
+ case 590:
+ Actor_Says(0, 4960, 13);
+ Actor_Says(14, 250, 30);
+ Actor_Says(14, 260, 33);
+ Actor_Says(0, 4995, 15);
+ Actor_Says(14, 270, 32);
+ Actor_Says(0, 5005, 11);
+ Actor_Says(14, 280, 33);
+ Actor_Says(14, 290, 30);
+ Actor_Says(14, 300, 32);
+ Actor_Says(14, 310, 37);
+ Actor_Says(0, 5010, 13);
+ Actor_Says(14, 320, 37);
+ Actor_Says(14, 330, 33);
+ Actor_Says(14, 340, 11);
+ Actor_Says(0, 5015, 16);
+ Actor_Modify_Friendliness_To_Other(14, 0, 3);
+ if (Game_Flag_Query(44)) {
+ Actor_Says(14, 350, 32);
+ Actor_Says(14, 360, 30);
+ Actor_Says(14, 370, 33);
+ Actor_Says(0, 5020, 15);
+ Actor_Says(14, 380, 33);
+ Actor_Says(14, 390, 37);
+ Actor_Says(14, 400, 32);
+ Actor_Clue_Acquire(0, 58, 1, 0);
+ } else {
+ Actor_Says(14, 410, 32);
+ Actor_Says(14, 420, 30);
+ Actor_Says(0, 5025, 13);
+ Actor_Says(14, 430, 33);
+ Actor_Says(14, 440, 32);
+ Actor_Says(14, 450, 37);
+ Actor_Says(0, 5030, 16);
+ Actor_Says(14, 460, 30);
+ Actor_Clue_Acquire(0, 59, 1, 0);
+ }
+ break;
+ case 600:
+ Actor_Says(0, 4965, 11);
+ Actor_Says(14, 470, 11);
+ Actor_Says(0, 5035, 15);
+ Actor_Says(14, 480, 30);
+ Actor_Says(14, 490, 31);
+ Actor_Says(14, 500, 32);
+ Actor_Says(14, 510, 33);
+ Actor_Says(14, 520, 34);
+ Actor_Says(14, 530, 35);
+ Actor_Says(14, 540, 36);
+ Actor_Says(0, 5040, 16);
+ Actor_Says(14, 550, 11);
+ Actor_Modify_Friendliness_To_Other(14, 0, -6);
+ break;
+ case 610:
+ Actor_Says(0, 4970, 16);
+ if (Actor_Query_Friendliness_To_Other(14, 0) < 50) {
+ Actor_Says(14, 700, 11);
+ Actor_Says(0, 5070, 11);
+ Actor_Says(14, 710, 11);
+ Actor_Says(0, 5075, 15);
+ Actor_Says(14, 720, 30);
+ Actor_Says(0, 5080, 11);
+ Actor_Says(14, 730, 37);
+ Actor_Clue_Acquire(0, 58, 1, 0);
+ } else {
+ Actor_Says(14, 560, 37);
+ Actor_Says(0, 5070, 13);
+ Actor_Says(14, 570, 36);
+ Actor_Says(14, 580, 37);
+ Actor_Says(14, 590, 31);
+ Actor_Says(14, 600, 32);
+ Actor_Says(14, 610, 30);
+ Actor_Says(0, 5050, 16);
+ Actor_Says(14, 620, 35);
+ Actor_Says(14, 630, 35);
+ Actor_Says(0, 5055, 11);
+ Actor_Says(14, 640, 36);
+ Actor_Says(14, 650, 35);
+ Actor_Says(14, 660, 30);
+ Actor_Says(0, 5060, 13);
+ Actor_Clue_Acquire(0, 63, 1, 0);
+ }
+ break;
+ case 1280:
+ Actor_Says(0, 9040, 16);
+ if (!Game_Flag_Query(305)) {
+ Actor_Says(14, 2080, 30);
+ Actor_Says(14, 2090, 37);
+ Actor_Says(0, 9045, 14);
+ Actor_Says(14, 2100, 32);
+ Actor_Says(14, 2110, 37);
+ Game_Flag_Set(305);
+ }
+ Actor_Says(14, 2120, 31);
+ if (Global_Variable_Query(2) > 40 || Query_Difficulty_Level() == 0) {
+ Actor_Says(0, 4940, 13);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 40);
+ }
+ Item_Pickup_Spin_Effect(995, 405, 192);
+ Give_McCoy_Ammo(1, 24);
+ } else {
+ Actor_Says(0, 125, 13);
+ Actor_Modify_Friendliness_To_Other(14, 0, -2);
+ }
+ break;
+ case 1310:
+ Actor_Says(0, 4980, 11);
+ if (Actor_Query_Friendliness_To_Other(14, 0) > 49) {
+ Actor_Says(14, 740, 37);
+ Actor_Says(0, 5085, 16);
+ Actor_Says(14, 750, 37);
+ Actor_Says(14, 760, 37);
+ Voight_Kampff_Activate(14, 50);
+ Actor_Modify_Friendliness_To_Other(14, 0, 3);
+ Actor_Says(14, 810, 37);
+ Actor_Says(0, 5025, 13);
+ Actor_Says(14, 820, 32);
+ Actor_Says(0, 5100, 11);
+ Actor_Says(14, 830, 31);
+ Actor_Says(14, 840, 35);
+ } else {
+ Actor_Says(14, 770, 36);
+ Actor_Says(14, 780, 36);
+ Actor_Says(0, 5090, 16);
+ Actor_Says(14, 790, 36);
+ Actor_Says(14, 800, 35);
+ Voight_Kampff_Activate(14, 50);
+ Actor_Says(14, 810, 30);
+ Actor_Says(0, 5025, 13);
+ Actor_Says(14, 820, 31);
+ Actor_Says(0, 5100, 15);
+ Actor_Says(14, 830, 34);
+ Actor_Says(14, 840, 34);
+ }
+ break;
+ case 620:
+ Actor_Says(0, 4985, 11);
+ Actor_Says(14, 850, 35);
+ Actor_Says(0, 5105, 13);
+ Actor_Says(0, 5110, 11);
+ Actor_Says(14, 860, 30);
+ Actor_Says(0, 5115, 16);
+ Actor_Says(14, 870, 31);
+ Actor_Says(0, 5120, 15);
+ Actor_Says(14, 880, 34);
+ Actor_Clue_Acquire(14, 110, 1, 0);
+ Actor_Modify_Friendliness_To_Other(14, 0, 8);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Increment(2, 60);
+ }
+ break;
+ case 630:
+ Actor_Says(0, 1315, 12);
+ break;
+ }
+}
+
+bool ScriptRC04::ClickedOnActor(int actorId) {
+ if (Player_Query_Combat_Mode()) {
+ return false;
+ }
+ if (actorId == 14 && Global_Variable_Query(1) == 2 && !Game_Flag_Query(289)) {
+ Loop_Actor_Walk_To_Waypoint(0, 104, 0, 0, false);
+ Actor_Face_Actor(0, 14, true);
+ if (Game_Flag_Query(287) && !Game_Flag_Query(292) && Actor_Query_Friendliness_To_Other(14, 0) > 45) {
+ Actor_Says(14, 30, 30);
+ Actor_Says(0, 4875, 13);
+ Actor_Says(14, 80, 31);
+ Actor_Says(0, 4900, 15);
+ Actor_Says(14, 90, 33);
+ Actor_Says(14, 100, 34);
+ Actor_Says(0, 4905, 15);
+ Game_Flag_Set(292);
+ } else if (Game_Flag_Query(287) && !Game_Flag_Query(290) && Actor_Query_Friendliness_To_Other(14, 0) < 45) {
+ Actor_Says(14, 40, 30);
+ Actor_Says(0, 4880, 13);
+ Actor_Says(14, 50, 35);
+ Actor_Says(0, 4875, 16);
+ Actor_Says(14, 60, 36);
+ Actor_Says(0, 4890, 13);
+ Actor_Says(14, 70, 33);
+ Actor_Says(0, 4895, 16);
+ Actor_Modify_Friendliness_To_Other(14, 0, -5);
+ Game_Flag_Set(290);
+ } else if (Actor_Query_Friendliness_To_Other(14, 0) > 51 && !Game_Flag_Query(717)) {
+ Actor_Says(14, 1870, 30);
+ Actor_Says(14, 1880, 30);
+ Actor_Says(0, 8960, 13);
+ Actor_Says(14, 1890, 36);
+ Actor_Says(14, 1900, 35);
+ Actor_Says(0, 8965, 16);
+ Actor_Says(14, 1920, 36);
+ Actor_Says(14, 1930, 33);
+ Actor_Says(14, 1940, 36);
+ Actor_Says(14, 1950, 30);
+ Actor_Says(0, 8970, 13);
+ Actor_Says(14, 1960, 33);
+ Actor_Says(14, 1970, 30);
+ Actor_Says(14, 1980, 36);
+ Delay(1000);
+ Actor_Says(14, 2010, 35);
+ if (Global_Variable_Query(2) > 50 || Query_Difficulty_Level() == 0) {
+ Actor_Says(0, 8975, 16);
+ if (Query_Difficulty_Level()) {
+ Global_Variable_Decrement(2, 50);
+ }
+ Delay(3000);
+ Item_Pickup_Spin_Effect(941, 405, 192);
+ Actor_Says(14, 2030, 30);
+ Game_Flag_Set(487);
+ } else {
+ Actor_Says(0, 8980, 16);
+ Actor_Says(14, 2040, 30);
+ Actor_Says(0, 8985, 15);
+ Actor_Says(14, 2050, 33);
+ }
+ Game_Flag_Set(717);
+ } else if (Actor_Clue_Query(0, 11) || Actor_Clue_Query(0, 5) || Actor_Clue_Query(0, 62) || Actor_Clue_Query(0, 110) || Actor_Clue_Query(0, 57) || !Game_Flag_Query(305)) {
+ sub_401DF4();
+ } else {
+ Actor_Says(14, 1820, 30);
+ }
+ return true;
+ }
+ if (actorId == 14 && Game_Flag_Query(289)) {
+ Actor_Face_Actor(0, 14, true);
+ if (Actor_Clue_Query(0, 164)) {
+ Actor_Says(0, 8590, -1);
+ } else {
+ Actor_Voice_Over(2100, 99);
+ Actor_Voice_Over(2110, 99);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptRC04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 45.0f, 0.15f, 68.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(121);
+ Set_Enter(70, 80);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptRC04::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptRC04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptRC04::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_Waypoint(0, 103, 0, 0, false);
+ if (Global_Variable_Query(1) != 2 || Game_Flag_Query(287) || Player_Query_Combat_Mode()) {
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(289) && !Game_Flag_Query(306)) {
+ Actor_Says(38, 40, 3);
+ Actor_Says(14, 890, 37);
+ Actor_Set_Goal_Number(14, 2);
+ }
+ Game_Flag_Set(287);
+ } else {
+ Actor_Says(14, 0, 31);
+ Loop_Actor_Walk_To_Waypoint(0, 104, 0, 0, false);
+ Actor_Face_Actor(0, 14, true);
+ Actor_Says(0, 4865, 13);
+ Actor_Says(14, 10, 32);
+ Actor_Says(0, 4870, 16);
+ Actor_Says(14, 20, 31);
+ Game_Flag_Set(287);
+ }
+}
+
+void ScriptRC04::PlayerWalkedOut() {
+ Game_Flag_Reset(303);
+}
+
+void ScriptRC04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/rc51.cpp b/engines/bladerunner/script/rc51.cpp
new file mode 100644
index 0000000000..907ffd8ba3
--- /dev/null
+++ b/engines/bladerunner/script/rc51.cpp
@@ -0,0 +1,130 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptRC51::InitializeScene() {
+ Setup_Scene_Information(-8.87f, -1238.89f, 108164.27f, 66);
+ Scene_Exit_Add_2D_Exit(0, 0, 460, 639, 479, 2);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptRC51::SceneLoaded() {
+ Obstacle_Object("POSTER_2", true);
+ Obstacle_Object("CURTAIN", true);
+ Clickable_Object("POSTER_2");
+ Unclickable_Object("GRL_DSK");
+ Unclickable_Object("GRL_DSKLEG");
+ Unclickable_Object("CURTAIN");
+ if (!Game_Flag_Query(147)) {
+ Item_Add_To_World(82, 937, 16, 47.56f, -1238.89f, 108048.61f, 0, 6, 18, false, true, false, true);
+ }
+ if (!Game_Flag_Query(148)) {
+ Item_Add_To_World(79, 933, 16, 67.28f, -1193.38f, 108011.27f, 0, 6, 6, false, true, false, true);
+ }
+ if (!Game_Flag_Query(149)) {
+ Item_Add_To_World(98, 971, 16, -69.65f, -1238.89f, 107995.24f, 256, 18, 18, false, true, false, true);
+ }
+}
+
+bool ScriptRC51::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptRC51::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("POSTER_2", objectName)) {
+ Actor_Face_Object(0, "POSTER_2", true);
+ Actor_Says(0, 8620, 3);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC51::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptRC51::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 82 && !Loop_Actor_Walk_To_XYZ(0, 17.97f, -1238.89f, 108053.5f, 0, 1, false, 0)) {
+ Actor_Face_Item(0, 82, true);
+ Actor_Clue_Acquire(0, 8, 1, -1);
+ Item_Remove_From_World(82);
+ Item_Pickup_Spin_Effect(937, 437, 407);
+ Actor_Voice_Over(2010, 99);
+ Game_Flag_Set(147);
+ return true;
+ }
+ if (itemId == 79 && !Loop_Actor_Walk_To_Item(0, 79, 36, 1, false)) {
+ Actor_Face_Item(0, 79, true);
+ Actor_Clue_Acquire(0, 6, 1, -1);
+ Item_Remove_From_World(79);
+ Item_Pickup_Spin_Effect(933, 445, 230);
+ Actor_Says(0, 8735, 3);
+ Actor_Says(0, 8529, 3);
+ Game_Flag_Set(148);
+ return true;
+ }
+ if (itemId == 98 && !Loop_Actor_Walk_To_Item(0, 98, 36, 1, false)) {
+ Actor_Face_Item(0, 98, true);
+ Actor_Clue_Acquire(0, 7, 1, -1);
+ Item_Remove_From_World(98);
+ Item_Pickup_Spin_Effect(971, 55, 376);
+ Actor_Says(0, 8525, 3);
+ Actor_Says(0, 8740, 3);
+ Game_Flag_Set(149);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC51::ClickedOnExit(int exitId) {
+ if (exitId == 0 && !Loop_Actor_Walk_To_XYZ(0, -8.87f, -1238.89f, 108173.27f, 0, 1, false, 0)) {
+ Set_Enter(16, 79);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptRC51::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptRC51::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptRC51::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptRC51::PlayerWalkedIn() {
+ Game_Flag_Set(709);
+}
+
+void ScriptRC51::PlayerWalkedOut() {
+}
+
+void ScriptRC51::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/script.cpp b/engines/bladerunner/script/script.cpp
index c93c5db4e4..e9f9b602e3 100644
--- a/engines/bladerunner/script/script.cpp
+++ b/engines/bladerunner/script/script.cpp
@@ -33,6 +33,7 @@
#include "bladerunner/combat.h"
#include "bladerunner/gameflags.h"
#include "bladerunner/gameinfo.h"
+#include "bladerunner/movement_track.h"
#include "bladerunner/settings.h"
#include "bladerunner/set_effects.h"
#include "bladerunner/scene.h"
@@ -72,12 +73,57 @@ void Script::SceneLoaded() {
_inScriptCounter--;
}
-bool Script::ClickedOn3DObject(const char *objectName) {
+bool Script::MouseClick(int x, int y) {
+ if (_inScriptCounter > 0)
+ return true;
+
+ _inScriptCounter++;
+ //MouseX = x;
+ //MouseY = y;
+ bool result = _currentScript->MouseClick(x, y);
+ //SelectedEntity = -1;
+ _inScriptCounter--;
+ //MouseX = -1;
+ //MouseY = -1;
+ return result;
+}
+
+bool Script::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (_inScriptCounter > 0)
+ return true;
+
+ _inScriptCounter++;
+ bool result = _currentScript->ClickedOn3DObject(objectName, a2);
+ _inScriptCounter--;
+ return result;
+}
+
+bool Script::ClickedOnActor(int actorId) {
if (_inScriptCounter > 0)
return true;
_inScriptCounter++;
- bool result = _currentScript->ClickedOn3DObject(objectName);
+ bool result = _currentScript->ClickedOnActor(actorId);
+ _inScriptCounter--;
+ return result;
+}
+
+bool Script::ClickedOnItem(int itemId, bool a2) {
+ if (_inScriptCounter > 0)
+ return true;
+
+ _inScriptCounter++;
+ bool result = _currentScript->ClickedOnItem(itemId, a2);
+ _inScriptCounter--;
+ return result;
+}
+
+bool Script::ClickedOnExit(int exitId) {
+ if (_inScriptCounter > 0)
+ return true;
+
+ _inScriptCounter++;
+ bool result = _currentScript->ClickedOnExit(exitId);
_inScriptCounter--;
return result;
}
@@ -98,9 +144,9 @@ void Script::SceneFrameAdvanced(int frame) {
_inScriptCounter--;
}
-void Script::SceneActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+void Script::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
_inScriptCounter++;
- _currentScript->SceneActorChangedGoal(actorId, newGoal, oldGoal, currentSet);
+ _currentScript->ActorChangedGoal(actorId, newGoal, oldGoal, currentSet);
_inScriptCounter--;
}
@@ -110,6 +156,18 @@ void Script::PlayerWalkedIn() {
_inScriptCounter--;
}
+void Script::PlayerWalkedOut() {
+ _inScriptCounter++;
+ _currentScript->PlayerWalkedOut();
+ _inScriptCounter--;
+}
+
+void Script::DialogueQueueFlushed(int a1) {
+ _inScriptCounter++;
+ _currentScript->DialogueQueueFlushed(a1);
+ _inScriptCounter--;
+}
+
void ScriptBase::Preload(int animationId) {
_vm->_sliceRenderer->preload(animationId);
}
@@ -128,6 +186,7 @@ void ScriptBase::Actor_Set_At_Waypoint(int actorId, int waypointId, int angle) {
bool ScriptBase::Region_Check(int left, int top, int right, int down) {
//TODO: return _vm->_mouse.x >= left && _vm->_mouse.y >= top && _vm->_mouse.x <= right && _vm->_mouse.y <= down;
+ warning("Region_Check(%d, %d, %d, %d)", left, top, right, down);
return false;
}
@@ -171,7 +230,7 @@ void ScriptBase::Actor_Face_Current_Camera(int actorId, bool animate) {
_vm->_actors[actorId]->faceCurrentCamera(animate);
}
-void ScriptBase::Actor_Face_Heading(int actorId, int heading) {
+void ScriptBase::Actor_Face_Heading(int actorId, int heading, bool animate) {
_vm->_actors[actorId]->faceHeading(heading, true);
}
@@ -471,10 +530,19 @@ int ScriptBase::Actor_Query_Animation_Mode(int actorId) {
return _vm->_actors[actorId]->getAnimationMode();
}
-// ScriptBase::Loop_Actor_Walk_To_Actor
-// ScriptBase::Loop_Actor_Walk_To_Item
+bool ScriptBase::Loop_Actor_Walk_To_Actor(int actorId, int otherActorId, int a3, int a4, bool running) {
+ //TODO
+ warning("Loop_Actor_Walk_To_Actor(%d, %d, %d, %d, %d)", actorId, otherActorId, a3, a4, running);
+ return false;
+}
+
+bool ScriptBase::Loop_Actor_Walk_To_Item(int actorId, int itemId, int a3, int a4, bool running) {
+ //TODO
+ warning("Loop_Actor_Walk_To_Item(%d, %d, %d, %d, %d)", actorId, itemId, a3, a4, running);
+ return false;
+}
-bool ScriptBase::Loop_Actor_Walk_To_Scene_Object(int actorId, const char *objectName, int distance, int a4, int a5) {
+bool ScriptBase::Loop_Actor_Walk_To_Scene_Object(int actorId, const char *objectName, int distance, int a4, bool running) {
_vm->gameWaitForActive();
_vm->_actors[actorId]->loopWalkToSceneObject(objectName);
@@ -482,17 +550,46 @@ bool ScriptBase::Loop_Actor_Walk_To_Scene_Object(int actorId, const char *object
return false;
}
-// ScriptBase::Loop_Actor_Walk_To_Waypoint
+bool ScriptBase::Loop_Actor_Walk_To_Waypoint(int actorId, int waypointId, int a3, int a4, bool running) {
+ //TODO
+ warning("Loop_Actor_Walk_To_Waypoint(%d, %d, %d, %d, %d)", actorId, waypointId, a3, a4, running);
+ return false;
+}
+
+bool ScriptBase::Loop_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a4, int a5, bool running, int a7) {
+ _vm->gameWaitForActive();
+
+ _vm->_actors[actorId]->loopWalkToXYZ(x, y, z, a4, a5, running, 1);
+
+ return false;
+}
+
+void ScriptBase::Async_Actor_Walk_To_Waypoint(int actorId, int waypointId, int a3, int running) {
+ //TODO
+ warning("Async_Actor_Walk_To_Waypoint(%d, %d, %d, %d)", actorId, a3, running);
+}
-void ScriptBase::Loop_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a4, int a5, int a6, int a7) {
- _vm->loopActorWalkToXYZ(actorId, x, y, z, a4, a5, a6, a7);
+void ScriptBase::Async_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a5, bool running) {
+ //TODO
+ warning("Async_Actor_Walk_To_XYZ(%d, %f, %f, %f, %d, %d)", actorId, x, y, z, a5, running);
}
-// ScriptBase::Async_Actor_Walk_To_Waypoint
-// ScriptBase::Async_Actor_Walk_To_XYZ
-// ScriptBase::Actor_Force_Stop_Walking
-// ScriptBase::Loop_Actor_Travel_Stairs
-// ScriptBase::Loop_Actor_Travel_Ladder
+void ScriptBase::Actor_Force_Stop_Walking(int actorId) {
+ //TODO
+ warning("Loop_Actor_Travel_Stairs(%d)", actorId);
+}
+
+bool ScriptBase::Loop_Actor_Travel_Stairs(int actorId, int a2, int a3, int a4) {
+ //TODO
+ warning("Loop_Actor_Travel_Stairs(%d, %d, %d, %d)", actorId, a2, a3, a4);
+ return false;
+}
+
+bool ScriptBase::Loop_Actor_Travel_Ladder(int actorId, int a2, int a3, int a4) {
+ //TODO
+ warning("Loop_Actor_Travel_Ladder(%d, %d, %d, %d)", actorId,a2,a3,a4);
+ return false;
+}
void ScriptBase::Actor_Clue_Add_To_Database(int actorId, int clueId, int unknown, bool clueAcquired, bool unknownFlag, int fromActorId) {
_vm->_actors[actorId]->addClueToDatabase(clueId, unknown, clueAcquired, unknownFlag, fromActorId);
@@ -526,12 +623,32 @@ void ScriptBase::Actor_Set_Immunity_To_Obstacles(int actorId, bool isImmune) {
_vm->_actors[actorId]->setImmunityToObstacles(isImmune);
}
-// ScriptBase::Item_Add_To_World
-// ScriptBase::Item_Remove_From_World
-// ScriptBase::Item_Spin_In_World
-// ScriptBase::Item_Flag_As_Target
-// ScriptBase::Item_Flag_As_Non_Target
-// ScriptBase::Item_Pickup_Spin_Effect
+void ScriptBase::Item_Add_To_World(int itemId, int animationId, int sceneIndex, float x, float y, float z, signed int angle, int height, int width, bool isTargetable, bool isObstacle, bool isPoliceMazeEnemy, bool updateOnly) {
+ //TODO
+ warning("Item_Add_To_World(%d, %d, %d, %f, %f, %f, %d, %d, %d, %d, %d, %d, %d)", itemId, animationId, sceneIndex, x, y, z, angle, height, width, isTargetable, isObstacle, isPoliceMazeEnemy, updateOnly);
+}
+
+void ScriptBase::Item_Remove_From_World(int itemId) {
+ //TODO
+ warning("Item_Remove_From_World(%d)", itemId);
+}
+
+void ScriptBase::Item_Spin_In_World(int itemId) {
+ warning("Item_Spin_In_World(%d)", itemId);
+}
+
+void ScriptBase::Item_Flag_As_Target(int itemId) {
+ warning("Item_Flag_As_Target(%d)", itemId);
+}
+
+void ScriptBase::Item_Flag_As_Non_Target(int itemId) {
+ warning("Item_Flag_As_Non_Target(%d)", itemId);
+}
+
+void ScriptBase::Item_Pickup_Spin_Effect(int a1, int a2, int a3) {
+ //TODO
+ warning("Item_Pickup_Spin_Effect(%d, %d, %d)", a1, a2, a3);
+}
int ScriptBase::Animation_Open() {
//This is not implemented in game
@@ -667,21 +784,62 @@ void ScriptBase::Sound_Play(int id, int volume, int panFrom, int panTo, int prio
_vm->_audioPlayer->playAud(name, volume, panFrom, panTo, priority);
}
-// ScriptBase::Sound_Play_Speech_Line
+void ScriptBase::Sound_Play_Speech_Line(int actorId, int speechId, int a3, int a4, int a5) {
+ //TODO
+ warning("Sound_Play_Speech_Line(%d, %d, %d, %d, %d)", actorId, speechId, a3, a4, a5);
+}
// ScriptBase::Sound_Left_Footstep_Walk
// ScriptBase::Sound_Right_Footstep_Walk
// ScriptBase::Sound_Left_Footstep_Run
// ScriptBase::Sound_Right_Footstep_Run
// ScriptBase::Sound_Walk_Shuffle_Stop
-// ScriptBase::Footstep_Sounds_Set
-// ScriptBase::Footstep_Sound_Override_On
-// ScriptBase::Footstep_Sound_Override_Off
-// ScriptBase::Music_Play
-// ScriptBase::Music_Adjust
-// ScriptBase::Music_Stop
-// ScriptBase::Music_Is_Playing
-// ScriptBase::Overlay_Play
-// ScriptBase::Overlay_Remove
+
+void ScriptBase::Footstep_Sounds_Set(int walkboxId, int stepSound) {
+ //TODO
+ warning("Footstep_Sounds_Set(%d, %d)", walkboxId, stepSound);
+}
+
+void ScriptBase::Footstep_Sound_Override_On(int footstepSoundOverride) {
+ //TODO
+ warning("Footstep_Sound_Override_On(%d)", footstepSoundOverride);
+}
+
+void ScriptBase::Footstep_Sound_Override_Off() {
+ //TODO
+ warning("Footstep_Sound_Override_Off()");
+}
+
+bool ScriptBase::Music_Play(int a1, int a2, int a3, int a4, int a5, int a6, int a7) {
+ //TODO
+ warning("Music_Play(%d, %d, %d, %d, %d, %d, %d)", a1, a2, a3, a4, a5, a6, a7);
+ return false;
+}
+
+void ScriptBase::Music_Adjust(int a1, int a2, int a3) {
+ //TODO
+ warning("Music_Adjust(%d, %d, %d)", a1, a2, a3);
+}
+
+void ScriptBase::Music_Stop(int a1) {
+ //TODO
+ warning("Music_Stop(%d)", a1);
+}
+
+bool ScriptBase::Music_Is_Playing() {
+ //TODO
+ warning("Music_Is_Playing()");
+ return false;
+}
+
+void ScriptBase::Overlay_Play(const char *overlay, int a2, int a3, int a4, int a5) {
+ //TODO
+ warning("Overlay_Play(%s, %d, %d, %d, %d)", overlay, a2, a3, a4, a5);
+}
+
+void ScriptBase::Overlay_Remove(const char *overlay) {
+ //TODO
+ warning("Overlay_Remove(%s)", overlay);
+}
void ScriptBase::Scene_Loop_Set_Default(int a) {
// debug("Scene_Loop_Set_Default(%d)", a);
@@ -705,10 +863,24 @@ void ScriptBase::Ambient_Sounds_Add_Sound(int id, int time1, int time2, int volu
_vm->_ambientSounds->addSound(id, time1, time2, volume1, volume2, pan1begin, pan1end, pan2begin, pan2end, priority, unk);
}
-// ScriptBase::Ambient_Sounds_Remove_Sound
-// ScriptBase::Ambient_Sounds_Add_Speech_Sound
+void ScriptBase::Ambient_Sounds_Remove_Sound(int id, bool a2) {
+ //TODO
+ warning("Ambient_Sounds_Remove_Sound(%d, %d)", id, a2);
+}
+
+void ScriptBase::Ambient_Sounds_Add_Speech_Sound(int id, int unk1, int time1, int time2, int volume1, int volume2, int pan1begin, int pan1end, int pan2begin, int pan2end, int priority, int unk2){
+ //TODO
+ warning("Ambient_Sounds_Add_Speech_Sound(%d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d)", id, unk1, time1, time2, volume1, volume2, pan1begin, pan1end, pan2begin, pan2end, priority, unk2);
+}
+
// ScriptBase::Ambient_Sounds_Remove_Speech_Sound
-// ScriptBase::Ambient_Sounds_Play_Sound
+
+int ScriptBase::Ambient_Sounds_Play_Sound(int a1, int a2, int a3, int a4, int a5) {
+ //TODO
+ warning("Ambient_Sounds_Remove_Sound(%d, %d, %d, %d, %d)", a1, a2, a3, a4, a5);
+ return -1;
+}
+
// ScriptBase::Ambient_Sounds_Play_Speech_Sound
void ScriptBase::Ambient_Sounds_Remove_All_Non_Looping_Sounds(int time) {
@@ -719,8 +891,15 @@ void ScriptBase::Ambient_Sounds_Add_Looping_Sound(int id, int volume, int pan, i
_vm->_ambientSounds->addLoopingSound(id, volume, pan, fadeInTime);
}
-// ScriptBase::Ambient_Sounds_Adjust_Looping_Sound
-// ScriptBase::Ambient_Sounds_Remove_Looping_Sound
+void ScriptBase::Ambient_Sounds_Adjust_Looping_Sound(int id, int panBegin, int panEnd, int a4) {
+ //TODO
+ warning("Ambient_Sounds_Adjust_Looping_Sound(%d, %d, %d, %d)", id, panBegin, panEnd, a4);
+}
+
+void ScriptBase::Ambient_Sounds_Remove_Looping_Sound(int id, bool a2){
+ //TODO
+ warning("Ambient_Sounds_Remove_Looping_Sound(%d, %d)", id, a2);
+}
void ScriptBase::Ambient_Sounds_Remove_All_Looping_Sounds(int time) {
// _vm->_ambientSounds->removeAllLoopingSounds(time);
@@ -730,17 +909,66 @@ void ScriptBase::Setup_Scene_Information(float actorX, float actorY, float actor
_vm->_scene->setActorStart(Vector3(actorX, actorY, actorZ), actorFacing);
}
-// ScriptBase::Dialogue_Menu_Appear
-// ScriptBase::Dialogue_Menu_Disappear
-// ScriptBase::Dialogue_Menu_Clear_List
-// ScriptBase::Dialogue_Menu_Add_To_List
-// ScriptBase::Dialogue_Menu_Add_DONE_To_List
-// ScriptBase::Dialogue_Menu_Add_To_List_Never_Repeat_Once_Selected
-// ScriptBase::DM_Add_To_List
-// ScriptBase::DM_Add_To_List_Never_Repeat_Once_Selected
-// ScriptBase::Dialogue_Menu_Remove_From_List
-// ScriptBase::Dialogue_Menu_Query_Input
-// ScriptBase::Dialogue_Menu_Query_List_Size
+bool ScriptBase::Dialogue_Menu_Appear(int x, int y) {
+ //TODO
+ warning("Dialogue_Menu_Appear(%d, %d)", x, y);
+ return false;
+}
+
+bool ScriptBase::Dialogue_Menu_Disappear() {
+ //TODO
+ warning("Dialogue_Menu_Disappear()");
+ return false;
+}
+
+bool ScriptBase::Dialogue_Menu_Clear_List() {
+ //TODO
+ warning("Dialogue_Menu_Clear_List()");
+ return false;
+}
+
+bool ScriptBase::Dialogue_Menu_Add_To_List(int answer) {
+ //TODO
+ warning("Dialogue_Menu_Add_To_List(%d)", answer);
+ return false;
+}
+
+bool ScriptBase::Dialogue_Menu_Add_DONE_To_List(int answerValue) {
+ //TODO
+ warning("Dialogue_Menu_Add_DONE_To_List(%d)", answerValue);
+ return false;
+}
+
+// Dialogue_Menu_Add_To_List_Never_Repeat_Once_Selected
+
+bool ScriptBase::DM_Add_To_List(int answer, int a2, int a3, int a4) {
+ //TODO
+ warning("DM_Add_To_List(%d, %d, %d, %d)", answer, a2, a3, a4);
+ return false;
+}
+
+bool ScriptBase::DM_Add_To_List_Never_Repeat_Once_Selected(int answer, int a2, int a3, int a4) {
+ //TODO
+ warning("DM_Add_To_List_Never_Repeat_Once_Selected(%d, %d, %d, %d)", answer, a2, a3, a4);
+ return false;
+}
+
+void ScriptBase::Dialogue_Menu_Remove_From_List(int answer) {
+ //TODO
+ warning("Dialogue_Menu_Remove_From_List(%d)", answer);
+}
+
+int ScriptBase::Dialogue_Menu_Query_Input() {
+ //TODO
+ warning("Dialogue_Menu_Query_Input()");
+ return 0;
+}
+
+int ScriptBase::Dialogue_Menu_Query_List_Size() {
+ //TODO
+ warning("Dialogue_Menu_Query_List_Size()");
+ return 0;
+}
void ScriptBase::Scene_Exit_Add_2D_Exit(int index, int left, int top, int right, int down, int type) {
_vm->_scene->_exits->add(index, Common::Rect(left, top, right, down), type);
@@ -765,39 +993,154 @@ void ScriptBase::Scene_2D_Region_Remove(int index) {
_vm->_scene->_regions->remove(index);
}
-// ScriptBase::World_Waypoint_Set
+void ScriptBase::World_Waypoint_Set(int waypointId, int sceneId, float x, float y, float z) {
+ //TODO
+ warning("World_Waypoint_Set(%d, %d, %f, %f, %f)", waypointId, sceneId, x, y, z);
+}
// ScriptBase::World_Waypoint_Reset
-// ScriptBase::World_Waypoint_Query_X
-// ScriptBase::World_Waypoint_Query_Y
-// ScriptBase::World_Waypoint_Query_Z
-// ScriptBase::Combat_Cover_Waypoint_Set_Data
-// ScriptBase::Combat_Flee_Waypoint_Set_Data
-// ScriptBase::Police_Maze_Target_Track_Add
+
+float ScriptBase::World_Waypoint_Query_X(int waypointId) {
+ //TODO
+ warning("World_Waypoint_Query_X(%d)", waypointId);
+ return 0.0f;
+}
+
+float ScriptBase::World_Waypoint_Query_Y(int waypointId) {
+ //TODO
+ warning("World_Waypoint_Query_Y(%d)", waypointId);
+ return 0.0f;
+}
+
+float ScriptBase::World_Waypoint_Query_Z(int waypointId) {
+ //TODO
+ warning("World_Waypoint_Query_Z(%d)", waypointId);
+ return 0.0f;
+}
+
+void ScriptBase::Combat_Cover_Waypoint_Set_Data(int combatCoverId, int a2, int sceneId, int a4, float x, float y, float z) {
+ //TODO
+ warning("Combat_Cover_Waypoint_Set_Data(%d, %d, %d, %d, %f, %f, %f)", combatCoverId, a2, sceneId, a4, x, y, z);
+}
+
+void ScriptBase::Combat_Flee_Waypoint_Set_Data(int combatFleeWaypointId, int a2, int sceneId, int a4, float x, float y, float z, int a8) {
+ //TODO
+ warning("Combat_Cover_Waypoint_Set_Data(%d, %d, %d, %d, %f, %f, %f, %d)", combatFleeWaypointId, a2, sceneId, a4, x, y, z, a8);
+}
+
+void ScriptBase::Police_Maze_Target_Track_Add(int itemId, float startX, float startY, float startZ, float endX, float endY, float endZ, int steps, signed int data[], bool a10) {
+ //TODO
+ warning("Police_Maze_Target_Track_Add(%d, %f, %f, %f, %f, %f, %f, %d, %x, %d)", itemId, startX, startY, startZ, endX, endY, endZ, steps, data, a10);
+
+}
+
// ScriptBase::Police_Maze_Query_Score
// ScriptBase::Police_Maze_Zero_Score
// ScriptBase::Police_Maze_Increment_Score
// ScriptBase::Police_Maze_Decrement_Score
// ScriptBase::Police_Maze_Set_Score
-// ScriptBase::Police_Maze_Set_Pause_State
-// ScriptBase::CDB_Set_Crime
-// ScriptBase::CDB_Set_Clue_Asset_Type
-// ScriptBase::SDB_Set_Actor
-// ScriptBase::SDB_Add_Photo_Clue
-// ScriptBase::SDB_Set_Name
-// ScriptBase::SDB_Set_Sex
-// ScriptBase::SDB_Add_Identity_Clue
-// ScriptBase::SDB_Add_MO_Clue
-// ScriptBase::SDB_Add_Whereabouts_Clue
-// ScriptBase::SDB_Add_Replicant_Clue
-// ScriptBase::SDB_Add_Non_Replicant_Clue
-// ScriptBase::SDB_Add_Other_Clue
+
+void ScriptBase::Police_Maze_Set_Pause_State(int a1) {
+ //TODO
+ warning("Police_Maze_Set_Pause_State(%d)", a1);
+}
+
+void ScriptBase::CDB_Set_Crime(int crimeId, int value) {
+ //TODO
+ warning("CDB_Set_Crime(%d, %d)", crimeId, value);
+}
+
+void ScriptBase::CDB_Set_Clue_Asset_Type(int assetId, int type) {
+ //TODO
+ warning("CDB_Set_Clue_Asset_Type(%d, %d)", assetId, type);
+}
+
+void ScriptBase::SDB_Set_Actor(int actorId, int a2) {
+ //TODO
+ warning("SDB_Set_Actor(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Photo_Clue(int actorId, int a2, int a3) {
+ //TODO
+ warning("SDB_Add_Photo_Clue(%d, %d, %d)", actorId, a2, a3);
+}
+
+void ScriptBase::SDB_Set_Name(int actorId) {
+ // not implemented in game
+}
+
+void ScriptBase::SDB_Set_Sex(int actorId, int a2) {
+ //TODO
+ warning("SDB_Set_Sex(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Identity_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_Identity_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_MO_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_MO_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Whereabouts_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_Whereabouts_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Replicant_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_Replicant_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Non_Replicant_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_Non_Replicant_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::SDB_Add_Other_Clue(int actorId, int a2) {
+ //TODO
+ warning("SDB_Add_Other_Clue(%d, %d)", actorId, a2);
+}
+
+void ScriptBase::Spinner_Set_Selectable_Destination_Flag(int a1, int a2) {
+ //TODO
+ warning("Spinner_Set_Selectable_Destination_Flag(%d, %d)", a1, a2);
+}
+
+// ScriptBase::Spinner_Query_Selectable_Destination_Flag
+
+int ScriptBase::Spinner_Interface_Choose_Dest(int a1, int a2) {
+ //TODO
+ warning("Spinner_Interface_Choose_Dest(%d, %d)", a1, a2);
+ return -1;
+}
+
// ScriptBase::Spinner_Set_Selectable_Destination_Flag
// ScriptBase::Spinner_Query_Selectable_Destination_Flag
// ScriptBase::Spinner_Interface_Choose_Dest
-// ScriptBase::ESPER_Flag_To_Activate
-// ScriptBase::Voight_Kampff_Activate
-// ScriptBase::Elevator_Activate
-// ScriptBase::View_Score_Board
+
+void ScriptBase::ESPER_Flag_To_Activate() {
+ //TODO
+ warning("ESPER_Flag_To_Activate()");
+}
+
+bool ScriptBase::Voight_Kampff_Activate(int a1, int a2){
+ //TODO
+ warning("Voight_Kampff_Activate(%d, %d)", a1, a2);
+ return false;
+}
+
+int ScriptBase::Elevator_Activate(int elevator) {
+ //TODO
+ warning("Elevator_Activate(%d)", elevator);
+ return 0;
+}
+
+void ScriptBase::View_Score_Board() {
+ //TODO
+ warning("View_Score_Board()");
+}
// ScriptBase::Query_Score
void ScriptBase::Set_Score(int a0, int a1) {
@@ -820,7 +1163,7 @@ void ScriptBase::Assign_Player_Gun_Miss_Sounds(int row, int soundId1, int soundI
_vm->_combat->setMissSoundId(row, 2, soundId3);
}
-void ScriptBase::Disable_Shadows(int *animationsIdsList, int listSize) {
+void ScriptBase::Disable_Shadows(int animationsIdsList[], int listSize) {
_vm->_sliceRenderer->disableShadows(animationsIdsList, listSize);
}
@@ -899,9 +1242,20 @@ void ScriptBase::Set_Fog_Density(char* fogName, float density) {
_vm->_scene->_set->_effects->setFogDensity(fogName, density);
}
-// ScriptBase::ADQ_Flush
-// ScriptBase::ADQ_Add
-// ScriptBase::ADQ_Add_Pause
+void ScriptBase::ADQ_Flush() {
+ //TODO
+ warning("ADQ_Flush()");
+}
+
+void ScriptBase::ADQ_Add(int a1, int a2, int a3) {
+ //TODO
+ warning("ADQ_Add(%d, %d, %d)", a1, a2, a3);
+}
+
+void ScriptBase::ADQ_Add_Pause(int delay) {
+ //TODO
+ warning("ADQ_Add_Pause(%d)", delay);
+}
bool ScriptBase::Game_Over() {
_vm->_gameIsRunning = false;
@@ -917,6 +1271,75 @@ void ScriptBase::I_Sez(const char *str) {
_vm->ISez(str);
}
+void ScriptBase::AI_Countdown_Timer_Start(int actorId, signed int timer, int seconds) {
+// if (timer >= 0 && timer <= 2)
+// _vm->_actors[actorId]->timerSet(timer, 1000 * seconds);
+}
+
+void ScriptBase::AI_Countdown_Timer_Reset(int actorId, int timer) {
+// if (timer >= 0 && timer <= 2)
+// _vm->_actors[actorId]->timerReset(timer);
+}
+
+void ScriptBase::AI_Movement_Track_Unpause(int actorId) {
+ //_vm->_actors[actorId]->movementTrackUnpause();
+}
+
+void ScriptBase::AI_Movement_Track_Pause(int actorId) {
+ //_vm->_actors[actorId]->movementTrackPause();
+}
+
+void ScriptBase::AI_Movement_Track_Repeat(int actorId) {
+ _vm->_actors[actorId]->_movementTrack->repeat();
+ //_vm->_actors[actorId]->movementTrackRepeat(1);
+}
+
+void ScriptBase::AI_Movement_Track_Append_Run_With_Facing(int actorId, int waypointId, int delay, int angle) {
+ _vm->_actors[actorId]->_movementTrack->append(waypointId, delay, angle, 1);
+}
+
+void ScriptBase::AI_Movement_Track_Append_With_Facing(int actorId, int waypointId, int delay, int angle) {
+ _vm->_actors[actorId]->_movementTrack->append(waypointId, delay, angle, 0);
+}
+
+void ScriptBase::AI_Movement_Track_Append_Run(int actorId, int waypointId, int delay) {
+ _vm->_actors[actorId]->_movementTrack->append(waypointId, delay, 1);
+}
+
+void ScriptBase::AI_Movement_Track_Append(int actorId, int waypointId, int delay) {
+ _vm->_actors[actorId]->_movementTrack->append(waypointId, delay, 0);
+}
+
+void ScriptBase::AI_Movement_Track_Flush(int actorId) {
+ _vm->_actors[actorId]->_movementTrack->flush();
+ _vm->_actors[actorId]->stopWalking(false);
+}
+
+void ScriptBase::KIA_Play_Actor_Dialogue(int a1, int a2) {
+ //TODO
+ warning("KIA_Play_Actor_Dialogue(%d, %d)", a1, a2);
+}
+
+void ScriptBase::KIA_Play_Slice_Model(int a1) {
+ //TODO
+ warning("KIA_Play_Slice_Model(%d)", a1);
+}
+
+void ScriptBase::KIA_Play_Photograph(int a1) {
+ //TODO
+ warning("KIA_Play_Photograph(%d)", a1);
+}
+
+void ScriptBase::ESPER_Add_Photo(const char* fileName, int a2, int a3) {
+ //TODO
+ warning("ESPER_Add_Photo(%s, %d, %d)", fileName, a2, a3);
+}
+
+void ScriptBase::ESPER_Define_Special_Region(int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8, int a9, int a10, int a11, int a12, int a13, const char *name) {
+ //TODO
+ warning("ESPER_Define_Special_Region(%d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %d, %s)", a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, name);
+}
+
AIScripts::AIScripts(BladeRunnerEngine *vm)
: _vm(vm),
_inScriptCounter(0)
diff --git a/engines/bladerunner/script/script.h b/engines/bladerunner/script/script.h
index 8f38657ae0..20ed8456ca 100644
--- a/engines/bladerunner/script/script.h
+++ b/engines/bladerunner/script/script.h
@@ -42,7 +42,7 @@ public:
protected:
void Preload(int animationId);
- void Actor_Put_In_Set(int id, int set);
+ void Actor_Put_In_Set(int actorId, int set);
void Actor_Set_At_XYZ(int actorId, float x, float y, float z, int direction);
void Actor_Set_At_Waypoint(int actorId, int waypointId, int angle);
bool Region_Check(int left, int top, int right, int down);
@@ -55,7 +55,7 @@ protected:
void Actor_Face_Waypoint(int actorId, int waypointId, bool animate);
void Actor_Face_XYZ(int actorId, float x, float y, float z, bool animate);
void Actor_Face_Current_Camera(int actorId, bool animate);
- void Actor_Face_Heading(int actorId, int heading);
+ void Actor_Face_Heading(int actorId, int heading, bool animate);
int Actor_Query_Friendliness_To_Other(int actorId, int otherActorId);
void Actor_Modify_Friendliness_To_Other(int actorId, int otherActorId, signed int change);
void Actor_Set_Friendliness_To_Other(int actorId, int otherActorId, int friendliness);
@@ -101,16 +101,16 @@ protected:
int Slice_Animation_Query_Number_Of_Frames(int animationId);
void Actor_Change_Animation_Mode(int actorId, int animationMode);
int Actor_Query_Animation_Mode(int actorId);
- // Loop_Actor_Walk_To_Actor
- // Loop_Actor_Walk_To_Item
- bool Loop_Actor_Walk_To_Scene_Object(int actorId, const char *objectName, int distance, int a4, int a5);
- // Loop_Actor_Walk_To_Waypoint
- void Loop_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a4, int a5, int a6, int a7);
- // Async_Actor_Walk_To_Waypoint
- // Async_Actor_Walk_To_XYZ
- // Actor_Force_Stop_Walking
- // Loop_Actor_Travel_Stairs
- // Loop_Actor_Travel_Ladder
+ bool Loop_Actor_Walk_To_Actor(int actorId, int otherActorId, int a3, int a4, bool running);
+ bool Loop_Actor_Walk_To_Item(int actorId, int itemId, int a3, int a4, bool running);
+ bool Loop_Actor_Walk_To_Scene_Object(int actorId, const char *objectName, int distance, int a4, bool running);
+ bool Loop_Actor_Walk_To_Waypoint(int actorId, int waypointId, int a3, int a4, bool running);
+ bool Loop_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a4, int a5, bool running, int a7);
+ void Async_Actor_Walk_To_Waypoint(int actorId, int waypointId, int a3, int running);
+ void Async_Actor_Walk_To_XYZ(int actorId, float x, float y, float z, int a5, bool running);
+ void Actor_Force_Stop_Walking(int actorId);
+ bool Loop_Actor_Travel_Stairs(int actorId, int a2, int a3, int a4);
+ bool Loop_Actor_Travel_Ladder(int actorId, int a2, int a3, int a4);
void Actor_Clue_Add_To_Database(int actorId, int clueId, int unknown, bool clueAcquired, bool unknownFlag, int fromActorId);
void Actor_Clue_Acquire(int actorId, int clueId, byte unknownFlag, int fromActorId);
void Actor_Clue_Lose(int actorId, int clueId);
@@ -119,12 +119,12 @@ protected:
void Actor_Clues_Transfer_New_From_Mainframe(int actorId);
void Actor_Set_Invisible(int actorId, bool isInvisible);
void Actor_Set_Immunity_To_Obstacles(int actorId, bool isImmune);
- // Item_Add_To_World
- // Item_Remove_From_World
- // Item_Spin_In_World
- // Item_Flag_As_Target
- // Item_Flag_As_Non_Target
- // Item_Pickup_Spin_Effect
+ void Item_Add_To_World(int itemId, int animationId, int sceneIndex, float x, float y, float z, signed int angle, int height, int width, bool isTargetable, bool isObstacle, bool isPoliceMazeEnemy, bool updateOnly);
+ void Item_Remove_From_World(int itemId);
+ void Item_Spin_In_World(int itemId);
+ void Item_Flag_As_Target(int itemId);
+ void Item_Flag_As_Non_Target(int itemId);
+ void Item_Pickup_Spin_Effect(int a1, int a2, int a3);
int Animation_Open();
int Animation_Close();
int Animation_Start();
@@ -153,92 +153,92 @@ protected:
int Global_Variable_Decrement(int, int);
int Random_Query(int min, int max);
void Sound_Play(int id, int volume, int panFrom, int panTo, int priority);
- // Sound_Play_Speech_Line
+ void Sound_Play_Speech_Line(int actorId, int speechId, int a3, int a4, int a5);
// Sound_Left_Footstep_Walk
// Sound_Right_Footstep_Walk
// Sound_Left_Footstep_Run
// Sound_Right_Footstep_Run
// Sound_Walk_Shuffle_Stop
- // Footstep_Sounds_Set
- // Footstep_Sound_Override_On
- // Footstep_Sound_Override_Off
- // Music_Play
- // Music_Adjust
- // Music_Stop
- // Music_Is_Playing
- // Overlay_Play
- // Overlay_Remove
+ void Footstep_Sounds_Set(int index, int value);
+ void Footstep_Sound_Override_On(int footstepSoundOverride);
+ void Footstep_Sound_Override_Off();
+ bool Music_Play(int a1, int a2, int a3, int a4, int a5, int a6, int a7);
+ void Music_Adjust(int a1, int a2, int a3);
+ void Music_Stop(int a1);
+ bool Music_Is_Playing();
+ void Overlay_Play(const char *overlay, int a2, int a3, int a4, int a5);
+ void Overlay_Remove(const char *overlay);
void Scene_Loop_Set_Default(int);
void Scene_Loop_Start_Special(int, int, int);
void Outtake_Play(int id, int noLocalization = false, int container = -1);
void Ambient_Sounds_Add_Sound(int id, int time1, int time2, int volume1, int volume2, int pan1begin, int pan1end, int pan2begin, int pan2end, int priority, int unk);
- // Ambient_Sounds_Remove_Sound
- // Ambient_Sounds_Add_Speech_Sound
+ void Ambient_Sounds_Remove_Sound(int id, bool a2);
+ void Ambient_Sounds_Add_Speech_Sound(int id, int unk1, int time1, int time2, int volume1, int volume2, int pan1begin, int pan1end, int pan2begin, int pan2end, int priority, int unk2);
// Ambient_Sounds_Remove_Speech_Sound
- // Ambient_Sounds_Play_Sound
+ int Ambient_Sounds_Play_Sound(int a1, int a2, int a3, int a4, int a5);
// Ambient_Sounds_Play_Speech_Sound
void Ambient_Sounds_Remove_All_Non_Looping_Sounds(int time);
void Ambient_Sounds_Add_Looping_Sound(int id, int volume, int pan, int fadeInTime);
- // Ambient_Sounds_Adjust_Looping_Sound
- // Ambient_Sounds_Remove_Looping_Sound
+ void Ambient_Sounds_Adjust_Looping_Sound(int id, int panBegin, int panEnd, int a4);
+ void Ambient_Sounds_Remove_Looping_Sound(int id, bool a2);
void Ambient_Sounds_Remove_All_Looping_Sounds(int time);
void Setup_Scene_Information(float actorX, float actorY, float actorZ, int actorFacing);
- // Dialogue_Menu_Appear
- // Dialogue_Menu_Disappear
- // Dialogue_Menu_Clear_List
- // Dialogue_Menu_Add_To_List
- // Dialogue_Menu_Add_DONE_To_List
+ bool Dialogue_Menu_Appear(int x, int y);
+ bool Dialogue_Menu_Disappear();
+ bool Dialogue_Menu_Clear_List();
+ bool Dialogue_Menu_Add_To_List(int answer);
+ bool Dialogue_Menu_Add_DONE_To_List(int answer);
// Dialogue_Menu_Add_To_List_Never_Repeat_Once_Selected
- // DM_Add_To_List
- // DM_Add_To_List_Never_Repeat_Once_Selected
- // Dialogue_Menu_Remove_From_List
- // Dialogue_Menu_Query_Input
- // Dialogue_Menu_Query_List_Size
+ bool DM_Add_To_List(int answer, int a2, int a3, int a4);
+ bool DM_Add_To_List_Never_Repeat_Once_Selected(int answer, int a2, int a3, int a4);
+ void Dialogue_Menu_Remove_From_List(int answer);
+ int Dialogue_Menu_Query_Input();
+ int Dialogue_Menu_Query_List_Size();
void Scene_Exit_Add_2D_Exit(int index, int left, int top, int right, int down, int type);
void Scene_Exit_Remove(int index);
void Scene_Exits_Disable();
void Scene_Exits_Enable();
void Scene_2D_Region_Add(int index, int left, int top, int right, int down);
void Scene_2D_Region_Remove(int index);
- // World_Waypoint_Set
+ void World_Waypoint_Set(int waypointId, int sceneId, float x, float y, float z);
// World_Waypoint_Reset
- // World_Waypoint_Query_X
- // World_Waypoint_Query_Y
- // World_Waypoint_Query_Z
- // Combat_Cover_Waypoint_Set_Data
- // Combat_Flee_Waypoint_Set_Data
- // Police_Maze_Target_Track_Add
+ float World_Waypoint_Query_X(int waypointId);
+ float World_Waypoint_Query_Y(int waypointId);
+ float World_Waypoint_Query_Z(int waypointId);
+ void Combat_Cover_Waypoint_Set_Data(int combatCoverId, int a2, int sceneId, int a4, float x, float y, float z);
+ void Combat_Flee_Waypoint_Set_Data(int combatFleeWaypointId, int a2, int sceneId, int a4, float x, float y, float z, int a8);
+ void Police_Maze_Target_Track_Add(int itemId, float startX, float startY, float startZ, float endX, float endY, float endZ, int steps, signed int data[], bool a10);
// Police_Maze_Query_Score
// Police_Maze_Zero_Score
// Police_Maze_Increment_Score
// Police_Maze_Decrement_Score
// Police_Maze_Set_Score
- // Police_Maze_Set_Pause_State
- // CDB_Set_Crime
- // CDB_Set_Clue_Asset_Type
- // SDB_Set_Actor
- // SDB_Add_Photo_Clue
- // SDB_Set_Name
- // SDB_Set_Sex
- // SDB_Add_Identity_Clue
- // SDB_Add_MO_Clue
- // SDB_Add_Whereabouts_Clue
- // SDB_Add_Replicant_Clue
- // SDB_Add_Non_Replicant_Clue
- // SDB_Add_Other_Clue
- // Spinner_Set_Selectable_Destination_Flag
+ void Police_Maze_Set_Pause_State(int a1);
+ void CDB_Set_Crime(int crimeId, int value);
+ void CDB_Set_Clue_Asset_Type(int assetId, int type);
+ void SDB_Set_Actor(int actorId, int a2);
+ void SDB_Add_Photo_Clue(int actorId, int a2, int a3);
+ void SDB_Set_Name(int actorId);
+ void SDB_Set_Sex(int actorId, int a2);
+ void SDB_Add_Identity_Clue(int actorId, int a2);
+ void SDB_Add_MO_Clue(int actorId, int a2);
+ void SDB_Add_Whereabouts_Clue(int actorId, int a2);
+ void SDB_Add_Replicant_Clue(int actorId, int a2);
+ void SDB_Add_Non_Replicant_Clue(int actorId, int a2);
+ void SDB_Add_Other_Clue(int actorId, int a2);
+ void Spinner_Set_Selectable_Destination_Flag(int a1, int a2);
// Spinner_Query_Selectable_Destination_Flag
- // Spinner_Interface_Choose_Dest
- // ESPER_Flag_To_Activate
- // Voight_Kampff_Activate
- // Elevator_Activate
- // View_Score_Board
+ int Spinner_Interface_Choose_Dest(int a1, int a2);
+ void ESPER_Flag_To_Activate();
+ bool Voight_Kampff_Activate(int a1, int a2);
+ int Elevator_Activate(int elevator);
+ void View_Score_Board();
// Query_Score
void Set_Score(int a0, int a1);
void Give_McCoy_Ammo(int ammoType, int ammo);
void Assign_Player_Gun_Hit_Sounds(int row, int soundId1, int soundId2, int soundId3);
void Assign_Player_Gun_Miss_Sounds(int row, int soundId1, int soundId2, int soundId3);
- void Disable_Shadows(int *animationsIdsList, int listSize);
+ void Disable_Shadows(int animationsIdsList[], int listSize);
bool Query_System_Currently_Loading_Game();
void Actor_Retired_Here(int actorId, int width, int height, int retired, int retiredByActorId);
void Clickable_Object(const char *objectName);
@@ -252,12 +252,35 @@ protected:
void Set_Fade_Density(float density);
void Set_Fog_Color(char* fogName, float r, float g, float b);
void Set_Fog_Density(char* fogName, float density);
- // ADQ_Flush
- // ADQ_Add
- // ADQ_Add_Pause
+ void ADQ_Flush();
+ void ADQ_Add(int a1, int a2, int a3);
+ void ADQ_Add_Pause(int delay);
bool Game_Over();
void Autosave_Game(int textId);
void I_Sez(const char *str);
+
+ void AI_Countdown_Timer_Start(int actorId, signed int timer, int seconds);
+ void AI_Countdown_Timer_Reset(int actorId, int timer);
+ void AI_Movement_Track_Unpause(int actorId);
+ void AI_Movement_Track_Pause(int actorId);
+ void AI_Movement_Track_Repeat(int actorId);
+ void AI_Movement_Track_Append_Run_With_Facing(int actorId, int waypointId, int delay, int angle);
+ void AI_Movement_Track_Append_With_Facing(int actorId, int waypointId, int delay, int angle);
+ void AI_Movement_Track_Append_Run(int actorId, int waypointId, int delay);
+ void AI_Movement_Track_Append(int actorId, int waypointId, int delay);
+ void AI_Movement_Track_Flush(int actorId);
+
+ void ESPER_Add_Photo(const char* fileName, int a2, int a3);
+ void ESPER_Define_Special_Region(int a1, int a2, int a3, int a4, int a5, int a6, int a7, int a8, int a9, int a10, int a11, int a12, int a13, const char *name);
+
+ void KIA_Play_Actor_Dialogue(int a1, int a2);
+ void KIA_Play_Slice_Model(int a1);
+ void KIA_Play_Photograph(int a1);
+
+ void VK_Play_Speech_Line(int actorIndex, int a2, float a3);
+ void VK_Add_Question(int a1, int a2, int a3);
+ void VK_Subject_Reacts(int a1, int a2, int a3, int a4);
+ void VK_Eye_Animates(int a1);
};
class SceneScriptBase : public ScriptBase {
@@ -268,11 +291,17 @@ public:
virtual void InitializeScene() = 0;
virtual void SceneLoaded() = 0;
- virtual bool ClickedOn3DObject(const char *objectName) = 0;
+ virtual bool MouseClick(int x, int y) = 0;
+ virtual bool ClickedOn3DObject(const char *objectName, bool a2) = 0;
+ virtual bool ClickedOnActor(int actorId) = 0;
+ virtual bool ClickedOnItem(int itemId, bool a2) = 0;
+ virtual bool ClickedOnExit(int exitId) = 0;
virtual bool ClickedOn2DRegion(int region) = 0;
virtual void SceneFrameAdvanced(int frame) = 0;
- virtual void SceneActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) = 0;
+ virtual void ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) = 0;
virtual void PlayerWalkedIn() = 0;
+ virtual void PlayerWalkedOut() = 0;
+ virtual void DialogueQueueFlushed(int a1) = 0;
};
/*
@@ -296,11 +325,17 @@ public:
void InitializeScene();
void SceneLoaded();
- bool ClickedOn3DObject(const char *objectName);
- bool ClickedOn2DRegion(int region);
+ bool MouseClick(int x, int y);
+ bool ClickedOn3DObject(const char *objectName, bool a2);
+ bool ClickedOnActor(int actorId);
+ bool ClickedOnItem(int itemId, bool a2);
+ bool ClickedOnExit(int exitId);
+ bool ClickedOn2DRegion(int region);
void SceneFrameAdvanced(int frame);
- void SceneActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet);
+ void ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet);
void PlayerWalkedIn();
+ void PlayerWalkedOut();
+ void DialogueQueueFlushed(int a1);
};
#define DECLARE_SCRIPT(name) \
@@ -311,16 +346,467 @@ public: \
{} \
void InitializeScene(); \
void SceneLoaded(); \
- bool ClickedOn3DObject(const char *objectName); \
+ bool MouseClick(int x, int y); \
+ bool ClickedOn3DObject(const char *objectName, bool a2); \
+ bool ClickedOnActor(int actorId); \
+ bool ClickedOnItem(int itemId, bool a2); \
+ bool ClickedOnExit(int exitId); \
bool ClickedOn2DRegion(int region); \
void SceneFrameAdvanced(int frame); \
- void SceneActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet); \
+ void ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet); \
void PlayerWalkedIn(); \
+ void PlayerWalkedOut(); \
+ void DialogueQueueFlushed(int a1); \
private:
#define END_SCRIPT };
+DECLARE_SCRIPT(AR01)
+END_SCRIPT
+
+DECLARE_SCRIPT(AR02)
+ void sub_402694();
+ void sub_402AE0();
+ void sub_402CE4();
+END_SCRIPT
+
+DECLARE_SCRIPT(BB01)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB02)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB03)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB04)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB05)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB06)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB07)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB08)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB09)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB10)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB11)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB12)
+END_SCRIPT
+
+DECLARE_SCRIPT(BB51)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT01)
+ void sub_40269C();
+END_SCRIPT
+
+DECLARE_SCRIPT(CT02)
+ void sub_401ACC();
+END_SCRIPT
+
+DECLARE_SCRIPT(CT03)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT04)
+ void sub_401D4C();
+END_SCRIPT
+
+DECLARE_SCRIPT(CT05)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT06)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT07)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT08)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT09)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT10)
+ void sub_401844();
+END_SCRIPT
+
+DECLARE_SCRIPT(CT11)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT12)
+END_SCRIPT
+
+DECLARE_SCRIPT(CT51)
+END_SCRIPT
+
+DECLARE_SCRIPT(DR01)
+END_SCRIPT
+
+DECLARE_SCRIPT(DR02)
+END_SCRIPT
+
+DECLARE_SCRIPT(DR03)
+ void sub_401B18();
+END_SCRIPT
+
+DECLARE_SCRIPT(DR04)
+ bool sub_401160();
+END_SCRIPT
+
+DECLARE_SCRIPT(DR05)
+END_SCRIPT
+
+DECLARE_SCRIPT(DR06)
+END_SCRIPT
+
+DECLARE_SCRIPT(HC01)
+ void sub_402384();
+ void sub_40346C();
+END_SCRIPT
+
+DECLARE_SCRIPT(HC02)
+END_SCRIPT
+
+DECLARE_SCRIPT(HC03)
+END_SCRIPT
+
+DECLARE_SCRIPT(HC04)
+ void sub_401B90();
+END_SCRIPT
+
+DECLARE_SCRIPT(HF01)
+ void sub_4026B4();
+ void sub_4032DC();
+ void sub_403484();
+END_SCRIPT
+
+DECLARE_SCRIPT(HF02)
+END_SCRIPT
+
+DECLARE_SCRIPT(HF03)
+ void sub_401C80();
+END_SCRIPT
+
+DECLARE_SCRIPT(HF04)
+END_SCRIPT
+
+DECLARE_SCRIPT(HF05)
+ void sub_402370();
+ void sub_402970();
+ void sub_402AE4();
+ void sub_403738();
+ void sub_403A34(int actorId);
+ void sub_403F0C();
+ void sub_40410C();
+ void sub_4042E4();
+ void sub_404474();
+ int sub_404858();
+ int sub_4048C0();
+END_SCRIPT
+
+DECLARE_SCRIPT(HF06)
+ void sub_401EF4();
+ void sub_4023E0();
+END_SCRIPT
+
+DECLARE_SCRIPT(HF07)
+ int sub_401864();
+END_SCRIPT
+
+DECLARE_SCRIPT(KP01)
+END_SCRIPT
+
+DECLARE_SCRIPT(KP02)
+END_SCRIPT
+
+DECLARE_SCRIPT(KP03)
+ void sub_401E54();
+END_SCRIPT
+
+DECLARE_SCRIPT(KP04)
+END_SCRIPT
+
+DECLARE_SCRIPT(KP05)
+END_SCRIPT
+
+DECLARE_SCRIPT(KP06)
+END_SCRIPT
+
+DECLARE_SCRIPT(KP07)
+END_SCRIPT
+
+DECLARE_SCRIPT(MA01)
+END_SCRIPT
+
+DECLARE_SCRIPT(MA02)
+ void sub_401E4C();
+ bool sub_401F7C();
+ void sub_402044();
+END_SCRIPT
+
+//MA03 does not exists
+
+DECLARE_SCRIPT(MA04)
+ bool sub_402758();
+ bool sub_402820();
+ bool sub_402888();
+ void sub_4028A8();
+ void sub_402F2C();
+ void sub_4032A0();
+ void sub_4034D8();
+ void sub_403864();
+ void sub_403DA8();
+END_SCRIPT
+
+DECLARE_SCRIPT(MA05)
+ bool sub_401990();
+END_SCRIPT
+
+DECLARE_SCRIPT(MA06)
+ bool sub_4012C0();
+ void sub_4014E4();
+END_SCRIPT
+
+DECLARE_SCRIPT(MA07)
+END_SCRIPT
+
+DECLARE_SCRIPT(MA08)
+END_SCRIPT
+
+DECLARE_SCRIPT(NR01)
+END_SCRIPT
+
+DECLARE_SCRIPT(NR02)
+ void sub_402134();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR03)
+ void sub_40259C(int frame);
+ void sub_402994();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR04)
+ void sub_401DB0();
+ void sub_402860(int frame);
+ void sub_402960();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR05)
+ void sub_401F74(int frame);
+ void sub_4020B4();
+ void sub_4022DC();
+ void sub_402A48(int actorId);
+ void sub_402B9C();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR06)
+ void sub_401BAC();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR07)
+ void sub_4018D4();
+ void sub_401A10();
+ void sub_401C60();
+ void sub_401EF4();
+ void sub_4020F0();
+ void sub_402284();
+ void sub_402510();
+ void sub_402614();
+ void sub_402738();
+ void sub_4028FC();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR08)
+ void sub_4021B4();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR09)
+ void sub_40172C();
+END_SCRIPT
+
+DECLARE_SCRIPT(NR10)
+END_SCRIPT
+
+DECLARE_SCRIPT(NR11)
+ void sub_4027D0(int actorId, signed int frame);
+ void sub_4028EC();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS01)
+END_SCRIPT
+
+DECLARE_SCRIPT(PS02)
+ void sub_4018BC();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS03)
+END_SCRIPT
+
+DECLARE_SCRIPT(PS04)
+ void sub_4017E4();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS05)
+ void sub_401B34();
+ void sub_401C30();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS06)
+END_SCRIPT
+
+DECLARE_SCRIPT(PS07)
+ void sub_401D60();
+END_SCRIPT
+
+// PS08 does not exits
+
+DECLARE_SCRIPT(PS09)
+ void sub_402090();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS10)
+ void sub_402238();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS11)
+ void sub_402744();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS12)
+ void sub_4028C4();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS13)
+ void sub_40267C();
+END_SCRIPT
+
+DECLARE_SCRIPT(PS14)
+END_SCRIPT
+
+DECLARE_SCRIPT(PS15)
+END_SCRIPT
+
DECLARE_SCRIPT(RC01)
void sub_403850();
+ void sub_4037AC();
+END_SCRIPT
+
+DECLARE_SCRIPT(RC02)
+ void sub_402A7C();
+END_SCRIPT
+
+DECLARE_SCRIPT(RC03)
+ void sub_402834();
+END_SCRIPT
+
+DECLARE_SCRIPT(RC04)
+ void sub_401DF4();
+END_SCRIPT
+
+DECLARE_SCRIPT(RC51)
+END_SCRIPT
+
+DECLARE_SCRIPT(TB02)
+ void sub_402644();
+ void sub_402B50();
+END_SCRIPT
+
+DECLARE_SCRIPT(TB03)
+END_SCRIPT
+
+DECLARE_SCRIPT(TB05)
+END_SCRIPT
+
+DECLARE_SCRIPT(TB06)
+END_SCRIPT
+
+DECLARE_SCRIPT(TB07)
+ void sub_401B0C();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG01)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG02)
+ bool sub_402354();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG03)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG04)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG05)
+ int sub_4021B0();
+ void sub_402218();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG06)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG07)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG08)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG09)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG10)
+END_SCRIPT
+
+// UG11 does not exists
+
+DECLARE_SCRIPT(UG12)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG13)
+ void sub_40223C();
+ void sub_4023D8();
+ void sub_4025E0();
+ void sub_402960();
+ int sub_402AD0();
+ void sub_402AD4();
+ void sub_402E24();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG14)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG15)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG16)
+ void sub_401D78();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG17)
+END_SCRIPT
+
+DECLARE_SCRIPT(UG18)
+ void sub_402734();
+ void sub_402DE8();
+ void sub_402F8C();
+ void sub_403114();
+ void sub_403278();
+ void sub_403588();
+END_SCRIPT
+
+DECLARE_SCRIPT(UG19)
END_SCRIPT
#undef DECLARE_SCRIPT
diff --git a/engines/bladerunner/script/tb02.cpp b/engines/bladerunner/script/tb02.cpp
new file mode 100644
index 0000000000..50f3b9728e
--- /dev/null
+++ b/engines/bladerunner/script/tb02.cpp
@@ -0,0 +1,469 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptTB02::InitializeScene() {
+ if (Game_Flag_Query(155)) {
+ Setup_Scene_Information(-152.0f, 0.0f, 1774.0f, 999);
+ } else if (Game_Flag_Query(95)) {
+ Setup_Scene_Information(-32.0f, 0.0f, 1578.0f, 639);
+ } else if (Game_Flag_Query(608)) {
+ Setup_Scene_Information(-32.0f, 0.0f, 1578.0f, 639);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(27, 0, -1);
+ Setup_Scene_Information(-304.0f, -81.46f, 1434.0f, 250);
+ }
+ if (Global_Variable_Query(1) > 3) {
+ Scene_Exit_Add_2D_Exit(0, 0, 455, 639, 479, 2);
+ }
+ Ambient_Sounds_Add_Looping_Sound(211, 20, 0, 1);
+ Ambient_Sounds_Add_Sound(212, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(213, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(214, 2, 20, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(215, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(216, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ if (Global_Variable_Query(1) <= 3) {
+ Ambient_Sounds_Add_Looping_Sound(45, 35, 0, 1);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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);
+ }
+ if (Game_Flag_Query(307) && Global_Variable_Query(1) < 4) {
+ Scene_Exit_Add_2D_Exit(2, 67, 0, 233, 362, 3);
+ }
+ if (Game_Flag_Query(155)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+ Actor_Put_In_Set(17, 17);
+ Actor_Set_At_XYZ(17, -38.53f, 2.93f, 1475.97f, 673);
+ if (Global_Variable_Query(1) == 4) {
+ if (Actor_Query_Goal_Number(17) < 300) {
+ Actor_Set_Goal_Number(17, 300);
+ }
+ Scene_Exit_Add_2D_Exit(1, 430, 235, 487, 396, 0);
+ }
+}
+
+void ScriptTB02::SceneLoaded() {
+ Obstacle_Object("SPHERE02", true);
+ Unobstacle_Object("BOX36", true);
+}
+
+bool ScriptTB02::MouseClick(int x, int y) {
+ return Region_Check(600, 300, 639, 479);
+}
+
+bool ScriptTB02::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptTB02::ClickedOnActor(int actorId) {
+ if (actorId == 17) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -76.35f, 0.15f, 1564.2f, 0, 1, false, 0)) {
+ Actor_Face_Actor(0, 17, true);
+ int v1 = Global_Variable_Query(1);
+ if (v1 == 2) {
+ if (Game_Flag_Query(450) && !Game_Flag_Query(451)) {
+ Actor_Says(0, 5150, 18);
+ Actor_Says(17, 60, 12);
+ Actor_Says(17, 70, 13);
+ Actor_Says(0, 5155, 13);
+ Actor_Modify_Friendliness_To_Other(17, 0, -1);
+ return true;
+ }
+ if (!Game_Flag_Query(450) && !Game_Flag_Query(451)) {
+ Game_Flag_Set(450);
+ Actor_Says(0, 5160, 18);
+ Actor_Says(17, 80, 14);
+ Scene_Exit_Add_2D_Exit(1, 430, 235, 487, 396, 0);
+ return true;
+ }
+ if (Game_Flag_Query(451)) {
+ sub_402644();
+ } else {
+ Actor_Face_Actor(17, 0, true);
+ Actor_Says(0, 5150, 18);
+ Actor_Says(17, 60, 13);
+ Actor_Says(17, 70, 12);
+ Actor_Says(0, 5155, 13);
+ Actor_Modify_Friendliness_To_Other(17, 0, -1);
+ Actor_Face_Heading(17, 788, false);
+ }
+ return true;
+ }
+ if (v1 == 3) {
+ Actor_Says(0, 5235, 18);
+ Actor_Says(17, 280, 13);
+ Actor_Says(17, 290, 12);
+ Actor_Says(0, 5240, 18);
+ Actor_Says(17, 300, 12);
+ return false;
+ }
+ if (v1 == 4) {
+ if (Actor_Query_Goal_Number(17) == 300) {
+ Actor_Set_Goal_Number(17, 301);
+ }
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptTB02::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptTB02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -152.0f, 0.0f, 1774.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(154);
+ Game_Flag_Reset(450);
+ Set_Enter(17, 83);
+ Async_Actor_Walk_To_XYZ(0, -152.0f, 0.0f, 1890.0f, 0, false);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -32.0f, 0.0f, 1578.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (Global_Variable_Query(1) < 4) {
+ Game_Flag_Set(451);
+ Game_Flag_Set(96);
+ Set_Enter(72, 84);
+ } else {
+ Set_Enter(18, 108);
+ }
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -192.0f, 0.0f, 1430.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 800, false);
+ Loop_Actor_Travel_Stairs(0, 9, 0, 0);
+ if (Actor_Query_Goal_Number(17) == 300) {
+ Actor_Set_Goal_Number(17, 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(450);
+ switch (Spinner_Interface_Choose_Dest(-1, 0)) {
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ break;
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ break;
+ default:
+ Game_Flag_Set(261);
+ break;
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptTB02::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptTB02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptTB02::PlayerWalkedIn() {
+ if (Game_Flag_Query(625) && ((Game_Flag_Reset(625) , Global_Variable_Query(1) == 2) || Global_Variable_Query(1) == 3)) {
+ Set_Enter(18, 108);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(155)) {
+ Async_Actor_Walk_To_XYZ(0, -152.0f, 0.0f, 1702.0f, 0, false);
+ Game_Flag_Reset(155);
+ } else if (Game_Flag_Query(95)) {
+ Game_Flag_Reset(95);
+ } else if (Game_Flag_Query(608)) {
+ Game_Flag_Reset(608);
+ if (Actor_Query_Goal_Number(17) == 300) {
+ Actor_Set_Goal_Number(17, 302);
+ }
+ Music_Play(1, 50, 0, 2, -1, 0, 0);
+ } else {
+ Loop_Actor_Travel_Stairs(0, 9, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, -140.0f, 0.79f, 1470.0f, 0, 0, false, 0);
+ }
+ int v0 = Global_Variable_Query(1);
+ if (v0 > 4) {
+ //return false;
+ return;
+ }
+ if (v0 == 2) {
+ if (!Game_Flag_Query(453)) {
+ Player_Loses_Control();
+ Actor_Says(0, 5125, 18);
+ Actor_Says(17, 0, 50);
+ Actor_Says(0, 5130, 13);
+ Actor_Says(17, 10, 15);
+ Item_Pickup_Spin_Effect(975, 351, 315);
+ Actor_Says(17, 20, 23);
+ Actor_Says(0, 5140, 17);
+ Actor_Says(17, 30, 14);
+ Actor_Says(17, 40, 13);
+ Loop_Actor_Walk_To_XYZ(0, -140.0f, 0.0f, 1586.0f, 12, 0, false, 0);
+ Loop_Actor_Walk_To_XYZ(0, -112.0f, 0.0f, 1586.0f, 12, 0, false, 0);
+ Actor_Face_Actor(0, 17, true);
+ Actor_Face_Actor(17, 0, true);
+ Actor_Says(0, 5145, 13);
+ Actor_Says(17, 50, 15);
+ Actor_Face_Heading(17, 788, false);
+ Actor_Clue_Acquire(0, 45, 1, -1);
+ Game_Flag_Set(453);
+ Game_Flag_Set(450);
+ Player_Gains_Control();
+ Loop_Actor_Walk_To_XYZ(0, -138.17f, 0.15f, 1578.32f, 0, 1, false, 0);
+ }
+ if (Game_Flag_Query(450)) {
+ Scene_Exit_Add_2D_Exit(1, 430, 235, 487, 396, 0);
+ }
+ if (Game_Flag_Query(451) && !Game_Flag_Query(450)) {
+ Actor_Says(17, 90, 18);
+ Game_Flag_Set(450);
+ Scene_Exit_Add_2D_Exit(1, 430, 235, 487, 396, 0);
+ }
+ if (Game_Flag_Query(451) && !Game_Flag_Query(456)) {
+ Loop_Actor_Walk_To_Actor(1, 0, 36, 1, false);
+ Actor_Says(1, 2220, 14);
+ Actor_Says(0, 5245, 13);
+ Actor_Says(1, 2230, 12);
+ Actor_Says(1, 2240, 13);
+ sub_402B50();
+ //return true;
+ }
+ //return false;
+ return;
+ }
+ if (v0 == 3 && !Game_Flag_Query(455)) {
+ Loop_Actor_Walk_To_XYZ(0, -131.28f, 0.79f, 1448.25f, 12, 1, false, 0);
+ Actor_Says(17, 260, 15);
+ Actor_Says(0, 5225, 16);
+ Actor_Says(17, 270, 14);
+ Game_Flag_Set(455);
+ Actor_Modify_Friendliness_To_Other(17, 0, -1);
+ }
+ //return false;
+}
+
+void ScriptTB02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptTB02::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptTB02::sub_402644() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(700, 4, 5, 6);
+ if (Actor_Clue_Query(0, 44)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(710, 5, 5, 4);
+ }
+ if (Actor_Clue_Query(0, 50) || Actor_Clue_Query(0, 51)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(720, 3, 5, 5);
+ }
+ if (Actor_Clue_Query(0, 51)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(730, 3, 4, 8);
+ }
+ Dialogue_Menu_Add_DONE_To_List(100);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 100:
+ Actor_Says(0, 5145, 13);
+ Actor_Says(17, 50, 15);
+ break;
+ case 730:
+ Actor_Says(0, 5180, 16);
+ Actor_Says(17, 240, 12);
+ Actor_Says(0, 5215, 18);
+ Actor_Says(17, 250, 13);
+ Actor_Says(0, 5220, 16);
+ break;
+ case 720:
+ Actor_Says(0, 5175, 12);
+ Actor_Says(17, 210, 14);
+ Actor_Says(0, 5200, 13);
+ Actor_Says(17, 220, 13);
+ Actor_Says(0, 5205, 15);
+ Actor_Says(17, 230, 12);
+ Actor_Says(0, 5210, 12);
+ break;
+ case 710:
+ Actor_Says(0, 5170, 12);
+ Actor_Says(17, 180, 12);
+ Actor_Says(17, 190, 14);
+ if (Game_Flag_Query(102)) {
+ Actor_Says(0, 5195, 13);
+ Actor_Says(17, 200, 13);
+ }
+ break;
+ case 700:
+ Actor_Says(0, 5165, 11);
+ Actor_Says(17, 100, 13);
+ Actor_Says(17, 110, 12);
+ Actor_Says(0, 5185, 15);
+ Actor_Says(17, 120, 12);
+ Actor_Says(17, 130, 14);
+ Actor_Says(0, 5190, 16);
+ Actor_Says(17, 140, 13);
+ Actor_Says(17, 150, 14);
+ Actor_Says(17, 170, 12);
+ Actor_Clue_Acquire(0, 50, 1, 17);
+ break;
+ }
+}
+
+void ScriptTB02::sub_402B50() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(740, 4, 5, 6);
+ DM_Add_To_List_Never_Repeat_Once_Selected(750, 3, 5, 5);
+ Dialogue_Menu_Add_DONE_To_List(100);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 740:
+ Actor_Says(0, 5250, 15);
+ if (Game_Flag_Query(48)) {
+ Actor_Says(1, 2250, 12);
+ Actor_Says(1, 2260, 13);
+ Actor_Says(0, 5265, 12);
+ Actor_Says(1, 2270, 16);
+ Actor_Says(1, 2280, 13);
+ Actor_Says(0, 5270, 16);
+ Actor_Says(1, 2290, 14);
+ Actor_Clue_Acquire(0, 52, 1, 1);
+ Actor_Modify_Friendliness_To_Other(1, 0, 1);
+ Game_Flag_Set(456);
+ } else {
+ Actor_Says(1, 2300, 12);
+ Actor_Says(1, 2310, 15);
+ Actor_Says(0, 5275, 14);
+ Actor_Says(1, 2320, 12);
+ Actor_Says(0, 5280, 13);
+ Actor_Modify_Friendliness_To_Other(1, 0, 1);
+ Game_Flag_Set(456);
+ }
+ break;
+ case 750:
+ Actor_Says(0, 5255, 11);
+ Actor_Says(1, 2330, 13);
+ Actor_Says(1, 2340, 14);
+ Game_Flag_Set(456);
+ break;
+ case 100:
+ Actor_Says(1, 2350, 13);
+ Actor_Modify_Friendliness_To_Other(1, 0, -5);
+ Game_Flag_Set(456);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/tb03.cpp b/engines/bladerunner/script/tb03.cpp
new file mode 100644
index 0000000000..5a2996f6d9
--- /dev/null
+++ b/engines/bladerunner/script/tb03.cpp
@@ -0,0 +1,155 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptTB03::InitializeScene() {
+ if (Game_Flag_Query(448)) {
+ Setup_Scene_Information(-260.0f, 0.15f, 2014.0f, 276);
+ } else {
+ Setup_Scene_Information(-152.0f, 0.0f, 1890.0f, 500);
+ }
+ Scene_Exit_Add_2D_Exit(0, 25, 227, 81, 300, 0);
+ Scene_Exit_Add_2D_Exit(1, 298, 0, 639, 305, 0);
+ Ambient_Sounds_Add_Looping_Sound(211, 16, 0, 1);
+ Ambient_Sounds_Add_Sound(212, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(213, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(214, 2, 20, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(215, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(216, 2, 15, 16, 20, 0, 0, -101, -101, 0, 0);
+ if (Global_Variable_Query(1) <= 3) {
+ Ambient_Sounds_Add_Looping_Sound(45, 25, 0, 1);
+ Ambient_Sounds_Add_Sound(181, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(182, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(183, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(184, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(185, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(186, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(188, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(189, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(190, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(191, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(192, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(193, 5, 70, 12, 12, -100, 100, -101, -101, 0, 0);
+ 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(17, 17);
+ Actor_Set_At_XYZ(17, -38.53f, 2.93f, 1475.97f, 673);
+ if (Global_Variable_Query(1) == 4) {
+ int goal = Actor_Query_Goal_Number(17);
+ if (goal == 304) {
+ Actor_Change_Animation_Mode(17, 0);
+ Actor_Set_Goal_Number(24, 399);
+ } else if (goal != 302) {
+ Actor_Set_Goal_Number(17, 300);
+ }
+ }
+ if (Game_Flag_Query(448)) {
+ if (Game_Flag_Query(549)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ Game_Flag_Set(549);
+ }
+ Game_Flag_Reset(448);
+ } else {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptTB03::SceneLoaded() {
+ Obstacle_Object("SPHERE02", true);
+}
+
+bool ScriptTB03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptTB03::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptTB03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptTB03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptTB03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -260.0f, 0.15f, 2014.0f, 0, 1, false, 0)) {
+ Actor_Set_Goal_Number(17, 304);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(447);
+ Set_Enter(88, 101);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -152.0f, 0.0f, 1774.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(155);
+ Set_Enter(17, 82);
+ Async_Actor_Walk_To_XYZ(0, -152.0f, 0.0f, 1702.0f, 0, false);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptTB03::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptTB03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptTB03::PlayerWalkedIn() {
+ if (Actor_Query_Goal_Number(17) == 304) {
+ Player_Set_Combat_Mode(false);
+ Actor_Says(24, 260, -1);
+ Actor_Says(0, 170, 14);
+ Delay(1000);
+ Actor_Set_Goal_Number(0, 500);
+ }
+}
+
+void ScriptTB03::PlayerWalkedOut() {
+ Music_Stop(2);
+}
+
+void ScriptTB03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/tb05.cpp b/engines/bladerunner/script/tb05.cpp
new file mode 100644
index 0000000000..e61fec4a2d
--- /dev/null
+++ b/engines/bladerunner/script/tb05.cpp
@@ -0,0 +1,197 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptTB05::InitializeScene() {
+ if (Game_Flag_Query(98)) {
+ Setup_Scene_Information(23.0f, 151.53f, -205.0f, 450);
+ Game_Flag_Set(102);
+ Game_Flag_Reset(98);
+ } else {
+ Setup_Scene_Information(14.0f, 151.53f, -77.0f, 6);
+ }
+ Scene_Exit_Add_2D_Exit(0, 62, 193, 206, 419, 0);
+ Scene_Exit_Add_2D_Exit(1, 0, 455, 639, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(236, 100, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(237, 100, 0, 1);
+ Ambient_Sounds_Add_Sound(217, 5, 30, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(218, 5, 30, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(219, 5, 30, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(220, 5, 30, 25, 33, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(146, 2, 30, 20, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(147, 2, 30, 20, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(148, 2, 30, 20, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(149, 2, 30, 20, 25, 0, 0, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(151, 2, 30, 20, 25, 0, 0, -101, -101, 0, 0);
+ Scene_Loop_Set_Default(0);
+}
+
+void ScriptTB05::SceneLoaded() {
+ Clickable_Object("MONITOR05");
+ Unclickable_Object("SMUDGE_GLASS01");
+ if (!Actor_Clue_Query(0, 44)) {
+ Item_Add_To_World(76, 940, 72, 76.160004f, 147.36f, -235.14999f, 0, 6, 6, false, true, false, true);
+ }
+ if (!Actor_Clue_Query(0, 54) && !Actor_Clue_Query(0, 55) && (Game_Flag_Query(45) || Game_Flag_Query(46))) {
+ Item_Add_To_World(119, 972, 72, 129.00999f, 147.12f, -162.98f, 0, 8, 8, false, true, false, true);
+ }
+}
+
+bool ScriptTB05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptTB05::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("MONITOR05", objectName) && !Loop_Actor_Walk_To_XYZ(0, 122.54f, 147.12f, -197.17f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 38, false);
+ if (!Actor_Clue_Query(0, 152) && !Game_Flag_Query(99)) {
+ Actor_Clue_Acquire(0, 51, 1, -1);
+ Actor_Voice_Over(2170, 99);
+ Actor_Voice_Over(2180, 99);
+ Actor_Voice_Over(2190, 99);
+ Actor_Voice_Over(2200, 99);
+ Game_Flag_Set(99);
+ return true;
+ }
+ if (Game_Flag_Query(99) && !Game_Flag_Query(100) && !Actor_Clue_Query(0, 152)) {
+ if (Actor_Clue_Query(0, 65) || Actor_Clue_Query(0, 262)) {
+ Actor_Clue_Acquire(0, 152, 1, -1);
+ Actor_Voice_Over(2230, 99);
+ Item_Pickup_Spin_Effect(941, 352, 333);
+ Actor_Voice_Over(2240, 99);
+ Actor_Voice_Over(2250, 99);
+ Actor_Voice_Over(2260, 99);
+ Game_Flag_Set(100);
+ Game_Flag_Set(101);
+ } else {
+ Actor_Voice_Over(2270, 99);
+ Game_Flag_Set(100);
+ }
+ return true;
+ }
+ if (Game_Flag_Query(100) && !Game_Flag_Query(101)) {
+ if (Actor_Clue_Query(0, 65) || Actor_Clue_Query(0, 262)) {
+ Actor_Clue_Acquire(0, 152, 1, -1);
+ Actor_Voice_Over(2230, 99);
+ Item_Pickup_Spin_Effect(941, 352, 333);
+ Actor_Voice_Over(2240, 99);
+ Actor_Voice_Over(2250, 99);
+ Actor_Voice_Over(2260, 99);
+ Game_Flag_Set(101);
+ } else {
+ Actor_Voice_Over(2280, 99);
+ Actor_Voice_Over(2290, 99);
+ Game_Flag_Set(101);
+ }
+ return true;
+ }
+ if (Game_Flag_Query(101)) {
+ Actor_Voice_Over(3700, 99);
+ return true;
+ }
+ return false;
+ }
+ return false;
+}
+
+bool ScriptTB05::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptTB05::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 76 && !Loop_Actor_Walk_To_XYZ(0, 54.0f, 147.12f, -209.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 126, false);
+ Item_Remove_From_World(76);
+ Item_Pickup_Spin_Effect(940, 295, 408);
+ Actor_Voice_Over(2140, 99);
+ Actor_Voice_Over(2150, 99);
+ Actor_Voice_Over(2160, 99);
+ Actor_Clue_Acquire(0, 44, 1, -1);
+ return true;
+ }
+ if (itemId == 119 && !Loop_Actor_Walk_To_XYZ(0, 107.89f, 147.12f, -156.26f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 126, false);
+ Item_Remove_From_World(119);
+ Item_Pickup_Spin_Effect(972, 449, 431);
+ Actor_Voice_Over(4280, 99);
+ if (Game_Flag_Query(45)) {
+ Actor_Voice_Over(4290, 99);
+ Actor_Clue_Acquire(0, 54, 1, -1);
+ } else {
+ Actor_Voice_Over(4300, 99);
+ Actor_Clue_Acquire(0, 55, 1, -1);
+ }
+ }
+ return false;
+}
+
+bool ScriptTB05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 23.0f, 151.53f, -205.0f, 12, 1, false, 0)) {
+ Game_Flag_Set(97);
+ Set_Enter(73, 85);
+ Scene_Loop_Start_Special(1, 2, 1);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 14.0f, 147.12f, 123.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(95);
+ Set_Enter(17, 82);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptTB05::SceneFrameAdvanced(int frame) {
+ if (frame == 61) {
+ Sound_Play(150, Random_Query(52, 52), 0, 0, 50);
+ }
+ if (frame == 63) {
+ Sound_Play(283, Random_Query(55, 55), 0, 0, 50);
+ }
+ //return true;
+}
+
+void ScriptTB05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptTB05::PlayerWalkedIn() {
+}
+
+void ScriptTB05::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptTB05::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/tb06.cpp b/engines/bladerunner/script/tb06.cpp
new file mode 100644
index 0000000000..81b35b6fc0
--- /dev/null
+++ b/engines/bladerunner/script/tb06.cpp
@@ -0,0 +1,192 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptTB06::InitializeScene() {
+ Setup_Scene_Information(-16.0f, 149.0f, -466.0f, 990);
+ Scene_Exit_Add_2D_Exit(0, 330, 195, 417, 334, 0);
+ Ambient_Sounds_Add_Looping_Sound(236, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(237, 50, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(285, 66, 0, 1);
+ if (Game_Flag_Query(103)) {
+ Scene_Loop_Set_Default(0);
+ //return false;
+ return;
+ } else {
+ Actor_Put_In_Set(21, 73);
+ Actor_Set_At_XYZ(21, 135.0f, 151.0f, -671.0f, 800);
+ Actor_Retired_Here(21, 60, 32, 1, -1);
+ //return true;
+ return;
+ }
+}
+
+void ScriptTB06::SceneLoaded() {
+ Obstacle_Object("DOOR", true);
+ Unobstacle_Object("GLASS01", true);
+ Clickable_Object("DOOR");
+ Unclickable_Object("SMUDGE_GLASS01");
+ if (!Game_Flag_Query(519) && Actor_Query_Goal_Number(37) != 199) {
+ Item_Add_To_World(84, 942, 73, 36.54f, 149.48f, -565.67f, 0, 6, 6, false, true, false, true);
+ }
+ if (!Game_Flag_Query(520)) {
+ Item_Add_To_World(108, 955, 73, 18.0f, 149.65f, -599.0f, 0, 6, 6, false, true, false, true);
+ }
+ if (Actor_Query_Goal_Number(37) != 199) {
+ Item_Add_To_World(103, 978, 73, -46.82f, 149.6f, -666.88f, 0, 12, 12, false, true, false, true);
+ Item_Add_To_World(104, 979, 73, -30.27f, 149.6f, -610.7f, 0, 15, 45, false, true, false, true);
+ Item_Add_To_World(105, 980, 73, 9.87f, 149.6f, -683.5f, 0, 12, 12, false, true, false, true);
+ }
+}
+
+bool ScriptTB06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptTB06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptTB06::ClickedOnActor(int actorId) {
+ if (actorId == 21 && !Loop_Actor_Walk_To_Actor(0, 21, 24, 1, false)) {
+ if (Actor_Clue_Query(0, 49)) {
+ Actor_Says(0, 8665, 13);
+ return false;
+ }
+ Actor_Voice_Over(2300, 99);
+ Actor_Voice_Over(2310, 99);
+ Item_Pickup_Spin_Effect(974, 66, 397);
+ Actor_Voice_Over(2320, 99);
+ if (Game_Flag_Query(48)) {
+ Actor_Voice_Over(2330, 99);
+ Actor_Voice_Over(2340, 99);
+ }
+ Actor_Voice_Over(2350, 99);
+ Actor_Clue_Acquire(0, 49, 1, -1);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB06::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 84 && !Loop_Actor_Walk_To_Item(0, 84, 12, 1, false)) {
+ Actor_Face_Item(0, 84, true);
+ Actor_Clue_Acquire(0, 65, 1, -1);
+ Item_Pickup_Spin_Effect(942, 341, 368);
+ Item_Remove_From_World(84);
+ Actor_Voice_Over(4160, 99);
+ Game_Flag_Set(519);
+ return true;
+ }
+ if (itemId == 108 && !Loop_Actor_Walk_To_Item(0, 108, 12, 1, false)) {
+ Actor_Face_Item(0, 108, true);
+ Actor_Clue_Acquire(0, 53, 1, -1);
+ Item_Remove_From_World(108);
+ Item_Pickup_Spin_Effect(955, 390, 368);
+ Actor_Says(0, 8775, 3);
+ Game_Flag_Set(520);
+ return true;
+ }
+ if (itemId == 82 && !Loop_Actor_Walk_To_Item(0, 82, 12, 1, false)) {
+ Actor_Face_Item(0, 82, true);
+ Actor_Says(0, 5285, 3);
+ return true;
+ }
+ if (itemId == 103 || itemId == 104 || itemId == 105 && !Loop_Actor_Walk_To_Item(0, 103, 24, 1, false)) {
+ Actor_Face_Item(0, 103, true);
+ Actor_Voice_Over(2380, 99);
+ Actor_Voice_Over(2390, 99);
+ Actor_Voice_Over(2400, 99);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -16.0f, 149.0f, -427.0f, 12, 1, false, 0)) {
+ Game_Flag_Set(98);
+ Set_Enter(72, 84);
+ Scene_Loop_Start_Special(1, 2, 1);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptTB06::SceneFrameAdvanced(int frame) {
+ if (frame == 61) {
+ Sound_Play(150, Random_Query(52, 52), 0, 0, 50);
+ }
+ if (frame == 63) {
+ Sound_Play(283, Random_Query(55, 55), 0, 0, 50);
+ }
+ //return true;
+}
+
+void ScriptTB06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptTB06::PlayerWalkedIn() {
+ if (!Game_Flag_Query(102) && !Game_Flag_Query(483)) {
+ Actor_Face_Actor(0, 21, true);
+ Actor_Says(0, 5290, 3);
+ Loop_Actor_Walk_To_XYZ(0, -10.0f, 149.0f, -631.0f, 0, 0, false, 0);
+ AI_Movement_Track_Pause(37);
+ Actor_Face_Actor(0, 37, true);
+ Actor_Face_Actor(37, 0, true);
+ Actor_Says(37, 0, 3);
+ Actor_Says(0, 5295, 3);
+ Actor_Face_Actor(37, 21, true);
+ Actor_Says(37, 10, 3);
+ AI_Movement_Track_Unpause(37);
+ Game_Flag_Set(483);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(103)) {
+ Item_Remove_From_World(84);
+ Item_Remove_From_World(82);
+ Item_Remove_From_World(98);
+ //return true;
+ return;
+ }
+ //return false;
+ return;
+}
+
+void ScriptTB06::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptTB06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/tb07.cpp b/engines/bladerunner/script/tb07.cpp
new file mode 100644
index 0000000000..ca42ebbcd5
--- /dev/null
+++ b/engines/bladerunner/script/tb07.cpp
@@ -0,0 +1,290 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptTB07::InitializeScene() {
+ Setup_Scene_Information(68.0f, 12.0f, 288.0f, 0);
+ Scene_Exit_Add_2D_Exit(0, 383, 445, 639, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(109, 20, 0, 1);
+ Ambient_Sounds_Add_Sound(363, 2, 55, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(364, 2, 55, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(365, 2, 55, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(366, 2, 55, 14, 14, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(212, 1, 15, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(213, 1, 15, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(214, 1, 20, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(215, 1, 15, 20, 25, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(216, 1, 15, 20, 25, -100, 100, -101, -101, 0, 0);
+ if (Global_Variable_Query(1) == 4 && !Actor_Clue_Query(0, 147)) {
+ Item_Add_To_World(83, 941, 18, 9.7f, 48.7f, -174.22f, 0, 12, 12, false, true, false, true);
+ }
+ if (Game_Flag_Query(661)) {
+ Scene_Loop_Set_Default(3);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptTB07::SceneLoaded() {
+ Obstacle_Object("EAGLE01", true);
+ Clickable_Object("EAGLE01");
+}
+
+bool ScriptTB07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptTB07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptTB07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptTB07::ClickedOnItem(int itemId, bool a2) {
+ if (!Loop_Actor_Walk_To_Item(0, itemId, 36, 1, false)) {
+ Actor_Face_Item(0, itemId, true);
+ if (itemId == 83) {
+ Item_Pickup_Spin_Effect(941, 331, 296);
+ Actor_Clue_Acquire(0, 147, 0, -1);
+ }
+ Item_Remove_From_World(itemId);
+ }
+ return false;
+}
+
+bool ScriptTB07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 68.0f, 12.0f, 288.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (Global_Variable_Query(1) == 4) {
+ Game_Flag_Set(608);
+ Set_Enter(17, 82);
+ } 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(450);
+ switch (Spinner_Interface_Choose_Dest(-1, 0)) {
+ case 9:
+ Game_Flag_Set(257);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(256);
+ Set_Enter(37, 34);
+ break;
+ case 8:
+ Game_Flag_Set(181);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(255);
+ Set_Enter(54, 54);
+ break;
+ case 7:
+ Game_Flag_Set(258);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(254);
+ Set_Enter(20, 2);
+ break;
+ case 6:
+ Game_Flag_Set(177);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(253);
+ Set_Enter(7, 25);
+ break;
+ case 4:
+ Game_Flag_Set(180);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(252);
+ Set_Enter(0, 0);
+ break;
+ case 3:
+ Game_Flag_Set(176);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(248);
+ Set_Enter(4, 13);
+ break;
+ case 2:
+ Game_Flag_Set(182);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(249);
+ Set_Enter(69, 78);
+ break;
+ case 1:
+ Game_Flag_Set(179);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(250);
+ Set_Enter(49, 48);
+ break;
+ case 0:
+ Game_Flag_Set(178);
+ Game_Flag_Reset(307);
+ Game_Flag_Set(251);
+ Set_Enter(61, 65);
+ break;
+ default:
+ Game_Flag_Set(261);
+ Loop_Actor_Walk_To_XYZ(0, 44.0f, 12.0f, 176.0f, 0, 0, false, 0);
+ break;
+ }
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptTB07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptTB07::SceneFrameAdvanced(int frame) {
+ if (frame == 66) {
+ Ambient_Sounds_Play_Sound(591, 20, 99, 0, 0);
+ }
+ //return false;
+}
+
+void ScriptTB07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptTB07::PlayerWalkedIn() {
+ int v0 = Global_Variable_Query(1);
+ Loop_Actor_Walk_To_XYZ(0, 44.0f, 12.0f, 176.0f, 0, 0, false, 0);
+ if ((v0 == 2 || v0 == 3) && !Game_Flag_Query(612)) {
+ Player_Set_Combat_Mode(false);
+ sub_401B0C();
+ }
+}
+
+void ScriptTB07::PlayerWalkedOut() {
+}
+
+void ScriptTB07::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptTB07::sub_401B0C() {
+ Game_Flag_Set(612);
+ Delay(1500);
+ Loop_Actor_Walk_To_XYZ(0, 44.98f, 12.0f, 49.79f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 178, true);
+ Delay(3000);
+ Actor_Put_In_Set(57, 18);
+ Actor_Set_At_XYZ(57, -260.15f, 12.0f, -19.16f, 256);
+ Actor_Change_Animation_Mode(57, 0);
+ Outtake_Play(39, 1, -1);
+ Loop_Actor_Walk_To_XYZ(57, -146.15f, 12.0f, -5.84f, 0, 0, false, 0);
+ Actor_Face_Actor(57, 0, true);
+ Actor_Says(57, 480, 14);
+ Actor_Face_Actor(0, 57, true);
+ Actor_Says(0, 5315, 9);
+ Actor_Says(57, 490, 3);
+ Actor_Face_Heading(0, 178, true);
+ Actor_Says(0, 5320, 15);
+ Actor_Says_With_Pause(0, 5325, 1.0f, 19);
+ Actor_Start_Speech_Sample(57, 500);
+ Loop_Actor_Walk_To_XYZ(57, -60.15f, 12.0f, 60.84f, 0, 0, false, 0);
+ Actor_Face_Actor(57, 0, true);
+ Actor_Face_Actor(0, 57, true);
+ Actor_Says(0, 5330, 14);
+ Actor_Says(57, 510, 12);
+ Actor_Says(0, 5335, 16);
+ Actor_Says(57, 520, 17);
+ Actor_Says(0, 5340, 3);
+ Actor_Start_Speech_Sample(57, 530);
+ Loop_Actor_Walk_To_XYZ(57, -4.15f, 12.0f, 54.73f, 0, 0, false, 0);
+ Actor_Says(57, 540, 16);
+ Actor_Says(0, 5345, 18);
+ Actor_Says(57, 550, 13);
+ Actor_Says(57, 570, 18);
+ Actor_Says_With_Pause(0, 5350, 0.0f, 18);
+ Actor_Says(57, 580, 16);
+ Actor_Says(0, 5355, 16);
+ Actor_Says(57, 590, 17);
+ Actor_Says(0, 5360, 17);
+ Actor_Says(0, 5365, 13);
+ Actor_Says_With_Pause(57, 600, 1.0f, 12);
+ Actor_Says(0, 5370, 3);
+ Loop_Actor_Walk_To_XYZ(57, -24.15f, 12.0f, -10.84f, 0, 0, false, 0);
+ Actor_Says(57, 610, 13);
+ Actor_Face_Actor(0, 57, true);
+ Actor_Says(0, 5375, 18);
+ Actor_Says(0, 5380, 19);
+ Actor_Face_Actor(57, 0, true);
+ Actor_Says(57, 620, 18);
+ Actor_Says_With_Pause(0, 5385, 2.0f, 12);
+ Actor_Says_With_Pause(0, 5390, 2.0f, 14);
+ Actor_Says(0, 5395, 15);
+ Actor_Says_With_Pause(57, 630, 0.0f, 14);
+ Actor_Says(0, 5400, 18);
+ Actor_Says(0, 5405, 3);
+ Actor_Says(57, 640, 12);
+ Actor_Says(0, 5410, 16);
+ Actor_Says(57, 650, 15);
+ Actor_Says_With_Pause(0, 5415, 1.0f, 17);
+ Actor_Says(0, 5420, 14);
+ Actor_Says(57, 660, 15);
+ Actor_Put_In_Set(51, 18);
+ Actor_Set_At_XYZ(51, 68.0f, 12.0f, 288.0f, 0);
+ Actor_Change_Animation_Mode(51, 0);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 0);
+ Actor_Start_Speech_Sample(51, 0);
+ Loop_Actor_Walk_To_XYZ(51, 44.0f, 12.0f, 176.0f, 0, 0, false, 0);
+ Actor_Face_Actor(51, 0, true);
+ Actor_Face_Actor(0, 51, true);
+ Actor_Face_Actor(57, 51, true);
+ Actor_Says(51, 10, 12);
+ Actor_Says(51, 20, 3);
+ Actor_Says(51, 30, 12);
+ Actor_Says(0, 5425, 18);
+ Actor_Set_Goal_Number(57, 200);
+ Actor_Says(51, 40, 15);
+ Actor_Start_Speech_Sample(51, 50);
+ Loop_Actor_Walk_To_XYZ(51, -10.0f, 12.0f, 100.0f, 0, 0, false, 0);
+ Actor_Face_Actor(51, 0, true);
+ Actor_Face_Actor(0, 51, true);
+ Actor_Says(0, 5430, 17);
+ Actor_Says(0, 5435, 16);
+ Actor_Says(51, 60, 14);
+ Actor_Face_Actor(0, 51, true);
+ Actor_Says(0, 5440, 14);
+ Actor_Says(51, 70, 13);
+ Actor_Says(0, 5445, 15);
+ Actor_Says_With_Pause(51, 80, 1.0f, 12);
+ Actor_Says(51, 90, 15);
+ Actor_Says_With_Pause(0, 5450, 1.0f, 15);
+ Actor_Says(0, 5455, 12);
+ Actor_Says(51, 100, 14);
+ Actor_Clue_Acquire(0, 278, 0, 57);
+ Actor_Clue_Acquire(0, 279, 0, 51);
+ Loop_Actor_Walk_To_XYZ(51, -260.15f, 12.0f, -19.16f, 0, 0, false, 0);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug01.cpp b/engines/bladerunner/script/ug01.cpp
new file mode 100644
index 0000000000..1d39e9553e
--- /dev/null
+++ b/engines/bladerunner/script/ug01.cpp
@@ -0,0 +1,179 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG01::InitializeScene() {
+ if (Game_Flag_Query(317)) {
+ Setup_Scene_Information(34.47f, -50.13f, -924.11f, 500);
+ Game_Flag_Reset(317);
+ } else if (Game_Flag_Query(118)) {
+ Setup_Scene_Information(-68.0f, -50.13f, -504.0f, 377);
+ } else {
+ Setup_Scene_Information(-126.0f, -50.13f, -286.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 280, 204, 330, 265, 0);
+ Scene_Exit_Add_2D_Exit(1, 144, 0, 210, 104, 0);
+ Scene_Exit_Add_2D_Exit(2, 0, 173, 139, 402, 3);
+ Ambient_Sounds_Add_Looping_Sound(331, 28, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 10, 11, 20, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(370, 2, 120, 10, 11, 20, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 10, 11, 20, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(396, 2, 120, 10, 11, 20, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(234, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(391, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(394, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(224, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(227, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(228, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, 0, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, 0, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(324)) {
+ Scene_Loop_Set_Default(3);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptUG01::SceneLoaded() {
+ Unobstacle_Object("BEAM02", true);
+ Unobstacle_Object("BEAM03", true);
+ Unobstacle_Object("BEAM04", true);
+ Clickable_Object("PIPES_FG_LFT");
+}
+
+bool ScriptUG01::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG01::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("PIPES_FG_LFT", objectName)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -9.0f, -50.13f, -148.0f, 0, 1, false, 0) && !Game_Flag_Query(324)) {
+ Actor_Says(0, 8525, 13);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ Game_Flag_Set(324);
+ } else {
+ Actor_Says(0, 8525, 13);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG01::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG01::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG01::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -32.0f, -50.13f, -1350.0f, 12, 1, false, 0)) {
+ Game_Flag_Set(316);
+ Set_Enter(83, 95);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -70.0f, -50.13f, -500.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 768, false);
+ Loop_Actor_Travel_Ladder(0, 12, 1, 0);
+ Game_Flag_Set(119);
+ Game_Flag_Reset(259);
+ Game_Flag_Set(182);
+ Set_Enter(70, 80);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -126.0f, -50.13f, -286.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(314);
+ Set_Enter(75, 87);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG01::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG01::SceneFrameAdvanced(int frame) {
+ if (frame >= 61 && frame <= 120) {
+ float v1 = (120 - frame) / 29500.0f;
+ Set_Fog_Density("BoxFog01", v1);
+ Set_Fog_Density("BoxFog02", v1);
+ Set_Fog_Density("BoxFog03", v1);
+ Set_Fog_Density("BoxFog04", v1);
+ } else if (frame > 120) {
+ Set_Fog_Density("BoxFog01", 0.0f);
+ Set_Fog_Density("BoxFog02", 0.0f);
+ Set_Fog_Density("BoxFog03", 0.0f);
+ Set_Fog_Density("BoxFog04", 0.0f);
+ }
+ //return false;
+}
+
+void ScriptUG01::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG01::PlayerWalkedIn() {
+ if (Game_Flag_Query(315)) {
+ Loop_Actor_Walk_To_XYZ(0, -55.0f, -50.13f, -288.0f, 12, 0, false, 0);
+ Game_Flag_Reset(315);
+ }
+ if (Game_Flag_Query(118)) {
+ Actor_Set_At_XYZ(0, -70.0f, 93.87f, -500.0f, 768);
+ Loop_Actor_Travel_Ladder(0, 12, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -58.0f, -50.13f, -488.0f, 0, 0, false, 0);
+ Game_Flag_Reset(118);
+ }
+ if (Actor_Query_Goal_Number(6) == 310) {
+ Music_Play(21, 35, 0, 3, -1, 0, 0);
+ Actor_Set_Goal_Number(6, 311);
+ }
+ //return false;
+}
+
+void ScriptUG01::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptUG01::DialogueQueueFlushed(int a1) {
+}
+
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug02.cpp b/engines/bladerunner/script/ug02.cpp
new file mode 100644
index 0000000000..d58806c335
--- /dev/null
+++ b/engines/bladerunner/script/ug02.cpp
@@ -0,0 +1,256 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG02::InitializeScene() {
+ if (Game_Flag_Query(319)) {
+ Setup_Scene_Information(-313.0f, 155.73f, -128.0f, 556);
+ } else {
+ Setup_Scene_Information(-95.0f, 74.78f, -503.0f, 556);
+ }
+ Scene_Exit_Add_2D_Exit(0, 529, 130, 607, 277, 0);
+ Scene_Exit_Add_2D_Exit(1, 305, 36, 335, 192, 0);
+ Ambient_Sounds_Add_Looping_Sound(332, 43, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 43, 0, 1);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, 100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(123, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(130, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(131, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(132, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(133, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(134, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(135, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(136, 2, 50, 17, 37, -50, -20, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(47, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(48, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(49, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(50, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(51, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(52, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(53, 2, 50, 27, 27, 10, 30, -101, -101, 0, 0);
+}
+
+void ScriptUG02::SceneLoaded() {
+ Unobstacle_Object("BOX BACKROOM 2", true);
+ Unobstacle_Object("BACK_ROOM HALFWALL_", true);
+ Unobstacle_Object("GUN_4", true);
+ Obstacle_Object("GUN_1", true);
+ Unobstacle_Object("WALL_LEFT", true);
+ Unobstacle_Object("BOX BY STAIRS 1", true);
+ Unobstacle_Object("TANK", true);
+ Unobstacle_Object("DESK_DRUM", true);
+ Clickable_Object("GUN_1");
+ Clickable_Object("GUN_2");
+ Clickable_Object("CRATE_3");
+ Footstep_Sounds_Set(0, 0);
+ Footstep_Sounds_Set(8, 2);
+ if (!Game_Flag_Query(656) && Game_Flag_Query(44)) {
+ Item_Add_To_World(88, 963, 75, -300.37f, 120.16f, -81.31f, 0, 8, 8, false, true, false, true);
+ }
+}
+
+bool ScriptUG02::MouseClick(int x, int y) {
+ if (Game_Flag_Query(499)) {
+ return false;
+ }
+ if (Region_Check(0, 0, 245, 285) || Region_Check(0, 0, 350, 257)) {
+ return true;
+ }
+ if (Region_Check(81, 224, 639, 479) && !Game_Flag_Query(498)) {
+ Game_Flag_Set(499);
+ sub_402354();
+ Game_Flag_Reset(499);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG02::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("GUN_1", objectName) || Object_Query_Click("GUN_2", objectName) || Object_Query_Click("CRATE_3", objectName)) {
+ Actor_Face_Object(0, "GUN_1", true);
+ if (!Game_Flag_Query(449) && Global_Variable_Query(1) < 4) {
+ Actor_Voice_Over(2430, 99);
+ Actor_Voice_Over(2440, 99);
+ Actor_Voice_Over(2450, 99);
+ Actor_Voice_Over(2460, 99);
+ Game_Flag_Set(449);
+ Actor_Clue_Acquire(0, 66, 1, -1);
+ return true;
+ }
+ if (Global_Variable_Query(1) <= 3) {
+ Actor_Says(0, 8580, 14);
+ return false;
+ }
+ if (Actor_Clue_Query(0, 66) && !Actor_Clue_Query(0, 121)) {
+ Actor_Voice_Over(2470, 99);
+ Actor_Voice_Over(2480, 99);
+ Actor_Voice_Over(2490, 99);
+ Actor_Voice_Over(2500, 99);
+ Actor_Clue_Acquire(0, 121, 1, -1);
+ } else if (!Actor_Clue_Query(0, 66)) {
+ Actor_Voice_Over(2510, 99);
+ Actor_Voice_Over(2520, 99);
+ Actor_Voice_Over(2530, 99);
+ } else if (Game_Flag_Query(708)) {
+ Actor_Says(0, 8580, 14);
+ } else {
+ Item_Pickup_Spin_Effect(996, 360, 440);
+ Actor_Says(0, 8525, 14);
+ Give_McCoy_Ammo(2, 18);
+ Game_Flag_Set(708);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG02::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG02::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 88) {
+ Actor_Face_Item(0, 88, true);
+ Actor_Clue_Acquire(0, 62, 1, -1);
+ Game_Flag_Set(656);
+ Item_Remove_From_World(88);
+ Item_Pickup_Spin_Effect(963, 426, 316);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG02::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (Game_Flag_Query(498) || !sub_402354()) {
+ int v2 = Player_Query_Combat_Mode();
+ if (!Loop_Actor_Walk_To_XYZ(0, -202.0f, 120.16f, -74.0f, 0, 1, v2, 0)) {
+ Actor_Face_Heading(0, 270, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 4, 0, 0);
+ Footstep_Sound_Override_Off();
+ int v3 = Player_Query_Combat_Mode();
+ Loop_Actor_Walk_To_XYZ(0, -96.57f, 74.870003f, -271.28f, 0, 0, v3, 0);
+ int v4 = Player_Query_Combat_Mode();
+ Loop_Actor_Walk_To_XYZ(0, -95.0f, 74.870003f, -503.0f, 0, 0, v4, 0);
+ Game_Flag_Set(315);
+ Set_Enter(74, 86);
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (Game_Flag_Query(498)) {
+ if (sub_402354()) {
+ return true;
+ }
+ Loop_Actor_Walk_To_XYZ(0, -368.75f, 155.75f, -63.0f, 0, 0, false, 0);
+ Loop_Actor_Walk_To_XYZ(0, -340.75f, 155.75f, -119.0f, 0, 0, false, 0);
+ }
+ Loop_Actor_Walk_To_XYZ(0, -304.75f, 155.75f, -171.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 14, false);
+ Loop_Actor_Travel_Ladder(0, 9, 1, 0);
+ Game_Flag_Set(318);
+ Game_Flag_Reset(259);
+ 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, 33);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG02::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG02::SceneFrameAdvanced(int frame) {
+ //return true;
+}
+
+void ScriptUG02::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG02::PlayerWalkedIn() {
+ if (Game_Flag_Query(314)) {
+ Actor_Set_At_XYZ(0, -106.01f, 84.13f, -228.62f, 575);
+ Loop_Actor_Walk_To_XYZ(0, -148.0f, 84.13f, -67.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 761, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 4, 1, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Reset(314);
+ Game_Flag_Set(498);
+ } else if (Game_Flag_Query(319)) {
+ Actor_Set_At_XYZ(0, -304.75f, 265.0f, -171.0f, 0);
+ Loop_Actor_Travel_Ladder(0, 9, 0, 0);
+ Game_Flag_Reset(319);
+ Game_Flag_Reset(498);
+ } else {
+ Actor_Set_At_XYZ(0, -269.24f, 120.16f, -9.94f, 477);
+ Game_Flag_Set(498);
+ }
+ Game_Flag_Reset(499);
+ //return false;
+}
+
+void ScriptUG02::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptUG02::DialogueQueueFlushed(int a1) {
+}
+
+bool ScriptUG02::sub_402354() {
+ if (!Game_Flag_Query(498)) {
+ int v0 = Player_Query_Combat_Mode();
+ Loop_Actor_Walk_To_XYZ(0, -340.75f, 155.75f, -119.0f, 0, 0, v0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -368.75f, 155.75f, -63.0f, 0, 0, v0, 0);
+ Loop_Actor_Walk_To_XYZ(0, -365.0f, 155.65f, -19.0f, 0, 0, v0, 0);
+ Actor_Face_Heading(0, 318, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 4, 0, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Set(498);
+ return false;
+ }
+ if (!Loop_Actor_Walk_To_XYZ(0, -312.75f, 120.16f, 1.01f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 830, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 4, 1, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Reset(498);
+ return false;
+ }
+ return true;
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug03.cpp b/engines/bladerunner/script/ug03.cpp
new file mode 100644
index 0000000000..fa413175e3
--- /dev/null
+++ b/engines/bladerunner/script/ug03.cpp
@@ -0,0 +1,146 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG03::InitializeScene() {
+ if (Game_Flag_Query(335)) {
+ Setup_Scene_Information(-51.0f, 0.03f, 255.0f, 780);
+ Game_Flag_Reset(335);
+ } else if (Game_Flag_Query(337)) {
+ Setup_Scene_Information(-139.0f, 0.03f, -13.0f, 540);
+ Game_Flag_Reset(337);
+ } else {
+ Setup_Scene_Information(-121.88f, 0.03f, 213.35f, 540);
+ }
+ Scene_Exit_Add_2D_Exit(0, 46, 137, 131, 296, 0);
+ Scene_Exit_Add_2D_Exit(1, 559, 141, 639, 380, 1);
+ Ambient_Sounds_Add_Looping_Sound(331, 15, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 10, 11, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(370, 2, 120, 10, 11, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(396, 2, 120, 10, 11, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(395, 2, 120, 10, 11, 0, 100, 0, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(234, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(235, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(391, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(392, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(393, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(394, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(224, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(225, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(226, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(227, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(228, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptUG03::SceneLoaded() {
+ Obstacle_Object("=WALL_RIGHT_HOLE", true);
+ Unobstacle_Object("=HOLERUBBLE1", true);
+ Clickable_Object("CHAIR_HEADZAPPER");
+ Clickable_Object("CHAIR_BACK");
+ Clickable_Object("CHAIR_SEAT");
+ Clickable_Object("CHAIR_STRAPLEGLEFT");
+ Clickable_Object("CHAIR_STRAPLEGRIGHT");
+}
+
+bool ScriptUG03::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG03::ClickedOn3DObject(const char *objectName, bool a2) {
+ if ((Object_Query_Click("CHAIR_BACK", objectName) || Object_Query_Click("CHAIR_SEAT", objectName) || Object_Query_Click("CHAIR_HEADZAPPER", objectName)) && !Loop_Actor_Walk_To_Scene_Object(0, "CHAIR_BACK", 36, 1, false)) {
+ Actor_Face_Object(0, "CHAIR_BACK", true);
+ if (!Actor_Clue_Query(0, 120)) {
+ Actor_Voice_Over(2550, 99);
+ Actor_Voice_Over(2560, 99);
+ Actor_Voice_Over(2570, 99);
+ Actor_Voice_Over(2580, 99);
+ Actor_Voice_Over(2590, 99);
+ Actor_Clue_Acquire(0, 120, 1, -1);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG03::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG03::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG03::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -139.0f, 0.0f, -13.0f, 0, 1, false, 0)) {
+ if (Global_Variable_Query(1) < 4) {
+ Actor_Says(0, 8522, 14);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(336);
+ Set_Enter(83, 95);
+ }
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -51.0f, 0.0f, 255.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(334);
+ Set_Enter(77, 89);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG03::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG03::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptUG03::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG03::PlayerWalkedIn() {
+}
+
+void ScriptUG03::PlayerWalkedOut() {
+}
+
+void ScriptUG03::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug04.cpp b/engines/bladerunner/script/ug04.cpp
new file mode 100644
index 0000000000..c65d74fdf5
--- /dev/null
+++ b/engines/bladerunner/script/ug04.cpp
@@ -0,0 +1,140 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG04::InitializeScene() {
+ if (Game_Flag_Query(339)) {
+ Setup_Scene_Information(0.0f, -1.74f, -2400.0f, 496);
+ Game_Flag_Reset(339);
+ } else if (Game_Flag_Query(341)) {
+ Setup_Scene_Information(164.0f, 11.87f, -1013.0f, 83);
+ } else {
+ Setup_Scene_Information(-172.0f, 16.29f, -735.0f, 380);
+ Game_Flag_Reset(334);
+ }
+ Scene_Exit_Add_2D_Exit(0, 123, 308, 159, 413, 3);
+ if (Global_Variable_Query(1) > 3) {
+ Scene_Exit_Add_2D_Exit(1, 256, 333, 290, 373, 0);
+ }
+ Scene_Exit_Add_2D_Exit(2, 344, 298, 451, 390, 1);
+ Ambient_Sounds_Add_Looping_Sound(331, 25, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(234, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(224, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(225, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(227, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(370, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(235, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(392, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(394, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+}
+
+void ScriptUG04::SceneLoaded() {
+ Obstacle_Object("NAV", true);
+ Unobstacle_Object("RUBBLE", true);
+ Unobstacle_Object("FLOOR DEBRIS WADS", true);
+ Unobstacle_Object("FLOOR DEBRIS WADS01", true);
+ Unobstacle_Object("FLOOR DEBRIS WADS02", true);
+}
+
+bool ScriptUG04::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG04::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG04::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG04::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG04::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -172.0f, 16.29f, -735.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(335);
+ Set_Enter(76, 88);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 0.0f, -1.74f, -2400.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(338);
+ Set_Enter(78, 90);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 164.0f, 11.87f, -1013.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(340);
+ Set_Enter(79, 91);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG04::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG04::SceneFrameAdvanced(int frame) {
+ if (frame == 1) {
+ Ambient_Sounds_Play_Sound(367, 90, -100, 100, 100);
+ }
+}
+
+void ScriptUG04::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG04::PlayerWalkedIn() {
+ if (Game_Flag_Query(341)) {
+ Loop_Actor_Walk_To_XYZ(0, 60.0f, -1.74f, -976.0f, 6, 0, false, 0);
+ Game_Flag_Reset(341);
+ }
+}
+
+void ScriptUG04::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptUG04::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug05.cpp b/engines/bladerunner/script/ug05.cpp
new file mode 100644
index 0000000000..e087cacf92
--- /dev/null
+++ b/engines/bladerunner/script/ug05.cpp
@@ -0,0 +1,275 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG05::InitializeScene() {
+ if (Game_Flag_Query(360)) {
+ if (Game_Flag_Query(663) && !Game_Flag_Query(368)) {
+ Setup_Scene_Information(-356.35f, 132.77f, -1092.36f, 389);
+ } else {
+ Setup_Scene_Information(-180.0f, 37.28f, -1124.0f, 296);
+ }
+ } else {
+ Setup_Scene_Information(0.0f, -1.37f, 0.0f, 0);
+ Game_Flag_Reset(338);
+ }
+ Scene_Exit_Add_2D_Exit(0, 215, 240, 254, 331, 3);
+ if (!Game_Flag_Query(663)) {
+ Scene_Exit_Add_2D_Exit(1, 303, 422, 639, 479, 2);
+ }
+ if (!Game_Flag_Query(663) || Game_Flag_Query(368)) {
+ Scene_Exit_Add_2D_Exit(2, 352, 256, 393, 344, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(105, 28, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(234, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(225, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(226, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(227, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(235, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(391, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(395, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(224, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(228, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(392, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(368)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptUG05::SceneLoaded() {
+ if (!Game_Flag_Query(368)) {
+ Unobstacle_Object("DROPPED CAR OBSTACL", true);
+ }
+ Obstacle_Object("VANBODY", true);
+}
+
+bool ScriptUG05::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG05::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG05::ClickedOnActor(int actorId) {
+ if (!Loop_Actor_Walk_To_Actor(0, actorId, 30, 1, false)) {
+ Actor_Face_Actor(0, actorId, true);
+ int v1 = sub_4021B0();
+ if (actorId == 24 && Game_Flag_Query(368) && !Game_Flag_Query(683)) {
+ Actor_Says(24, 220, -1);
+ Actor_Says(0, 5540, 14);
+ Actor_Says(24, 230, -1);
+ Actor_Says(0, 5545, 17);
+ Actor_Says(24, 240, -1);
+ Actor_Says(0, 5550, 3);
+ Game_Flag_Set(683);
+ return false;
+ }
+ if (actorId == v1) {
+ sub_402218();
+ return true;
+ }
+ return false;
+ }
+ return false;
+}
+
+bool ScriptUG05::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG05::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (Game_Flag_Query(663) && !Game_Flag_Query(368)) {
+ Loop_Actor_Walk_To_XYZ(0, -356.35f, 132.77f, -1092.36f, 0, 0, false, 0);
+ Game_Flag_Set(361);
+ Set_Enter(43, 40);
+ } else if (!Loop_Actor_Walk_To_XYZ(0, -156.72f, 3.03f, -1118.17f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 760, false);
+ Loop_Actor_Travel_Stairs(0, 3, 1, 0);
+ Game_Flag_Set(361);
+ Set_Enter(43, 40);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 4.0f, -11.67f, -4.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(339);
+ Set_Enter(77, 89);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Game_Flag_Query(662)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 0.0f, -1.37f, -1500.0f, 0, 1, false, 0)) {
+ if (!Game_Flag_Query(522)) {
+ Actor_Voice_Over(2600, 99);
+ Actor_Voice_Over(2610, 99);
+ Game_Flag_Set(522);
+ }
+ return true;
+ }
+ } else {
+ int v1 = sub_4021B0();
+ bool v2;
+ if (v1 == -1) {
+ v2 = Loop_Actor_Walk_To_XYZ(0, 0.0f, -1.37f, -1500.0f, 0, 1, false, 0) != 0;
+ } else {
+ v2 = Loop_Actor_Walk_To_Actor(0, v1, 30, 1, false) != 0;
+ }
+ if (!v2) {
+ sub_402218();
+ return true;
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptUG05::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG05::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG05::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG05::PlayerWalkedIn() {
+ if (Game_Flag_Query(663)) {
+ if (Game_Flag_Query(368)) {
+ Music_Stop(2);
+ Actor_Put_In_Set(24, 78);
+ Actor_Set_At_XYZ(24, 4.22f, -1.37f, -925.0f, 750);
+ Actor_Set_Goal_Number(24, 599);
+ Actor_Retired_Here(24, 70, 36, 1, -1);
+ int v0 = sub_4021B0();
+ if (v0 == 3) {
+ Actor_Put_In_Set(3, 78);
+ Actor_Set_At_XYZ(3, -100.0f, -10.31f, -906.0f, 866);
+ Actor_Force_Stop_Walking(3);
+ } else if (v0 == 6) {
+ Actor_Put_In_Set(6, 78);
+ Actor_Set_At_XYZ(6, -100.0f, -10.31f, -906.0f, 866);
+ Actor_Force_Stop_Walking(6);
+ }
+ } else {
+ if (!Actor_Query_In_Set(23, 78)) {
+ Actor_Put_In_Set(23, 78);
+ Actor_Set_At_XYZ(23, 0.0f, -1.37f, -1400.0f, 768);
+ }
+ if (!Actor_Query_In_Set(24, 78)) {
+ ADQ_Flush();
+ ADQ_Add(24, 280, 3);
+ Actor_Put_In_Set(24, 78);
+ Actor_Set_At_XYZ(24, -16.0f, -1.37f, -960.0f, 768);
+ }
+ }
+ }
+ if (Game_Flag_Query(360)) {
+ if (Game_Flag_Query(663) && !Game_Flag_Query(368)) {
+ Loop_Actor_Walk_To_XYZ(0, -288.35f, 132.77f, -1092.36f, 0, 1, false, 0);
+ } else {
+ Loop_Actor_Travel_Stairs(0, 2, 0, 0);
+ }
+ }
+ if (Game_Flag_Query(663)) {
+ Game_Flag_Query(368);
+ }
+ Game_Flag_Reset(360);
+}
+
+void ScriptUG05::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptUG05::DialogueQueueFlushed(int a1) {
+}
+
+int ScriptUG05::sub_4021B0() {
+ if (Global_Variable_Query(45) == 2 && Actor_Query_Goal_Number(3) != 599) {
+ return 3;
+ }
+ if (Global_Variable_Query(45) == 3 && Actor_Query_Goal_Number(6) != 599) {
+ return 6;
+ }
+ return -1;
+}
+
+void ScriptUG05::sub_402218() {
+ int v0 = sub_4021B0();
+ if (v0 != -1) {
+ Actor_Face_Actor(0, v0, true);
+ Actor_Face_Actor(v0, 0, true);
+ Actor_Says(0, 5535, 13);
+ if (v0 == 3) {
+ Actor_Says(3, 1110, 15);
+ } else {
+ Actor_Says(6, 670, 17);
+ }
+ }
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (v0 == 6) {
+ if (Game_Flag_Query(46)) {
+ if (Global_Variable_Query(48) > 3) {
+ Outtake_Play(13, 0, -1);
+ } else {
+ Outtake_Play(14, 0, -1);
+ }
+ } else {
+ Outtake_Play(12, 0, -1);
+ }
+ } else if (v0 == 3) {
+ if (Game_Flag_Query(47)) {
+ if (Global_Variable_Query(48) > 3) {
+ Outtake_Play(16, 0, -1);
+ } else {
+ Outtake_Play(17, 0, -1);
+ }
+ } else {
+ Outtake_Play(15, 0, -1);
+ }
+ } else {
+ Outtake_Play(19, 0, -1);
+ }
+ Outtake_Play(18, 0, -1);
+ Game_Over();
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug06.cpp b/engines/bladerunner/script/ug06.cpp
new file mode 100644
index 0000000000..b3198c79ea
--- /dev/null
+++ b/engines/bladerunner/script/ug06.cpp
@@ -0,0 +1,161 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG06::InitializeScene() {
+ if (Game_Flag_Query(680)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Outtake_Play(7, 0, -1);
+ if (Game_Flag_Query(560)) {
+ Outtake_Play(9, 0, -1);
+ } else {
+ Outtake_Play(8, 0, -1);
+ }
+ Game_Flag_Reset(680);
+ }
+ if (Game_Flag_Query(340)) {
+ Setup_Scene_Information(23.0f, 0.0f, 321.0f, 0);
+ } else if (Game_Flag_Query(343)) {
+ Setup_Scene_Information(66.0f, 153.0f, -301.4f, 512);
+ } else {
+ Setup_Scene_Information(-165.0f, 1.0f, 89.0f, 990);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 0, 30, 479, 3);
+ Scene_Exit_Add_2D_Exit(1, 294, 68, 544, 236, 0);
+ Ambient_Sounds_Add_Looping_Sound(288, 18, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(234, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(235, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(392, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(394, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(225, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(227, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(228, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptUG06::SceneLoaded() {
+ Obstacle_Object("BOX06", true);
+ Unobstacle_Object("BOX06", true);
+ Unobstacle_Object("BOX07", true);
+ Unobstacle_Object("BOX16", true);
+ Unobstacle_Object("BOX05", true);
+}
+
+bool ScriptUG06::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG06::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG06::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG06::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG06::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 23.0f, 0.0f, 321.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(341);
+ Set_Enter(77, 89);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 66.0f, 0.0f, -90.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 0, false);
+ Loop_Actor_Travel_Stairs(0, 17, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, 66.0f, 153.0f, -446.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(342);
+ Set_Enter(54, 54);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG06::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG06::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG06::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG06::PlayerWalkedIn() {
+ if (Game_Flag_Query(340)) {
+ Loop_Actor_Walk_To_XYZ(0, 23.0f, 0.0f, 273.0f, 0, 0, false, 0);
+ Game_Flag_Reset(340);
+ }
+ if (Game_Flag_Query(343)) {
+ Loop_Actor_Travel_Stairs(0, 17, 0, 0);
+ Loop_Actor_Walk_To_XYZ(0, 66.0f, 0.0f, -36.91f, 0, 0, false, 0);
+ Game_Flag_Reset(343);
+ }
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(524)) {
+ Player_Loses_Control();
+ Actor_Voice_Over(2620, 99);
+ Actor_Voice_Over(2630, 99);
+ Actor_Voice_Over(2640, 99);
+ Actor_Voice_Over(2650, 99);
+ Actor_Voice_Over(2660, 99);
+ Actor_Voice_Over(2670, 99);
+ Actor_Voice_Over(2680, 99);
+ Actor_Voice_Over(2690, 99);
+ Actor_Voice_Over(2700, 99);
+ Player_Gains_Control();
+ Game_Flag_Set(524);
+ Autosave_Game(2);
+ }
+ //return false;
+}
+
+void ScriptUG06::PlayerWalkedOut() {
+}
+
+void ScriptUG06::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug07.cpp b/engines/bladerunner/script/ug07.cpp
new file mode 100644
index 0000000000..b27063b8ce
--- /dev/null
+++ b/engines/bladerunner/script/ug07.cpp
@@ -0,0 +1,193 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG07::InitializeScene() {
+ if (Game_Flag_Query(428)) {
+ Setup_Scene_Information(-76.0f, -12.21f, -738.0f, 505);
+ Game_Flag_Reset(428);
+ } else if (Game_Flag_Query(426)) {
+ Setup_Scene_Information(110.0f, -12.21f, -276.0f, 605);
+ } else {
+ Setup_Scene_Information(-10.0f, -12.21f, -58.0f, 0);
+ Game_Flag_Reset(424);
+ }
+ if (Game_Flag_Query(623)) {
+ Scene_Exit_Add_2D_Exit(0, 0, 192, 51, 334, 0);
+ Scene_Exit_Add_2D_Exit(1, 226, 224, 314, 396, 1);
+ }
+ Scene_Exit_Add_2D_Exit(2, 60, 440, 460, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(105, 90, -45, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(395, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptUG07::SceneLoaded() {
+ Obstacle_Object("BOX RIGHT WALL 01", true);
+ Obstacle_Object("BOX RIGHT WALL 09", true);
+ Obstacle_Object("SLIDING DOOR", true);
+ Unobstacle_Object("BOX LEFT WALL 01", true);
+ Unclickable_Object("BOX RIGHT WALL 09");
+ Unclickable_Object("BOX RIGHT WALL 01");
+ Unclickable_Object("SLIDING DOOR");
+ Unobstacle_Object("BOX FOR WALL LEFT02", true);
+ Unobstacle_Object("BOX FOR WALL LEFT03", true);
+ Unobstacle_Object("BOX FOR WALL LEFT05", true);
+ Unobstacle_Object("BOX FOR WALL LEFT07", true);
+ Unobstacle_Object("BOX FOR WALL LEFT09", true);
+ Unobstacle_Object("BOX FOR WALL LEFT10", true);
+ Unobstacle_Object("BOX FOR WALL LEFT11", true);
+ Unobstacle_Object("BOX FOR WALL LEFT12", true);
+ Unobstacle_Object("BOX FOR WALL LEFT13", true);
+}
+
+bool ScriptUG07::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG07::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG07::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG07::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG07::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -94.0f, -12.21f, -710.0f, 0, 1, false, 0) && Actor_Query_Goal_Number(5) != 402) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(427);
+ Set_Enter(82, 94);
+ return true;
+ }
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 110.0f, -12.21f, -274.0f, 0, 1, false, 0) && Actor_Query_Goal_Number(5) != 402) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(425);
+ Set_Enter(81, 93);
+ return true;
+ }
+ }
+ if (exitId == 2) {
+ if (!Game_Flag_Query(607) && Game_Flag_Query(671) && Global_Variable_Query(1) == 4 && !Game_Flag_Query(598)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 49.0f, -12.21f, -130.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(598);
+ Actor_Put_In_Set(5, 80);
+ Actor_Set_At_XYZ(5, 118.02f, -12.21f, -154.0f, 768);
+ Player_Set_Combat_Mode(true);
+ Actor_Face_Actor(0, 5, true);
+ Loop_Actor_Walk_To_XYZ(5, 98.019997f, -12.21f, -154.0f, 0, 0, false, 0);
+ Actor_Face_Actor(5, 0, true);
+ Actor_Set_Goal_Number(0, 301);
+ Actor_Face_Heading(0, 0, true);
+ Delay(1500);
+ Actor_Says_With_Pause(5, 550, 1.0f, 3);
+ if (Actor_Clue_Query(5, 224)) {
+ Actor_Says(5, 560, 3);
+ Actor_Set_Goal_Number(0, 302);
+ Sound_Play(561, 100, 0, 0, 50);
+ Delay(2000);
+ }
+ if (Actor_Clue_Query(5, 223)) {
+ Actor_Says(5, 570, 3);
+ Actor_Set_Goal_Number(0, 302);
+ Sound_Play(561, 100, 0, 0, 50);
+ Delay(2000);
+ }
+ Actor_Set_Goal_Number(0, 303);
+ Delay(1000);
+ Actor_Set_Goal_Number(5, 401);
+ }
+ } else {
+ if (!Loop_Actor_Walk_To_XYZ(0, -10.0f, -21.47f, -58.0f, 0, 1, false, 0) && Actor_Query_Goal_Number(5) != 402) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(423);
+ Set_Enter(83, 95);
+ return true;
+ }
+ }
+ }
+ return false;
+}
+
+bool ScriptUG07::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG07::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG07::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG07::PlayerWalkedIn() {
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(623)) {
+ Actor_Set_Goal_Number(23, 307);
+ Actor_Set_Goal_Number(24, 307);
+ }
+ if (Game_Flag_Query(426)) {
+ Loop_Actor_Walk_To_XYZ(0, 62.0f, -12.21f, -274.0f, 0, 0, false, 0);
+ Game_Flag_Reset(426);
+ }
+}
+
+void ScriptUG07::PlayerWalkedOut() {
+ if (Global_Variable_Query(1) == 4 && (Actor_Query_Goal_Number(23) == 307 || Actor_Query_Goal_Number(24) == 307)) {
+ Non_Player_Actor_Combat_Mode_Off(23);
+ Non_Player_Actor_Combat_Mode_Off(24);
+ Actor_Set_Goal_Number(23, 306);
+ Actor_Set_Goal_Number(24, 306);
+ }
+ if (Actor_Query_In_Set(5, 80)) {
+ Actor_Set_Goal_Number(5, 400);
+ }
+}
+
+void ScriptUG07::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug08.cpp b/engines/bladerunner/script/ug08.cpp
new file mode 100644
index 0000000000..34c1943cd7
--- /dev/null
+++ b/engines/bladerunner/script/ug08.cpp
@@ -0,0 +1,145 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG08::InitializeScene() {
+ if (Game_Flag_Query(430)) {
+ Setup_Scene_Information(-124.0f, 93.18f, 71.0f, 745);
+ } else {
+ Setup_Scene_Information(-432.0f, 0.0f, -152.0f, 370);
+ }
+ Scene_Exit_Add_2D_Exit(0, 125, 220, 157, 303, 3);
+ Scene_Exit_Add_2D_Exit(1, 353, 145, 552, 309, 1);
+ Ambient_Sounds_Add_Looping_Sound(331, 28, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ if (!Game_Flag_Query(610)) {
+ Game_Flag_Set(431);
+ Game_Flag_Set(610);
+ }
+ if (Game_Flag_Query(430)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(431)) {
+ Scene_Loop_Set_Default(1);
+ } else {
+ Scene_Loop_Set_Default(4);
+ }
+}
+
+void ScriptUG08::SceneLoaded() {
+ Obstacle_Object("ELEV LEGS", true);
+ Unobstacle_Object("ELEV LEGS", true);
+ Unobstacle_Object("BOX RIGHT WALL ", true);
+}
+
+bool ScriptUG08::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG08::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG08::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG08::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG08::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -432.0f, 0.0f, -152.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(426);
+ Set_Enter(80, 92);
+ }
+ } else if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -312.0f, -2.0f, 152.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 240, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 11, 1, 0);
+ Footstep_Sound_Override_Off();
+ Loop_Actor_Walk_To_XYZ(0, -118.02f, 93.02f, 52.76f, 0, 0, false, 0);
+ Player_Loses_Control();
+ Actor_Set_Invisible(0, true);
+ Game_Flag_Set(429);
+ Game_Flag_Reset(431);
+ Set_Enter(85, 97);
+ Scene_Loop_Start_Special(1, 3, 0);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG08::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG08::SceneFrameAdvanced(int frame) {
+ if (frame == 91) {
+ Ambient_Sounds_Play_Sound(372, 90, 0, 0, 100);
+ }
+}
+
+void ScriptUG08::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG08::PlayerWalkedIn() {
+ if (Game_Flag_Query(430)) {
+ Loop_Actor_Walk_To_XYZ(0, -167.0f, 93.18f, 71.0f, 0, 0, false, 0);
+ Loop_Actor_Walk_To_XYZ(0, -180.0f, 93.18f, 134.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 745, false);
+ Footstep_Sound_Override_On(2);
+ Loop_Actor_Travel_Stairs(0, 11, 0, 0);
+ Footstep_Sound_Override_Off();
+ Player_Gains_Control();
+ }
+ Game_Flag_Reset(425);
+ Game_Flag_Reset(430);
+}
+
+void ScriptUG08::PlayerWalkedOut() {
+}
+
+void ScriptUG08::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug09.cpp b/engines/bladerunner/script/ug09.cpp
new file mode 100644
index 0000000000..e76f9870b7
--- /dev/null
+++ b/engines/bladerunner/script/ug09.cpp
@@ -0,0 +1,153 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG09::InitializeScene() {
+ if (Game_Flag_Query(433)) {
+ Setup_Scene_Information(-67.0f, 156.94f, -425.0f, 500);
+ Game_Flag_Reset(433);
+ } else {
+ Setup_Scene_Information(-53.0f, 156.94f, 174.0f, 1000);
+ Game_Flag_Reset(427);
+ }
+ Scene_Exit_Add_2D_Exit(0, 204, 159, 392, 360, 0);
+ Scene_Exit_Add_2D_Exit(1, 0, 455, 639, 479, 2);
+ Ambient_Sounds_Add_Looping_Sound(105, 71, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(1, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(57, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(58, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(198, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(199, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptUG09::SceneLoaded() {
+ Obstacle_Object("FACADE_CANOPY", true);
+ Obstacle_Object("VW PROP SLAB", true);
+ Obstacle_Object("WALL_LEFT FRONT", true);
+ Unobstacle_Object("PATH_FRAGMENT 1", true);
+ Unobstacle_Object("BOXS FOR ARCHWAY 02", true);
+ Unobstacle_Object("BOXS FOR ARCHWAY 04", true);
+ Unobstacle_Object("BOXS FOR ARCHWAY 05", true);
+ Unobstacle_Object("BOX45", true);
+ Unobstacle_Object("BOX44", true);
+ Unobstacle_Object("BOX43", true);
+ Unobstacle_Object("BOX42", true);
+ Unobstacle_Object("BOX41", true);
+ Unobstacle_Object("BOX40", true);
+ Unobstacle_Object("BOX39", true);
+ Unobstacle_Object("BOX38", true);
+ Unobstacle_Object("BOX37", true);
+ Unobstacle_Object("BOX36", true);
+ Unobstacle_Object("BOX35", true);
+ Unobstacle_Object("BOX34", true);
+ Unobstacle_Object("BOX32", true);
+ Clickable_Object("FACADE_CANOPY");
+}
+
+bool ScriptUG09::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG09::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG09::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG09::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG09::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -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, 24);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -53.0f, 156.94f, 206.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(428);
+ Set_Enter(80, 92);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG09::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG09::SceneFrameAdvanced(int frame) {
+ //return false;
+}
+
+void ScriptUG09::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG09::PlayerWalkedIn() {
+ if (Global_Variable_Query(1) == 4 && Game_Flag_Query(623)) {
+ Game_Flag_Set(630);
+ }
+}
+
+void ScriptUG09::PlayerWalkedOut() {
+ if (Global_Variable_Query(1) == 4 && Global_Variable_Query(1) != 5) {
+ Game_Flag_Reset(630);
+ }
+ if (Game_Flag_Query(432)) {
+ Game_Flag_Set(176);
+ Game_Flag_Reset(259);
+ }
+}
+
+void ScriptUG09::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug10.cpp b/engines/bladerunner/script/ug10.cpp
new file mode 100644
index 0000000000..689dbdc896
--- /dev/null
+++ b/engines/bladerunner/script/ug10.cpp
@@ -0,0 +1,234 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG10::InitializeScene() {
+ if (Game_Flag_Query(336)) {
+ Setup_Scene_Information(-92.0f, 81.33f, -652.0f, 520);
+ } else if (Game_Flag_Query(423)) {
+ Game_Flag_Reset(423);
+ Setup_Scene_Information(-385.12f, 1.15f, 57.44f, 400);
+ } else if (Game_Flag_Query(346)) {
+ Setup_Scene_Information(2.5f, 1.15f, 405.0f, 200);
+ } else {
+ Setup_Scene_Information(235.0f, 1.15f, 29.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 589, 300, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 460, 70, 632, 171, 0);
+ Scene_Exit_Add_2D_Exit(2, 38, 78, 83, 264, 3);
+ Scene_Exit_Add_2D_Exit(3, 0, 0, 30, 479, 3);
+ Scene_2D_Region_Add(0, 349, 311, 382, 364);
+ Ambient_Sounds_Add_Looping_Sound(105, 71, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(1, 5, 150, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(58, 5, 150, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(230, 2, 20, 25, 32, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(233, 2, 20, 25, 32, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(235, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(394, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(224, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(228, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(229, 2, 190, 12, 16, -100, 100, -100, 100, 0, 0);
+ if (Game_Flag_Query(474)) {
+ Scene_Loop_Set_Default(4);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptUG10::SceneLoaded() {
+ Obstacle_Object("SLUICEGATE_LEVER", true);
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(474) && Game_Flag_Query(172) && !Game_Flag_Query(693)) {
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 6, 1);
+ Game_Flag_Set(693);
+ //return true;
+ }
+ //return false;
+}
+
+bool ScriptUG10::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG10::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG10::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG10::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG10::ClickedOnExit(int exitId) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (exitId == 0) {
+ if (!Game_Flag_Query(474) && x > 125.0f || Game_Flag_Query(474)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 235.0f, 1.15f, 29.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(317);
+ Set_Enter(74, 86);
+ return true;
+ }
+ } else if (!Game_Flag_Query(474)) {
+ Actor_Says(0, 8521, 3);
+ }
+ } else if (exitId == 1) {
+ if (!Game_Flag_Query(474) && x < 120.0f || Game_Flag_Query(474)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -1.83f, 1.15f, -410.8f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 0, false);
+ Loop_Actor_Travel_Stairs(0, 9, 1, 0);
+ Loop_Actor_Walk_To_XYZ(0, -92.0f, 81.83f, -652.0f, 0, 0, false, 0);
+ Game_Flag_Set(337);
+ Set_Enter(76, 88);
+ return true;
+ }
+ } else if (!Game_Flag_Query(474)) {
+ Actor_Says(0, 6165, 3);
+ }
+ } else if (exitId == 2) {
+ if (!Game_Flag_Query(474) && x < 120.0f || Game_Flag_Query(474)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -385.0f, 1.15f, 57.44f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 1001, false);
+ Loop_Actor_Travel_Ladder(0, 1, 1, 0);
+ Game_Flag_Set(424);
+ Set_Enter(80, 92);
+ return true;
+ }
+ } else if (!Game_Flag_Query(474)) {
+ Actor_Says(0, 6165, 3);
+ }
+ } else if (exitId == 3) {
+ if (!Game_Flag_Query(474) && x < 120.0f || Game_Flag_Query(474)) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 2.5f, 1.15f, 405.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(347);
+ Set_Enter(86, 98);
+ return true;
+ }
+ } else if (!Game_Flag_Query(474)) {
+ Actor_Says(0, 6165, 3);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG10::ClickedOn2DRegion(int region) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (region == 0 && !Player_Query_Combat_Mode()) {
+ if (x >= 120.0f) {
+ Actor_Says(0, 8525, 3);
+ } else if (!Loop_Actor_Walk_To_XYZ(0, 4.98f, 0.38f, 83.15f, 0, 1, false, 0)) {
+ if (Game_Flag_Query(474)) {
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 0, 0);
+ Game_Flag_Reset(474);
+ Obstacle_Object("BOX01 BRIDGE", true);
+ Player_Loses_Control();
+ } else {
+ Scene_Loop_Set_Default(4);
+ Scene_Loop_Start_Special(2, 3, 0);
+ Game_Flag_Set(474);
+ Unobstacle_Object("BOX01 BRIDGE", true);
+ Player_Loses_Control();
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+void ScriptUG10::SceneFrameAdvanced(int frame) {
+ if (frame == 121) {
+ Ambient_Sounds_Play_Sound(558, 90, 0, 0, 99);
+ }
+ if (frame == 127) {
+ Ambient_Sounds_Play_Sound(353, 90, 0, 0, 99);
+ }
+ if (frame == 147) {
+ Ambient_Sounds_Play_Sound(353, 90, 0, 0, 99);
+ }
+ if (frame == 1) {
+ Ambient_Sounds_Play_Sound(558, 90, 0, 0, 99);
+ }
+ if (frame == 3) {
+ Ambient_Sounds_Play_Sound(353, 90, 0, 0, 99);
+ }
+ if (frame == 23) {
+ Ambient_Sounds_Play_Sound(353, 90, 0, 0, 99);
+ }
+ if (frame == 58 || frame == 179) {
+ Player_Gains_Control();
+ }
+ //return false;
+}
+
+void ScriptUG10::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG10::PlayerWalkedIn() {
+ if (Game_Flag_Query(346)) {
+ Game_Flag_Reset(346);
+ Loop_Actor_Walk_To_XYZ(0, 2.5f, 1.15f, 377.0f, 0, 0, false, 0);
+ } else if (Game_Flag_Query(316)) {
+ Game_Flag_Reset(316);
+ Loop_Actor_Walk_To_XYZ(0, 207.0f, 1.15f, 29.0f, 0, 0, false, 0);
+ } else if (Game_Flag_Query(336)) {
+ Game_Flag_Reset(336);
+ Loop_Actor_Walk_To_XYZ(0, -1.83f, 81.33f, -518.8f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 506, false);
+ Loop_Actor_Travel_Stairs(0, 9, 0, 0);
+ }
+ if (Game_Flag_Query(474)) {
+ Unobstacle_Object("BOX01 BRIDGE", true);
+ } else {
+ Obstacle_Object("BOX01 BRIDGE", true);
+ }
+}
+
+void ScriptUG10::PlayerWalkedOut() {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+}
+
+void ScriptUG10::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug12.cpp b/engines/bladerunner/script/ug12.cpp
new file mode 100644
index 0000000000..695d3093ca
--- /dev/null
+++ b/engines/bladerunner/script/ug12.cpp
@@ -0,0 +1,122 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG12::InitializeScene() {
+ if (Game_Flag_Query(411)) {
+ Setup_Scene_Information(207.0f, -126.21f, -364.0f, 561);
+ Game_Flag_Reset(411);
+ } else {
+ Setup_Scene_Information(375.0f, -126.21f, 180.0f, 730);
+ Game_Flag_Reset(345);
+ }
+ Scene_Exit_Add_2D_Exit(0, 538, 222, 615, 346, 1);
+ if (Game_Flag_Query(373)) {
+ Scene_Exit_Add_2D_Exit(1, 334, 176, 426, 266, 0);
+ }
+ Ambient_Sounds_Add_Looping_Sound(105, 47, 60, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(370, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ if (Game_Flag_Query(373)) {
+ Scene_Loop_Set_Default(2);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptUG12::SceneLoaded() {
+ Unobstacle_Object("GATE1", true);
+ Obstacle_Object("TRAIN WRECK", true);
+}
+
+bool ScriptUG12::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG12::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG12::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG12::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG12::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 375.0f, -126.21f, 180.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(344);
+ Set_Enter(86, 98);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 207.0f, -126.21f, -364.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(412);
+ Set_Enter(45, 42);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG12::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG12::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG12::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG12::PlayerWalkedIn() {
+}
+
+void ScriptUG12::PlayerWalkedOut() {
+}
+
+void ScriptUG12::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug13.cpp b/engines/bladerunner/script/ug13.cpp
new file mode 100644
index 0000000000..6391b8b97f
--- /dev/null
+++ b/engines/bladerunner/script/ug13.cpp
@@ -0,0 +1,410 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG13::InitializeScene() {
+ if (Game_Flag_Query(435)) {
+ Setup_Scene_Information(-477.0f, 141.9f, -870.0f, 378);
+ } else if (Game_Flag_Query(350)) {
+ Setup_Scene_Information(39.0f, 52.94f, -528.0f, 600);
+ } else {
+ Setup_Scene_Information(-22.0f, 54.63f, -883.0f, 578);
+ Actor_Set_Invisible(0, false);
+ }
+ if (!Game_Flag_Query(431)) {
+ Scene_Exit_Add_2D_Exit(0, 394, 205, 464, 281, 0);
+ }
+ Scene_Exit_Add_2D_Exit(1, 560, 90, 639, 368, 1);
+ Scene_Exit_Add_2D_Exit(2, 108, 85, 175, 210, 3);
+ Ambient_Sounds_Add_Looping_Sound(331, 15, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ if (Global_Variable_Query(1) == 4 && !Game_Flag_Query(169)) {
+ Actor_Set_Goal_Number(12, 390);
+ }
+ if (Actor_Query_Goal_Number(12) == 599) {
+ Actor_Change_Animation_Mode(12, 89);
+ }
+ if (Game_Flag_Query(429)) {
+ Scene_Loop_Start_Special(0, 0, 0);
+ Scene_Loop_Set_Default(1);
+ } else if (Game_Flag_Query(431)) {
+ Scene_Loop_Set_Default(4);
+ } else {
+ Scene_Loop_Set_Default(1);
+ }
+}
+
+void ScriptUG13::SceneLoaded() {
+ Obstacle_Object("BASKET", true);
+ Obstacle_Object("BOLLARD", true);
+ Unobstacle_Object("STAIR", true);
+ Unobstacle_Object("BOX FOR ARCHWAY 02", true);
+ Unobstacle_Object("STAIR_RAIL", true);
+ Unobstacle_Object("DISC_LEFT", true);
+ Clickable_Object("BASKET");
+ Clickable_Object("BOLLARD");
+ Unclickable_Object("BASKET");
+ if (Global_Variable_Query(1) >= 3 && !Actor_Clue_Query(0, 128) && Game_Flag_Query(169) && (Actor_Clue_Query(0, 81) || Actor_Clue_Query(0, 80))) {
+ Item_Add_To_World(111, 958, 85, -209.01f, 70.76f, -351.79f, 0, 16, 12, false, true, false, true);
+ }
+}
+
+bool ScriptUG13::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG13::ClickedOn3DObject(const char *objectName, bool a2) {
+
+ if (Object_Query_Click("BOLLARD", objectName) && !Loop_Actor_Walk_To_XYZ(0, 7.0f, 44.0f, -695.0f, 0, 1, false, 0)) {
+ Actor_Face_Object(0, "BOLLARD", true);
+ if (Game_Flag_Query(431)) {
+ Scene_Loop_Set_Default(1);
+ Scene_Loop_Start_Special(2, 0, 0);
+ Game_Flag_Reset(431);
+ Game_Flag_Set(436);
+ return true;
+ } else {
+ Scene_Loop_Set_Default(4);
+ Scene_Loop_Start_Special(2, 3, 0);
+ Game_Flag_Set(431);
+ Scene_Exit_Remove(0);
+ return true;
+ }
+ }
+ return false;
+}
+
+bool ScriptUG13::ClickedOnActor(int actorId) {
+ if (actorId == 12 && Global_Variable_Query(1) == 4 && !Loop_Actor_Walk_To_XYZ(0, -248.0f, 44.0f, -390.0f, 12, 1, false, 0)) {
+ Actor_Face_Actor(0, 12, true);
+ if (Actor_Query_Goal_Number(12) != 6 && Actor_Query_Goal_Number(12) != 599) {
+ if (!Game_Flag_Query(554)) {
+ sub_40223C();
+ } else if (!Actor_Clue_Query(0, 122) || !Actor_Clue_Query(0, 123)) {
+ sub_402AD4();
+ } else {
+ Actor_Set_Goal_Number(12, 391);
+ if (Actor_Clue_Query(0, 131)) {
+ sub_402AD4();
+ } else {
+ Actor_Face_Actor(0, 12, true);
+ Actor_Says(0, 5600, 14);
+ Actor_Says(12, 100, 53);
+ Actor_Says(0, 5605, 18);
+ Actor_Start_Speech_Sample(12, 110);
+ Actor_Set_Goal_Number(12, 395);
+ }
+ }
+ } else if (Random_Query(0, 1) == 1) {
+ Actor_Says(0, 8590, 16);
+ } else {
+ Actor_Says(0, 8655, 15);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG13::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 111 && !Loop_Actor_Walk_To_Item(0, 111, 36, 1, false)) {
+ Actor_Face_Item(0, 111, true);
+ Actor_Clue_Acquire(0, 128, 1, -1);
+ Item_Remove_From_World(111);
+ Item_Pickup_Spin_Effect(958, 426, 316);
+ Actor_Voice_Over(3950, 99);
+ Actor_Voice_Over(3960, 99);
+ Actor_Voice_Over(3970, 99);
+ Actor_Voice_Over(3980, 99);
+ Actor_Voice_Over(3990, 99);
+ Actor_Voice_Over(4000, 99);
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG13::ClickedOnExit(int exitId) {
+
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -32.0f, 54.63f, -883.0f, 0, 1, false, 0)) {
+ Player_Loses_Control();
+ Game_Flag_Set(430);
+ Game_Flag_Set(431);
+ Set_Enter(81, 93);
+ Scene_Loop_Start_Special(1, 3, 0);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 39.0f, 52.94f, -528.0f, 0, 1, false, 0)) {
+ Game_Flag_Set(351);
+ Set_Enter(87, 99);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -267.0f, 44.0f, -795.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 830, false);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 11, 1, 0);
+ Footstep_Sound_Override_Off();
+ if (!sub_402AD0()) {
+ Loop_Actor_Walk_To_XYZ(0, -477.0f, 141.9f, -870.0f, 0, 0, false, 0);
+ Game_Flag_Set(434);
+ Set_Enter(89, 102);
+ return true;
+ }
+ Actor_Face_Heading(0, 325, false);
+ Loop_Actor_Travel_Stairs(0, 11, 0, 0);
+ } else {
+ return true;
+ }
+ }
+
+ return false;
+}
+
+bool ScriptUG13::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG13::SceneFrameAdvanced(int frame) {
+ if (frame == 94) {
+ Ambient_Sounds_Play_Sound(372, 90, 0, 0, 100);
+ }
+ if (Game_Flag_Query(436) && frame > 29 && frame < 91) {
+ Scene_Exit_Add_2D_Exit(0, 394, 205, 464, 281, 0);
+ Game_Flag_Reset(436);
+ //return true;
+ return;
+ }
+ if (Game_Flag_Query(429) && frame < 25) {
+ Actor_Set_Invisible(0, true);
+ } else if (Game_Flag_Query(430) && frame >= 94 && frame <= 120) {
+ Actor_Set_Invisible(0, true);
+ } else {
+ Actor_Set_Invisible(0, false);
+ }
+ //return false;
+ return;
+}
+
+void ScriptUG13::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG13::PlayerWalkedIn() {
+ if (Game_Flag_Query(435)) {
+ Loop_Actor_Walk_To_XYZ(0, -389.0f, 143.0f, -844.0f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 325, false);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 11, 0, 0);
+ Footstep_Sound_Override_Off();
+ Game_Flag_Reset(435);
+ } else if (Game_Flag_Query(350)) {
+ Loop_Actor_Walk_To_XYZ(0, -12.0f, 44.0f, -528.0f, 0, 0, false, 0);
+ Game_Flag_Reset(350);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, -60.0f, 55.24f, -816.0f, 0, 0, false, 0);
+ Game_Flag_Reset(429);
+ Player_Gains_Control();
+ }
+ if (Actor_Query_Goal_Number(12) >= 390 && !Game_Flag_Query(169)) {
+ if (Game_Flag_Query(553)) {
+ if (Random_Query(1, 3) == 1) {
+ Actor_Set_Goal_Number(12, 395);
+ }
+ } else {
+ Game_Flag_Set(553);
+ Actor_Says(12, 50, 3);
+ }
+ }
+ //return false;
+}
+
+void ScriptUG13::PlayerWalkedOut() {
+ Actor_Set_Invisible(0, false);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ if (Game_Flag_Query(430)) {
+ Ambient_Sounds_Remove_Sound(401, false);
+ Ambient_Sounds_Remove_Sound(402, false);
+ Ambient_Sounds_Remove_Sound(369, false);
+ Ambient_Sounds_Remove_Sound(397, false);
+ Ambient_Sounds_Remove_Sound(398, false);
+ } else {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ }
+}
+
+void ScriptUG13::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptUG13::sub_40223C() {
+ Actor_Face_Actor(0, 12, true);
+ Game_Flag_Set(554);
+ Actor_Says(0, 5560, 13);
+ Actor_Says_With_Pause(0, 5565, 3.0f, 18);
+ Actor_Says(12, 70, 31);
+ Actor_Says(12, 80, 32);
+ Actor_Says(0, 5570, 3);
+ Actor_Says(12, 90, 32);
+}
+
+void ScriptUG13::sub_4023D8() {
+ Actor_Face_Actor(0, 12, true);
+ Actor_Clue_Acquire(0, 122, 0, 12);
+ Actor_Modify_Friendliness_To_Other(12, 0, -5);
+ Actor_Says(0, 5575, 16);
+ Actor_Says(12, 120, 31);
+ Actor_Says(0, 5610, 15);
+ Actor_Says(12, 140, 32);
+ Actor_Says(0, 5615, 18);
+ Actor_Says(12, 160, 33);
+ Actor_Says(0, 5620, 9);
+ Actor_Says(12, 170, 30);
+ Actor_Says(0, 5625, 12);
+ Actor_Says(12, 180, 32);
+ Actor_Says(0, 5630, 18);
+ Actor_Says(12, 190, 32);
+ Actor_Says(0, 5635, 15);
+ Actor_Says(12, 200, 31);
+}
+
+void ScriptUG13::sub_4025E0() {
+ Actor_Clue_Acquire(0, 123, 0, 12);
+ Actor_Modify_Friendliness_To_Other(12, 0, -10);
+ Actor_Says(12, 220, 30);
+ Actor_Says(0, 5640, 19);
+ Actor_Says(12, 230, 33);
+ Actor_Says(0, 5645, 16);
+ Actor_Says(12, 240, 30);
+ Actor_Says(12, 250, 33);
+ Actor_Says(0, 5650, 14);
+ Actor_Says(12, 260, 32);
+}
+
+void ScriptUG13::sub_402960() {
+ Actor_Says(0, 5670, 9);
+ Actor_Says(12, 340, 31);
+ Actor_Says(0, 5690, 19);
+ Actor_Says(12, 350, 32);
+ Actor_Says(0, 5695, 14);
+ Actor_Says(12, 360, 33);
+ Actor_Voice_Over(2710, 99);
+ Actor_Voice_Over(2730, 99);
+ Actor_Clue_Acquire(0, 124, 0, 12);
+}
+
+int ScriptUG13::sub_402AD0() {
+ return 0;
+}
+
+void ScriptUG13::sub_402AD4() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(1320, 6, 3, 1);
+ if (Actor_Clue_Query(0, 122)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1330, 5, 8, 5);
+ }
+ DM_Add_To_List_Never_Repeat_Once_Selected(1340, 2, 4, 6);
+ if (Actor_Clue_Query(0, 131)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1350, 1, 3, 7);
+ }
+ Dialogue_Menu_Add_DONE_To_List(1360);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 1360:
+ return;
+ case 1350:
+ Actor_Clue_Acquire(12, 131, 0, 0);
+ Actor_Says_With_Pause(0, 5595, 1.0f, 23);
+ Item_Pickup_Spin_Effect(945, 193, 325);
+ Actor_Says(12, 290, 33);
+ Actor_Says(0, 5660, 13);
+ Actor_Clue_Lose(0, 131);
+ sub_402E24();
+ break;
+ case 1340:
+ Actor_Modify_Friendliness_To_Other(12, 0, -10);
+ Actor_Says(0, 5590, 15);
+ Actor_Says(12, 270, 31);
+ Actor_Says(0, 5655, 16);
+ Actor_Says(12, 280, 32);
+ break;
+ case 1330:
+ Actor_Says(0, 5585, 16);
+ sub_4025E0();
+ break;
+ case 1320:
+ sub_4023D8();
+ break;
+ default:
+ Actor_Face_Actor(0, 12, true);
+ Actor_Says(0, 5600, 14);
+ Actor_Says(12, 100, 53);
+ Actor_Says(0, 5605, 18);
+ Actor_Start_Speech_Sample(12, 110);
+ Actor_Set_Goal_Number(12, 395);
+ break;
+ }
+}
+
+void ScriptUG13::sub_402E24() {
+ Actor_Set_Friendliness_To_Other(12, 0, 40);
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(1370, 1, 1, 8);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1380, 1, 8, 1);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1390, 8, 1, 1);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ if (answer == 1370) {
+ Actor_Says(0, 5665, 16);
+ Actor_Says(12, 300, 32);
+ Actor_Says(0, 5680, 19);
+ Actor_Says(12, 310, 33);
+ Actor_Says(12, 330, 30);
+ Actor_Start_Speech_Sample(12, 110);
+ Actor_Set_Goal_Number(12, 395);
+ Actor_Says(0, 5685, 18);
+ } else if (answer == 1380) {
+ if (Actor_Clue_Query(0, 123)) {
+ sub_402960();
+ } else {
+ Actor_Says(0, 5700, 15);
+ sub_4025E0();
+ }
+ } else if (answer == 1390) {
+ Actor_Says(0, 5675, 9);
+ Actor_Says(12, 370, 32);
+ Actor_Says(0, 5705, 10);
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug14.cpp b/engines/bladerunner/script/ug14.cpp
new file mode 100644
index 0000000000..156f405b0b
--- /dev/null
+++ b/engines/bladerunner/script/ug14.cpp
@@ -0,0 +1,193 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG14::InitializeScene() {
+ if (Game_Flag_Query(349)) {
+ Setup_Scene_Information(-278.0f, 12.97f, -152.0f, 200);
+ } else if (Game_Flag_Query(344)) {
+ Setup_Scene_Information(-50.0f, 129.0f, -814.0f, 533);
+ } else {
+ Setup_Scene_Information(233.0f, 186.04f, -32.0f, 865);
+ }
+ Scene_Exit_Add_2D_Exit(0, 0, 232, 45, 427, 3);
+ Scene_Exit_Add_2D_Exit(1, 175, 44, 228, 115, 0);
+ Scene_Exit_Add_2D_Exit(2, 537, 0, 639, 190, 1);
+ Ambient_Sounds_Add_Looping_Sound(331, 28, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 20, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+}
+
+void ScriptUG14::SceneLoaded() {
+ Obstacle_Object("OBSTACLE02", true);
+ Unobstacle_Object("WALL_E_01", true);
+ Unclickable_Object("OBSTACLE02");
+}
+
+bool ScriptUG14::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG14::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG14::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG14::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG14::ClickedOnExit(int exitId) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ bool v1 = y > 57.0f;
+ if (exitId > 2) {
+ return false;
+ }
+ if (!exitId) {
+ if (v1) {
+ if (Loop_Actor_Walk_To_XYZ(0, 141.47f, 128.92f, -150.16f, 0, 1, false, 0)) {
+ return false;
+ }
+ Actor_Face_XYZ(0, -14.53f, 12.12f, -150.16f, true);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 13, 0, 0);
+ Footstep_Sound_Override_Off();
+ }
+ if (!Loop_Actor_Walk_To_XYZ(0, -278.0f, 12.97f, -152.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(348);
+ Set_Enter(90, 103);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!v1) {
+ if (Loop_Actor_Walk_To_XYZ(0, -14.53f, 12.12f, -150.16f, 0, 1, false, 0)) {
+ return false;
+ }
+ Actor_Face_XYZ(0, 141.47f, 128.92f, -150.16f, true);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 13, 1, 0);
+ Footstep_Sound_Override_Off();
+ }
+ if (!Loop_Actor_Walk_To_XYZ(0, -50.0f, 129.0f, -814.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(345);
+ Set_Enter(6, 96);
+ }
+ return true;
+ }
+
+ if (exitId == 2) {
+ if (!v1) {
+ if (Loop_Actor_Walk_To_XYZ(0, -14.53f, 12.12f, -150.16f, 0, 1, false, 0)) {
+ return false;
+ }
+ Actor_Face_XYZ(0, 141.47f, 128.92f, -150.16f, true);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 13, 1, 0);
+ Footstep_Sound_Override_Off();
+ }
+ if (!Loop_Actor_Walk_To_XYZ(0, 157.0f, 128.92f, -108.01f, 0, 1, false, 0)) {
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 6, 1, 0);
+ Footstep_Sound_Override_Off();
+ Loop_Actor_Walk_To_XYZ(0, 233.0f, 186.04f, -32.0f, 0, 0, false, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(346);
+ Set_Enter(83, 95);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG14::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG14::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG14::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG14::PlayerWalkedIn() {
+ if (Game_Flag_Query(349)) {
+ Loop_Actor_Walk_To_XYZ(0, -250.0f, 12.97f, -152.0f, 0, 0, false, 0);
+ Game_Flag_Reset(349);
+ } else if (Game_Flag_Query(344)) {
+ Loop_Actor_Walk_To_XYZ(0, -50.0f, 129.0f, -604.0f, 0, 0, false, 0);
+ Game_Flag_Reset(344);
+ } else {
+ Loop_Actor_Walk_To_XYZ(0, 157.0f, 186.04f, -44.01f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 10, false);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Stairs(0, 6, 0, 0);
+ Footstep_Sound_Override_Off();
+ Loop_Actor_Walk_To_XYZ(0, 157.0f, 128.92f, -148.01f, 0, 0, false, 0);
+ Actor_Face_Heading(0, 807, false);
+ Game_Flag_Reset(347);
+ }
+ if (Global_Variable_Query(1) == 4 && Game_Flag_Query(172) && !Game_Flag_Query(694)) {
+ Overlay_Play("UG14OVER", 0, 0, 1, 0);
+ Delay(1000);
+ Actor_Face_Heading(0, 609, false);
+ Delay(3000);
+ Actor_Voice_Over(270, 99);
+ Delay(2150);
+ Actor_Voice_Over(300, 99);
+ Game_Flag_Set(694);
+ }
+ //return false;
+}
+
+void ScriptUG14::PlayerWalkedOut() {
+}
+
+void ScriptUG14::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug15.cpp b/engines/bladerunner/script/ug15.cpp
new file mode 100644
index 0000000000..c202e4f428
--- /dev/null
+++ b/engines/bladerunner/script/ug15.cpp
@@ -0,0 +1,204 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG15::InitializeScene() {
+ if (Game_Flag_Query(353)) {
+ Setup_Scene_Information(-25.0f, 26.309999f, -434.0f, 520);
+ } else if (Game_Flag_Query(153)) {
+ Setup_Scene_Information(-17.0f, 26.309999f, -346.0f, 711);
+ } else if (Game_Flag_Query(355)) {
+ Setup_Scene_Information(-18.0f, 48.07f, 62.0f, 650);
+ } else {
+ Setup_Scene_Information(-238.0f, 48.07f, 222.0f, 180);
+ if (Game_Flag_Query(676) && Random_Query(1, 10) == 10) {
+ Game_Flag_Reset(676);
+ }
+ }
+ if (Game_Flag_Query(682)) {
+ Scene_Loop_Set_Default(3);
+ }
+ if (Game_Flag_Query(353) || Game_Flag_Query(153)) {
+ Scene_Exit_Add_2D_Exit(0, 260, 0, 307, 298, 0);
+ Scene_Exit_Add_2D_Exit(1, 301, 147, 337, 304, 1);
+ Game_Flag_Reset(353);
+ Game_Flag_Reset(153);
+ } else {
+ Scene_Exit_Add_2D_Exit(2, 406, 128, 480, 316, 1);
+ Scene_Exit_Add_2D_Exit(3, 0, 0, 30, 479, 3);
+ }
+ Ambient_Sounds_Add_Looping_Sound(105, 71, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(1, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(57, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(58, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(196, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(197, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(198, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(199, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+
+}
+
+void ScriptUG15::SceneLoaded() {
+ Unobstacle_Object("CATWALK_01_RAIL02", true);
+ Unobstacle_Object("LOFT01", true);
+ Obstacle_Object("NUT1", true);
+ Clickable_Object("NUT1");
+}
+
+bool ScriptUG15::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG15::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG15::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG15::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG15::ClickedOnExit(int exitId) {
+
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -25.0f, 26.31f, -434.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(352);
+ Set_Enter(88, 101);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -17.0f, 26.31f, -346.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(152);
+ Set_Enter(19, 100);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ int v1 = Actor_Query_Goal_Number(64);
+ if (v1 >= 300 && v1 <= 303) {
+ Loop_Actor_Walk_To_XYZ(0, -137.61f, 48.07f, 147.12f, 0, 1, false, 0);
+ } else if (!Loop_Actor_Walk_To_XYZ(0, 18.0f, 52.28f, 46.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(354);
+ Set_Enter(19, 100);
+ }
+ return true;
+ }
+ if (exitId == 3) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -238.0f, 52.46f, 222.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(350);
+ Set_Enter(85, 97);
+ }
+ return true;
+ }
+ return false;
+
+}
+
+bool ScriptUG15::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG15::SceneFrameAdvanced(int frame) {
+ if (Actor_Query_Goal_Number(64) == 300) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (-160.0f <= x && z < 220.0f) {
+ Actor_Set_Goal_Number(64, 301);
+ }
+ }
+ if (frame == 61) {
+ Ambient_Sounds_Play_Sound(583, 80, 0, 0, 99);
+ }
+ if (Game_Flag_Query(677) && !Game_Flag_Query(682)) {
+ float x, y, z;
+ Actor_Query_XYZ(0, &x, &y, &z);
+ if (-180.0f <= x && (z < 220.0f && !Game_Flag_Query(724))) {
+ Game_Flag_Set(724);
+ Game_Flag_Set(682);
+ Scene_Loop_Set_Default(3);
+ Scene_Loop_Start_Special(2, 2, 1);
+ Actor_Set_Goal_Number(0, 390);
+ Actor_Query_XYZ(64, &x, &y, &z);
+ if (-200.0f < x && -62.0f > x) {
+ Actor_Set_Goal_Number(64, 309);
+ }
+ }
+ }
+ // return false;
+}
+
+void ScriptUG15::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG15::PlayerWalkedIn() {
+ if (Game_Flag_Query(355)) {
+ Loop_Actor_Walk_To_XYZ(0, -62.0f, 48.07f, 102.0f, 0, 0, false, 0);
+ Game_Flag_Reset(355);
+ } else if (Game_Flag_Query(351)) {
+ Game_Flag_Reset(351);
+ if (!Game_Flag_Query(676)) {
+ Actor_Set_Goal_Number(64, 310);
+ }
+ }
+}
+
+void ScriptUG15::PlayerWalkedOut() {
+
+}
+
+void ScriptUG15::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug16.cpp b/engines/bladerunner/script/ug16.cpp
new file mode 100644
index 0000000000..379e0bb793
--- /dev/null
+++ b/engines/bladerunner/script/ug16.cpp
@@ -0,0 +1,369 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG16::InitializeScene() {
+ if (Game_Flag_Query(552)) {
+ Setup_Scene_Information(-270.76f, -34.88f, -504.02f, 404);
+ Game_Flag_Reset(552);
+ } else if (Game_Flag_Query(152)) {
+ Setup_Scene_Information(-322.0f, -34.0f, -404.0f, 345);
+ Game_Flag_Reset(152);
+ } else {
+ Setup_Scene_Information(-318.0f, -34.0f, -216.0f, 340);
+ Game_Flag_Reset(354);
+ }
+ Scene_Exit_Add_2D_Exit(0, 242, 169, 282, 262, 3);
+ Scene_Exit_Add_2D_Exit(1, 375, 166, 407, 251, 3);
+ Scene_Exit_Add_2D_Exit(2, 461, 148, 523, 248, 0);
+ Ambient_Sounds_Add_Looping_Sound(516, 33, 81, 0);
+ Ambient_Sounds_Add_Looping_Sound(332, 40, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(333, 40, 0, 1);
+ if (Game_Flag_Query(568)) {
+ Scene_Loop_Set_Default(5);
+ } else {
+ Scene_Loop_Set_Default(0);
+ }
+}
+
+void ScriptUG16::SceneLoaded() {
+ Obstacle_Object("BED", true);
+ Obstacle_Object("QUADPATCH07", true);
+ Obstacle_Object("QUADPATCH05", true);
+ Obstacle_Object("SCREEN 01", true);
+ Obstacle_Object("BOX49", true);
+ Obstacle_Object("CYLINDER07", true);
+ Unobstacle_Object("SEAT 1", true);
+ Unobstacle_Object("SEAT 2", true);
+ Unclickable_Object("BED");
+ Unclickable_Object("QUADPATCH07");
+ Clickable_Object("QUADPATCH05");
+ Clickable_Object("SCREEN 01");
+ Unclickable_Object("BOX49");
+ Unclickable_Object("CYLINDER07");
+ Unobstacle_Object("BOX67", true);
+ Footstep_Sounds_Set(0, 3);
+ Footstep_Sounds_Set(1, 2);
+ Footstep_Sounds_Set(2, 3);
+ Footstep_Sounds_Set(6, 3);
+}
+
+bool ScriptUG16::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG16::ClickedOn3DObject(const char *objectName, bool a2) {
+ if (Object_Query_Click("QUADPATCH05", objectName) && !Loop_Actor_Walk_To_XYZ(0, 194.0f, -35.0f, 160.8f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 870, false);
+ if (!Game_Flag_Query(597) && Game_Flag_Query(595)) {
+ Game_Flag_Set(597);
+ Delay(1000);
+ Actor_Voice_Over(3480, 99);
+ Actor_Change_Animation_Mode(0, 38);
+ Sound_Play(339, 100, 0, 0, 50);
+ Delay(1000);
+ Item_Pickup_Spin_Effect(948, 460, 287);
+ Actor_Voice_Over(2740, 99);
+ Actor_Voice_Over(2750, 99);
+ Actor_Voice_Over(2760, 99);
+ Actor_Voice_Over(2770, 99);
+ Actor_Clue_Acquire(0, 125, 1, -1);
+ } else {
+ Actor_Says(0, 8523, 12);
+ Actor_Says(0, 8635, 12);
+ }
+ return true;
+ }
+ if (Object_Query_Click("SCREEN 01", objectName) && !Loop_Actor_Walk_To_XYZ(0, 194.0f, -35.0f, 160.8f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 870, false);
+ if (Game_Flag_Query(595) || !Actor_Query_Is_In_Current_Set(10) && !Actor_Clue_Query(0, 151) && !Game_Flag_Query(568)) {
+ Delay(2000);
+ Actor_Face_Heading(0, 1016, false);
+ Delay(2000);
+ Actor_Says(0, 5725, 14);
+ Delay(1000);
+ Item_Pickup_Spin_Effect(941, 418, 305);
+ Actor_Clue_Acquire(0, 151, 1, -1);
+ return true;
+ }
+ Actor_Says(0, 8525, 12);
+ Actor_Says(0, 8526, 12);
+ return false;
+ }
+ return false;
+}
+
+bool ScriptUG16::ClickedOnActor(int actorId) {
+ if (Actor_Query_Goal_Number(10) < 490) {
+ sub_401D78();
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG16::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG16::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -322.0f, -34.0f, -216.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(355);
+ Set_Enter(87, 99);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -322.0f, -34.0f, -404.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(153);
+ Set_Enter(87, 99);
+ }
+ return true;
+ }
+ if (exitId == 2) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -316.78f, -34.88f, -533.27f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 0, false);
+ Loop_Actor_Travel_Stairs(0, 13, 1, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(551);
+ Set_Enter(36, 30);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG16::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG16::SceneFrameAdvanced(int frame) {
+ if (frame == 132) {
+ Ambient_Sounds_Remove_Looping_Sound(516, true);
+ }
+}
+
+void ScriptUG16::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG16::PlayerWalkedIn() {
+ Game_Flag_Set(715);
+ if (!Game_Flag_Query(595)) {
+ Actor_Set_Goal_Number(10, 403);
+ }
+ if (!Game_Flag_Query(556) && Actor_Query_Is_In_Current_Set(10)) {
+ Player_Loses_Control();
+ Loop_Actor_Walk_To_XYZ(0, 120.29f, -35.67f, 214.8f, 310, 0, false, 0);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(10, 0, 6);
+ Actor_Says(10, 30, 13);
+ Actor_Change_Animation_Mode(10, 17);
+ Actor_Says(13, 0, 17);
+ Actor_Says(0, 5710, 14);
+ Actor_Says(10, 40, 13);
+ Actor_Says(10, 50, 15);
+ Actor_Says(13, 20, 12);
+ Actor_Says(10, 60, 23);
+ Actor_Says(0, 5715, 14);
+ Actor_Says(13, 30, 16);
+ Actor_Says(10, 70, 6);
+ Player_Gains_Control();
+ Game_Flag_Set(556);
+ }
+}
+
+void ScriptUG16::PlayerWalkedOut() {
+ if (!Game_Flag_Query(595)) {
+ Actor_Set_Goal_Number(10, 401);
+ //return true;
+ }
+ //return false;
+}
+
+void ScriptUG16::DialogueQueueFlushed(int a1) {
+}
+
+void ScriptUG16::sub_401D78() {
+ Dialogue_Menu_Clear_List();
+ DM_Add_To_List_Never_Repeat_Once_Selected(1400, 5, 6, 2);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1410, 5, 4, 8);
+ if (Game_Flag_Query(600) || Game_Flag_Query(601)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1420, 6, 4, 5);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1430, 6, 4, 5);
+ DM_Add_To_List_Never_Repeat_Once_Selected(1440, 6, 4, 5);
+ }
+ if (Global_Variable_Query(49) > 1 && !Actor_Clue_Query(0, 125)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1450, 6, 4, 5);
+ }
+ if (Actor_Clue_Query(0, 76)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1460, 6, 4, 5);
+ }
+ if (Actor_Clue_Query(0, 147) && !Actor_Clue_Query(0, 125) && Game_Flag_Query(698)) {
+ DM_Add_To_List_Never_Repeat_Once_Selected(1470, 6, 4, 5);
+ }
+ Dialogue_Menu_Add_DONE_To_List(1480);
+ Dialogue_Menu_Appear(320, 240);
+ int answer = Dialogue_Menu_Query_Input();
+ Dialogue_Menu_Disappear();
+ switch (answer) {
+ case 1400:
+ Actor_Says(0, 5730, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(10, 100, 18);
+ Actor_Says(0, 5775, 13);
+ Actor_Says(13, 70, 17);
+ Actor_Says(10, 110, 16);
+ Actor_Says(13, 80, 6);
+ Actor_Says(0, 5780, 13);
+ Actor_Says(10, 120, 16);
+ Actor_Says(13, 120, 13);
+ Actor_Says(0, 5785, 13);
+ Actor_Says(10, 130, 6);
+ Actor_Says(0, 5825, 13);
+ Actor_Modify_Friendliness_To_Other(10, 0, -5);
+ if (Game_Flag_Query(560)) {
+ Actor_Says(10, 140, 13);
+ Actor_Says(10, 150, 14);
+ Actor_Says(10, 160, 13);
+ Actor_Says(13, 140, 16);
+ Actor_Says(0, 5790, 13);
+ Actor_Says(10, 170, 14);
+ Game_Flag_Set(600);
+ Actor_Modify_Friendliness_To_Other(10, 0, 5);
+ } else {
+ Actor_Says(10, 180, 14);
+ Actor_Says(0, 5795, 13);
+ Actor_Says(13, 150, 17);
+ Actor_Says(0, 5800, 13);
+ Actor_Says(10, 190, 15);
+ Game_Flag_Set(601);
+ Actor_Modify_Friendliness_To_Other(10, 0, -10);
+ }
+ break;
+ case 1410:
+ Actor_Says(0, 5735, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 160, 17);
+ Actor_Says(10, 200, 14);
+ break;
+ case 1420:
+ Actor_Says(0, 5740, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 180, 15);
+ Actor_Says(10, 220, 13);
+ Actor_Says(13, 190, 17);
+ Actor_Says(0, 5805, 13);
+ Actor_Says(10, 230, 14);
+ Actor_Says(10, 240, 13);
+ Actor_Says(13, 200, 17);
+ Actor_Says(10, 260, 13);
+ Actor_Says(10, 270, 15);
+ Actor_Says(13, 210, 14);
+ Actor_Says(0, 5810, 13);
+ Actor_Says(13, 220, 14);
+ Actor_Says(13, 230, 17);
+ Actor_Clue_Acquire(0, 136, 1, 10);
+ break;
+ case 1430:
+ Actor_Says(0, 5745, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 240, 15);
+ Actor_Says(0, 5815, 13);
+ Actor_Says(13, 250, 16);
+ Actor_Says(10, 290, 15);
+ Actor_Says(13, 260, 15);
+ break;
+ case 1440:
+ Actor_Says(0, 5750, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 280, 6);
+ Actor_Says(10, 300, 14);
+ Actor_Says(10, 310, 15);
+ Actor_Modify_Friendliness_To_Other(10, 0, -5);
+ break;
+ case 1450:
+ Actor_Says(0, 5755, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 290, 17);
+ Actor_Says(10, 320, 16);
+ Actor_Says(0, 5820, 13);
+ Actor_Says(13, 300, 17);
+ Actor_Says(10, 330, 14);
+ Actor_Says(0, 5825, 13);
+ Actor_Says(10, 340, 13);
+ Actor_Says(13, 310, 13);
+ Actor_Says(10, 350, 13);
+ Actor_Says(10, 360, 15);
+ Actor_Says(0, 5830, 13);
+ Actor_Says(13, 320, 16);
+ Actor_Says(13, 330, 15);
+ Game_Flag_Set(698);
+ break;
+ case 1460:
+ Actor_Says(0, 5760, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(10, 370, 15);
+ Actor_Says(13, 340, 14);
+ Actor_Says(0, 5835, 13);
+ Actor_Says(10, 380, 15);
+ Actor_Says(13, 370, 6);
+ Actor_Says(0, 5840, 13);
+ Actor_Says(13, 380, 13);
+ break;
+ case 1470:
+ Actor_Says(0, 5765, 13);
+ Actor_Face_Actor(0, 10, true);
+ Actor_Says(13, 400, 15);
+ Actor_Says(0, 5845, 13);
+ Actor_Says(10, 390, 23);
+ Actor_Says(13, 410, 14);
+ Actor_Says(13, 420, 17);
+ Actor_Says(0, 5835, 13);
+ Delay(1000);
+ Item_Pickup_Spin_Effect(948, 239, 454);
+ Actor_Voice_Over(2740, 99);
+ Actor_Voice_Over(2750, 99);
+ Actor_Voice_Over(2760, 99);
+ Actor_Voice_Over(2770, 99);
+ Actor_Says(0, 5850, 13);
+ Actor_Says(10, 400, 15);
+ Actor_Says(13, 430, 6);
+ Actor_Says(0, 5855, 13);
+ Actor_Says(10, 410, 14);
+ Game_Flag_Set(597);
+ Actor_Clue_Acquire(0, 125, 1, 10);
+ break;
+ case 1480:
+ Actor_Says(0, 4595, 14);
+ break;
+ }
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug17.cpp b/engines/bladerunner/script/ug17.cpp
new file mode 100644
index 0000000000..d438a62ae4
--- /dev/null
+++ b/engines/bladerunner/script/ug17.cpp
@@ -0,0 +1,117 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG17::InitializeScene() {
+ if (Game_Flag_Query(447)) {
+ Setup_Scene_Information(1013.0f, 67.96f, -1892.0f, 525);
+ Game_Flag_Reset(447);
+ } else {
+ Setup_Scene_Information(1000.0f, 67.96f, -1539.0f, 0);
+ }
+ Scene_Exit_Add_2D_Exit(0, 610, 0, 639, 479, 1);
+ Scene_Exit_Add_2D_Exit(1, 551, 347, 594, 386, 0);
+ Ambient_Sounds_Add_Looping_Sound(589, 100, 1, 1);
+ Ambient_Sounds_Add_Looping_Sound(384, 50, 1, 1);
+ Ambient_Sounds_Add_Sound(72, 5, 80, 10, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(73, 5, 80, 10, 11, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(74, 5, 80, 10, 11, -100, 100, -101, -101, 0, 0);
+ Overlay_Play("UG17OVER", 0, 1, 0, 0);
+}
+
+void ScriptUG17::SceneLoaded() {
+ Obstacle_Object("BOX FOR BIG VENT13", true);
+ Unclickable_Object("BOX FOR BIG VENT13");
+}
+
+bool ScriptUG17::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG17::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG17::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG17::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG17::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1000.0f, 67.96f, -1539.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(353);
+ Set_Enter(87, 99);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 1013.0f, 67.96f, -1892.0f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 89, false);
+ if (Global_Variable_Query(1) == 5) {
+ Actor_Says(0, 8522, 14);
+ } else {
+ Loop_Actor_Travel_Ladder(0, 10, 1, 0);
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(448);
+ Set_Enter(17, 83);
+ }
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG17::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG17::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG17::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG17::PlayerWalkedIn() {
+ if (Game_Flag_Query(352)) {
+ Loop_Actor_Walk_To_XYZ(0, 961.0f, 67.96f, -1539.0f, 0, 0, false, 0);
+ Game_Flag_Reset(352);
+ }
+ //return false;
+}
+
+void ScriptUG17::PlayerWalkedOut() {
+}
+
+void ScriptUG17::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug18.cpp b/engines/bladerunner/script/ug18.cpp
new file mode 100644
index 0000000000..3ba8223500
--- /dev/null
+++ b/engines/bladerunner/script/ug18.cpp
@@ -0,0 +1,409 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG18::InitializeScene() {
+ Setup_Scene_Information(-684.71f, 0.0f, 171.59f, 0);
+ Game_Flag_Reset(434);
+ Scene_Exit_Add_2D_Exit(0, 0, 158, 100, 340, 3);
+ Ambient_Sounds_Add_Looping_Sound(105, 71, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(402, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(368, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(398, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 25, 25, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(1, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(57, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(58, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(196, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(197, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(198, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(199, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Scene_Loop_Set_Default(4);
+ if (Game_Flag_Query(670) && !Game_Flag_Query(671) && Global_Variable_Query(1) == 4) {
+ Actor_Set_Goal_Number(4, 300);
+ Actor_Set_Goal_Number(5, 300);
+ Actor_Set_Goal_Number(8, 300);
+ }
+}
+
+void ScriptUG18::SceneLoaded() {
+ Obstacle_Object("MACHINE_01", true);
+ Unobstacle_Object("PLATFM_RAIL 01", true);
+ Unobstacle_Object("PLATFM_RAIL 02", true);
+ Unobstacle_Object("OBSTACLE1", true);
+ Clickable_Object("MACHINE_01");
+ Unclickable_Object("MACHINE_01");
+ if (Game_Flag_Query(671)) {
+ Actor_Put_In_Set(4, 99);
+ Actor_Set_At_Waypoint(4, 41, 0);
+ if (Actor_Query_Which_Set_In(8) == 89) {
+ Actor_Put_In_Set(8, 91);
+ Actor_Set_At_Waypoint(8, 33, 0);
+ }
+ }
+ if (Game_Flag_Query(670) && !Game_Flag_Query(671) && Global_Variable_Query(1) == 4) {
+ Item_Add_To_World(91, 987, 89, -55.21f, 0.0f, -302.17f, 0, 12, 12, false, true, false, true);
+ }
+
+}
+
+bool ScriptUG18::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG18::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG18::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG18::ClickedOnItem(int itemId, bool a2) {
+ if (itemId == 91) {
+ if (a2) {
+ Item_Remove_From_World(91);
+ } else if (!Loop_Actor_Walk_To_Item(0, 91, 12, 1, false)) {
+ Item_Pickup_Spin_Effect(987, 368, 243);
+ Item_Remove_From_World(itemId);
+ Game_Flag_Set(703);
+ Actor_Clue_Acquire(0, 32, 1, 4);
+ }
+ }
+ return false;
+}
+
+bool ScriptUG18::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, -684.712f, 0.0f, 171.59f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(435);
+ Set_Enter(85, 97);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG18::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG18::SceneFrameAdvanced(int frame) {
+
+}
+
+void ScriptUG18::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+ if (actorId == 4) {
+ if (newGoal == 303) {
+ Game_Flag_Set(607);
+ ADQ_Flush();
+ Actor_Modify_Friendliness_To_Other(5, 0, 7);
+ Actor_Modify_Friendliness_To_Other(8, 0, 10);
+ Player_Loses_Control();
+ Actor_Face_Actor(4, 0, true);
+ ADQ_Add(4, 1220, 58);
+ Scene_Exits_Enable();
+ Actor_Set_Goal_Number(4, 305);
+ } else if (newGoal == 304) {
+ ADQ_Flush();
+ Actor_Modify_Friendliness_To_Other(5, 0, 7);
+ Actor_Modify_Friendliness_To_Other(8, 0, 10);
+ Player_Loses_Control();
+ Actor_Face_Actor(4, 0, true);
+ ADQ_Add(4, 1220, 58);
+ Scene_Exits_Enable();
+ Actor_Set_Goal_Number(4, 306);
+ }
+ } else if (actorId == 8) {
+ if (newGoal == 302) {
+ if (Actor_Query_Friendliness_To_Other(5, 0) > 55 && Game_Flag_Query(607)) {
+ sub_403588();
+ } else {
+ Actor_Set_Goal_Number(8, 307);
+ Actor_Set_Goal_Number(5, 310);
+ }
+ } else if (newGoal == 304) {
+ Actor_Modify_Friendliness_To_Other(5, 0, -3);
+ ADQ_Add(8, 380, -1);
+ Actor_Set_Goal_Number(8, 306);
+ } else if (newGoal == 305) {
+ Actor_Change_Animation_Mode(8, 6);
+ Sound_Play(12, 100, 0, 0, 50);
+ Actor_Force_Stop_Walking(0);
+ Actor_Change_Animation_Mode(0, 48);
+ Player_Loses_Control();
+ Actor_Retired_Here(0, 6, 6, 1, 8);
+ }
+ }
+}
+
+void ScriptUG18::PlayerWalkedIn() {
+ Loop_Actor_Walk_To_XYZ(0, -488.71f, 0.0f, 123.59f, 0, 0, false, 0);
+ if (Game_Flag_Query(670) && !Game_Flag_Query(671) && Actor_Query_Is_In_Current_Set(4)) {
+ Scene_Exits_Disable();
+ sub_402734();
+ sub_403278();
+ Game_Flag_Set(671);
+ }
+}
+
+void ScriptUG18::PlayerWalkedOut() {
+
+}
+
+void ScriptUG18::DialogueQueueFlushed(int a1) {
+ int v0 = Actor_Query_Goal_Number(4);
+ if (v0 == 301) {
+ Actor_Set_Goal_Number(4, 302);
+ Actor_Change_Animation_Mode(8, 6);
+ Sound_Play(14, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 22);
+ ADQ_Add(5, 630, 13);
+ Actor_Set_Goal_Number(5, 301);
+ } else if (v0 == 305) {
+ Actor_Change_Animation_Mode(0, 6);
+ Sound_Play(13, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 22);
+ Delay(900);
+ Actor_Change_Animation_Mode(0, 6);
+ Sound_Play(14, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 22);
+ Delay(1100);
+ Actor_Change_Animation_Mode(0, 6);
+ Sound_Play(12, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 22);
+ Delay(900);
+ Actor_Change_Animation_Mode(0, 6);
+ Sound_Play(14, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 61);
+ Overlay_Play("UG18over", 1, 0, 1, 0);
+ Actor_Set_Goal_Number(4, 307);
+ Player_Gains_Control();
+ ADQ_Add_Pause(2000);
+ ADQ_Add(8, 360, -1);
+ ADQ_Add_Pause(2000);
+ ADQ_Add(5, 650, 14);
+ ADQ_Add(8, 370, 14);
+ ADQ_Add(5, 1320, 14);
+ Actor_Set_Goal_Number(5, 303);
+ } else if (v0 == 306) {
+ Actor_Change_Animation_Mode(4, 6);
+ Sound_Play(13, 100, 0, 0, 50);
+ Actor_Force_Stop_Walking(0);
+ Actor_Change_Animation_Mode(0, 48);
+ Player_Loses_Control();
+ Actor_Retired_Here(0, 6, 6, 1, 4);
+ Actor_Set_Goal_Number(4, 307);
+ }
+
+ int v1 = Actor_Query_Goal_Number(5);
+ if (v1 == 301) {
+ Actor_Change_Animation_Mode(8, 6);
+ Sound_Play(14, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 22);
+ ADQ_Add(5, 640, 13);
+ ADQ_Add(4, 1210, 13);
+ Actor_Set_Goal_Number(5, 302);
+ } else if (v1 == 302) {
+ Actor_Change_Animation_Mode(8, 6);
+ Sound_Play(14, 100, 0, 0, 50);
+ Actor_Change_Animation_Mode(4, 61);
+ ADQ_Add_Pause(2000);
+ ADQ_Add(5, 650, 14);
+ ADQ_Add(8, 370, 14);
+ ADQ_Add(5, 1320, 14);
+ Actor_Set_Goal_Number(4, 390);
+ Actor_Retired_Here(4, 72, 32, 1, 8);
+ Actor_Set_Goal_Number(5, 303);
+ Scene_Exits_Enable();
+ } else if (v1 == 303) {
+ Actor_Set_Goal_Number(8, 301);
+ }
+ if (Actor_Query_Goal_Number(8) == 306) {
+ Actor_Change_Animation_Mode(8, 48);
+ Actor_Set_Goal_Number(8, 307);
+ Actor_Set_Goal_Number(5, 310);
+ }
+}
+
+void ScriptUG18::sub_402734() {
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5860, 9);
+ Delay(500);
+ Actor_Face_Actor(4, 0, true);
+ Delay(500);
+ Actor_Says(4, 790, 3);
+ Actor_Says(0, 5865, 12);
+ Actor_Says(4, 800, 3);
+ Loop_Actor_Walk_To_XYZ(0, -357.13f, 0.0f, -44.47f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5870, 14);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Start_Speech_Sample(4, 810);
+ Loop_Actor_Walk_To_XYZ(4, -57.21f, 0.0f, -334.17f, 0, 0, false, 0);
+ Actor_Says(0, 5875, 13);
+ Actor_Says(4, 830, 3);
+ Actor_Says(4, 840, 12);
+ Actor_Says(4, 850, 14);
+ Actor_Says(4, 860, 13);
+ Actor_Says(0, 5880, 15);
+ Actor_Says(0, 5885, 9);
+ Actor_Says(0, 5890, 13);
+ Actor_Says(4, 870, 15);
+ Loop_Actor_Walk_To_XYZ(0, -205.13f, 0.0f, -184.47f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5900, 15);
+ Actor_Says(4, 880, 13);
+ Actor_Says(0, 5905, 9);
+ Actor_Says(0, 5910, 12);
+ Actor_Says(0, 5915, 13);
+ Actor_Says(4, 890, 16);
+ Actor_Says(0, 5920, 14);
+ Loop_Actor_Walk_To_XYZ(4, -57.21f, 0.0f, -334.17f, 0, 0, false, 0);
+ Actor_Face_Actor(4, 0, true);
+ Actor_Says(4, 900, 15);
+ Actor_Says(4, 910, 12);
+ Actor_Says(4, 920, 16);
+ Actor_Says(0, 5925, 14);
+ Actor_Says(4, 940, 14);
+ Actor_Says(0, 5930, 18);
+ Actor_Says(4, 950, 14);
+ Actor_Says(4, 960, 13);
+ Actor_Says(4, 970, 3);
+ if (Game_Flag_Query(607)) {
+ Actor_Modify_Friendliness_To_Other(5, 0, 3);
+ Actor_Modify_Friendliness_To_Other(8, 0, 5);
+ Loop_Actor_Walk_To_XYZ(0, -117.13f, 0.0f, -284.47f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5960, 9);
+ Actor_Says(0, 5965, 14);
+ Actor_Says(4, 980, 15);
+ Actor_Says(4, 990, 13);
+ Actor_Says(0, 5970, 14);
+ Actor_Says(4, 1000, 3);
+ Actor_Says(0, 5975, 15);
+ } else {
+ sub_402DE8();
+ }
+}
+
+void ScriptUG18::sub_402DE8() {
+
+ if (Player_Query_Agenda()) {
+ if (Global_Variable_Query(45) > 1 || Player_Query_Agenda() == 2) {
+ sub_403114();
+ } else {
+ sub_402F8C();
+ }
+ } else {
+ Actor_Modify_Friendliness_To_Other(5, 0, -1);
+ Actor_Modify_Friendliness_To_Other(8, 0, -1);
+ Actor_Says(0, 5935, 14);
+ Actor_Says(0, 5940, 18);
+ Actor_Says(4, 1020, 13);
+ Actor_Says(4, 1030, 14);
+ }
+}
+
+void ScriptUG18::sub_402F8C() {
+ Loop_Actor_Walk_To_XYZ(0, -117.13f, 0.0f, -284.47f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5945, 12);
+ Actor_Says(4, 1040, 15);
+ Actor_Says(0, 5980, 15);
+ Actor_Says(4, 1050, 12);
+ Actor_Says(4, 1060, 13);
+ Actor_Says(4, 1070, 14);
+ Actor_Says(0, 5985, 18);
+ Actor_Says(4, 1080, 3);
+ Actor_Says(4, 1090, 14);
+ Actor_Says(4, 1100, 13);
+}
+
+void ScriptUG18::sub_403114() {
+ Actor_Modify_Friendliness_To_Other(5, 0, 20);
+ Actor_Modify_Friendliness_To_Other(8, 0, 10);
+ Loop_Actor_Walk_To_XYZ(0, -117.13f, 0.0f, -284.47f, 0, 0, false, 0);
+ Actor_Face_Actor(0, 4, true);
+ Actor_Says(0, 5950, 16);
+ Actor_Says(0, 5955, 14);
+ Actor_Says(4, 1110, 13);
+ Actor_Says(4, 1120, 15);
+ Actor_Says(0, 5990, 3);
+ Actor_Says(4, 1130, 15);
+ Actor_Says(4, 1140, 16);
+}
+
+void ScriptUG18::sub_403278() {
+ ADQ_Flush();
+ Actor_Start_Speech_Sample(5, 590);
+ Delay(500);
+ Loop_Actor_Walk_To_XYZ(4, 126.79f, 0.0f, -362.17f, 0, 0, false, 0);
+ Actor_Face_Heading(4, 729, false);
+ Actor_Set_Goal_Number(4, 301);
+ ADQ_Add(8, 350, 13);
+ ADQ_Add_Pause(1500);
+ ADQ_Add(4, 1150, 58);
+ ADQ_Add(5, 600, 13);
+ ADQ_Add_Pause(1000);
+ ADQ_Add(4, 1160, 60);
+ ADQ_Add_Pause(500);
+ ADQ_Add(4, 1170, 59);
+ ADQ_Add(4, 1180, 58);
+ ADQ_Add(5, 610, 13);
+ ADQ_Add(4, 1190, 60);
+ ADQ_Add(5, 620, 13);
+ ADQ_Add(4, 1200, 59);
+}
+
+void ScriptUG18::sub_403588() {
+ Actor_Says(5, 660, 13);
+ Actor_Says(0, 5995, 13);
+ Actor_Says(5, 670, 13);
+ Actor_Says(0, 6000, 13);
+ Actor_Says_With_Pause(5, 680, 2.0f, 13);
+ Actor_Says(5, 690, 13);
+ Actor_Says(5, 700, 13);
+ Actor_Set_Goal_Number(8, 310);
+ Actor_Set_Goal_Number(5, 310);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/ug19.cpp b/engines/bladerunner/script/ug19.cpp
new file mode 100644
index 0000000000..9a6000d363
--- /dev/null
+++ b/engines/bladerunner/script/ug19.cpp
@@ -0,0 +1,139 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+void ScriptUG19::InitializeScene() {
+ if (Game_Flag_Query(357)) {
+ Setup_Scene_Information(67.03f, 105.0f, -74.97f, 256);
+ } else {
+ Setup_Scene_Information(181.0f, 11.52f, -18.0f, 777);
+ }
+ Scene_Exit_Add_2D_Exit(0, 351, 0, 491, 347, 0);
+ Scene_Exit_Add_2D_Exit(1, 548, 124, 639, 369, 1);
+ Ambient_Sounds_Add_Looping_Sound(95, 45, 0, 1);
+ Ambient_Sounds_Add_Looping_Sound(332, 76, 0, 1);
+ Ambient_Sounds_Add_Sound(291, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(292, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(293, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(294, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(295, 2, 20, 25, 33, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(401, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(369, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(396, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(397, 2, 120, 11, 12, -100, 100, -100, 100, 0, 0);
+ Ambient_Sounds_Add_Sound(303, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(304, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(305, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(1, 5, 50, 47, 57, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(57, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(58, 5, 50, 17, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(306, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(307, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(308, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(196, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(197, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(198, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+ Ambient_Sounds_Add_Sound(199, 5, 50, 27, 37, -100, 100, -101, -101, 0, 0);
+
+}
+
+void ScriptUG19::SceneLoaded() {
+ Obstacle_Object("LADDER", true);
+ Unclickable_Object("LADDER");
+ Footstep_Sounds_Set(1, 0);
+ Footstep_Sounds_Set(0, 3);
+}
+
+bool ScriptUG19::MouseClick(int x, int y) {
+ return false;
+}
+
+bool ScriptUG19::ClickedOn3DObject(const char *objectName, bool a2) {
+ return false;
+}
+
+bool ScriptUG19::ClickedOnActor(int actorId) {
+ return false;
+}
+
+bool ScriptUG19::ClickedOnItem(int itemId, bool a2) {
+ return false;
+}
+
+bool ScriptUG19::ClickedOnExit(int exitId) {
+ if (exitId == 0) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 67.03f, 7.29f, -74.97f, 0, 1, false, 0)) {
+ Actor_Face_Heading(0, 256, false);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Ladder(0, 8, 1, 0);
+ Footstep_Sound_Override_Off();
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(356);
+ Set_Enter(53, 53);
+ }
+ return true;
+ }
+ if (exitId == 1) {
+ if (!Loop_Actor_Walk_To_XYZ(0, 181.0f, 11.52f, -18.0f, 0, 1, false, 0)) {
+ Ambient_Sounds_Remove_All_Non_Looping_Sounds(1);
+ Ambient_Sounds_Remove_All_Looping_Sounds(1);
+ Game_Flag_Set(349);
+ Set_Enter(86, 98);
+ }
+ return true;
+ }
+ return false;
+}
+
+bool ScriptUG19::ClickedOn2DRegion(int region) {
+ return false;
+}
+
+void ScriptUG19::SceneFrameAdvanced(int frame) {
+}
+
+void ScriptUG19::ActorChangedGoal(int actorId, int newGoal, int oldGoal, bool currentSet) {
+}
+
+void ScriptUG19::PlayerWalkedIn() {
+ if (Game_Flag_Query(348)) {
+ Game_Flag_Reset(348);
+ Loop_Actor_Walk_To_XYZ(0, 129.0f, 11.52f, -18.0f, 0, 0, false, 0);
+ } else {
+ Game_Flag_Reset(357);
+ Footstep_Sound_Override_On(3);
+ Loop_Actor_Travel_Ladder(0, 8, 0, 0);
+ Footstep_Sound_Override_Off();
+ }
+}
+
+void ScriptUG19::PlayerWalkedOut() {
+}
+
+void ScriptUG19::DialogueQueueFlushed(int a1) {
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/vk.cpp b/engines/bladerunner/script/vk.cpp
new file mode 100644
index 0000000000..5dfbbd7ae4
--- /dev/null
+++ b/engines/bladerunner/script/vk.cpp
@@ -0,0 +1,3524 @@
+/* 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.
+ *
+ */
+
+#include "bladerunner/script/vk.h"
+
+#include "bladerunner/bladerunner.h"
+
+namespace BladeRunner {
+
+bool ScriptVK::SCRIPT_VK_DLL_Initialize(int a1) {
+ VK_Add_Question(0, 7400, -1);
+ VK_Add_Question(0, 7405, -1);
+ VK_Add_Question(0, 7410, -1);
+ VK_Add_Question(0, 7415, -1);
+ VK_Add_Question(0, 7420, -1);
+ VK_Add_Question(0, 7425, -1);
+ if (a1 == 6 || a1 == 3) {
+ VK_Add_Question(0, 7430, -1);
+ }
+ VK_Add_Question(0, 7435, -1);
+ VK_Add_Question(0, 7440, -1);
+ VK_Add_Question(0, 7445, -1);
+ VK_Add_Question(0, 7450, -1);
+ VK_Add_Question(0, 7455, -1);
+ VK_Add_Question(0, 7460, -1);
+ VK_Add_Question(0, 7465, -1);
+ VK_Add_Question(0, 7470, -1);
+ VK_Add_Question(1, 7475, -1);
+ VK_Add_Question(1, 7480, -1);
+ VK_Add_Question(1, 7485, -1);
+ VK_Add_Question(1, 7490, -1);
+ VK_Add_Question(1, 7495, -1);
+ VK_Add_Question(1, 7515, -1);
+ VK_Add_Question(1, 7525, -1);
+ VK_Add_Question(1, 7535, -1);
+ VK_Add_Question(1, 7540, -1);
+ VK_Add_Question(1, 7550, -1);
+ VK_Add_Question(1, 7565, -1);
+ VK_Add_Question(1, 7580, -1);
+ VK_Add_Question(1, 7585, -1);
+ VK_Add_Question(1, 7595, -1);
+ VK_Add_Question(1, 7600, -1);
+ VK_Add_Question(2, 7605, -1);
+ VK_Add_Question(2, 7620, -1);
+ VK_Add_Question(2, 7635, -1);
+ VK_Add_Question(2, 7670, -1);
+ VK_Add_Question(2, 7680, -1);
+ VK_Add_Question(2, 7690, -1);
+ VK_Add_Question(2, 7705, -1);
+ VK_Add_Question(2, 7740, -1);
+ VK_Add_Question(2, 7750, -1);
+ VK_Add_Question(2, 7770, -1);
+ switch (a1) {
+ default:
+ return false;
+ case 3:
+ case 6:
+ case 11:
+ case 14:
+ case 15:
+ return true;
+
+ }
+}
+
+void ScriptVK::SCRIPT_VK_DLL_Calibrate(int a1) {
+
+ if (unknown1 <= 2) {
+ if (unknown1 == 0) {
+ VK_Play_Speech_Line(0, 7370, 0.5f);
+ VK_Play_Speech_Line(0, 7385, 0.5f);
+ sub_40A300(a1, 7385);
+
+ } else if (unknown1 == 1) {
+ VK_Play_Speech_Line(0, 7390, 0.5f);
+ sub_40A350(a1, 7390);
+ } else {
+ VK_Play_Speech_Line(0, 7395, 0.5f);
+ sub_40A3A0(a1, 7395);
+ }
+ }
+ unknown1++;
+ if (unknown1 > 3) //bug?
+ {
+ unknown1 = 0;
+ }
+}
+
+bool ScriptVK::SCRIPT_VK_DLL_Begin_Test() {
+ unknown2 = 0;
+ return false;
+}
+
+void ScriptVK::SCRIPT_VK_DLL_McCoy_Asks_Question(int a1, int a2) {
+ switch (a2) {
+ case 7495:
+ VK_Play_Speech_Line(0, 7495, 0.5f);
+ VK_Play_Speech_Line(0, 7500, 0.5f);
+ VK_Play_Speech_Line(0, 7505, 0.5f);
+ VK_Play_Speech_Line(0, 7510, 0.5f);
+ break;
+ case 7490:
+ VK_Play_Speech_Line(0, 7490, 0.5f);
+ break;
+ case 7485:
+ VK_Play_Speech_Line(0, 7485, 0.5f);
+ break;
+ case 7480:
+ VK_Play_Speech_Line(0, 7480, 0.5f);
+ break;
+ case 7475:
+ VK_Play_Speech_Line(0, 7475, 0.5f);
+ break;
+ case 7470:
+ VK_Play_Speech_Line(0, 7470, 0.5f);
+ break;
+ case 7465:
+ VK_Play_Speech_Line(0, 7465, 0.5f);
+ break;
+ case 7460:
+ VK_Play_Speech_Line(0, 7460, 0.5f);
+ break;
+ case 7455:
+ VK_Play_Speech_Line(0, 7455, 0.5f);
+ break;
+ case 7450:
+ VK_Play_Speech_Line(0, 7450, 0.5f);
+ break;
+ case 7445:
+ VK_Play_Speech_Line(0, 7445, 0.5f);
+ break;
+ case 7440:
+ VK_Play_Speech_Line(0, 7440, 0.5f);
+ break;
+ case 7435:
+ VK_Play_Speech_Line(0, 7435, 0.5f);
+ break;
+ case 7430:
+ VK_Play_Speech_Line(0, 7430, 0.5f);
+ break;
+ case 7425:
+ VK_Play_Speech_Line(0, 7425, 0.5f);
+ break;
+ case 7420:
+ VK_Play_Speech_Line(0, 7420, 0.5f);
+ break;
+ case 7415:
+ VK_Play_Speech_Line(0, 7415, 0.5f);
+ break;
+ case 7410:
+ VK_Play_Speech_Line(0, 7410, 0.5f);
+ break;
+ case 7405:
+ VK_Play_Speech_Line(0, 7405, 0.5f);
+ break;
+ case 7400:
+ VK_Play_Speech_Line(0, 7400, 0.5f);
+ break;
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ break;
+ default:
+ switch (a2) {
+ case 7635:
+ VK_Play_Speech_Line(0, 7635, 0.5f);
+ VK_Play_Speech_Line(0, 7640, 0.5f);
+ if (a1 != 11 && a1 != 14) {
+ VK_Play_Speech_Line(0, 7645, 0.5f);
+ VK_Play_Speech_Line(0, 7650, 0.5f);
+ if (a1 != 6) {
+ VK_Play_Speech_Line(0, 7655, 0.5f);
+ VK_Play_Speech_Line(0, 7660, 0.5f);
+ VK_Play_Speech_Line(0, 7665, 0.5f);
+ }
+ }
+ break;
+ case 7620:
+ VK_Play_Speech_Line(0, 7620, 0.5f);
+ VK_Play_Speech_Line(0, 7625, 0.5f);
+ if (a1 != 14) {
+ if (a1 == 3 && Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2330, 0.5f);
+ VK_Play_Speech_Line(0, 7880, 0.5f);
+ }
+ VK_Play_Speech_Line(0, 7630, 0.5f);
+ }
+ break;
+ case 7605:
+ VK_Play_Speech_Line(0, 7605, 0.5f);
+ VK_Play_Speech_Line(0, 7610, 0.5f);
+ VK_Play_Speech_Line(0, 7615, 0.5f);
+ break;
+ case 7600:
+ VK_Play_Speech_Line(0, 7600, 0.5f);
+ break;
+ case 7595:
+ VK_Play_Speech_Line(0, 7595, 0.5f);
+ break;
+ case 7585:
+ VK_Play_Speech_Line(0, 7585, 0.5f);
+ if (a1 != 6 && a1 != 14) {
+ VK_Play_Speech_Line(0, 7590, 0.5f);
+ }
+ break;
+ case 7580:
+ VK_Play_Speech_Line(0, 7580, 0.5f);
+ break;
+ case 7565:
+ VK_Play_Speech_Line(0, 7565, 0.5f);
+ if (a1 != 14) {
+ VK_Play_Speech_Line(0, 7570, 0.5f);
+ VK_Play_Speech_Line(0, 7575, 0.5f);
+ }
+ break;
+ case 7550:
+ VK_Play_Speech_Line(0, 7550, 0.5f);
+ VK_Play_Speech_Line(0, 7555, 0.5f);
+ VK_Play_Speech_Line(0, 7560, 0.5f);
+ break;
+ case 7540:
+ VK_Play_Speech_Line(0, 7540, 0.5f);
+ VK_Play_Speech_Line(0, 7545, 0.5f);
+ break;
+ case 7535:
+ VK_Play_Speech_Line(0, 7535, 0.5f);
+ break;
+ case 7525:
+ VK_Play_Speech_Line(0, 7525, 0.5f);
+ VK_Play_Speech_Line(0, 7530, 0.5f);
+ break;
+ case 7515:
+ VK_Play_Speech_Line(0, 7515, 0.5f);
+ VK_Play_Speech_Line(0, 7520, 0.5f);
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ if (++unknown2 >= 10) {
+ VK_Subject_Reacts(5, 0, 0, 100);
+ }
+ return;
+ default:
+ switch (a2) {
+ case 7705:
+ VK_Play_Speech_Line(0, 7705, 0.5f);
+ VK_Play_Speech_Line(0, 7710, 0.5f);
+ VK_Play_Speech_Line(0, 7715, 0.5f);
+ if (a1 != 11 && a1 != 14) {
+ VK_Play_Speech_Line(0, 7720, 0.5f);
+ VK_Play_Speech_Line(0, 7725, 0.5f);
+ if (a1 != 6) {
+ if (a1 == 3) {
+ VK_Play_Speech_Line(3, 2490, 0.5f);
+ }
+ VK_Play_Speech_Line(0, 7730, 0.5f);
+ VK_Play_Speech_Line(0, 7735, 0.5f);
+ }
+ }
+ break;
+ case 7690:
+ VK_Play_Speech_Line(0, 7690, 0.5f);
+ if (a1 != 11) {
+ VK_Play_Speech_Line(0, 7695, 0.5f);
+ VK_Play_Speech_Line(0, 7700, 0.5f);
+ }
+ break;
+ case 7680:
+ VK_Play_Speech_Line(0, 7680, 0.5f);
+ VK_Play_Speech_Line(0, 7685, 0.5f);
+ break;
+ case 7670:
+ VK_Play_Speech_Line(0, 7670, 0.5f);
+ VK_Play_Speech_Line(0, 7675, 0.5f);
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ if (++unknown2 >= 10) {
+ VK_Subject_Reacts(5, 0, 0, 100);
+ }
+ return;
+ default:
+ if ((unsigned int)(a2 - 7740) > 10) {
+ if (a2 == 7770) {
+ VK_Play_Speech_Line(0, 7770, 0.5f);
+ if (a1 == 3) {
+ VK_Play_Speech_Line(3, 2620, 0.5f);
+ }
+ VK_Play_Speech_Line(0, 7775, 0.5f);
+ VK_Play_Speech_Line(0, 7780, 0.5f);
+ }
+ } else if (a2 == 7740) {
+ VK_Play_Speech_Line(0, 7740, 0.5f);
+ VK_Play_Speech_Line(0, 7745, 0.5f);
+ } else if (a2 == 7750) {
+ VK_Play_Speech_Line(0, 7750, 0.5f);
+ VK_Play_Speech_Line(0, 7755, 0.5f);
+ if (a1 == 3) {
+ VK_Play_Speech_Line(3, 2570, 0.5f);
+ }
+ VK_Play_Speech_Line(0, 7760, 0.5f);
+ VK_Play_Speech_Line(0, 7765, 0.5f);
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+ if (++unknown2 >= 10) {
+ VK_Subject_Reacts(5, 0, 0, 100);
+ }
+}
+
+void ScriptVK::SCRIPT_VK_DLL_Question_Asked(int a1, int a2) {
+ switch (a1) {
+ case 15:
+ sub_407CF8(a2);
+ break;
+ case 14:
+ sub_40897C(a2);
+ break;
+ case 11:
+ sub_404B44(a2);
+ break;
+ case 6:
+ sub_402604(a2);
+ break;
+ case 3:
+ sub_406088(a2);
+ break;
+ }
+}
+
+void ScriptVK::SCRIPT_VK_DLL_Shutdown(int a1, signed int a2, signed int a3) {
+ if (a2 > 79 && a3 > 79) {
+ VK_Play_Speech_Line(39, 450, 0.5f);
+ } else if (a3 > 79) {
+ VK_Play_Speech_Line(39, 420, 0.5f);
+ VK_Play_Speech_Line(39, 430, 0.5f);
+ switch (a1) {
+ case 15:
+ Actor_Clue_Acquire(0, 174, 1, -1);
+ break;
+ case 14:
+ Actor_Clue_Acquire(0, 164, 1, -1);
+ break;
+ case 11:
+ Actor_Clue_Acquire(0, 168, 1, -1);
+ break;
+ case 6:
+ Actor_Clue_Acquire(0, 271, 1, -1);
+ break;
+ case 3:
+ Actor_Clue_Acquire(0, 162, 1, -1);
+ break;
+ default:
+ break;
+ }
+ } else if (a2 > 79) {
+ VK_Play_Speech_Line(39, 420, 0.5f);
+ VK_Play_Speech_Line(39, 440, 0.5f);
+ switch (a1) {
+ case 15:
+ Actor_Clue_Acquire(0, 175, 1, -1);
+ break;
+ case 14:
+ Actor_Clue_Acquire(0, 165, 1, -1);
+ break;
+ case 11:
+ Actor_Clue_Acquire(0, 169, 1, -1);
+ break;
+ case 6:
+ Actor_Clue_Acquire(0, 272, 1, -1);
+ break;
+ case 3:
+ Actor_Clue_Acquire(0, 163, 1, -1);
+ break;
+ case 4:
+ case 5:
+ case 7:
+ case 8:
+ case 9:
+ case 10:
+ case 12:
+ case 13:
+ break;
+ }
+ }
+ VK_Play_Speech_Line(39, 460, 0.5f);
+}
+
+void ScriptVK::sub_402604(int a1) {
+ switch (a1) {
+ case 7495:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(10, 2, 8, 5);
+ } else {
+ VK_Subject_Reacts(30, 10, -1, 5);
+ }
+ VK_Play_Speech_Line(6, 1770, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 1780, 0.5f);
+ break;
+ case 7490:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(30, 3, 11, 9);
+ } else {
+ VK_Subject_Reacts(40, 11, 1, 8);
+ }
+ VK_Play_Speech_Line(6, 1750, 0.5f);
+ VK_Play_Speech_Line(0, 7985, 0.5f);
+ VK_Play_Speech_Line(0, 7990, 0.5f);
+ VK_Play_Speech_Line(6, 1760, 0.5f);
+ break;
+ case 7485:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, -2, 10, 6);
+ } else {
+ VK_Subject_Reacts(30, 10, -2, 6);
+ VK_Eye_Animates(2);
+ }
+ VK_Play_Speech_Line(6, 1740, 0.5f);
+ break;
+ case 7480:
+ VK_Play_Speech_Line(6, 1720, 0.5f);
+ VK_Play_Speech_Line(0, 7975, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, 2, 10, 7);
+ } else {
+ VK_Subject_Reacts(50, 12, 3, 7);
+ }
+ VK_Play_Speech_Line(6, 1730, 0.5f);
+ VK_Play_Speech_Line(0, 7980, 0.5f);
+ break;
+ case 7475:
+ if (Game_Flag_Query(46)) {
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1660, 0.5f);
+ VK_Play_Speech_Line(0, 7965, 0.5f);
+ VK_Subject_Reacts(70, -3, 13, 10);
+ VK_Play_Speech_Line(6, 1670, 0.5f);
+ } else {
+ VK_Play_Speech_Line(6, 1680, 0.5f);
+ VK_Subject_Reacts(60, 13, -4, 5);
+ VK_Play_Speech_Line(6, 1690, 0.5f);
+ VK_Play_Speech_Line(0, 7970, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1700, 0.5f);
+ VK_Play_Speech_Line(6, 1710, 0.5f);
+ }
+ break;
+ case 7470:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1610, 0.5f);
+ VK_Subject_Reacts(20, 3, 9, -5);
+ VK_Play_Speech_Line(6, 1620, 0.5f);
+ } else {
+ VK_Subject_Reacts(30, 9, 0, -5);
+ VK_Play_Speech_Line(6, 1630, 0.5f);
+ VK_Play_Speech_Line(6, 1640, 0.5f);
+ VK_Play_Speech_Line(0, 7960, 0.5f);
+ VK_Play_Speech_Line(6, 1650, 0.5f);
+ }
+ break;
+ case 7465:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, -1, 11, 2);
+ VK_Play_Speech_Line(6, 1590, 0.5f);
+ } else {
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 1590, 0.5f);
+ VK_Subject_Reacts(20, 9, 2, -8);
+ }
+ break;
+ case 7460:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(30, 1, 10, -5);
+ } else {
+ VK_Subject_Reacts(30, 9, 2, -5);
+ }
+ VK_Play_Speech_Line(6, 1560, 0.5f);
+ VK_Play_Speech_Line(0, 7955, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1570, 0.5f);
+ VK_Play_Speech_Line(6, 1580, 0.5f);
+ break;
+ case 7455:
+ VK_Play_Speech_Line(6, 1540, 0.5f);
+ VK_Play_Speech_Line(0, 7950, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(10, 1, 8, -5);
+ } else {
+ VK_Subject_Reacts(10, 9, -1, -2);
+ }
+ VK_Play_Speech_Line(6, 1550, 0.5f);
+ break;
+ case 7450:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, 3, 9, -6);
+ } else {
+ VK_Subject_Reacts(30, 9, 4, -6);
+ VK_Eye_Animates(2);
+ }
+ VK_Play_Speech_Line(6, 1530, 0.5f);
+ break;
+ case 7445:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1480, 0.5f);
+ VK_Play_Speech_Line(0, 7940, 0.5f);
+ VK_Subject_Reacts(50, 4, 11, 10);
+ VK_Play_Speech_Line(6, 1500, 0.5f);
+ } else {
+ VK_Subject_Reacts(30, 9, -1, -2);
+ VK_Play_Speech_Line(6, 1510, 0.5f);
+ VK_Play_Speech_Line(0, 7945, 0.5f);
+ VK_Play_Speech_Line(6, 1520, 0.5f);
+ }
+ break;
+ case 7440:
+ VK_Play_Speech_Line(6, 1460, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, 5, 10, 2);
+ VK_Eye_Animates(3);
+ } else {
+ VK_Subject_Reacts(20, 9, -3, 2);
+ }
+ VK_Play_Speech_Line(6, 1470, 0.5f);
+ break;
+ case 7435:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1440, 0.5f);
+ VK_Subject_Reacts(30, 5, 10, 2);
+ } else {
+ VK_Subject_Reacts(30, 9, 3, 2);
+ VK_Play_Speech_Line(6, 1450, 0.5f);
+ }
+ break;
+ case 7430:
+ VK_Play_Speech_Line(6, 1420, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, -1, 9, -3);
+ } else {
+ VK_Subject_Reacts(30, 9, -1, -3);
+ }
+ VK_Play_Speech_Line(6, 1430, 0.5f);
+ VK_Play_Speech_Line(0, 7940, 0.5f);
+ VK_Eye_Animates(2);
+ break;
+ case 7425:
+ VK_Play_Speech_Line(6, 1400, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, -2, 9, -2);
+ } else {
+ VK_Subject_Reacts(20, 9, -2, -2);
+ }
+ VK_Play_Speech_Line(6, 1410, 0.5f);
+ break;
+ case 7420:
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1370, 0.5f);
+ VK_Play_Speech_Line(0, 8000, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(50, 1, 11, -8);
+ } else {
+ VK_Subject_Reacts(60, 11, -2, -8);
+ }
+ VK_Play_Speech_Line(6, 1390, 0.5f);
+ break;
+ case 7415:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1340, 0.5f);
+ VK_Subject_Reacts(50, 1, 11, -5);
+ VK_Play_Speech_Line(0, 7935, 0.5f);
+ VK_Play_Speech_Line(6, 1350, 0.5f);
+ } else {
+ VK_Play_Speech_Line(6, 1360, 0.5f);
+ VK_Subject_Reacts(20, 9, -2, -5);
+ }
+ break;
+ case 7410:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, 1, 10, -5);
+ VK_Eye_Animates(2);
+ } else {
+ VK_Subject_Reacts(40, 10, -2, -5);
+ }
+ VK_Play_Speech_Line(6, 1330, 0.5f);
+ break;
+ case 7405:
+ VK_Play_Speech_Line(6, 1310, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(50, 1, 11, 5);
+ } else {
+ VK_Subject_Reacts(60, 11, 1, 5);
+ }
+ VK_Play_Speech_Line(6, 1320, 0.5f);
+ break;
+ case 7400:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, 0, 8, -5);
+ } else {
+ VK_Subject_Reacts(30, 9, 0, -10);
+ }
+ VK_Play_Speech_Line(6, 1300, 0.5f);
+ VK_Eye_Animates(3);
+ break;
+ case 7395:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1280, 0.5f);
+ VK_Subject_Reacts(40, 0, 0, 0);
+ } else {
+ VK_Subject_Reacts(40, 0, 0, 0);
+ VK_Play_Speech_Line(6, 1280, 0.5f);
+ }
+ break;
+ case 7390:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 1250, 0.5f);
+ VK_Subject_Reacts(40, 0, 2, 5);
+ VK_Play_Speech_Line(6, 1260, 0.5f);
+ VK_Eye_Animates(3);
+ } else {
+ VK_Play_Speech_Line(6, 1270, 0.5f);
+ VK_Subject_Reacts(40, 3, 0, 2);
+ }
+ break;
+ case 7385:
+ VK_Subject_Reacts(40, 0, 0, 0);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 1240, 0.5f);
+ break;
+ case 7386:
+ case 7387:
+ case 7388:
+ case 7389:
+ case 7391:
+ case 7392:
+ case 7393:
+ case 7394:
+ case 7396:
+ case 7397:
+ case 7398:
+ case 7399:
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ return;
+ default:
+ switch (a1) {
+ case 7635:
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 2110, 0.5f);
+ VK_Play_Speech_Line(0, 7655, 0.5f);
+ VK_Play_Speech_Line(0, 7660, 0.5f);
+ VK_Play_Speech_Line(0, 7665, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(80, 5, 14, 25);
+ } else {
+ VK_Subject_Reacts(70, 9, -2, 20);
+ }
+ VK_Play_Speech_Line(6, 2120, 0.5f);
+ break;
+ case 7620:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(60, -2, 14, 12);
+ } else {
+ VK_Subject_Reacts(70, 9, -1, 10);
+ }
+ VK_Play_Speech_Line(6, 2090, 0.5f);
+ VK_Play_Speech_Line(0, 8055, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 2100, 0.5f);
+ break;
+ case 7605:
+ VK_Play_Speech_Line(6, 2070, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(30, 0, 11, 12);
+ } else {
+ VK_Subject_Reacts(50, 10, -3, 15);
+ }
+ VK_Play_Speech_Line(6, 2080, 0.5f);
+ break;
+ case 7600:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(75, 4, 13, 15);
+ } else {
+ VK_Subject_Reacts(60, 12, -2, 10);
+ }
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 2050, 0.5f);
+ VK_Play_Speech_Line(0, 8050, 0.5f);
+ VK_Subject_Reacts(90, 0, 0, 0);
+ VK_Play_Speech_Line(6, 2060, 0.5f);
+ break;
+ case 7595:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 2010, 0.5f);
+ VK_Subject_Reacts(30, -2, 10, 5);
+ VK_Play_Speech_Line(6, 2020, 0.5f);
+ VK_Play_Speech_Line(0, 8045, 0.5f);
+ VK_Play_Speech_Line(6, 2030, 0.5f);
+ } else {
+ VK_Subject_Reacts(60, 12, -3, 7);
+ VK_Play_Speech_Line(6, 2040, 0.5f);
+ }
+ break;
+ case 7585:
+ VK_Play_Speech_Line(6, 1950, 0.5f);
+ VK_Play_Speech_Line(0, 8030, 0.5f);
+ VK_Play_Speech_Line(6, 1960, 0.5f);
+ VK_Play_Speech_Line(0, 8035, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1970, 0.5f);
+ VK_Play_Speech_Line(0, 7590, 0.5f);
+ VK_Play_Speech_Line(6, 1980, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, 1, 11, 5);
+ } else {
+ VK_Subject_Reacts(50, 12, -3, 5);
+ }
+ VK_Play_Speech_Line(6, 1990, 0.5f);
+ VK_Play_Speech_Line(0, 8040, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 2000, 0.5f);
+ break;
+ case 7580:
+ VK_Play_Speech_Line(6, 1930, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, 5, 10, -1);
+ } else {
+ VK_Subject_Reacts(30, 10, 3, 0);
+ }
+ VK_Play_Speech_Line(0, 8025, 0.5f);
+ VK_Play_Speech_Line(6, 1940, 0.5f);
+ break;
+ case 7565:
+ VK_Play_Speech_Line(6, 1910, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(30, -2, 10, 8);
+ } else {
+ VK_Subject_Reacts(20, 9, -3, 6);
+ }
+ VK_Play_Speech_Line(6, 1920, 0.5f);
+ VK_Play_Speech_Line(0, 8020, 0.5f);
+ VK_Eye_Animates(2);
+ break;
+ case 7550:
+ VK_Play_Speech_Line(6, 1890, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, 2, 9, -1);
+ } else {
+ VK_Subject_Reacts(10, 8, -1, -2);
+ }
+ VK_Play_Speech_Line(6, 1900, 0.5f);
+ VK_Play_Speech_Line(0, 8015, 0.5f);
+ break;
+ case 7540:
+ if (Game_Flag_Query(46)) {
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(6, 1860, 0.5f);
+ VK_Play_Speech_Line(0, 8010, 0.5f);
+ VK_Subject_Reacts(50, -2, 12, 5);
+ VK_Play_Speech_Line(6, 1870, 0.5f);
+ } else {
+ VK_Subject_Reacts(60, 12, -2, 5);
+ VK_Play_Speech_Line(6, 1880, 0.5f);
+ }
+ break;
+ case 7535:
+ VK_Play_Speech_Line(6, 1830, 0.5f);
+ VK_Play_Speech_Line(0, 8000, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(10, 1, 8, 0);
+ } else {
+ VK_Subject_Reacts(20, 9, -1, 0);
+ }
+ VK_Play_Speech_Line(6, 1840, 0.5f);
+ VK_Play_Speech_Line(6, 1850, 0.5f);
+ VK_Play_Speech_Line(0, 8005, 0.5f);
+ break;
+ case 7525:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(20, -4, 9, 5);
+ VK_Eye_Animates(3);
+ } else {
+ VK_Subject_Reacts(40, 11, -3, 7);
+ VK_Eye_Animates(2);
+ }
+ VK_Play_Speech_Line(6, 1820, 0.5f);
+ break;
+ case 7515:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(50, -1, 12, 5);
+ VK_Play_Speech_Line(6, 1790, 0.5f);
+ VK_Play_Speech_Line(0, 7995, 0.5f);
+ VK_Play_Speech_Line(6, 1800, 0.5f);
+ } else {
+ VK_Subject_Reacts(30, 10, 0, 3);
+ VK_Play_Speech_Line(6, 1810, 0.5f);
+ }
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ return;
+ default:
+ switch (a1) {
+ case 7705:
+ if (Game_Flag_Query(46)) {
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(30, 0, 0, 0);
+ VK_Play_Speech_Line(6, 2220, 0.5f);
+ VK_Play_Speech_Line(0, 7730, 0.5f);
+ VK_Play_Speech_Line(0, 7735, 0.5f);
+ VK_Subject_Reacts(50, 2, 10, 12);
+ VK_Play_Speech_Line(6, 2230, 0.5f);
+ VK_Play_Speech_Line(0, 8065, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 2240, 0.5f);
+ VK_Play_Speech_Line(0, 8070, 0.5f);
+ VK_Play_Speech_Line(0, 8075, 0.5f);
+ } else {
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(50, 0, 0, 0);
+ VK_Play_Speech_Line(6, 2250, 0.5f);
+ VK_Play_Speech_Line(0, 7730, 0.5f);
+ VK_Play_Speech_Line(0, 7735, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(60, 12, 2, 12);
+ VK_Play_Speech_Line(6, 2230, 0.5f);
+ VK_Play_Speech_Line(6, 2270, 0.5f);
+ VK_Play_Speech_Line(0, 8080, 0.5f);
+ VK_Play_Speech_Line(6, 2280, 0.5f);
+ }
+ break;
+ case 7690:
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, 0, 12, 0);
+ } else {
+ VK_Subject_Reacts(50, 13, 0, 0);
+ }
+ VK_Play_Speech_Line(6, 2190, 0.5f);
+ VK_Play_Speech_Line(0, 8060, 0.5f);
+ VK_Play_Speech_Line(6, 2200, 0.5f);
+ VK_Subject_Reacts(30, -4, -4, -5);
+ VK_Play_Speech_Line(6, 2210, 0.5f);
+ break;
+ case 7680:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(6, 2170, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(65, 1, 6, 5);
+ } else {
+ VK_Subject_Reacts(50, 10, 3, 4);
+ }
+ VK_Play_Speech_Line(6, 2180, 0.5f);
+ break;
+ case 7670:
+ if (Game_Flag_Query(46)) {
+ VK_Play_Speech_Line(6, 2130, 0.5f);
+ VK_Subject_Reacts(30, -3, 11, 8);
+ VK_Play_Speech_Line(6, 2140, 0.5f);
+ } else {
+ VK_Subject_Reacts(20, 10, 0, 5);
+ VK_Play_Speech_Line(6, 2150, 0.5f);
+ VK_Play_Speech_Line(6, 2160, 0.5f);
+ }
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ return;
+ default:
+ if ((unsigned int)(a1 - 7740) > 10) {
+ if (a1 == 7770) {
+ VK_Play_Speech_Line(6, 2350, 0.5f);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(90, -3, -1, 12);
+ } else {
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(90, 13, -4, 12);
+ }
+ VK_Play_Speech_Line(6, 2360, 0.5f);
+ }
+ } else if (a1 == 7740) {
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(40, -3, -1, 3);
+ } else {
+ VK_Subject_Reacts(50, -1, -3, 3);
+ }
+ VK_Play_Speech_Line(6, 2290, 0.5f);
+ VK_Play_Speech_Line(0, 8085, 0.5f);
+ VK_Play_Speech_Line(6, 2300, 0.5f);
+ VK_Play_Speech_Line(0, 8090, 0.5f);
+ VK_Subject_Reacts(20, 2, 2, 0);
+ VK_Play_Speech_Line(6, 2310, 0.5f);
+ VK_Play_Speech_Line(6, 2320, 0.5f);
+ } else if (a1 == 7750) {
+ VK_Eye_Animates(3);
+ if (Game_Flag_Query(46)) {
+ VK_Subject_Reacts(60, 4, 10, 15);
+ } else {
+ VK_Subject_Reacts(80, 12, -3, 18);
+ }
+ VK_Play_Speech_Line(6, 2330, 0.5f);
+ VK_Play_Speech_Line(0, 8095, 0.5f);
+ VK_Play_Speech_Line(6, 2340, 0.5f);
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+}
+
+void ScriptVK::sub_404B44(int a1) {
+ switch (a1) {
+ case 7495:
+ VK_Play_Speech_Line(11, 780, 0.5f);
+ VK_Subject_Reacts(30, 9, 6, 5);
+ VK_Play_Speech_Line(11, 790, 0.5f);
+ break;
+ case 7490:
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(30, 7, -4, 12);
+ VK_Play_Speech_Line(11, 770, 0.5f);
+ break;
+ case 7485:
+ VK_Subject_Reacts(15, 8, 8, 5);
+ VK_Play_Speech_Line(11, 760, 0.5f);
+ break;
+ case 7480:
+ VK_Subject_Reacts(20, 9, 4, 8);
+ VK_Play_Speech_Line(11, 740, 0.5f);
+ VK_Play_Speech_Line(11, 750, 0.5f);
+ break;
+ case 7475:
+ VK_Subject_Reacts(15, 8, 2, 5);
+ VK_Play_Speech_Line(11, 730, 0.5f);
+ break;
+ case 7470:
+ VK_Subject_Reacts(30, 4, 8, -2);
+ VK_Play_Speech_Line(11, 720, 0.5f);
+ break;
+ case 7465:
+ VK_Subject_Reacts(5, 7, -4, -7);
+ VK_Play_Speech_Line(11, 710, 0.5f);
+ break;
+ case 7460:
+ VK_Subject_Reacts(15, 4, 8, 0);
+ VK_Play_Speech_Line(11, 700, 0.5f);
+ break;
+ case 7455:
+ VK_Play_Speech_Line(11, 680, 0.5f);
+ VK_Subject_Reacts(20, 7, -3, -5);
+ VK_Play_Speech_Line(11, 690, 0.5f);
+ break;
+ case 7450:
+ VK_Play_Speech_Line(11, 660, 0.5f);
+ VK_Subject_Reacts(35, 4, 8, 3);
+ VK_Play_Speech_Line(0, 8145, 0.5f);
+ VK_Play_Speech_Line(11, 670, 0.5f);
+ break;
+ case 7445:
+ VK_Subject_Reacts(30, 8, 3, 5);
+ VK_Play_Speech_Line(11, 650, 0.5f);
+ break;
+ case 7440:
+ VK_Subject_Reacts(25, 4, 7, -3);
+ VK_Play_Speech_Line(11, 640, 0.5f);
+ break;
+ case 7435:
+ VK_Play_Speech_Line(11, 620, 0.5f);
+ VK_Subject_Reacts(15, 8, -3, -5);
+ VK_Play_Speech_Line(11, 630, 0.5f);
+ break;
+ case 7430:
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(45, 8, 7, 15);
+ VK_Play_Speech_Line(11, 600, 0.5f);
+ VK_Play_Speech_Line(0, 8130, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 610, 0.5f);
+ VK_Play_Speech_Line(0, 8135, 0.5f);
+ VK_Play_Speech_Line(0, 8140, 0.5f);
+ break;
+ case 7425:
+ VK_Subject_Reacts(30, 8, -2, 5);
+ VK_Play_Speech_Line(11, 590, 0.5f);
+ break;
+ case 7420:
+ VK_Subject_Reacts(10, 6, 8, -5);
+ VK_Play_Speech_Line(11, 580, 0.5f);
+ break;
+ case 7415:
+ VK_Play_Speech_Line(11, 550, 0.5f);
+ VK_Subject_Reacts(25, 7, 8, 8);
+ VK_Play_Speech_Line(11, 560, 0.5f);
+ VK_Play_Speech_Line(0, 8120, 0.5f);
+ VK_Play_Speech_Line(0, 8125, 0.5f);
+ VK_Subject_Reacts(75, 8, 0, 0);
+ VK_Play_Speech_Line(11, 570, 0.5f);
+ break;
+ case 7410:
+ VK_Subject_Reacts(20, 12, -3, -3);
+ VK_Play_Speech_Line(11, 530, 0.5f);
+ VK_Play_Speech_Line(11, 540, 0.5f);
+ break;
+ case 7405:
+ VK_Play_Speech_Line(11, 510, 0.5f);
+ VK_Subject_Reacts(30, 10, 7, 0);
+ VK_Play_Speech_Line(11, 520, 0.5f);
+ VK_Play_Speech_Line(0, 8115, 0.5f);
+ break;
+ case 7400:
+ VK_Subject_Reacts(10, 8, 0, -5);
+ VK_Play_Speech_Line(11, 490, 0.5f);
+ VK_Play_Speech_Line(11, 500, 0.5f);
+ break;
+ case 7395:
+ VK_Subject_Reacts(20, 0, 0, 7);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 470, 0.5f);
+ VK_Play_Speech_Line(11, 480, 0.5f);
+ VK_Play_Speech_Line(0, 8105, 0.5f);
+ break;
+ case 7390:
+ VK_Subject_Reacts(20, 0, 0, 3);
+ VK_Play_Speech_Line(11, 460, 0.5f);
+ break;
+ case 7385:
+ VK_Subject_Reacts(20, 0, 0, 5);
+ VK_Play_Speech_Line(11, 440, 0.5f);
+ VK_Play_Speech_Line(0, 8100, 0.5f);
+ VK_Play_Speech_Line(11, 450, 0.5f);
+ VK_Play_Speech_Line(0, 8105, 0.5f);
+ break;
+ case 7386:
+ case 7387:
+ case 7388:
+ case 7389:
+ case 7391:
+ case 7392:
+ case 7393:
+ case 7394:
+ case 7396:
+ case 7397:
+ case 7398:
+ case 7399:
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ return;
+ default:
+ switch (a1) {
+ case 7635:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 970, 0.5f);
+ VK_Play_Speech_Line(0, 7645, 0.5f);
+ VK_Play_Speech_Line(0, 7650, 0.5f);
+ VK_Play_Speech_Line(0, 7655, 0.5f);
+ VK_Play_Speech_Line(0, 7660, 0.5f);
+ VK_Play_Speech_Line(0, 7665, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 980, 0.5f);
+ VK_Subject_Reacts(20, 10, 5, 12);
+ break;
+ case 7620:
+ VK_Subject_Reacts(30, 9, 10, 10);
+ VK_Play_Speech_Line(11, 960, 0.5f);
+ break;
+ case 7605:
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(40, 10, -3, 15);
+ VK_Play_Speech_Line(11, 950, 0.5f);
+ break;
+ case 7600:
+ VK_Subject_Reacts(20, 5, 9, 2);
+ VK_Play_Speech_Line(11, 940, 0.5f);
+ break;
+ case 7595:
+ VK_Subject_Reacts(25, 8, -3, 5);
+ VK_Play_Speech_Line(11, 920, 0.5f);
+ VK_Play_Speech_Line(0, 8185, 0.5f);
+ VK_Play_Speech_Line(11, 930, 0.5f);
+ break;
+ case 7585:
+ VK_Subject_Reacts(50, 9, 3, 8);
+ VK_Play_Speech_Line(11, 1250, 0.5f);
+ break;
+ case 7580:
+ VK_Play_Speech_Line(11, 900, 0.5f);
+ VK_Play_Speech_Line(0, 8180, 0.5f);
+ VK_Subject_Reacts(20, 8, 3, 6);
+ VK_Play_Speech_Line(11, 910, 0.5f);
+ break;
+ case 7565:
+ VK_Subject_Reacts(40, 8, 8, 12);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 870, 0.5f);
+ VK_Play_Speech_Line(0, 8175, 0.5f);
+ VK_Play_Speech_Line(11, 880, 0.5f);
+ VK_Play_Speech_Line(11, 890, 0.5f);
+ break;
+ case 7550:
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(11, 850, 0.5f);
+ VK_Play_Speech_Line(0, 8165, 0.5f);
+ VK_Subject_Reacts(60, 6, 2, 15);
+ VK_Play_Speech_Line(11, 860, 0.5f);
+ VK_Play_Speech_Line(0, 8170, 0.5f);
+ VK_Eye_Animates(3);
+ break;
+ case 7540:
+ VK_Play_Speech_Line(11, 840, 0.5f);
+ VK_Subject_Reacts(20, 5, 1, 8);
+ break;
+ case 7535:
+ VK_Subject_Reacts(20, 9, 2, 4);
+ VK_Play_Speech_Line(11, 830, 0.5f);
+ break;
+ case 7525:
+ VK_Subject_Reacts(30, 8, 5, 8);
+ VK_Play_Speech_Line(11, 820, 0.5f);
+ break;
+ case 7515:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 800, 0.5f);
+ VK_Play_Speech_Line(0, 8150, 0.5f);
+ VK_Play_Speech_Line(0, 8155, 0.5f);
+ VK_Subject_Reacts(30, 9, -5, 12);
+ VK_Play_Speech_Line(11, 810, 0.5f);
+ VK_Play_Speech_Line(0, 8160, 0.5f);
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ return;
+ default:
+ switch (a1) {
+ case 7705:
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(11, 1070, 0.5f);
+ VK_Play_Speech_Line(0, 7720, 0.5f);
+ VK_Play_Speech_Line(0, 7725, 0.5f);
+ VK_Play_Speech_Line(0, 7730, 0.5f);
+ VK_Play_Speech_Line(0, 7735, 0.5f);
+ VK_Subject_Reacts(60, 14, 3, 20);
+ VK_Play_Speech_Line(11, 1080, 0.5f);
+ VK_Play_Speech_Line(0, 8195, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(11, 1090, 0.5f);
+ VK_Play_Speech_Line(0, 8200, 0.5f);
+ break;
+ case 7690:
+ VK_Play_Speech_Line(11, 1050, 0.5f);
+ VK_Play_Speech_Line(0, 7695, 0.5f);
+ VK_Play_Speech_Line(0, 7700, 0.5f);
+ VK_Subject_Reacts(60, 11, 9, 100);
+ VK_Play_Speech_Line(11, 1060, 0.5f);
+ break;
+ case 7680:
+ VK_Play_Speech_Line(11, 1000, 0.5f);
+ VK_Subject_Reacts(30, 9, 3, 10);
+ VK_Play_Speech_Line(11, 1010, 0.5f);
+ VK_Play_Speech_Line(0, 8190, 0.5f);
+ VK_Play_Speech_Line(11, 1020, 0.5f);
+ VK_Play_Speech_Line(11, 1030, 0.5f);
+ VK_Play_Speech_Line(11, 1040, 0.5f);
+ break;
+ case 7670:
+ VK_Subject_Reacts(30, 4, 1, 10);
+ VK_Play_Speech_Line(11, 990, 0.5f);
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ return;
+ default:
+ if ((unsigned int)(a1 - 7740) > 10) {
+ if (a1 == 7770) {
+ VK_Play_Speech_Line(11, 1160, 0.5f);
+ VK_Subject_Reacts(5, -8, 7, 10);
+ }
+ } else if (a1 == 7740) {
+ VK_Subject_Reacts(40, 10, 1, 15);
+ VK_Play_Speech_Line(11, 1100, 0.5f);
+ VK_Play_Speech_Line(0, 8205, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(11, 1110, 0.5f);
+ VK_Play_Speech_Line(0, 8210, 0.5f);
+ } else if (a1 == 7750) {
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(50, 9, -4, 20);
+ VK_Play_Speech_Line(11, 1120, 0.5f);
+ VK_Play_Speech_Line(11, 1130, 0.5f);
+ VK_Play_Speech_Line(11, 1140, 0.5f);
+ VK_Play_Speech_Line(0, 8220, 0.5f);
+ VK_Play_Speech_Line(11, 1150, 0.5f);
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+}
+
+void ScriptVK::sub_406088(int a1) {
+ switch (a1) {
+ case 7495:
+ VK_Play_Speech_Line(3, 1970, 0.5f);
+ VK_Play_Speech_Line(0, 7830, 0.5f);
+ VK_Play_Speech_Line(3, 1980, 0.5f);
+ VK_Subject_Reacts(65, 4, 4, 5);
+ VK_Play_Speech_Line(3, 1990, 0.5f);
+ break;
+ case 7490:
+ VK_Subject_Reacts(43, 8, 8, 5);
+ VK_Play_Speech_Line(3, 1950, 0.5f);
+ VK_Play_Speech_Line(0, 7820, 0.5f);
+ VK_Play_Speech_Line(3, 1960, 0.5f);
+ VK_Play_Speech_Line(0, 7825, 0.5f);
+ break;
+ case 7485:
+ VK_Play_Speech_Line(3, 1940, 0.5f);
+ VK_Subject_Reacts(38, 4, 9, 0);
+ break;
+ case 7480:
+ if (Game_Flag_Query(47)) {
+ VK_Subject_Reacts(55, -3, 12, 5);
+ VK_Play_Speech_Line(3, 1910, 0.5f);
+ } else {
+ VK_Play_Speech_Line(3, 1920, 0.5f);
+ VK_Subject_Reacts(55, 17, -3, 5);
+ VK_Play_Speech_Line(3, 1930, 0.5f);
+ }
+ break;
+ case 7475:
+ VK_Subject_Reacts(28, 0, 0, 0);
+ VK_Play_Speech_Line(3, 1900, 0.5f);
+ break;
+ case 7470:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 1850, 0.5f);
+ VK_Subject_Reacts(50, -2, 11, 0);
+ VK_Play_Speech_Line(3, 1860, 0.5f);
+ } else {
+ VK_Subject_Reacts(90, 15, -5, 10);
+ VK_Play_Speech_Line(3, 1870, 0.5f);
+ VK_Play_Speech_Line(0, 8532, 0.5f);
+ VK_Play_Speech_Line(3, 1890, 0.5f);
+ }
+ break;
+ case 7465:
+ if (Game_Flag_Query(47)) {
+ VK_Subject_Reacts(60, -3, 10, 5);
+ VK_Play_Speech_Line(3, 1830, 0.5f);
+ } else {
+ VK_Play_Speech_Line(3, 1840, 0.5f);
+ VK_Subject_Reacts(60, 13, 2, 5);
+ }
+ break;
+ case 7460:
+ if (Game_Flag_Query(47)) {
+ VK_Subject_Reacts(40, -2, 10, 10);
+ VK_Play_Speech_Line(3, 1810, 0.5f);
+ } else {
+ VK_Subject_Reacts(35, 14, 3, 0);
+ VK_Play_Speech_Line(3, 1820, 0.5f);
+ }
+ break;
+ case 7455:
+ VK_Play_Speech_Line(3, 1780, 0.5f);
+ VK_Subject_Reacts(35, 3, 5, 0);
+ VK_Play_Speech_Line(3, 1790, 0.5f);
+ VK_Play_Speech_Line(0, 7810, 0.5f);
+ VK_Play_Speech_Line(3, 1800, 0.5f);
+ VK_Play_Speech_Line(0, 7815, 0.5f);
+ break;
+ case 7450:
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(60, 7, 7, 20);
+ VK_Play_Speech_Line(3, 1740, 0.5f);
+ VK_Play_Speech_Line(0, 7805, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(3, 1750, 0.89999998f);
+ VK_Play_Speech_Line(3, 1760, 0.5f);
+ break;
+ case 7445:
+ VK_Play_Speech_Line(3, 1710, 0.5f);
+ VK_Play_Speech_Line(0, 7800, 0.5f);
+ VK_Play_Speech_Line(3, 1720, 0.5f);
+ VK_Subject_Reacts(45, 4, 6, 0);
+ VK_Play_Speech_Line(3, 1730, 0.5f);
+ break;
+ case 7440:
+ VK_Subject_Reacts(30, 3, 5, 0);
+ VK_Play_Speech_Line(3, 1700, 0.5f);
+ break;
+ case 7435:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 1670, 0.5f);
+ VK_Subject_Reacts(60, -2, 9, 0);
+ VK_Play_Speech_Line(3, 1680, 0.5f);
+ } else {
+ VK_Subject_Reacts(60, 14, 2, 0);
+ VK_Play_Speech_Line(3, 1690, 0.5f);
+ }
+ break;
+ case 7430:
+ VK_Subject_Reacts(65, 4, 6, 10);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(3, 1660, 0.5f);
+ break;
+ case 7425:
+ VK_Subject_Reacts(40, -1, -1, 0);
+ VK_Play_Speech_Line(3, 1650, 0.5f);
+ break;
+ case 7420:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 1620, 0.5f);
+ VK_Subject_Reacts(25, -1, 9, 0);
+ } else {
+ VK_Subject_Reacts(25, 14, -2, 0);
+ VK_Play_Speech_Line(3, 1630, 0.89999998f);
+ VK_Play_Speech_Line(3, 1640, 0.5f);
+ }
+ break;
+ case 7415:
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(80, 6, 4, 10);
+ VK_Play_Speech_Line(3, 1610, 0.5f);
+ break;
+ case 7410:
+ VK_Play_Speech_Line(3, 1590, 0.5f);
+ VK_Subject_Reacts(50, 10, 10, 10);
+ VK_Play_Speech_Line(3, 1600, 0.5f);
+ break;
+ case 7405:
+ VK_Eye_Animates(3);
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 1520, 0.5f);
+ VK_Play_Speech_Line(0, 7840, 0.5f);
+ VK_Subject_Reacts(20, -1, 9, 10);
+ VK_Play_Speech_Line(3, 1540, 0.80000001f);
+ VK_Play_Speech_Line(3, 1550, 0.5f);
+ } else {
+ VK_Play_Speech_Line(3, 1560, 0.5f);
+ VK_Subject_Reacts(25, 13, -3, 0);
+ VK_Play_Speech_Line(3, 1570, 0.80000001f);
+ VK_Play_Speech_Line(3, 1580, 0.5f);
+ }
+ break;
+ case 7400:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 1490, 0.5f);
+ VK_Subject_Reacts(15, -1, 9, 0);
+ VK_Play_Speech_Line(3, 1500, 0.5f);
+ } else {
+ VK_Subject_Reacts(15, 13, -1, 0);
+ VK_Play_Speech_Line(3, 1510, 0.5f);
+ }
+ break;
+ case 7395:
+ VK_Play_Speech_Line(3, 1470, 0.5f);
+ VK_Subject_Reacts(40, 4, 4, 0);
+ VK_Play_Speech_Line(0, 7795, 0.5f);
+ VK_Play_Speech_Line(3, 1480, 0.5f);
+ break;
+ case 7390:
+ VK_Subject_Reacts(40, 2, 2, 0);
+ VK_Play_Speech_Line(3, 1450, 0.5f);
+ VK_Play_Speech_Line(0, 7785, 0.5f);
+ VK_Play_Speech_Line(3, 1460, 0.5f);
+ VK_Play_Speech_Line(0, 7790, 0.5f);
+ break;
+ case 7385:
+ VK_Subject_Reacts(36, 0, 0, 0);
+ VK_Play_Speech_Line(3, 1440, 0.5f);
+ break;
+ case 7386:
+ case 7387:
+ case 7388:
+ case 7389:
+ case 7391:
+ case 7392:
+ case 7393:
+ case 7394:
+ case 7396:
+ case 7397:
+ case 7398:
+ case 7399:
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ return;
+ default:
+ switch (a1) {
+ case 7635:
+ VK_Subject_Reacts(60, 6, 7, 0);
+ VK_Play_Speech_Line(3, 2370, 0.5f);
+ break;
+ case 7620:
+ VK_Play_Speech_Line(3, 2340, 0.5f);
+ VK_Subject_Reacts(72, 9, 9, 5);
+ VK_Play_Speech_Line(3, 2350, 0.5f);
+ VK_Play_Speech_Line(0, 7885, 0.5f);
+ VK_Play_Speech_Line(3, 2360, 0.5f);
+ break;
+ case 7605:
+ VK_Subject_Reacts(60, -1, -1, 5);
+ VK_Play_Speech_Line(3, 2320, 0.5f);
+ break;
+ case 7600:
+ VK_Play_Speech_Line(3, 2300, 0.5f);
+ VK_Subject_Reacts(30, 4, 4, 5);
+ if (!Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2310, 0.5f);
+ }
+ break;
+ case 7595:
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(3, 2290, 0.5f);
+ VK_Subject_Reacts(30, 5, 5, 8);
+ break;
+ case 7585:
+ VK_Subject_Reacts(50, 8, 8, 7);
+ VK_Play_Speech_Line(3, 2280, 0.5f);
+ break;
+ case 7580:
+ VK_Play_Speech_Line(3, 2260, 0.5f);
+ VK_Subject_Reacts(40, 5, 5, 10);
+ VK_Play_Speech_Line(3, 2270, 0.5f);
+ break;
+ case 7565:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(3, 2210, 0.5f);
+ VK_Play_Speech_Line(0, 7870, 0.5f);
+ VK_Play_Speech_Line(3, 2220, 0.5f);
+ VK_Subject_Reacts(70, 8, 7, 10);
+ VK_Play_Speech_Line(3, 2230, 0.5f);
+ VK_Play_Speech_Line(0, 7875, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(3, 2240, 0.5f);
+ VK_Play_Speech_Line(3, 2250, 0.5f);
+ break;
+ case 7550:
+ VK_Play_Speech_Line(3, 2170, 0.5f);
+ VK_Play_Speech_Line(0, 7865, 0.5f);
+ VK_Play_Speech_Line(3, 2180, 0.5f);
+ VK_Subject_Reacts(55, 6, 5, 0);
+ VK_Play_Speech_Line(3, 2190, 0.5f);
+ break;
+ case 7540:
+ VK_Eye_Animates(2);
+ if (Game_Flag_Query(47)) {
+ VK_Subject_Reacts(70, -5, 12, 80);
+ VK_Play_Speech_Line(3, 2140, 0.5f);
+ } else {
+ VK_Subject_Reacts(80, 17, -1, 80);
+ VK_Play_Speech_Line(3, 2150, 1.0f);
+ VK_Play_Speech_Line(3, 2160, 0.5f);
+ VK_Play_Speech_Line(0, 7860, 0.5f);
+ }
+ break;
+ case 7535:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2080, 0.5f);
+ VK_Play_Speech_Line(0, 7845, 0.5f);
+ VK_Play_Speech_Line(3, 2090, 0.5f);
+ VK_Subject_Reacts(60, -6, 11, 0);
+ VK_Play_Speech_Line(3, 2100, 0.5f);
+ } else {
+ VK_Subject_Reacts(60, 17, -7, 0);
+ VK_Play_Speech_Line(3, 2110, 0.5f);
+ VK_Play_Speech_Line(0, 7850, 0.5f);
+ VK_Play_Speech_Line(3, 2120, 0.5f);
+ VK_Play_Speech_Line(0, 7855, 0.5f);
+ VK_Play_Speech_Line(3, 2130, 0.5f);
+ }
+ break;
+ case 7525:
+ VK_Subject_Reacts(40, 6, 6, 0);
+ VK_Play_Speech_Line(3, 2040, 0.5f);
+ VK_Play_Speech_Line(0, 8533, 0.5f);
+ VK_Play_Speech_Line(3, 2060, 0.5f);
+ VK_Play_Speech_Line(3, 2070, 0.5f);
+ break;
+ case 7515:
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2000, 0.5f);
+ VK_Subject_Reacts(72, -3, 12, 2);
+ VK_Play_Speech_Line(3, 2010, 0.5f);
+ VK_Play_Speech_Line(0, 7835, 0.5f);
+ VK_Play_Speech_Line(3, 2020, 0.5f);
+ } else {
+ VK_Subject_Reacts(60, 16, -1, 2);
+ VK_Play_Speech_Line(3, 2030, 0.5f);
+ VK_Play_Speech_Line(0, 7840, 0.5f);
+ }
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ return;
+ default:
+ switch (a1) {
+ case 7705:
+ VK_Eye_Animates(3);
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2500, 0.5f);
+ VK_Subject_Reacts(85, 7, 14, 20);
+ VK_Play_Speech_Line(3, 2510, 0.5f);
+ } else {
+ VK_Subject_Reacts(99, 18, 7, 20);
+ VK_Play_Speech_Line(3, 2530, 0.5f);
+ VK_Play_Speech_Line(0, 7910, 0.5f);
+ VK_Play_Speech_Line(3, 2550, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(0, 7915, 0.5f);
+ }
+ break;
+ case 7690:
+ VK_Play_Speech_Line(3, 2470, 0.5f);
+ VK_Subject_Reacts(20, 9, 8, 5);
+ VK_Play_Speech_Line(3, 2480, 0.5f);
+ VK_Play_Speech_Line(0, 7900, 0.5f);
+ break;
+ case 7680:
+ VK_Eye_Animates(3);
+ if (Game_Flag_Query(47)) {
+ VK_Subject_Reacts(70, -4, 14, 15);
+ VK_Play_Speech_Line(3, 2440, 0.5f);
+ } else {
+ VK_Play_Speech_Line(3, 2450, 0.5f);
+ VK_Subject_Reacts(70, 18, -4, 15);
+ VK_Play_Speech_Line(3, 2460, 0.5f);
+ }
+ break;
+ case 7670:
+ VK_Eye_Animates(3);
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2380, 0.5f);
+ VK_Play_Speech_Line(0, 7890, 0.5f);
+ VK_Play_Speech_Line(3, 2390, 0.5f);
+ VK_Subject_Reacts(90, -3, 14, 50);
+ VK_Play_Speech_Line(0, 7895, 0.5f);
+ } else {
+ VK_Subject_Reacts(80, 18, -3, 10);
+ VK_Play_Speech_Line(3, 2410, 0.5f);
+ VK_Play_Speech_Line(0, 8534, 0.5f);
+ VK_Play_Speech_Line(3, 2430, 0.5f);
+ }
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ return;
+ default:
+ if ((unsigned int)(a1 - 7740) > 10) {
+ if (a1 == 7770) {
+ VK_Eye_Animates(2);
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2630, 0.5f);
+ VK_Subject_Reacts(99, 6, 15, 30);
+ } else {
+ VK_Play_Speech_Line(3, 2640, 0.5f);
+ VK_Subject_Reacts(99, 15, -4, 30);
+ }
+ }
+ } else if (a1 == 7740) {
+ VK_Subject_Reacts(60, 5, 6, 0);
+ VK_Play_Speech_Line(3, 2560, 0.5f);
+ } else if (a1 == 7750) {
+ if (Game_Flag_Query(47)) {
+ VK_Play_Speech_Line(3, 2580, 0.5f);
+ VK_Subject_Reacts(90, -5, 14, 20);
+ VK_Play_Speech_Line(3, 2590, 0.5f);
+ VK_Play_Speech_Line(0, 7920, 0.5f);
+ } else {
+ VK_Subject_Reacts(90, 17, 3, 20);
+ VK_Play_Speech_Line(3, 2600, 0.5f);
+ VK_Play_Speech_Line(0, 7925, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(3, 2610, 0.5f);
+ VK_Play_Speech_Line(0, 7930, 0.5f);
+ }
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+}
+
+void ScriptVK::sub_407CF8(int a1) {
+ switch (a1) {
+ case 7495:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7490:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7485:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7480:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7475:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7470:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7465:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7460:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7455:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7450:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7445:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7440:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7435:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7430:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7425:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7420:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7415:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7410:
+ VK_Subject_Reacts(100, 10, 10, 0);
+ VK_Play_Speech_Line(15, 1330, 0.5f);
+ break;
+ case 7405:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7400:
+ VK_Subject_Reacts(70, -10, -10, 0);
+ VK_Play_Speech_Line(15, 1300, 0.5f);
+ break;
+ case 7395:
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(90, -40, -10, 6);
+ VK_Play_Speech_Line(15, 1280, 0.5f);
+ break;
+ case 7390:
+ VK_Eye_Animates(3);
+ VK_Subject_Reacts(60, 15, -30, 2);
+ VK_Play_Speech_Line(15, 1260, 0.5f);
+ break;
+ case 7385:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7386:
+ case 7387:
+ case 7388:
+ case 7389:
+ case 7391:
+ case 7392:
+ case 7393:
+ case 7394:
+ case 7396:
+ case 7397:
+ case 7398:
+ case 7399:
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ return;
+ default:
+ switch (a1) {
+ case 7635:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7620:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7605:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7600:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7595:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7585:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7580:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7565:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7550:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7540:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7535:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7525:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7515:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ return;
+ default:
+ switch (a1) {
+ case 7705:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7690:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7680:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7670:
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ return;
+ default:
+ if ((unsigned int)(a1 - 7740) > 10) {
+ if (a1 == 7770) {
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ }
+ } else if (a1 == 7740) {
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ } else if (a1 == 7750) {
+ VK_Subject_Reacts(20, 10, 20, 0);
+ VK_Play_Speech_Line(15, 1240, 0.5f);
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+}
+
+void ScriptVK::sub_40897C(int a1) {
+ switch (a1) {
+ case 7495:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(14, 1320, 0.5f);
+ VK_Subject_Reacts(10, 8, 7, 7);
+ break;
+ case 7490:
+ VK_Play_Speech_Line(14, 1290, 0.5f);
+ VK_Play_Speech_Line(14, 1300, 0.5f);
+ VK_Subject_Reacts(10, 11, 10, 0);
+ VK_Play_Speech_Line(14, 1310, 0.5f);
+ break;
+ case 7485:
+ VK_Subject_Reacts(70, 8, 9, 10);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1280, 0.5f);
+ break;
+ case 7480:
+ VK_Subject_Reacts(60, 10, 8, -6);
+ VK_Play_Speech_Line(14, 1270, 0.5f);
+ break;
+ case 7475:
+ VK_Play_Speech_Line(14, 1250, 0.5f);
+ VK_Subject_Reacts(30, 9, 7, -5);
+ VK_Play_Speech_Line(14, 1260, 0.5f);
+ break;
+ case 7470:
+ VK_Subject_Reacts(50, -4, 0, -5);
+ VK_Play_Speech_Line(14, 1240, 0.5f);
+ break;
+ case 7465:
+ VK_Subject_Reacts(15, 5, 3, -5);
+ VK_Play_Speech_Line(14, 1200, 0.5f);
+ if (Actor_Query_Friendliness_To_Other(14, 0) <= 40) {
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(14, 1210, 0.5f);
+ VK_Eye_Animates(1);
+ }
+ break;
+ case 7460:
+ VK_Subject_Reacts(10, 4, 4, 2);
+ VK_Play_Speech_Line(14, 1190, 0.5f);
+ break;
+ case 7455:
+ VK_Subject_Reacts(30, 7, 6, 3);
+ VK_Play_Speech_Line(14, 1180, 0.5f);
+ break;
+ case 7450:
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(14, 1160, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(60, 8, 8, -5);
+ VK_Play_Speech_Line(14, 1170, 0.5f);
+ break;
+ case 7445:
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1140, 0.5f);
+ VK_Subject_Reacts(80, 8, 8, -10);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(14, 1150, 0.5f);
+ break;
+ case 7440:
+ VK_Subject_Reacts(30, 8, 6, 0);
+ VK_Play_Speech_Line(14, 1130, 0.5f);
+ break;
+ case 7435:
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1100, 0.5f);
+ VK_Subject_Reacts(25, 8, 5, -7);
+ VK_Play_Speech_Line(0, 8265, 0.5f);
+ VK_Play_Speech_Line(14, 1110, 0.5f);
+ VK_Play_Speech_Line(14, 1120, 0.5f);
+ break;
+ case 7430:
+ VK_Subject_Reacts(15, 7, 6, -6);
+ VK_Play_Speech_Line(14, 1080, 0.5f);
+ break;
+ case 7425:
+ VK_Play_Speech_Line(14, 1050, 0.5f);
+ VK_Play_Speech_Line(14, 1060, 0.5f);
+ VK_Play_Speech_Line(0, 8260, 0.5f);
+ VK_Subject_Reacts(5, 5, 6, -5);
+ VK_Play_Speech_Line(14, 1070, 0.5f);
+ break;
+ case 7420:
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1030, 0.5f);
+ VK_Play_Speech_Line(0, 8255, 0.5f);
+ VK_Subject_Reacts(30, 7, 5, 3);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(14, 1040, 0.5f);
+ break;
+ case 7415:
+ VK_Subject_Reacts(25, 9, 6, 5);
+ VK_Play_Speech_Line(14, 1020, 0.5f);
+ break;
+ case 7410:
+ VK_Subject_Reacts(40, -6, -5, 5);
+ VK_Play_Speech_Line(14, 990, 0.5f);
+ VK_Play_Speech_Line(0, 8245, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1000, 0.5f);
+ VK_Play_Speech_Line(0, 8250, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(70, 8, 6, 0);
+ VK_Play_Speech_Line(14, 1010, 0.5f);
+ break;
+ case 7405:
+ VK_Subject_Reacts(25, 8, 7, 4);
+ VK_Play_Speech_Line(14, 970, 0.5f);
+ VK_Play_Speech_Line(0, 8240, 0.5f);
+ VK_Play_Speech_Line(14, 980, 0.5f);
+ break;
+ case 7400:
+ VK_Play_Speech_Line(14, 950, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(10, -5, -6, 2);
+ VK_Play_Speech_Line(14, 960, 0.5f);
+ break;
+ case 7395:
+ VK_Play_Speech_Line(14, 930, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(50, 0, 0, 8);
+ VK_Play_Speech_Line(14, 940, 0.5f);
+ VK_Play_Speech_Line(0, 8235, 0.5f);
+ break;
+ case 7390:
+ VK_Subject_Reacts(48, 0, 0, 3);
+ VK_Play_Speech_Line(14, 920, 0.5f);
+ VK_Play_Speech_Line(0, 8230, 0.5f);
+ break;
+ case 7385:
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(54, 0, 0, 0);
+ VK_Play_Speech_Line(14, 900, 0.5f);
+ VK_Play_Speech_Line(14, 910, 0.5f);
+ VK_Play_Speech_Line(0, 8225, 0.5f);
+ break;
+ case 7386:
+ case 7387:
+ case 7388:
+ case 7389:
+ case 7391:
+ case 7392:
+ case 7393:
+ case 7394:
+ case 7396:
+ case 7397:
+ case 7398:
+ case 7399:
+ case 7401:
+ case 7402:
+ case 7403:
+ case 7404:
+ case 7406:
+ case 7407:
+ case 7408:
+ case 7409:
+ case 7411:
+ case 7412:
+ case 7413:
+ case 7414:
+ case 7416:
+ case 7417:
+ case 7418:
+ case 7419:
+ case 7421:
+ case 7422:
+ case 7423:
+ case 7424:
+ case 7426:
+ case 7427:
+ case 7428:
+ case 7429:
+ case 7431:
+ case 7432:
+ case 7433:
+ case 7434:
+ case 7436:
+ case 7437:
+ case 7438:
+ case 7439:
+ case 7441:
+ case 7442:
+ case 7443:
+ case 7444:
+ case 7446:
+ case 7447:
+ case 7448:
+ case 7449:
+ case 7451:
+ case 7452:
+ case 7453:
+ case 7454:
+ case 7456:
+ case 7457:
+ case 7458:
+ case 7459:
+ case 7461:
+ case 7462:
+ case 7463:
+ case 7464:
+ case 7466:
+ case 7467:
+ case 7468:
+ case 7469:
+ case 7471:
+ case 7472:
+ case 7473:
+ case 7474:
+ case 7476:
+ case 7477:
+ case 7478:
+ case 7479:
+ case 7481:
+ case 7482:
+ case 7483:
+ case 7484:
+ case 7486:
+ case 7487:
+ case 7488:
+ case 7489:
+ case 7491:
+ case 7492:
+ case 7493:
+ case 7494:
+ return;
+ default:
+ switch (a1) {
+ case 7635:
+ VK_Play_Speech_Line(14, 1580, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(0, 8310, 0.5f);
+ VK_Play_Speech_Line(0, 7645, 0.5f);
+ VK_Play_Speech_Line(0, 7650, 0.5f);
+ VK_Play_Speech_Line(0, 7655, 0.5f);
+ VK_Play_Speech_Line(0, 7660, 0.5f);
+ VK_Play_Speech_Line(0, 7665, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(60, 8, 8, 40);
+ VK_Play_Speech_Line(14, 1590, 0.5f);
+ VK_Play_Speech_Line(0, 8315, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(85, 10, 11, 0);
+ VK_Play_Speech_Line(14, 1600, 0.5f);
+ VK_Eye_Animates(3);
+ break;
+ case 7620:
+ VK_Play_Speech_Line(14, 1560, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(0, 7630, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(14, 1570, 0.5f);
+ VK_Subject_Reacts(10, 10, 9, 10);
+ break;
+ case 7605:
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(40, 9, 8, 10);
+ VK_Play_Speech_Line(14, 1550, 0.5f);
+ break;
+ case 7600:
+ VK_Subject_Reacts(20, 8, 8, 5);
+ VK_Play_Speech_Line(14, 1540, 0.5f);
+ break;
+ case 7595:
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(40, 10, 9, 15);
+ VK_Play_Speech_Line(14, 1530, 0.5f);
+ VK_Eye_Animates(2);
+ break;
+ case 7585:
+ VK_Play_Speech_Line(14, 1500, 0.5f);
+ VK_Play_Speech_Line(0, 7590, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(10, 8, 7, 5);
+ VK_Play_Speech_Line(14, 1510, 0.5f);
+ VK_Play_Speech_Line(14, 1520, 0.5f);
+ break;
+ case 7580:
+ VK_Subject_Reacts(20, 9, 7, 0);
+ VK_Play_Speech_Line(14, 1480, 0.5f);
+ VK_Play_Speech_Line(0, 8305, 0.5f);
+ VK_Play_Speech_Line(14, 1490, 0.5f);
+ break;
+ case 7565:
+ VK_Play_Speech_Line(14, 1440, 0.5f);
+ VK_Play_Speech_Line(0, 8295, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1450, 0.5f);
+ VK_Play_Speech_Line(0, 7570, 0.5f);
+ VK_Play_Speech_Line(0, 7575, 0.5f);
+ VK_Eye_Animates(3);
+ VK_Play_Speech_Line(14, 1460, 0.5f);
+ VK_Play_Speech_Line(0, 8300, 0.5f);
+ VK_Subject_Reacts(90, 8, 9, 18);
+ VK_Play_Speech_Line(14, 1470, 0.5f);
+ VK_Eye_Animates(3);
+ break;
+ case 7550:
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1420, 0.5f);
+ VK_Subject_Reacts(20, 7, 7, -5);
+ VK_Play_Speech_Line(14, 1430, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ break;
+ case 7540:
+ VK_Play_Speech_Line(14, 1400, 0.5f);
+ VK_Subject_Reacts(30, 10, 9, 10);
+ VK_Play_Speech_Line(14, 1410, 0.5f);
+ break;
+ case 7535:
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1360, 0.5f);
+ VK_Play_Speech_Line(0, 8275, 0.5f);
+ VK_Subject_Reacts(10, 9, 7, -4);
+ VK_Play_Speech_Line(0, 8280, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1380, 0.5f);
+ VK_Play_Speech_Line(14, 1390, 0.5f);
+ VK_Play_Speech_Line(0, 8285, 0.5f);
+ break;
+ case 7525:
+ VK_Play_Speech_Line(14, 1350, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(10, 7, 6, 6);
+ break;
+ case 7515:
+ VK_Subject_Reacts(25, 7, 7, 0);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1330, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1340, 0.5f);
+ break;
+ case 7516:
+ case 7517:
+ case 7518:
+ case 7519:
+ case 7520:
+ case 7521:
+ case 7522:
+ case 7523:
+ case 7524:
+ case 7526:
+ case 7527:
+ case 7528:
+ case 7529:
+ case 7530:
+ case 7531:
+ case 7532:
+ case 7533:
+ case 7534:
+ case 7536:
+ case 7537:
+ case 7538:
+ case 7539:
+ case 7541:
+ case 7542:
+ case 7543:
+ case 7544:
+ case 7545:
+ case 7546:
+ case 7547:
+ case 7548:
+ case 7549:
+ case 7551:
+ case 7552:
+ case 7553:
+ case 7554:
+ case 7555:
+ case 7556:
+ case 7557:
+ case 7558:
+ case 7559:
+ case 7560:
+ case 7561:
+ case 7562:
+ case 7563:
+ case 7564:
+ case 7566:
+ case 7567:
+ case 7568:
+ case 7569:
+ case 7570:
+ case 7571:
+ case 7572:
+ case 7573:
+ case 7574:
+ case 7575:
+ case 7576:
+ case 7577:
+ case 7578:
+ case 7579:
+ case 7581:
+ case 7582:
+ case 7583:
+ case 7584:
+ case 7586:
+ case 7587:
+ case 7588:
+ case 7589:
+ case 7590:
+ case 7591:
+ case 7592:
+ case 7593:
+ case 7594:
+ case 7596:
+ case 7597:
+ case 7598:
+ case 7599:
+ case 7601:
+ case 7602:
+ case 7603:
+ case 7604:
+ case 7606:
+ case 7607:
+ case 7608:
+ case 7609:
+ case 7610:
+ case 7611:
+ case 7612:
+ case 7613:
+ case 7614:
+ case 7615:
+ case 7616:
+ case 7617:
+ case 7618:
+ case 7619:
+ case 7621:
+ case 7622:
+ case 7623:
+ case 7624:
+ case 7625:
+ case 7626:
+ case 7627:
+ case 7628:
+ case 7629:
+ case 7630:
+ case 7631:
+ case 7632:
+ case 7633:
+ case 7634:
+ return;
+ default:
+ switch (a1) {
+ case 7705:
+ VK_Play_Speech_Line(14, 1680, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(0, 7720, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Subject_Reacts(40, 12, 10, 0);
+ VK_Play_Speech_Line(0, 7725, 0.5f);
+ VK_Play_Speech_Line(0, 7730, 0.5f);
+ VK_Subject_Reacts(55, 6, 6, 0);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(0, 7735, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(70, 11, 9, 100);
+ VK_Play_Speech_Line(14, 1690, 0.5f);
+ VK_Eye_Animates(2);
+ break;
+ case 7690:
+ VK_Eye_Animates(2);
+ VK_Subject_Reacts(50, 14, 13, 15);
+ VK_Play_Speech_Line(14, 1660, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(0, 8325, 0.5f);
+ VK_Play_Speech_Line(14, 1670, 0.5f);
+ break;
+ case 7680:
+ VK_Play_Speech_Line(14, 1640, 0.5f);
+ VK_Subject_Reacts(15, 5, 6, 5);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Play_Speech_Line(0, 8320, 0.5f);
+ VK_Play_Speech_Line(14, 1650, 0.5f);
+ break;
+ case 7670:
+ VK_Subject_Reacts(50, 12, 7, 10);
+ VK_Play_Speech_Line(14, 1620, 0.5f);
+ VK_Eye_Animates(1);
+ VK_Play_Speech_Line(14, 1630, 0.5f);
+ break;
+ case 7671:
+ case 7672:
+ case 7673:
+ case 7674:
+ case 7675:
+ case 7676:
+ case 7677:
+ case 7678:
+ case 7679:
+ case 7681:
+ case 7682:
+ case 7683:
+ case 7684:
+ case 7685:
+ case 7686:
+ case 7687:
+ case 7688:
+ case 7689:
+ case 7691:
+ case 7692:
+ case 7693:
+ case 7694:
+ case 7695:
+ case 7696:
+ case 7697:
+ case 7698:
+ case 7699:
+ case 7700:
+ case 7701:
+ case 7702:
+ case 7703:
+ case 7704:
+ return;
+ default:
+ if ((unsigned int)(a1 - 7740) > 10) {
+ if (a1 == 7770) {
+ VK_Play_Speech_Line(14, 1780, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Play_Speech_Line(0, 8335, 0.5f);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(14, 1790, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Subject_Reacts(30, 7, 7, 10);
+ }
+ } else if (a1 == 7740) {
+ VK_Subject_Reacts(30, 4, 3, 3);
+ VK_Eye_Animates(2);
+ VK_Play_Speech_Line(14, 1700, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Play_Speech_Line(14, 1710, 0.5f);
+ VK_Play_Speech_Line(14, 1720, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Play_Speech_Line(14, 1730, 0.5f);
+ } else if (a1 == 7750) {
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Subject_Reacts(10, 8, 5, 0);
+ VK_Play_Speech_Line(14, 1740, 0.5f);
+ VK_Play_Speech_Line(0, 8330, 0.5f);
+ if (Random_Query(0, 1) == 1) {
+ VK_Eye_Animates(1);
+ }
+ VK_Play_Speech_Line(14, 1750, 0.5f);
+ VK_Subject_Reacts(25, 7, 5, 8);
+ VK_Play_Speech_Line(14, 1760, 0.5f);
+ VK_Play_Speech_Line(14, 1770, 0.5f);
+ }
+ break;
+ }
+ break;
+ }
+ break;
+ }
+}
+
+void ScriptVK::sub_40A300(int a1, int a2) {
+ switch (a1) {
+ case 15:
+ sub_407CF8(7385);
+ break;
+ case 14:
+ sub_40897C(7385);
+ break;
+ case 11:
+ sub_404B44(7385);
+ break;
+ case 6:
+ sub_402604(7385);
+ break;
+ case 3:
+ sub_40A510(7385);
+ break;
+ default:
+ return;
+ }
+}
+
+void ScriptVK::sub_40A350(int a1, int a2) {
+ switch (a1) {
+ case 15:
+ sub_407CF8(7390);
+ break;
+ case 14:
+ sub_40897C(7390);
+ break;
+ case 11:
+ sub_404B44(7390);
+ break;
+ case 6:
+ sub_402604(7390);
+ break;
+ case 3:
+ sub_40A470(7390);
+ break;
+ default:
+ return;
+ }
+}
+
+void ScriptVK::sub_40A3A0(int a1, int a2) {
+ switch (a1) {
+ case 15:
+ sub_407CF8(7395);
+ break;
+ case 14:
+ sub_40897C(7395);
+ break;
+ case 11:
+ sub_404B44(7395);
+ break;
+ case 6:
+ sub_402604(7395);
+ break;
+ case 3:
+ sub_40A3F0(7395);
+ break;
+ default:
+ return;
+ }
+}
+
+void ScriptVK::sub_40A3F0(int a1) {
+ VK_Play_Speech_Line(3, 1470, 0.5f);
+ VK_Subject_Reacts(40, 4, 4, 0);
+ VK_Play_Speech_Line(0, 7795, 0.5f);
+ VK_Play_Speech_Line(3, 1480, 0.5f);
+}
+
+void ScriptVK::sub_40A470(int a1) {
+ VK_Subject_Reacts(40, 2, 2, 0);
+ VK_Play_Speech_Line(3, 1450, 0.5f);
+ VK_Play_Speech_Line(0, 7785, 0.5f);
+ VK_Play_Speech_Line(3, 1460, 0.5f);
+ VK_Play_Speech_Line(0, 7790, 0.5f);
+}
+
+void ScriptVK::sub_40A510(int a1) {
+ VK_Subject_Reacts(36, 0, 0, 0);
+ VK_Play_Speech_Line(3, 1440, 0.5f);
+}
+
+} // End of namespace BladeRunner
diff --git a/engines/bladerunner/script/vk.h b/engines/bladerunner/script/vk.h
new file mode 100644
index 0000000000..087faa88d1
--- /dev/null
+++ b/engines/bladerunner/script/vk.h
@@ -0,0 +1,65 @@
+/* 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.
+ *
+ */
+
+#ifndef BLADERUNNER_SCRIPT_KIA_H
+#define BLADERUNNER_SCRIPT_KIA_H
+
+#include "bladerunner/script/script.h"
+
+namespace BladeRunner {
+
+class BladeRunnerEngine;
+
+class ScriptVK : ScriptBase {
+public:
+ ScriptVK(BladeRunnerEngine *vm)
+ : ScriptBase(vm) {
+ }
+
+ bool SCRIPT_VK_DLL_Initialize(int a1);
+ void SCRIPT_VK_DLL_Calibrate(int a1);
+ bool SCRIPT_VK_DLL_Begin_Test();
+ void SCRIPT_VK_DLL_McCoy_Asks_Question(int a1, int a2);
+ void SCRIPT_VK_DLL_Question_Asked(int a1, int a2);
+ void SCRIPT_VK_DLL_Shutdown(int a1, signed int a2, signed int a3);
+
+private:
+ int unknown1;
+ int unknown2;
+
+ void sub_402604(int a1);
+ void sub_404B44(int a1);
+ void sub_406088(int a1);
+ void sub_407CF8(int a1);
+ void sub_40897C(int a1);
+ void sub_40A300(int a1, int a2);
+ void sub_40A350(int a1, int a2);
+ void sub_40A3A0(int a1, int a2);
+ void sub_40A3F0(int a1);
+ void sub_40A470(int a1);
+ void sub_40A510(int a1);
+};
+
+} // End of namespace BladeRunner
+
+#endif
+
diff --git a/engines/bladerunner/set.cpp b/engines/bladerunner/set.cpp
index e07a37a99c..f7db1c2f0c 100644
--- a/engines/bladerunner/set.cpp
+++ b/engines/bladerunner/set.cpp
@@ -23,7 +23,10 @@
#include "bladerunner/set.h"
#include "bladerunner/bladerunner.h"
+#include "bladerunner/lights.h"
#include "bladerunner/scene_objects.h"
+#include "bladerunner/set_effects.h"
+#include "bladerunner/slice_renderer.h"
#include "common/debug.h"
#include "common/ptr.h"
@@ -39,9 +42,12 @@ Set::Set(BladeRunnerEngine *vm) : _vm(vm) {
_walkboxCount = 0;
_objects = new Object[85];
_walkboxes = new Walkbox[95];
+ _footstepSoundOverride = -1;
+ _effects = new SetEffects(vm);
}
Set::~Set() {
+ delete _effects;
delete[] _objects;
delete[] _walkboxes;
}
@@ -53,7 +59,7 @@ bool Set::open(const Common::String &name) {
if (sig != kSet0)
return false;
- s->skip(4); // TODO: LITE length
+ int framesCount = s->readUint32LE();
_objectCount = s->readUint32LE();
assert(_objectCount <= 85);
@@ -102,7 +108,12 @@ bool Set::open(const Common::String &name) {
// debug("WALKBOX: %s", _walkboxes[i]._name);
}
- // TODO: Read LITE
+ _vm->_lights->reset();
+ _vm->_lights->read(s.get(), framesCount);
+ _vm->_sliceRenderer->setLights(_vm->_lights);
+ _effects->reset();
+ _effects->read(s.get(), framesCount);
+ _vm->_sliceRenderer->setSetEffects(_effects);
return true;
}
diff --git a/engines/bladerunner/shape.cpp b/engines/bladerunner/shape.cpp
index be4db1ecee..4f5a826872 100644
--- a/engines/bladerunner/shape.cpp
+++ b/engines/bladerunner/shape.cpp
@@ -54,7 +54,7 @@ bool Shape::readFromContainer(const Common::String &container, int index) {
return false;
}
- uint32 size, width, height;
+ uint32 size = 0, width = 0, height = 0;
for (int i = 0; i <= index; ++i) {
width = stream->readUint32LE();
height = stream->readUint32LE();
diff --git a/engines/bladerunner/slice_animations.cpp b/engines/bladerunner/slice_animations.cpp
index 7061dd975a..8497620265 100644
--- a/engines/bladerunner/slice_animations.cpp
+++ b/engines/bladerunner/slice_animations.cpp
@@ -66,10 +66,10 @@ bool SliceAnimations::open(const Common::String &name) {
_animations[i].frameCount = file.readUint32LE();
_animations[i].frameSize = file.readUint32LE();
_animations[i].fps = file.readFloatLE();
- _animations[i].unk0 = file.readFloatLE();
- _animations[i].unk1 = file.readFloatLE();
- _animations[i].unk2 = file.readFloatLE();
- _animations[i].unk3 = file.readFloatLE();
+ _animations[i].positionChange.x = file.readFloatLE();
+ _animations[i].positionChange.y = file.readFloatLE();
+ _animations[i].positionChange.z = file.readFloatLE();
+ _animations[i].facingChange = file.readFloatLE();
_animations[i].offset = file.readUint32LE();
#if 0
diff --git a/engines/bladerunner/slice_animations.h b/engines/bladerunner/slice_animations.h
index ac254d429f..dc5c88fbb1 100644
--- a/engines/bladerunner/slice_animations.h
+++ b/engines/bladerunner/slice_animations.h
@@ -27,6 +27,7 @@
#include "common/file.h"
#include "common/str.h"
#include "common/types.h"
+#include "vector.h"
namespace BladeRunner {
@@ -46,10 +47,8 @@ class SliceAnimations {
uint32 frameCount;
uint32 frameSize;
float fps;
- float unk0;
- float unk1;
- float unk2;
- float unk3;
+ Vector3 positionChange;
+ float facingChange;
uint32 offset;
};
diff --git a/engines/bladerunner/slice_renderer.cpp b/engines/bladerunner/slice_renderer.cpp
index 581bed2e22..6bce572064 100644
--- a/engines/bladerunner/slice_renderer.cpp
+++ b/engines/bladerunner/slice_renderer.cpp
@@ -343,6 +343,9 @@ void setupLookupTable(int t[256], int inc) {
void SliceRenderer::drawFrame(Graphics::Surface &surface, uint16 *zbuffer) {
assert(_sliceFramePtr);
+ assert(_lights);
+ assert(_setEffects);
+ //assert(_view);
SliceLineIterator sliceLineIterator;
sliceLineIterator.setup(
@@ -352,6 +355,9 @@ void SliceRenderer::drawFrame(Graphics::Surface &surface, uint16 *zbuffer) {
_field_109E // 3x2 matrix
);
+ _lights->setupFrame(_view._frame);
+ _setEffects->setupFrame(_view._frame);
+
setupLookupTable(_t1, sliceLineIterator._field_00[0][0]);
setupLookupTable(_t2, sliceLineIterator._field_00[0][1]);
setupLookupTable(_t4, sliceLineIterator._field_00[1][0]);
@@ -433,7 +439,7 @@ void SliceRenderer::preload(int animationId) {
_vm->_sliceAnimations->getFramePtr(animationId, i);
}
-void SliceRenderer::disableShadows(int* animationsIdsList, int listSize) {
+void SliceRenderer::disableShadows(int animationsIdsList[], int listSize) {
int i;
for (i = 0; i < listSize; i++) {
_animationsShadowEnabled[animationsIdsList[i]] = false;
diff --git a/engines/bladerunner/vqa_decoder.cpp b/engines/bladerunner/vqa_decoder.cpp
index 06036e737c..df1b4f4641 100644
--- a/engines/bladerunner/vqa_decoder.cpp
+++ b/engines/bladerunner/vqa_decoder.cpp
@@ -25,11 +25,16 @@
#include "bladerunner/bladerunner.h"
#include "bladerunner/decompress_lcw.h"
#include "bladerunner/decompress_lzo.h"
+#include "bladerunner/lights.h"
+#include "bladerunner/view.h"
#include "audio/decoders/raw.h"
#include "common/array.h"
#include "common/util.h"
+#include "common/memstream.h"
+
+
namespace BladeRunner {
@@ -204,6 +209,16 @@ Audio::SeekableAudioStream *VQADecoder::decodeAudioFrame() {
return _audioTrack->decodeAudioFrame();
}
+void VQADecoder::decodeView(View* view)
+{
+ _videoTrack->decodeView(view);
+}
+
+void VQADecoder::decodeLights(Lights *lights)
+{
+ _videoTrack->decodeLights(lights);
+}
+
void VQADecoder::readNextPacket() {
IFFChunkHeader chd;
@@ -582,6 +597,9 @@ VQADecoder::VQAVideoTrack::VQAVideoTrack(VQADecoder *vqaDecoder) {
_surface = new Graphics::Surface();
_surface->create(_width, _height, createRGB555());
+
+ _viewData = nullptr;
+ _lightsData = nullptr;
}
VQADecoder::VQAVideoTrack::~VQAVideoTrack() {
@@ -594,6 +612,11 @@ VQADecoder::VQAVideoTrack::~VQAVideoTrack() {
_surface->free();
delete _surface;
delete[] _zbuffer;
+
+ if (_viewData)
+ delete[] _viewData;
+ if (_lightsData)
+ delete[] _lightsData;
}
uint16 VQADecoder::VQAVideoTrack::getWidth() const {
@@ -770,23 +793,66 @@ bool VQADecoder::VQAVideoTrack::readVIEW(Common::SeekableReadStream *s, uint32 s
if (size != 56)
return false;
- _view.read(s);
+ if (_viewData) {
+ delete[] _viewData;
+ _viewData = nullptr;
+ }
+
+ _viewDataSize = size;
+ _viewData = new uint8[_viewDataSize];
+ s->read(_viewData, _viewDataSize);
return true;
}
+void VQADecoder::VQAVideoTrack::decodeView(View* view)
+{
+ if (!view || !_viewData)
+ return;
+
+ Common::MemoryReadStream s(_viewData, _viewDataSize);
+ view->read(&s);
+
+ delete[] _viewData;
+ _viewData = nullptr;
+}
+
bool VQADecoder::VQAVideoTrack::readAESC(Common::SeekableReadStream *s, uint32 size)
{
+ debug("VQADecoder::readAESC(%d)", size);
+
s->skip(roundup(size));
return true;
}
bool VQADecoder::VQAVideoTrack::readLITE(Common::SeekableReadStream *s, uint32 size)
{
- s->skip(roundup(size));
+ if (_lightsData) {
+ delete[] _lightsData;
+ _lightsData = nullptr;
+ }
+
+ _lightsDataSize = size;
+ _lightsData = new uint8[_lightsDataSize];
+ s->read(_lightsData, _lightsDataSize);
+
return true;
}
+
+void VQADecoder::VQAVideoTrack::decodeLights(Lights *lights)
+{
+ if (!lights || !_lightsData)
+ return;
+
+ Common::MemoryReadStream s(_lightsData, _lightsDataSize);
+ lights->readVqa(&s);
+
+ delete[] _lightsData;
+ _lightsData = nullptr;
+}
+
+
bool VQADecoder::VQAVideoTrack::readVPTR(Common::SeekableReadStream *s, uint32 size)
{
if (size > _maxVPTRSize)
diff --git a/engines/bladerunner/vqa_decoder.h b/engines/bladerunner/vqa_decoder.h
index fecc14db9b..eb486c8413 100644
--- a/engines/bladerunner/vqa_decoder.h
+++ b/engines/bladerunner/vqa_decoder.h
@@ -24,7 +24,6 @@
#define BLADERUNNER_VQA_DECODER_H
#include "bladerunner/adpcm_decoder.h"
-#include "bladerunner/view.h"
#include "audio/audiostream.h"
@@ -39,6 +38,9 @@
namespace BladeRunner {
+class Lights;
+class View;
+
class VQADecoder
{
public:
@@ -53,8 +55,8 @@ public:
const Graphics::Surface *decodeVideoFrame();
const uint16 *decodeZBuffer();
Audio::SeekableAudioStream *decodeAudioFrame();
-
- const View &getView() { return _videoTrack->getView(); }
+ void decodeView(View *view);
+ void decodeLights(Lights *lights);
uint16 numFrames() const { return _header.numFrames; }
uint8 frameRate() const { return _header.frameRate; }
@@ -166,7 +168,8 @@ private:
int getFrameCount() const;
const Graphics::Surface *decodeVideoFrame();
const uint16 *decodeZBuffer();
- const View &getView() { return _view; }
+ void decodeView(View *view);
+ void decodeLights(Lights *lights);
bool readVQFR(Common::SeekableReadStream *s, uint32 size);
bool readVPTR(Common::SeekableReadStream *s, uint32 size);
@@ -210,7 +213,10 @@ private:
int _curFrame;
- View _view;
+ uint8 *_viewData;
+ uint32 _viewDataSize;
+ uint8 *_lightsData;
+ uint32 _lightsDataSize;
void VPTRWriteBlock(uint16 *frame, unsigned int dstBlock, unsigned int srcBlock, int count, bool alpha = false);
bool decodeFrame(uint16 *frame);
diff --git a/engines/bladerunner/vqa_player.cpp b/engines/bladerunner/vqa_player.cpp
index d7b53ff94c..2c408066fd 100644
--- a/engines/bladerunner/vqa_player.cpp
+++ b/engines/bladerunner/vqa_player.cpp
@@ -65,7 +65,7 @@ int VQAPlayer::update() {
queueAudioFrame(_decoder.decodeAudioFrame());
_surface = _decoder.decodeVideoFrame();
_zBuffer = _decoder.decodeZBuffer();
- _view = _decoder.getView();
+ //_view = _decoder.getView();
}
_decodedFrame = calcNextFrame(_curFrame);
@@ -89,7 +89,7 @@ int VQAPlayer::update() {
if (_curFrame >= 0) {
_surface = _decoder.decodeVideoFrame();
_zBuffer = _decoder.decodeZBuffer();
- _view = _decoder.getView();
+ //_view = _decoder.getView();
}
_decodedFrame = calcNextFrame(_curFrame);
@@ -115,6 +115,16 @@ const uint16 *VQAPlayer::getZBuffer() const {
return _zBuffer;
}
+void VQAPlayer::updateView(View* view)
+{
+ _decoder.decodeView(view);
+}
+
+void VQAPlayer::updateLights(Lights* lights)
+{
+ _decoder.decodeLights(lights);
+}
+
bool VQAPlayer::setLoop(int loop) {
int begin, end;
if (!_decoder.getLoopBeginAndEndFrame(loop, &begin, &end)) {
diff --git a/engines/bladerunner/vqa_player.h b/engines/bladerunner/vqa_player.h
index cc29832ee2..0acbb35ee4 100644
--- a/engines/bladerunner/vqa_player.h
+++ b/engines/bladerunner/vqa_player.h
@@ -33,6 +33,8 @@
namespace BladeRunner {
class BladeRunnerEngine;
+class View;
+class Lights;
class VQAPlayer {
BladeRunnerEngine *_vm;
@@ -48,8 +50,6 @@ class VQAPlayer {
int _loopBegin;
int _loopEnd;
- View _view;
-
uint32 _nextFrameTime;
bool _hasAudio;
bool _audioStarted;
@@ -82,7 +82,8 @@ public:
int update();
const Graphics::Surface *getSurface() const;
const uint16 *getZBuffer() const;
- const View &getView() const { return _view; }
+ void updateView(View *view);
+ void updateLights(Lights *lights);
bool setLoop(int loop);
// void setLoopSpecial(int loop, bool wait);