ScummVM API documentation
room202.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef MADS_PHANTOM_ROOM202_H
23 #define MADS_PHANTOM_ROOM202_H
24 
25 #include "mads/madsv2/phantom/rooms/section2.h"
26 #include "mads/madsv2/phantom/global.h"
27 
28 namespace MADS {
29 namespace MADSV2 {
30 namespace Phantom {
31 namespace Rooms {
32 
33 #define local (&scratch)
34 #define ss local->sprite
35 #define seq local->sequence
36 #define aa local->animation
37 
38 struct Scratch { /* Room local variables */
39 
40  int16 sprite[15]; /* Sprite series handles */
41  int16 sequence[15]; /* Sequence handles */
42  int16 animation[4]; /* Animation handles */
43 
44  int16 usher_action;
45  int16 usher_frame;
46  int16 usher_talk_count;
47 
48  int16 degas_action;
49  int16 degas_frame;
50 
51  int16 rich_frame;
52  int16 rich_action;
53  int16 rich_talk_count;
54 
55  int16 anim_0_running;
56  int16 anim_1_running;
57  int16 converse_counter;
58  int16 prevent;
59 
60  int16 chandelier_base[5];
61  int16 dyn_chandeliers[5];
62 
63  int16 gave;
64 
65 };
66 
67 
68 /* ========================= Sprite Series ========================= */
69 
70 #define fx_left_door 0 /* rm202x0 */
71 #define fx_take_9 1 /* rdr_9 */
72 #define fx_chandelier_0 2 /* rm202f0 */
73 #define fx_chandelier_1 3
74 #define fx_chandelier_2 4
75 #define fx_chandelier_3 5
76 #define fx_chandelier_4 6
77 
78 
79 /* ========================= Conversations ========================= */
80 
81 #define CONV_USHER_17 17
82 #define CONV_DEGAS_9 9
83 
84 /* Conv 17 — Usher action states */
85 #define CONV17_USHER_TALK 0
86 #define CONV17_USHER_POINT 1
87 #define CONV17_USHER_SHUT_UP 2
88 #define CONV17_USHER_HAVE_TICKET 3
89 #define CONV17_USHER_LEFT_UP 4
90 
91 /* Conv 9 — Degas action states */
92 #define CONV9_DEGAS_TALK 0
93 #define CONV9_DEGAS_BOW 1
94 #define CONV9_DEGAS_GIRL 2
95 #define CONV9_DEGAS_LEAVE 3
96 #define CONV9_DEGAS_SHUT_UP 4
97 
98 
99 /* ========================= Triggers ============================== */
100 
101 #define ROOM_202_DOOR_CLOSES 60
102 #define ROOM_202_USHER_TALK 70
103 #define ROOM_202_USHER_POINT 72
104 #define ROOM_202_ME_TALK 74
105 #define ROOM_202_END 76
106 #define ROOM_202_DOOR_OPENS 80
107 #define ROOM_202_TALK_TO_DEGAS 90
108 #define ROOM_202_DEGAS_TALK 93
109 #define ROOM_202_DEGAS_WALK 96
110 #define ROOM_202_DEGAS_DONE 100
111 
112 
113 /* ========================= Player positions ====================== */
114 
115 #define PLAYER_X_FROM_201 3
116 #define PLAYER_Y_FROM_201 141
117 
118 #define PLAYER_X_FROM_204 253
119 #define PLAYER_Y_FROM_204 117
120 
121 #define PLAYER_X_FROM_205 510
122 #define PLAYER_Y_FROM_205 117
123 
124 #define PLAYER_X_FROM_101 636
125 #define PLAYER_Y_FROM_101 143
126 
127 #define WALK_TO_X_FROM_201 40
128 #define WALK_TO_Y_FROM_201 141
129 
130 #define WALK_TO_X_FROM_203 132
131 #define WALK_TO_Y_FROM_203 134
132 
133 #define WALK_TO_X_FROM_204 255
134 #define WALK_TO_Y_FROM_204 133
135 
136 #define WALK_TO_X_FROM_205 512
137 #define WALK_TO_Y_FROM_205 133
138 
139 #define WALK_TO_X_FROM_101 598
140 #define WALK_TO_Y_FROM_101 143
141 
142 #define WALK_TO_X_BEHIND_LEFT_DOOR 134
143 #define WALK_TO_Y_BEHIND_LEFT_DOOR 112
144 
145 
146 /* ========================= Misc positions ======================== */
147 
148 #define FRONT_OF_LEFT_DOOR_X 126
149 #define FRONT_OF_LEFT_DOOR_Y 123
150 
151 #define USHER_X 569
152 #define USHER_Y 147
153 
154 #define DEGAS_X 400
155 #define DEGAS_Y 141
156 
157 #define DEGAS_AFTER_CONV_X 596
158 #define DEGAS_AFTER_CONV_Y 144
159 
160 #define RIGHT_HALF 320
161 
162 
163 /* ========================= Chandelier ============================ */
164 
165 #define NUM_CHANDELIERS 5
166 #define camera_ratio_1 1
167 #define camera_ratio_2 5
168 
169 
170 extern void set_chandelier_positions();
171 
172 extern void room_202_init();
173 extern void room_202_daemon();
174 extern void room_202_pre_parser();
175 extern void room_202_parser();
176 extern void room_202_preload();
177 
178 } // namespace Rooms
179 } // namespace Phantom
180 } // namespace MADSV2
181 } // namespace MADS
182 
183 #endif
Definition: mps_installer.h:31