Initial commit
This commit is contained in:
131
engines/m4/riddle/rooms/section9/room901.cpp
Normal file
131
engines/m4/riddle/rooms/section9/room901.cpp
Normal file
@@ -0,0 +1,131 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "common/config-manager.h"
|
||||
#include "m4/riddle/rooms/section9/room901.h"
|
||||
#include "m4/riddle/hotkeys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room901::preload() {
|
||||
if (_G(game).room_id == 494)
|
||||
digi_preload("wind", 901);
|
||||
|
||||
_G(player).walker_type = 1;
|
||||
_G(player).shadow_type = 1;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room901::init() {
|
||||
// WORKAROUND: Original created a dummy file called believe.it
|
||||
// on first run with "Never forget the llama and the spleen."
|
||||
// For ScummVM, I've instead used a simple config manager flag
|
||||
|
||||
if (!ConfMan.getBool("believe_it")) {
|
||||
ConfMan.setBool("believe_it", true);
|
||||
|
||||
_G(game).previous_room = 494;
|
||||
digi_preload("wind", 901);
|
||||
_G(flags)[V001] = 1;
|
||||
}
|
||||
|
||||
mouse_hide();
|
||||
player_set_commands_allowed(false);
|
||||
|
||||
if (_G(game).previous_room == 494) {
|
||||
digi_play_loop("wind", 1, 255, -1, 901);
|
||||
kernel_timing_trigger(1, 10);
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
} else {
|
||||
kernel_timing_trigger(1, 5);
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
}
|
||||
}
|
||||
|
||||
void Room901::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 5:
|
||||
kernel_timing_trigger(300, 6);
|
||||
break;
|
||||
|
||||
case 6:
|
||||
disable_player_commands_and_fade_init(7);
|
||||
break;
|
||||
|
||||
case 7:
|
||||
case 56:
|
||||
AddSystemHotkey(KEY_ESCAPE, Hotkeys::escape_key_pressed);
|
||||
AddSystemHotkey(KEY_F2, Hotkeys::saveGame);
|
||||
AddSystemHotkey(KEY_F3, Hotkeys::loadGame);
|
||||
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 10:
|
||||
kernel_timing_trigger(300, 20);
|
||||
break;
|
||||
|
||||
case 20:
|
||||
digi_play_loop("wind", 2, 255, -1, 901);
|
||||
kernel_timing_trigger(100, 21);
|
||||
disable_player_commands_and_fade_init(30);
|
||||
break;
|
||||
|
||||
case 21:
|
||||
digi_stop(1);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(902);
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
bool mouseReleased = false;
|
||||
if (_G(MouseState).ButtonState) {
|
||||
_btnPressed = true;
|
||||
} else if (_btnPressed) {
|
||||
_btnPressed = false;
|
||||
mouseReleased = true;
|
||||
}
|
||||
|
||||
if (mouseReleased)
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
48
engines/m4/riddle/rooms/section9/room901.h
Normal file
48
engines/m4/riddle/rooms/section9/room901.h
Normal file
@@ -0,0 +1,48 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM901_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM901_H
|
||||
|
||||
#include "m4/riddle/rooms/section9/section9_room.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room901 : public Section9Room {
|
||||
private:
|
||||
bool _btnPressed = false;
|
||||
|
||||
public:
|
||||
Room901() : Section9Room() {}
|
||||
~Room901() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
131
engines/m4/riddle/rooms/section9/room902.cpp
Normal file
131
engines/m4/riddle/rooms/section9/room902.cpp
Normal file
@@ -0,0 +1,131 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room902.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room902::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room902::init() {
|
||||
player_set_commands_allowed(false);
|
||||
digi_preload("gunshot1", 902);
|
||||
digi_preload("gunshot2", 902);
|
||||
digi_preload("introcu-", 901);
|
||||
digi_play("introcu-", 1, 255, -1, 901);
|
||||
series_load("902 one frame hold");
|
||||
kernel_timing_trigger(1, 1);
|
||||
interface_hide();
|
||||
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
}
|
||||
|
||||
void Room902::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 1:
|
||||
kernel_timing_trigger(120, 2);
|
||||
kernel_timing_trigger(100, 789);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
series_ranged_play("902 TITLE", 1, 0, 0, 9, 100, 0xa00, 5, 3, 0);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
_title = series_ranged_play("902 TITLE", -1, 0, 9, 9, 100, 0xa00, 500, -1, 0);
|
||||
kernel_timing_trigger(180, 4);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
terminateMachineAndNull(_title);
|
||||
series_ranged_play("902 TITLE", 1, 2, 0, 9, 100, 0xa00, 5, 5, 0);
|
||||
break;
|
||||
|
||||
case 5:
|
||||
kernel_timing_trigger(120, 6);
|
||||
break;
|
||||
|
||||
case 6:
|
||||
_everything = series_stream("EVERYTHING MINUS TITLE FADE", 6, 0x100, 131);
|
||||
series_stream_break_on_frame(_everything, 121, 101);
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 101:
|
||||
digi_play("gunshot1", 3);
|
||||
series_stream_break_on_frame(_everything, 144, 102);
|
||||
break;
|
||||
|
||||
case 102:
|
||||
digi_play("gunshot2", 3, 255, -1, 902);
|
||||
break;
|
||||
|
||||
case 131:
|
||||
series_plain_play("902 one frame hold", -1, 0, 100, 256, 3000);
|
||||
disable_player_commands_and_fade_init(132);
|
||||
break;
|
||||
|
||||
case 132:
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(903);
|
||||
break;
|
||||
|
||||
case 789:
|
||||
digi_stop(2);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
bool flag = false;
|
||||
if (_G(MouseState).ButtonState) {
|
||||
_buttonDown = true;
|
||||
} else if (_buttonDown) {
|
||||
_buttonDown = false;
|
||||
flag = true;
|
||||
}
|
||||
|
||||
if (flag)
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
50
engines/m4/riddle/rooms/section9/room902.h
Normal file
50
engines/m4/riddle/rooms/section9/room902.h
Normal file
@@ -0,0 +1,50 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM902_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM902_H
|
||||
|
||||
#include "m4/riddle/rooms/section9/section9_room.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room902 : public Section9Room {
|
||||
private:
|
||||
machine *_title = nullptr;
|
||||
machine *_everything = nullptr;
|
||||
bool _buttonDown = false;
|
||||
|
||||
public:
|
||||
Room902() : Section9Room() {}
|
||||
~Room902() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
122
engines/m4/riddle/rooms/section9/room903.cpp
Normal file
122
engines/m4/riddle/rooms/section9/room903.cpp
Normal file
@@ -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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/m4.h"
|
||||
#include "m4/riddle/rooms/section9/room903.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room903::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room903::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
|
||||
void Room903::init() {
|
||||
player_set_commands_allowed(false);
|
||||
digi_preload("INTMOAN", 901);
|
||||
digi_preload("ricochet", 902);
|
||||
series_load("903 hold frame");
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
kernel_timing_trigger(150, 100, nullptr);
|
||||
}
|
||||
|
||||
void Room903::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 10:
|
||||
kernel_timing_trigger(300, 20, nullptr);
|
||||
break;
|
||||
|
||||
case 20:
|
||||
case 201:
|
||||
disable_player_commands_and_fade_init(30);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
digi_stop(3);
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(905);
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 100:
|
||||
_roomStates_field4 = series_stream("EVERYTHING IN 903", 6, 2560, 200);
|
||||
series_stream_break_on_frame(_roomStates_field4, 59, 102);
|
||||
break;
|
||||
|
||||
case 102:
|
||||
digi_play("gunshot2", 3, 255, -1, 902);
|
||||
series_stream_break_on_frame(_roomStates_field4, 63, 104);
|
||||
break;
|
||||
|
||||
case 104:
|
||||
digi_play("ricochet", 2, 255, -1, 902);
|
||||
series_stream_break_on_frame(_roomStates_field4, 292, 106);
|
||||
break;
|
||||
|
||||
case 106:
|
||||
digi_play("INTMOAN", 2, 255, -1, 901);
|
||||
break;
|
||||
|
||||
case 200:
|
||||
digi_unload("introcu-");
|
||||
digi_unload("gunshot1");
|
||||
digi_unload("gunshot2");
|
||||
digi_unload("ricochet");
|
||||
series_plain_play("903 hold frame", -1, 0, 100, 256, 3000, -1, false);
|
||||
kernel_timing_trigger(120, 201, nullptr);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (_G(MouseState).ButtonState)
|
||||
_buttonDown = true;
|
||||
else if (_buttonDown) {
|
||||
_buttonDown = false;
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
50
engines/m4/riddle/rooms/section9/room903.h
Normal file
50
engines/m4/riddle/rooms/section9/room903.h
Normal file
@@ -0,0 +1,50 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM903_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM903_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room903 : public Room {
|
||||
public:
|
||||
Room903() : Room() {}
|
||||
~Room903() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
machine *_roomStates_field4 = nullptr;
|
||||
bool _buttonDown = false;
|
||||
static void escapePressed(void *, void *);
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
115
engines/m4/riddle/rooms/section9/room905.cpp
Normal file
115
engines/m4/riddle/rooms/section9/room905.cpp
Normal file
@@ -0,0 +1,115 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/m4.h"
|
||||
#include "m4/riddle/rooms/section9/room905.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room905::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room905::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
|
||||
void Room905::init() {
|
||||
_roomStates_field4 = -1;
|
||||
warning("Room 905 - large STUB in init");
|
||||
series_load("905 hold frame", -1, nullptr);
|
||||
g_engine->adv_camera_pan_step(3);
|
||||
player_set_commands_allowed(false);
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
_roomStates_tt = series_stream("RIP EATS SAND WITH HIS ANUS", 5, 2560, 666);
|
||||
series_stream_break_on_frame(_roomStates_tt, 50, 3);
|
||||
}
|
||||
|
||||
void Room905::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 3:
|
||||
g_engine->camera_shift_xy(0, 0);
|
||||
kernel_timing_trigger(120, 4, nullptr);
|
||||
digi_play("INTMOAN", 1, 255, -1, 901);
|
||||
kernel_timing_trigger(60, 100, nullptr);
|
||||
break;
|
||||
|
||||
case 4:
|
||||
if (g_engine->game_camera_panning())
|
||||
kernel_timing_trigger(120, 4, nullptr);
|
||||
else
|
||||
kernel_timing_trigger(150, 20, nullptr);
|
||||
break;
|
||||
|
||||
case 20:
|
||||
disable_player_commands_and_fade_init(30);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
_roomStates_field4 -= 3;
|
||||
if (_roomStates_field4 <= 40) {
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(906);
|
||||
} else {
|
||||
digi_change_panning(1, _roomStates_field4);
|
||||
kernel_timing_trigger(2, 30, nullptr);
|
||||
}
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 666:
|
||||
series_plain_play("905 hold frame", -1, 0, 100, 256, 3000);
|
||||
break;
|
||||
|
||||
case 1000:
|
||||
digi_stop(2);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
void Room905::shutdown() {
|
||||
warning("STUB - Room905::shutdown");
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
53
engines/m4/riddle/rooms/section9/room905.h
Normal file
53
engines/m4/riddle/rooms/section9/room905.h
Normal file
@@ -0,0 +1,53 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM905_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM905_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room905 : public Room {
|
||||
public:
|
||||
Room905() : Room() {}
|
||||
~Room905() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
void shutdown() override;
|
||||
|
||||
|
||||
private:
|
||||
int _roomStates_field4 = -1;
|
||||
static void escapePressed(void *, void *);
|
||||
machine *_roomStates_tt = nullptr;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
108
engines/m4/riddle/rooms/section9/room906.cpp
Normal file
108
engines/m4/riddle/rooms/section9/room906.cpp
Normal file
@@ -0,0 +1,108 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room906.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room906::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room906::init() {
|
||||
_roomStates_pu = 40;
|
||||
player_set_commands_allowed(false);
|
||||
series_load("hold frame 906", -1, nullptr);
|
||||
interface_hide();
|
||||
digi_preload("906r01", -1);
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
_roomStates_field4 = series_stream("EVERYTHING IN 906", 6, 2560, 200);
|
||||
series_stream_break_on_frame(_roomStates_field4, 0, 2);
|
||||
}
|
||||
|
||||
void Room906::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 2:
|
||||
series_stream_break_on_frame(_roomStates_field4, 10, 15);
|
||||
break;
|
||||
|
||||
case 15:
|
||||
digi_play("906r01", 2, 225, -1, -1);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
_roomStates_pu -= 3;
|
||||
if (_roomStates_pu <= 0) {
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(907);
|
||||
} else {
|
||||
digi_change_panning(1, _roomStates_pu);
|
||||
kernel_timing_trigger(2, 30, nullptr);
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 200:
|
||||
series_plain_play("hold frame 906", -1, 0, 100, 256, 3000, -1, false);
|
||||
kernel_timing_trigger(120, 201, nullptr);
|
||||
break;
|
||||
|
||||
case 201:
|
||||
disable_player_commands_and_fade_init(30);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (_G(MouseState).ButtonState)
|
||||
_buttonDown = true;
|
||||
else if (_buttonDown) {
|
||||
_buttonDown = false;
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
}
|
||||
|
||||
void Room906::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
52
engines/m4/riddle/rooms/section9/room906.h
Normal file
52
engines/m4/riddle/rooms/section9/room906.h
Normal file
@@ -0,0 +1,52 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM906_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM906_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room906 : public Room {
|
||||
public:
|
||||
Room906() : Room() {}
|
||||
~Room906() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
static void escapePressed(void *, void *);
|
||||
int _roomStates_pu = -1;
|
||||
machine *_roomStates_field4 = nullptr;
|
||||
bool _buttonDown = false;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
114
engines/m4/riddle/rooms/section9/room907.cpp
Normal file
114
engines/m4/riddle/rooms/section9/room907.cpp
Normal file
@@ -0,0 +1,114 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room907.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room907::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room907::init() {
|
||||
player_set_commands_allowed(false);
|
||||
digi_preload("950_s11", 950);
|
||||
digi_preload("907r01", -1);
|
||||
|
||||
|
||||
_roomStates_tt = series_stream("zep flies low over sea", 6, 2560, -1);
|
||||
series_stream_break_on_frame(_roomStates_tt, 8, 1);
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
kernel_timing_trigger(10, 8, nullptr);
|
||||
}
|
||||
|
||||
void Room907::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 1:
|
||||
series_stream_break_on_frame(_roomStates_tt, 70, 30);
|
||||
kernel_timing_trigger(60, 29, nullptr);
|
||||
break;
|
||||
|
||||
case 8:
|
||||
digi_stop(1);
|
||||
digi_unload("INTMOAN");
|
||||
digi_play("950_s11", 2, 255, -1, -1);
|
||||
kernel_timing_trigger(120, 10, nullptr);
|
||||
break;
|
||||
|
||||
case 10:
|
||||
digi_stop(1);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
kernel_timing_trigger(60, 31, nullptr);
|
||||
break;
|
||||
|
||||
case 31:
|
||||
disable_player_commands_and_fade_init(40);
|
||||
break;
|
||||
|
||||
case 29:
|
||||
digi_play("907r01", 3, 255, 30, -1);
|
||||
break;
|
||||
|
||||
case 40:
|
||||
adv_kill_digi_between_rooms(false);
|
||||
_G(game).setRoom(908);
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (_G(MouseState).ButtonState)
|
||||
_buttonDown = true;
|
||||
else if (_buttonDown) {
|
||||
_buttonDown = false;
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
}
|
||||
|
||||
void Room907::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
51
engines/m4/riddle/rooms/section9/room907.h
Normal file
51
engines/m4/riddle/rooms/section9/room907.h
Normal file
@@ -0,0 +1,51 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM907_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM907_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room907 : public Room {
|
||||
public:
|
||||
Room907() : Room() {}
|
||||
~Room907() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
static void escapePressed(void *, void *);
|
||||
machine * _roomStates_tt = nullptr;
|
||||
bool _buttonDown = false;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
251
engines/m4/riddle/rooms/section9/room908.cpp
Normal file
251
engines/m4/riddle/rooms/section9/room908.cpp
Normal file
@@ -0,0 +1,251 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room908.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/gui/gui_sys.h"
|
||||
#include "m4/platform/keys.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room908::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room908::init() {
|
||||
player_set_commands_allowed(false);
|
||||
digi_preload("950_s12", 950);
|
||||
digi_preload("908m01", 908);
|
||||
digi_preload("908m01a", 908);
|
||||
digi_preload("908m01b", 908);
|
||||
digi_preload("908r01", 908);
|
||||
digi_preload("908r01a", 908);
|
||||
digi_preload("908r01b", 908);
|
||||
digi_preload("908m02", 908);
|
||||
digi_preload("908r02", 908);
|
||||
digi_preload("908m03", 908);
|
||||
digi_preload("908m04", 908);
|
||||
digi_preload("908r03", 908);
|
||||
digi_preload("908r03a", 908);
|
||||
digi_preload("908m05", 908);
|
||||
digi_preload("908m05a", 908);
|
||||
digi_preload("909m01", 909);
|
||||
digi_preload("910m01", 910);
|
||||
digi_preload("911s01", 911);
|
||||
digi_preload("911k01", 911);
|
||||
digi_preload("912k01", 912);
|
||||
digi_preload("912s01", 912);
|
||||
digi_preload("950_s13", 950);
|
||||
_roomStates_field8 = series_load("Hold frame 908", -1, nullptr);
|
||||
interface_hide();
|
||||
AddSystemHotkey(KEY_ESCAPE, escapePressed);
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
_roomStates_field4 = series_stream("conversation half frames", 8, 256, 10);
|
||||
series_stream_break_on_frame(_roomStates_field4, 1, 71);
|
||||
kernel_timing_trigger(60, 200, nullptr);
|
||||
}
|
||||
|
||||
void Room908::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 10:
|
||||
_roomStates_field4 = series_place_sprite("Hold frame 908", 0, 0, 0, 100, 0);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
digi_stop(1);
|
||||
digi_stop(2);
|
||||
digi_stop(3);
|
||||
_G(game).setRoom(352);
|
||||
break;
|
||||
|
||||
case 55:
|
||||
_G(game).setRoom(304);
|
||||
break;
|
||||
|
||||
case 56:
|
||||
_G(game).setRoom(494);
|
||||
break;
|
||||
|
||||
case 71:
|
||||
series_stream_break_on_frame(_roomStates_field4, 15, 72);
|
||||
digi_play("908m01", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 72:
|
||||
series_stream_break_on_frame(_roomStates_field4, 40, 73);
|
||||
digi_play("908m01a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 73:
|
||||
series_stream_break_on_frame(_roomStates_field4, 51, 74);
|
||||
digi_play("908m01b", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 74:
|
||||
series_stream_break_on_frame(_roomStates_field4, 59, 75);
|
||||
series_set_frame_rate(_roomStates_field4, 9);
|
||||
digi_play("908r01", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 75:
|
||||
series_stream_break_on_frame(_roomStates_field4, 66, 76);
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
digi_play("908r01a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 76:
|
||||
series_stream_break_on_frame(_roomStates_field4, 82, 77);
|
||||
series_set_frame_rate(_roomStates_field4, 10);
|
||||
digi_play("908r01b", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 77:
|
||||
series_stream_break_on_frame(_roomStates_field4, 95, 78);
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
digi_play("908m02", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 78:
|
||||
series_stream_break_on_frame(_roomStates_field4, 121, 79);
|
||||
series_set_frame_rate(_roomStates_field4, 9);
|
||||
digi_play("908r02", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 79:
|
||||
series_stream_break_on_frame(_roomStates_field4, 138, 80);
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
digi_play("908m03", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 80:
|
||||
series_stream_break_on_frame(_roomStates_field4, 158, 82);
|
||||
series_set_frame_rate(_roomStates_field4, 9);
|
||||
digi_play("908m04", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 82:
|
||||
series_stream_break_on_frame(_roomStates_field4, 175, 83);
|
||||
series_set_frame_rate(_roomStates_field4, 10);
|
||||
digi_play("908r03", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 83:
|
||||
series_stream_break_on_frame(_roomStates_field4, 192, 84);
|
||||
series_set_frame_rate(_roomStates_field4, 9);
|
||||
digi_play("908r03a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 84:
|
||||
series_stream_break_on_frame(_roomStates_field4, 200, 85);
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
digi_play("908m05", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 85:
|
||||
series_stream_break_on_frame(_roomStates_field4, 233, 86);
|
||||
series_set_frame_rate(_roomStates_field4, 9);
|
||||
digi_play("908m05a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 86:
|
||||
series_stream_break_on_frame(_roomStates_field4, 250, 87);
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
digi_play("909m01", 2, 255, -1, 909);
|
||||
break;
|
||||
|
||||
case 87:
|
||||
digi_play("910m01", 2, 255, -1, 910);
|
||||
series_stream_break_on_frame(_roomStates_field4, 251, 88);
|
||||
break;
|
||||
|
||||
case 88:
|
||||
series_set_frame_rate(_roomStates_field4, 85);
|
||||
series_stream_break_on_frame(_roomStates_field4, 252, 89);
|
||||
break;
|
||||
|
||||
case 89:
|
||||
series_set_frame_rate(_roomStates_field4, 8);
|
||||
series_stream_break_on_frame(_roomStates_field4, 259, 91);
|
||||
break;
|
||||
|
||||
case 91:
|
||||
series_stream_break_on_frame(_roomStates_field4, 278, 92);
|
||||
digi_play("950_s13", 1, 255, -1, 950);
|
||||
break;
|
||||
|
||||
case 92:
|
||||
series_stream_break_on_frame(_roomStates_field4, 295, 93);
|
||||
digi_play("911s01", 2, 255, -1, 911);
|
||||
break;
|
||||
|
||||
case 93:
|
||||
series_stream_break_on_frame(_roomStates_field4, 318, 94);
|
||||
digi_play("911k01", 2, 255, -1, 911);
|
||||
break;
|
||||
|
||||
case 94:
|
||||
series_stream_break_on_frame(_roomStates_field4, 339, -1);
|
||||
series_set_frame_rate(_roomStates_field4, 10);
|
||||
digi_play("912k01", 2, 255, 95, 912);
|
||||
break;
|
||||
|
||||
case 95:
|
||||
digi_play("912s01", 2, 255, 96, 912);
|
||||
break;
|
||||
|
||||
case 96:
|
||||
disable_player_commands_and_fade_init(30);
|
||||
break;
|
||||
|
||||
case 200:
|
||||
digi_stop(2);
|
||||
digi_play_loop("950_s12", 1, 255, -1, 950);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (_G(MouseState).ButtonState)
|
||||
_buttonDown = true;
|
||||
else if (_buttonDown) {
|
||||
_buttonDown = false;
|
||||
disable_player_commands_and_fade_init(55);
|
||||
}
|
||||
}
|
||||
|
||||
void Room908::parser() {
|
||||
if (player_said("TSA", nullptr, nullptr))
|
||||
_G(player).command_ready = false;
|
||||
}
|
||||
|
||||
void Room908::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
53
engines/m4/riddle/rooms/section9/room908.h
Normal file
53
engines/m4/riddle/rooms/section9/room908.h
Normal file
@@ -0,0 +1,53 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM908_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM908_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room908 : public Room {
|
||||
public:
|
||||
Room908() : Room() {}
|
||||
~Room908() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
void parser() override;
|
||||
|
||||
private:
|
||||
machine * _roomStates_field4 = nullptr;
|
||||
int32 _roomStates_field8 = -1;
|
||||
bool _buttonDown = false;
|
||||
static void escapePressed(void *, void *);
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
165
engines/m4/riddle/rooms/section9/room917.cpp
Normal file
165
engines/m4/riddle/rooms/section9/room917.cpp
Normal file
@@ -0,0 +1,165 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room917.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room917::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room917::init() {
|
||||
player_set_commands_allowed(false);
|
||||
adv_kill_digi_between_rooms(false);
|
||||
if (_G(flags)[V291] != 1) {
|
||||
digi_preload("950_s47", 950);
|
||||
digi_preload("907r02", 950);
|
||||
_roomStates_tt = series_stream("917zep01", 12, 256, -1);
|
||||
kernel_timing_trigger(180, 1, nullptr);
|
||||
digi_play_loop("950_s47", 3, 70, -1, 950);
|
||||
} else {
|
||||
digi_preload("908f01", 908);
|
||||
digi_preload("908w01", 908);
|
||||
digi_preload("908d01", 908);
|
||||
digi_preload("riptheme", 917);
|
||||
digi_preload("950_s48", 950);
|
||||
digi_preload("950_s48a", 950);
|
||||
digi_preload("950_s48b", 950);
|
||||
digi_preload("950_s48c", 950);
|
||||
digi_preload("950_s50", 950);
|
||||
_roomStates_tt = series_stream("917zep02", 10, 256, -1);
|
||||
series_stream_break_on_frame(_roomStates_tt, 1, 31);
|
||||
digi_play("950_s50", 3, 180, 50, -1);
|
||||
}
|
||||
interface_hide();
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
}
|
||||
|
||||
void Room917::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
case 1:
|
||||
digi_play("907r02", 2, 255, 3, 907);
|
||||
kernel_timing_trigger(180, 2, nullptr);
|
||||
break;
|
||||
|
||||
case 2:
|
||||
pal_fade_init(&_G(master_palette)[0], 0, 255, 0, 90, -1);
|
||||
break;
|
||||
|
||||
case 3:
|
||||
_G(flags)[V291] = 1;
|
||||
adv_kill_digi_between_rooms(false);
|
||||
digi_play_loop("950_s47", 3, 70, -1, 950);
|
||||
digi_stop(1);
|
||||
digi_stop(2);
|
||||
digi_unload("907R02");
|
||||
_G(game).setRoom(918);
|
||||
break;
|
||||
|
||||
case 11:
|
||||
digi_play("908f01", 1, 255, 12, 908);
|
||||
break;
|
||||
|
||||
case 12:
|
||||
kernel_timing_trigger(45, 13, nullptr);
|
||||
break;
|
||||
|
||||
case 13:
|
||||
digi_play("908w01", 1, 255, 14, 908);
|
||||
break;
|
||||
|
||||
case 14:
|
||||
kernel_timing_trigger(65, 15, nullptr);
|
||||
break;
|
||||
|
||||
case 31:
|
||||
series_stream_break_on_frame(_roomStates_tt, 9, 32);
|
||||
digi_play("950_s48", 2, 180, -1, -1);
|
||||
break;
|
||||
|
||||
case 32:
|
||||
series_stream_break_on_frame(_roomStates_tt, 19, 33);
|
||||
digi_play("950_s48a", 2, 220, -1, -1);
|
||||
break;
|
||||
|
||||
case 33:
|
||||
series_stream_break_on_frame(_roomStates_tt, 26, 34);
|
||||
digi_play("950_s48b", 2, 240, -1, -1);
|
||||
break;
|
||||
|
||||
case 34:
|
||||
series_stream_break_on_frame(_roomStates_tt, 57, 60);
|
||||
digi_play("950_s48c", 2, 255, -1, -1);
|
||||
kernel_timing_trigger(45, 35, nullptr);
|
||||
break;
|
||||
|
||||
case 35:
|
||||
digi_play("908d01", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 50:
|
||||
digi_play("950_s50", 3, 110, -1, -1);
|
||||
break;
|
||||
|
||||
case 60:
|
||||
digi_play("950_s48b", 2, 255, -1, -1);
|
||||
series_stream_break_on_frame(_roomStates_tt, 85, 70);
|
||||
break;
|
||||
|
||||
case 70:
|
||||
series_stream_break_on_frame(_roomStates_tt, 118, 80);
|
||||
digi_play("riptheme", 3, 255, -1, 917);
|
||||
break;
|
||||
|
||||
case 80:
|
||||
disable_player_commands_and_fade_init(90);
|
||||
digi_stop(1);
|
||||
digi_stop(2);
|
||||
break;
|
||||
|
||||
case 90:
|
||||
adv_kill_digi_between_rooms(false);
|
||||
digi_unload("907F01");
|
||||
digi_unload("907W01");
|
||||
digi_unload("907D01");
|
||||
digi_unload("950_S48");
|
||||
digi_unload("950_S48a");
|
||||
digi_unload("950_S48b");
|
||||
digi_unload("950_S48c");
|
||||
digi_unload("950_S50");
|
||||
_G(game).setRoom(493);
|
||||
break;
|
||||
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
49
engines/m4/riddle/rooms/section9/room917.h
Normal file
49
engines/m4/riddle/rooms/section9/room917.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM917_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM917_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room917 : public Room {
|
||||
public:
|
||||
Room917() : Room() {}
|
||||
~Room917() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
machine * _roomStates_tt = nullptr;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
247
engines/m4/riddle/rooms/section9/room918.cpp
Normal file
247
engines/m4/riddle/rooms/section9/room918.cpp
Normal file
@@ -0,0 +1,247 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room918.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room918::preload() {
|
||||
_G(player).walker_type = WALKER_ALT;
|
||||
_G(player).shadow_type = SHADOW_ALT;
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room918::init() {
|
||||
player_set_commands_allowed(false);
|
||||
digi_preload("908m06", 908);
|
||||
digi_preload("908R04", 908);
|
||||
digi_preload("908m07", 908);
|
||||
digi_preload("908r05", 908);
|
||||
digi_preload("908r05a", 908);
|
||||
digi_preload("908m07z", 908);
|
||||
digi_preload("908m08", 908);
|
||||
digi_preload("908m08a", 908);
|
||||
digi_preload("908r06", 908);
|
||||
digi_preload("908m09", 908);
|
||||
digi_preload("908m09a", 908);
|
||||
digi_preload("908m09b", 908);
|
||||
digi_preload("908r07", 908);
|
||||
digi_preload("908r07a", 908);
|
||||
digi_preload("908r07b", 908);
|
||||
digi_preload("908r07c", 908);
|
||||
digi_preload("908m10", 908);
|
||||
digi_preload("908m10a", 908);
|
||||
digi_preload("908m10b", 908);
|
||||
digi_preload("950_s48e", 950);
|
||||
digi_preload("950_s48f", 950);
|
||||
digi_preload("950_s48a", 950);
|
||||
digi_preload("950_s50", 950);
|
||||
digi_preload("950_s47", 950);
|
||||
interface_hide();
|
||||
_G(kernel).call_daemon_every_loop = true;
|
||||
digi_play_loop("950_s47", 3, 70, -1, 950);
|
||||
_roomStates_field4 = series_stream("918all", 5, 256, 10);
|
||||
series_stream_break_on_frame(_roomStates_field4, 3, 1);
|
||||
}
|
||||
|
||||
void Room918::daemon() {
|
||||
switch (_G(kernel).trigger) {
|
||||
|
||||
case 1:
|
||||
series_stream_break_on_frame(_roomStates_field4, 35, 30);
|
||||
digi_play("908m06", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 30:
|
||||
series_stream_break_on_frame(_roomStates_field4, 64, 40);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908R04", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 40:
|
||||
series_stream_break_on_frame(_roomStates_field4, 103, 50);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m07", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 50:
|
||||
series_stream_break_on_frame(_roomStates_field4, 121, 60);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908r05", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 60:
|
||||
series_stream_break_on_frame(_roomStates_field4, 133, 70);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908r05a", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 70:
|
||||
series_stream_break_on_frame(_roomStates_field4, 144, 75);
|
||||
digi_play("908m07z", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 75:
|
||||
series_stream_break_on_frame(_roomStates_field4, 174, 80);
|
||||
digi_play("908m08", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 80:
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
series_stream_break_on_frame(_roomStates_field4, 210, 90);
|
||||
digi_play("908m08a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 90:
|
||||
series_stream_break_on_frame(_roomStates_field4, 245, 100);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908r06", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 100:
|
||||
series_stream_break_on_frame(_roomStates_field4, 271, 102);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m09", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 102:
|
||||
series_stream_break_on_frame(_roomStates_field4, 291, 104);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m09a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 104:
|
||||
series_stream_break_on_frame(_roomStates_field4, 326, 110);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m09b", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 110:
|
||||
series_stream_break_on_frame(_roomStates_field4, 333, 112);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908r07", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 112:
|
||||
series_stream_break_on_frame(_roomStates_field4, 339, 114);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908r07a", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 114:
|
||||
series_stream_break_on_frame(_roomStates_field4, 354, 116);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908r07b", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 116:
|
||||
series_stream_break_on_frame(_roomStates_field4, 382, 120);
|
||||
series_set_frame_rate(_roomStates_field4, 6);
|
||||
digi_play("908r07c", 1, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 120:
|
||||
series_stream_break_on_frame(_roomStates_field4, 390, 122);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m10", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 122:
|
||||
series_stream_break_on_frame(_roomStates_field4, 435, 130);
|
||||
series_set_frame_rate(_roomStates_field4, 5);
|
||||
digi_play("908m10a", 2, 255, -1, 908);
|
||||
break;
|
||||
|
||||
case 130:
|
||||
digi_play("908m10b", 2, 255, -1, 908);
|
||||
series_stream_break_on_frame(_roomStates_field4, 470, 290);
|
||||
break;
|
||||
|
||||
case 200:
|
||||
digi_stop(2);
|
||||
break;
|
||||
|
||||
case 290:
|
||||
digi_play("950_s48e", 1, 255, -1, -1);
|
||||
series_stream_break_on_frame(_roomStates_field4, 480, 300);
|
||||
break;
|
||||
|
||||
case 300:
|
||||
series_set_frame_rate(_roomStates_field4, 7);
|
||||
series_stream_break_on_frame(_roomStates_field4, 486, 320);
|
||||
digi_play("950_s48f", 2, 255, 310, -1);
|
||||
break;
|
||||
|
||||
case 310:
|
||||
digi_play("950_s48a", 1, 255, 325, -1);
|
||||
digi_stop(3);
|
||||
digi_play("950_s50", 3, 180, -1, -1);
|
||||
break;
|
||||
|
||||
case 320:
|
||||
disable_player_commands_and_fade_init(-1);
|
||||
break;
|
||||
|
||||
case 325:
|
||||
digi_play("908f01", 1, 255, 340, 908);
|
||||
break;
|
||||
|
||||
case 340:
|
||||
adv_kill_digi_between_rooms(false);
|
||||
digi_stop(1);
|
||||
digi_stop(2);
|
||||
digi_unload("908m06");
|
||||
digi_unload("908R04");
|
||||
digi_unload("908m07");
|
||||
digi_unload("908r05");
|
||||
digi_unload("908r05a");
|
||||
digi_unload("908m07z");
|
||||
digi_unload("908m08");
|
||||
digi_unload("908m08a");
|
||||
digi_unload("908r06");
|
||||
digi_unload("908m09");
|
||||
digi_unload("908m09a");
|
||||
digi_unload("908m09b");
|
||||
digi_unload("908r07");
|
||||
digi_unload("908r07a");
|
||||
digi_unload("908r07b");
|
||||
digi_unload("908r07c");
|
||||
digi_unload("908m10");
|
||||
digi_unload("908m10a");
|
||||
digi_unload("908m10b");
|
||||
digi_unload("950_s48e");
|
||||
digi_unload("950_s48f");
|
||||
digi_unload("950_s48a");
|
||||
digi_unload("950_s47");
|
||||
_G(game).setRoom(917);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
49
engines/m4/riddle/rooms/section9/room918.h
Normal file
49
engines/m4/riddle/rooms/section9/room918.h
Normal file
@@ -0,0 +1,49 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM918_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM918_H
|
||||
|
||||
#include "m4/core/rooms.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room918 : public Room {
|
||||
public:
|
||||
Room918() : Room() {}
|
||||
~Room918() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
machine * _roomStates_field4 = nullptr;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
455
engines/m4/riddle/rooms/section9/room996.cpp
Normal file
455
engines/m4/riddle/rooms/section9/room996.cpp
Normal file
@@ -0,0 +1,455 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/ },.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/room996.h"
|
||||
#include "m4/graphics/gr_series.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Room996::preload() {
|
||||
_G(player).walker_in_this_scene = false;
|
||||
}
|
||||
|
||||
void Room996::init() {
|
||||
digi_preload("950_s56", -1);
|
||||
interface_hide();
|
||||
series_show("996mark", 0, 16, -1, -1, 0, 100, 0, 0);
|
||||
_journalIndex = 1;
|
||||
if (_G(flags)[V290]) {
|
||||
_roomStates_loop0 = series_show("996 Charcoal Page", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
digi_preload("205r13a", -1);
|
||||
digi_play("205r13a", 1, 255, -1, 205);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "FORWARD", false);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "BACK", false);
|
||||
} else if (player_been_here(205)) {
|
||||
_roomStates_loop0 = series_show("996 RIPPED OUT PAGE", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "FORWARD", false);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "BACK", false);
|
||||
} else {
|
||||
if (_G(flags)[V280]) {
|
||||
_roomStates_tt = series_show("996 Peru Pictograph Snake", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V148]) {
|
||||
_roomStates_field4 = series_show("996 Peru Pictograph Condor", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
} else {
|
||||
_roomStates_field4 = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, -13, -87);
|
||||
}
|
||||
|
||||
if (_G(flags)[V156]) {
|
||||
_roomStates_pu = series_show("996 Peru Pictos Solved Spider", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
} else {
|
||||
_roomStates_field8 = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
}
|
||||
|
||||
if (_G(flags)[V283]) {
|
||||
_roomStates_untie = series_show("996 Peru Pictograph Monkey", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
} else {
|
||||
_roomStates_untie = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, -21, 71);
|
||||
}
|
||||
}
|
||||
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "BACK", false);
|
||||
}
|
||||
|
||||
for (int i = 1; i < 12; ++i)
|
||||
_flagArray[i] = 0;
|
||||
|
||||
int index = 1;
|
||||
|
||||
if (_G(flags)[kEasterIslandCartoon]) {
|
||||
_flagArray[1] = 1;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kChinshiCartoon]) {
|
||||
_flagArray[index] = 2;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kTabletsCartoon]) {
|
||||
_flagArray[index] = 3;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kEpitaphCartoon]) {
|
||||
_flagArray[index] = 5;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kGraveyardCartoon]) {
|
||||
_flagArray[index] = 4;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kCastleCartoon]) {
|
||||
_flagArray[index] = 6;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kMocaMocheCartoon]) {
|
||||
_flagArray[index] = 7;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kTempleCartoon]) {
|
||||
_flagArray[index] = 8;
|
||||
++index;
|
||||
}
|
||||
|
||||
if (_G(flags)[kEmeraldCartoon]) {
|
||||
_flagArray[index] = 9;
|
||||
}
|
||||
|
||||
_journalIndex = 1;
|
||||
_moveValue = 0;
|
||||
}
|
||||
|
||||
void Room996::pre_parser() {
|
||||
if (player_said("forward", nullptr, nullptr) && (_journalIndex != 3)) {
|
||||
digi_play("950_s56", 1, 255, -1, 950);
|
||||
++_journalIndex;
|
||||
}
|
||||
|
||||
if (player_said("back", nullptr, nullptr) && (_journalIndex != 3)) {
|
||||
digi_play("950_s56", 1, 255, -1, 950);
|
||||
--_journalIndex;
|
||||
}
|
||||
|
||||
if (player_said("forward", nullptr, nullptr) && (_journalIndex == 3) && (_flagArray[1] == 0)) {
|
||||
++_journalIndex;
|
||||
}
|
||||
|
||||
if (player_said("forward", nullptr, nullptr) && (_journalIndex == 4) && (_G(flags)[V047] == 0)) {
|
||||
++_journalIndex;
|
||||
}
|
||||
|
||||
if (player_said("back", nullptr, nullptr) && (_journalIndex == 4) && (_G(flags)[V047] == 0)) {
|
||||
--_journalIndex;
|
||||
}
|
||||
|
||||
if (player_said("back", nullptr, nullptr) && (_journalIndex == 3) && (_flagArray[1] == 0)) {
|
||||
--_journalIndex;
|
||||
}
|
||||
|
||||
_journalIndex = CLIP(_journalIndex, (int32)1, (int32)5);
|
||||
|
||||
_G(player).need_to_walk = false;
|
||||
_G(player).ready_to_walk = true;
|
||||
_G(player).waiting_for_walk = false;
|
||||
}
|
||||
|
||||
void Room996::parser() {
|
||||
if (player_said("--", nullptr, nullptr)) {
|
||||
_G(player).command_ready = false;
|
||||
return;
|
||||
}
|
||||
|
||||
if (player_said("exit", nullptr, nullptr) && (_G(kernel).trigger >= -1)) {
|
||||
if (_G(kernel).trigger == -1) {
|
||||
player_set_commands_allowed(false);
|
||||
disable_player_commands_and_fade_init(1);
|
||||
_G(player).command_ready = false;
|
||||
return;
|
||||
}
|
||||
|
||||
if (_G(kernel).trigger == 1) {
|
||||
interface_show();
|
||||
restoreAutosave();
|
||||
_G(player).command_ready = false;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
switch (_journalIndex) {
|
||||
case 1:
|
||||
if (_G(kernel).trigger == -1) {
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "FORWARD", true);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "BACK", false);
|
||||
terminateMachine(_roomStates_ripTalker);
|
||||
terminateMachine(_roomStates_field18);
|
||||
terminateMachine(_roomStates_ripTalking);
|
||||
terminateMachine(_roomStates_ripTalk);
|
||||
terminateMachine(_roomStates_field24);
|
||||
kernel_timing_trigger(10, 1, nullptr);
|
||||
|
||||
} else if (_G(kernel).trigger == 1 && _G(flags)[V280] != 0) {
|
||||
_roomStates_tt = series_show("996 Peru Pictograph Snake", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V148])
|
||||
_roomStates_field4 = series_show("996 Peru Pictograph Condor", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
else
|
||||
_roomStates_field4 = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, -13, -87);
|
||||
|
||||
if (_G(flags)[V156])
|
||||
_roomStates_pu = series_show("996 Peru Pictos Solved Spider", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
else
|
||||
_roomStates_field8 = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V283])
|
||||
_roomStates_untie = series_show("996 Peru Pictograph Monkey", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
else
|
||||
_roomStates_untie = series_show("996 Peru Pictograph Spider", 256, 16, -1, -1, 0, 100, -21, 71);
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if (_G(kernel).trigger == -1) {
|
||||
if (_flagArray[_moveValue + 1] != 0 || _G(flags)[V047] || _G(flags)[V196] || _G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", true);
|
||||
else
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "back", true);
|
||||
terminateMachine(_roomStates_tt);
|
||||
terminateMachine(_roomStates_field4);
|
||||
terminateMachine(_roomStates_pu);
|
||||
terminateMachine(_roomStates_field8);
|
||||
terminateMachine(_roomStates_untie);
|
||||
terminateMachine(_roomStates_loop1);
|
||||
terminateMachine(_roomStates_loop2);
|
||||
terminateMachine(_roomStates_loop3);
|
||||
terminateMachine(_roomStates_loop4);
|
||||
terminateMachine(_roomStates_loop5);
|
||||
terminateMachine(_roomStates_loop6);
|
||||
terminateMachine(_roomStates_loop7);
|
||||
terminateMachine(_roomStates_ear2);
|
||||
terminateMachine(_roomStates_field4C);
|
||||
kernel_timing_trigger(10, 1, nullptr);
|
||||
|
||||
} else if (_G(kernel).trigger == 1) {
|
||||
// Original is only checking against flag 285. The problem is that if it's missing, it's becoming incoherent after,
|
||||
// so I added the other flags in the check to display the title when other things are displayed.
|
||||
if (_G(flags)[V285] || _G(flags)[V286] || _G(flags)[V287] || _G(flags)[V288] || _G(flags)[V289])
|
||||
_roomStates_ripTalker = series_show("996 TITLE JOURNAL TYPE", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V286])
|
||||
_roomStates_field18 = series_show("996 sikkamese text alone", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V287])
|
||||
_roomStates_ripTalking = series_show("996 PERU SCRIPT", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V288]) {
|
||||
if (player_been_here(615))
|
||||
_roomStates_ripTalk = series_show("996 EASTER ISLAND SCRIPT", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
else
|
||||
_roomStates_ripTalk = series_show("996 East Isl. w/o #s", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
}
|
||||
|
||||
if (_G(flags)[V289])
|
||||
_roomStates_field24 = series_show("996 KEY TO TOMB SCRIPT", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
if (_G(kernel).trigger == -1) {
|
||||
if (player_said("forward", nullptr, nullptr)) {
|
||||
digi_play("950_s56", 1, 255, -1, 950);
|
||||
++_moveValue;
|
||||
} else if (player_said("back", nullptr, nullptr)) {
|
||||
digi_play("950_s56", 1, 255, -1, 950);
|
||||
--_moveValue;
|
||||
}
|
||||
|
||||
if (_moveValue == 0) {
|
||||
_journalIndex = 2;
|
||||
digi_play("950_s56", 1, 255, -1, 950);
|
||||
} else if (_flagArray[_moveValue] == 0) {
|
||||
if (_G(flags)[V047])
|
||||
_journalIndex = 4;
|
||||
else if (_G(flags)[V196] || _G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
_journalIndex = 5;
|
||||
}
|
||||
|
||||
if (_flagArray[_moveValue] != 0 || _G(flags)[V047] || _G(flags)[V196] || _G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", true);
|
||||
else
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
|
||||
if (_journalIndex == 4) {
|
||||
if (_G(flags)[V196] || _G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", true);
|
||||
else
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
}
|
||||
|
||||
if (_journalIndex == 5)
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
|
||||
terminateMachine(_roomStates_ripTalker);
|
||||
terminateMachine(_roomStates_field18);
|
||||
terminateMachine(_roomStates_ripTalking);
|
||||
terminateMachine(_roomStates_ripTalk);
|
||||
terminateMachine(_roomStates_field24);
|
||||
terminateMachine(_roomStates_loop1);
|
||||
terminateMachine(_roomStates_loop2);
|
||||
terminateMachine(_roomStates_loop3);
|
||||
terminateMachine(_roomStates_loop4);
|
||||
terminateMachine(_roomStates_loop5);
|
||||
terminateMachine(_roomStates_loop6);
|
||||
terminateMachine(_roomStates_loop7);
|
||||
terminateMachine(_roomStates_ear2);
|
||||
terminateMachine(_roomStates_field4C);
|
||||
kernel_timing_trigger(10, 1, nullptr);
|
||||
} else if (_G(kernel).trigger == 1) {
|
||||
switch (_flagArray[_moveValue]) {
|
||||
case 1:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
break;
|
||||
case 2:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 1, 100, 0, 0);
|
||||
break;
|
||||
case 3:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 2, 100, 0, 0);
|
||||
break;
|
||||
case 4:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 3, 100, 0, 0);
|
||||
break;
|
||||
case 5:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 4, 100, 0, 0);
|
||||
break;
|
||||
case 6:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 5, 100, 0, 0);
|
||||
break;
|
||||
case 7:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 6, 100, 0, 0);
|
||||
break;
|
||||
case 8:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 7, 100, 0, 0);
|
||||
break;
|
||||
case 9:
|
||||
_roomStates_loop1 = series_show("996car", 256, 16, -1, -1, 8, 100, 0, 0);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
if (_G(kernel).trigger == -1) {
|
||||
if (_G(flags)[V196] || _G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", true);
|
||||
else
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
|
||||
terminateMachine(_roomStates_ripTalker);
|
||||
terminateMachine(_roomStates_field18);
|
||||
terminateMachine(_roomStates_ripTalking);
|
||||
terminateMachine(_roomStates_ripTalk);
|
||||
terminateMachine(_roomStates_field24);
|
||||
terminateMachine(_roomStates_loop1);
|
||||
terminateMachine(_roomStates_loop3);
|
||||
terminateMachine(_roomStates_loop4);
|
||||
terminateMachine(_roomStates_loop5);
|
||||
terminateMachine(_roomStates_loop6);
|
||||
terminateMachine(_roomStates_loop7);
|
||||
terminateMachine(_roomStates_ear2);
|
||||
terminateMachine(_roomStates_field4C);
|
||||
kernel_timing_trigger(10, 1, nullptr);
|
||||
} else if (_G(kernel).trigger == 1) {
|
||||
_check201Fl = _G(flags)[V201] != 0;
|
||||
_check207Fl = _G(flags)[V207] != 0;
|
||||
_check208Fl = _G(flags)[V208] != 0;
|
||||
_check209Fl = _G(flags)[V209] != 0;
|
||||
|
||||
if (!_check201Fl && !_check207Fl && !_check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ136", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && !_check207Fl && !_check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ122", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && _check207Fl && !_check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ123", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && !_check207Fl && !_check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ124", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && !_check207Fl && _check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ125", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && _check207Fl && !_check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ126", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && !_check207Fl && _check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ127", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && !_check207Fl && !_check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ128", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && _check207Fl && !_check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ129", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && _check207Fl && _check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ130", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && !_check207Fl && _check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ131", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && _check207Fl && _check208Fl && !_check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ132", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && !_check207Fl && _check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ133", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && _check207Fl && !_check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ134", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (!_check201Fl && _check207Fl && _check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING OBJ135", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
} else if (_check201Fl && _check207Fl && _check208Fl && _check209Fl) {
|
||||
_roomStates_loop2 = series_show("PING TWELVETREES' MAP", 256, 16, -1, -1, 0, 100, 206, 67);
|
||||
}
|
||||
}
|
||||
|
||||
break;
|
||||
case 5:
|
||||
if (_G(kernel).trigger == -1) {
|
||||
terminateMachine(_roomStates_ripTalker);
|
||||
terminateMachine(_roomStates_field18);
|
||||
terminateMachine(_roomStates_ripTalking);
|
||||
terminateMachine(_roomStates_ripTalk);
|
||||
terminateMachine(_roomStates_field24);
|
||||
terminateMachine(_roomStates_loop2);
|
||||
hotspot_set_active(_G(currentSceneDef).hotspots, "forward", false);
|
||||
kernel_timing_trigger(10, 1, nullptr);
|
||||
} else if (_G(kernel).trigger == 1) {
|
||||
_roomStates_loop3 = series_show("996 EA Glyph title", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
if (_G(flags)[V201] || _G(flags)[V207] || _G(flags)[V208] || _G(flags)[V209])
|
||||
_roomStates_loop5 = series_show("996 EA Glyph Quarry title", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V196])
|
||||
_roomStates_loop4 = series_show("996 EA Glyph Fallen head", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V201])
|
||||
_roomStates_loop7 = series_show("996 EA Glyph Sharks Tooth", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V207])
|
||||
_roomStates_loop6 = series_show("996 EA Glyph Scallop Shell", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V208])
|
||||
_roomStates_ear2 = series_show("996 EA Glyph Starfish", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
|
||||
if (_G(flags)[V209])
|
||||
_roomStates_field4C = series_show("996 EA Glyph SeaHorse", 256, 16, -1, -1, 0, 100, 0, 0);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
_G(player).command_ready = false;
|
||||
}
|
||||
|
||||
void Room996::daemon() {
|
||||
if (_G(kernel).trigger == 1)
|
||||
player_set_commands_allowed(true);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
78
engines/m4/riddle/rooms/section9/room996.h
Normal file
78
engines/m4/riddle/rooms/section9/room996.h
Normal file
@@ -0,0 +1,78 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM996_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM996_H
|
||||
|
||||
#include "m4/riddle/rooms/room.h"
|
||||
#include "m4/wscript/ws_machine.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Room996 : public Room {
|
||||
public:
|
||||
Room996() : Room() {}
|
||||
~Room996() override {}
|
||||
|
||||
void preload() override;
|
||||
void init() override;
|
||||
void pre_parser() override;
|
||||
void parser() override;
|
||||
void daemon() override;
|
||||
|
||||
private:
|
||||
int32 _flagArray[12] = {};
|
||||
int32 _journalIndex = 1;
|
||||
int32 _moveValue = 0;
|
||||
bool _check201Fl = false;
|
||||
bool _check207Fl = false;
|
||||
bool _check208Fl = false;
|
||||
bool _check209Fl = false;
|
||||
|
||||
machine *_roomStates_ear2 = nullptr;
|
||||
machine *_roomStates_field4 = nullptr;
|
||||
machine *_roomStates_field8 = nullptr;
|
||||
machine *_roomStates_field18 = nullptr;
|
||||
machine *_roomStates_field24 = nullptr;
|
||||
machine *_roomStates_field4C = nullptr;
|
||||
machine *_roomStates_loop0 = nullptr;
|
||||
machine *_roomStates_loop1 = nullptr;
|
||||
machine *_roomStates_loop2 = nullptr;
|
||||
machine *_roomStates_loop3 = nullptr;
|
||||
machine *_roomStates_loop4 = nullptr;
|
||||
machine *_roomStates_loop5 = nullptr;
|
||||
machine *_roomStates_loop6 = nullptr;
|
||||
machine *_roomStates_loop7 = nullptr;
|
||||
machine *_roomStates_pu = nullptr;
|
||||
machine *_roomStates_ripTalk = nullptr;
|
||||
machine *_roomStates_ripTalker = nullptr;
|
||||
machine *_roomStates_ripTalking = nullptr;
|
||||
machine *_roomStates_tt = nullptr;
|
||||
machine *_roomStates_untie = nullptr;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
48
engines/m4/riddle/rooms/section9/section9.cpp
Normal file
48
engines/m4/riddle/rooms/section9/section9.cpp
Normal file
@@ -0,0 +1,48 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/section9.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
Section9::Section9() : Rooms::Section() {
|
||||
add(901, &_room901);
|
||||
add(902, &_room902);
|
||||
add(903, &_room903);
|
||||
add(905, &_room905);
|
||||
add(906, &_room906);
|
||||
add(907, &_room907);
|
||||
add(908, &_room908);
|
||||
add(917, &_room917);
|
||||
add(918, &_room918);
|
||||
add(996, &_room996);
|
||||
}
|
||||
|
||||
void Section9::daemon() {
|
||||
_G(kernel).continue_handling_trigger = true;
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
64
engines/m4/riddle/rooms/section9/section9.h
Normal file
64
engines/m4/riddle/rooms/section9/section9.h
Normal file
@@ -0,0 +1,64 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_H
|
||||
|
||||
#include "m4/riddle/rooms/section.h"
|
||||
#include "m4/riddle/rooms/section9/room901.h"
|
||||
#include "m4/riddle/rooms/section9/room902.h"
|
||||
#include "m4/riddle/rooms/section9/room903.h"
|
||||
#include "m4/riddle/rooms/section9/room905.h"
|
||||
#include "m4/riddle/rooms/section9/room906.h"
|
||||
#include "m4/riddle/rooms/section9/room907.h"
|
||||
#include "m4/riddle/rooms/section9/room908.h"
|
||||
#include "m4/riddle/rooms/section9/room917.h"
|
||||
#include "m4/riddle/rooms/section9/room918.h"
|
||||
#include "m4/riddle/rooms/section9/room996.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Section9 : public Section {
|
||||
private:
|
||||
Room901 _room901;
|
||||
Room902 _room902;
|
||||
Room903 _room903;
|
||||
Room905 _room905;
|
||||
Room906 _room906;
|
||||
Room907 _room907;
|
||||
Room908 _room908;
|
||||
Room917 _room917;
|
||||
Room918 _room918;
|
||||
Room996 _room996;
|
||||
public:
|
||||
Section9();
|
||||
virtual ~Section9() {}
|
||||
|
||||
void daemon() override;
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
36
engines/m4/riddle/rooms/section9/section9_room.cpp
Normal file
36
engines/m4/riddle/rooms/section9/section9_room.cpp
Normal file
@@ -0,0 +1,36 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "m4/riddle/rooms/section9/section9_room.h"
|
||||
#include "m4/riddle/vars.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
void Section9Room::escapePressed(void *, void *) {
|
||||
_G(kernel).trigger_mode = KT_DAEMON;
|
||||
disable_player_commands_and_fade_init(56);
|
||||
}
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
44
engines/m4/riddle/rooms/section9/section9_room.h
Normal file
44
engines/m4/riddle/rooms/section9/section9_room.h
Normal file
@@ -0,0 +1,44 @@
|
||||
/* 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 3 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, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef M4_RIDDLE_ROOMS_SECTION9_ROOM_H
|
||||
#define M4_RIDDLE_ROOMS_SECTION9_ROOM_H
|
||||
|
||||
#include "m4/riddle/rooms/room.h"
|
||||
|
||||
namespace M4 {
|
||||
namespace Riddle {
|
||||
namespace Rooms {
|
||||
|
||||
class Section9Room : public Room {
|
||||
protected:
|
||||
static void escapePressed(void *, void *);
|
||||
|
||||
public:
|
||||
Section9Room() : Room() {}
|
||||
virtual ~Section9Room() {}
|
||||
};
|
||||
|
||||
} // namespace Rooms
|
||||
} // namespace Riddle
|
||||
} // namespace M4
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user