ScummVM API documentation
group1.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 GNAP_GROUP1_H
23 #define GNAP_GROUP1_H
24 
25 #include "gnap/debugger.h"
26 
27 namespace Gnap {
28 
29 enum {
30  kHS10Platypus = 0,
31  kHS10ExitBar = 1,
32  kHS10ExitBackdoor = 2,
33  kHS10Cook = 3,
34  kHS10Tongs = 4,
35  kHS10Box = 5,
36  kHS10Oven = 6,
37  kHS10WalkArea1 = 7,
38  kHS10Device = 8,
39  kHS10WalkArea2 = 9,
40  kHS10WalkArea3 = 10,
41  kHS10WalkArea4 = 11
42 };
43 
44 enum {
45  kHS11Platypus = 0,
46  kHS11ExitKitchen = 1,
47  kHS11ExitToilet = 2,
48  kHS11ExitLeft = 3,
49  kHS11GoggleGuy = 4,
50  kHS11HookGuy = 5,
51  kHS11Billard = 6,
52  kHS11WalkArea1 = 7,
53  kHS11Device = 8,
54  kHS11WalkArea2 = 9,
55  kHS11WalkArea3 = 10,
56  kHS11WalkArea4 = 11,
57  kHS11WalkArea5 = 12
58 };
59 
60 enum {
61  kHS12Platypus = 0,
62  kHS12ExitRight = 1,
63  kHS12ToothGuy = 2,
64  kHS12Barkeeper = 3,
65  kHS12BeardGuy = 4,
66  kHS12Jukebox = 5,
67  kHS12WalkArea1 = 6,
68  kHS12Device = 7,
69  kHS12WalkArea2 = 8,
70  kHS12WalkArea3 = 9,
71  kHS12WalkArea4 = 10
72 };
73 
74 enum {
75  kHS13Platypus = 0,
76  kHS13ExitBar = 1,
77  kHS13WalkArea1 = 2,
78  kHS13BackToilet = 3,
79  kHS13FrontToilet= 4,
80  kHS13Urinal = 5,
81  kHS13Scribble = 6,
82  kHS13Sink = 7,
83  kHS13WalkArea2 = 8,
84  kHS13Device = 9,
85  kHS13WalkArea3 = 10,
86  kHS13WalkArea4 = 11,
87  kHS13WalkArea5 = 12,
88  kHS13WalkArea6 = 13,
89  kHS13WalkArea7 = 14,
90  kHS13WalkArea8 = 15,
91  kHS13WalkArea9 = 16
92 };
93 
94 enum {
95  kHS14Platypus = 0,
96  kHS14Exit = 1,
97  kHS14Coin = 2,
98  kHS14Toilet = 3,
99  kHS14Device = 4
100 };
101 
102 enum {
103  kHS15Platypus = 0,
104  kHS15Exit = 1,
105  kHS15Button1 = 2,
106  kHS15Button2 = 3,
107  kHS15Button3 = 4,
108  kHS15Button4 = 5,
109  kHS15Button5 = 6,
110  kHS15Button6 = 7,
111  kHS15ButtonA = 8,
112  kHS15ButtonB = 9,
113  kHS15ButtonC = 10,
114  kHS15ButtonD = 11,
115  kHS15ButtonE = 12,
116  kHS15ButtonF = 13,
117  kHS15CoinSlot = 14,
118  kHS15PlayButton = 15,
119  kHS15Device = 16
120 };
121 
122 enum {
123  kHS17Platypus = 0,
124  kHS17Phone1 = 1,
125  kHS17Phone2 = 2,
126  kHS17ExitGrubCity = 3,
127  kHS17Device = 4,
128  kHS17ExitToyStore = 5,
129  kHS17Wrench = 6,
130  kHS17WalkArea1 = 7,
131  kHS17WalkArea2 = 8,
132  kHS17WalkArea3 = 9
133 };
134 
135 enum {
136  kHS18Platypus = 0,
137  kHS18GarbageCan = 1,
138  kHS18Device = 2,
139  kHS18ExitToyStore = 3,
140  kHS18ExitPhoneBooth = 4,
141  kHS18ExitGrubCity = 5,
142  kHS18HydrantTopValve = 6,
143  kHS18HydrantRightValve = 7,
144  kHS18CowboyHat = 8,
145  kHS18WalkArea1 = 9,
146  kHS18WalkArea2 = 10
147 };
148 
149 enum {
150  kHS19Platypus = 0,
151  kHS19ExitOutsideToyStore= 1,
152  kHS19Device = 2,
153  kHS19Picture = 3,
154  kHS19ShopAssistant = 4,
155  kHS19Toy1 = 5,
156  kHS19Toy2 = 6,
157  kHS19Toy3 = 7,
158  kHS19Phone = 8,
159  kHS19Toy4 = 9,
160  kHS19Toy5 = 10,
161  kHS19Toy6 = 11,
162  kHS19Toy7 = 12,
163  kHS19WalkArea1 = 13,
164  kHS19WalkArea2 = 14,
165  kHS19WalkArea3 = 15
166 };
167 
168 enum {
169  kAS10LeaveScene = 0,
170  kAS10AnnoyCook = 1,
171  kAS10PlatWithBox = 4
172 };
173 
174 enum {
175  kAS11LeaveScene = 0,
176  kAS11ShowMagazineToGoggleGuy = 3,
177  kAS11TalkGoggleGuy = 4,
178  kAS11GrabHookGuy = 6,
179  kAS11ShowItemToHookGuy = 8,
180  kAS11TalkHookGuy = 9,
181  kAS11GrabBillardBall = 11
182 };
183 
184 enum {
185  kAS12LeaveScene = 0,
186  kAS12QuarterToToothGuyDone = 1,
187  kAS12TalkToothGuy = 2,
188  kAS12GrabToothGuy = 4,
189  kAS12ShowItemToToothGuy = 5,
190  kAS12QuarterWithHoleToToothGuy = 6,
191  kAS12QuarterToToothGuy = 7,
192  kAS12TalkBeardGuy = 8,
193  kAS12LookBeardGuy = 9,
194  kAS12GrabBeardGuy = 10,
195  kAS12ShowItemToBeardGuy = 11,
196  kAS12TalkBarkeeper = 12,
197  kAS12LookBarkeeper = 13,
198  kAS12ShowItemToBarkeeper = 15,
199  kAS12QuarterWithBarkeeper = 16,
200  kAS12PlatWithBarkeeper = 17,
201  kAS12PlatWithToothGuy = 18,
202  kAS12PlatWithBeardGuy = 19
203 };
204 
205 enum {
206  kAS13LeaveScene = 0,
207  kAS13BackToilet = 1,
208  kAS13FrontToilet = 2,
209  kAS13LookScribble = 6,
210  kAS13GrabSink = 7,
211  kAS13GrabSinkDone = 8,
212  kAS13Wait = 12,
213  kAS13GrabUrinal = 13
214 };
215 
216 enum {
217  kAS17TryGetWrench = 0,
218  kAS17GetWrench2 = 1,
219  kAS17GetWrenchDone = 2,
220  kAS17GetWrench1 = 3,
221  kAS17PlatUsePhone = 4,
222  kAS17PutCoinIntoPhone = 5,
223  kAS17GetCoinFromPhone = 6,
224  kAS17GetCoinFromPhoneDone = 7,
225  kAS17PutCoinIntoPhoneDone = 8,
226  kAS17GnapUsePhone = 9,
227  kAS17GetWrenchGnapReady = 10,
228  kAS17GnapHangUpPhone = 11,
229  kAS17PlatPhoningAssistant = 12,
230  kAS17PlatHangUpPhone = 14,
231  kAS17LeaveScene = 15
232 };
233 
234 enum {
235  kAS18OpenRightValveNoGarbageCanDone = 0,
236  kAS18OpenRightValveNoGarbageCan = 1,
237  kAS18CloseRightValveNoGarbageCan = 2,
238  kAS18OpenTopValveDone = 3,
239  kAS18OpenTopValve = 4,
240  kAS18CloseTopValve = 5,
241  kAS18GrabGarbageCanFromStreet = 6,
242  kAS18GrabCowboyHat = 7,
243  kAS18GrabGarbageCanFromHydrant = 8,
244  kAS18PutGarbageCanOnRunningHydrant = 9,
245  kAS18PutGarbageCanOnRunningHydrant2 = 10,
246  kAS18GrabCowboyHatDone = 11,
247  kAS18StandingOnHydrant = 12,
248  kAS18OpenRightValveWithGarbageCan = 13,
249  kAS18OpenRightValveWithGarbageCanDone = 14,
250  kAS18CloseRightValveWithGarbageCan = 15,
251  kAS18PutGarbageCanOnHydrant = 16,
252  kAS18PutGarbageCanOnHydrantDone = 17,
253  kAS18PlatComesHere = 18,
254  kAS18CloseRightValveWithGarbageCanDone = 19,
255  kAS18LeaveScene = 20
256 };
257 
258 enum {
259  kAS19UsePhone = 0,
260  kAS19GrabToy = 1,
261  kAS19GrabPicture = 2,
262  kAS19GrabPictureDone = 3,
263  kAS19TalkShopAssistant = 4,
264  kAS19LeaveScene = 5
265 };
266 
267 /*****************************************************************************/
268 
269 class GnapEngine;
270 class CutScene;
271 
272 class Scene10: public Scene {
273 public:
274  Scene10(GnapEngine *vm);
275  ~Scene10() override {}
276 
277  int init() override;
278  void updateHotspots() override;
279  void run() override;
280  void updateAnimations() override;
281  void updateAnimationsCb() override;
282 
283 private:
284  int _nextCookSequenceId;
285  int _currCookSequenceId;
286 };
287 
288 class Scene11: public Scene {
289 public:
290  Scene11(GnapEngine *vm);
291  ~Scene11() override {}
292 
293  int init() override;
294  void updateHotspots() override;
295  void run() override;
296  void updateAnimations() override;
297  void updateAnimationsCb() override {};
298 
299 private:
300  int _billardBallCtr;
301  int _nextHookGuySequenceId;
302  int _currHookGuySequenceId;
303  int _nextGoggleGuySequenceId;
304  int _currGoggleGuySequenceId;
305 };
306 
307 class Scene12: public Scene {
308 public:
309  Scene12(GnapEngine *vm);
310  ~Scene12() override {}
311 
312  int init() override;
313  void updateHotspots() override;
314  void run() override;
315  void updateAnimations() override;
316  void updateAnimationsCb() override {};
317 
318 private:
319  int _nextBeardGuySequenceId;
320  int _currBeardGuySequenceId;
321  int _nextToothGuySequenceId;
322  int _currToothGuySequenceId;
323  int _nextBarkeeperSequenceId;
324  int _currBarkeeperSequenceId;
325 };
326 
327 class Scene13: public Scene {
328 public:
329  Scene13(GnapEngine *vm);
330  ~Scene13() override {}
331 
332  int init() override;
333  void updateHotspots() override;
334  void run() override;
335  void updateAnimations() override;
336  void updateAnimationsCb() override {};
337 
338 private:
339  int _backToiletCtr;
340 
341  void showScribble();
342 };
343 
344 class Scene14: public Scene {
345 public:
346  Scene14(GnapEngine *vm);
347  ~Scene14() override {}
348 
349  int init() override;
350  void updateHotspots() override;
351  void run() override;
352  void updateAnimations() override;
353  void updateAnimationsCb() override {};
354 };
355 
356 class Scene15: public Scene {
357 public:
358  Scene15(GnapEngine *vm);
359  ~Scene15() override {}
360 
361  int init() override;
362  void updateHotspots() override;
363  void run() override;
364  void updateAnimations() override;
365  void updateAnimationsCb() override {};
366 
367 private:
368  int _nextRecordSequenceId;
369  int _currRecordSequenceId;
370  int _nextSlotSequenceId;
371  int _currSlotSequenceId;
372  int _nextUpperButtonSequenceId;
373  int _currUpperButtonSequenceId;
374  int _nextLowerButtonSequenceId;
375  int _currLowerButtonSequenceId;
376 };
377 
378 class Scene17: public Scene {
379 public:
380  Scene17(GnapEngine *vm);
381  ~Scene17() override {}
382 
383  int init() override;
384  void updateHotspots() override;
385  void run() override;
386  void updateAnimations() override;
387  void updateAnimationsCb() override {};
388 
389 private:
390  bool _canTryGetWrench;
391  int _wrenchCtr;
392  int _platPhoneCtr;
393  int _platTryGetWrenchCtr;
394  int _nextPhoneSequenceId;
395  int _currPhoneSequenceId;
396  int _nextWrenchSequenceId;
397  int _currWrenchSequenceId;
398  int _nextCarWindowSequenceId;
399  int _currCarWindowSequenceId;
400 
401  void update();
402  void platHangUpPhone();
403 };
404 
405 class Scene18: public Scene {
406 public:
407  Scene18(GnapEngine *vm);
408  ~Scene18() override;
409 
410  int init() override;
411  void updateHotspots() override;
412  void run() override;
413  void updateAnimations() override;
414  void updateAnimationsCb() override {};
415 
416 private:
417  Graphics::Surface *_cowboyHatSurface;
418 
419  int _platPhoneCtr;
420  int _platPhoneIter;
421  int _nextPhoneSequenceId;
422  int _currPhoneSequenceId;
423 
424  void gnapCarryGarbageCanTo(int a5);
425  void putDownGarbageCan(int animationIndex);
426  void platEndPhoning(bool platFl);
427  void closeHydrantValve();
428  void waitForGnapAction();
429 };
430 
431 class Scene19: public Scene {
432 public:
433  Scene19(GnapEngine *vm);
434  ~Scene19() override;
435 
436  int init() override;
437  void updateHotspots() override;
438  void run() override;
439  void updateAnimations() override;
440  void updateAnimationsCb() override {};
441 
442 private:
443  int _currShopAssistantSequenceId;
444  int _nextShopAssistantSequenceId;
445  int _toyGrabCtr;
446  int _shopAssistantCtr;
447 
448  Graphics::Surface *_pictureSurface;
449 };
450 
451 } // End of namespace Gnap
452 
453 #endif // GNAP_GROUP1_H
Definition: surface.h:67
Definition: group1.h:356
Definition: group1.h:272
Definition: group1.h:431
Definition: group1.h:288
Definition: group1.h:327
Definition: character.h:25
Definition: group1.h:378
Definition: gnap.h:222
Definition: group1.h:307
Definition: group1.h:344
Definition: scenecore.h:31
Definition: group1.h:405