ScummVM API documentation
puzzles.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 PUZZLES_H_
23 #define PUZZLES_H_
24 
25 #include "common/scummsys.h"
26 
27 #include "graphics/surface.h"
28 
29 namespace Myst3 {
30 
31 class Myst3Engine;
32 
33 class Puzzles {
34 public:
35  Puzzles(Myst3Engine *vm);
36  virtual ~Puzzles();
37 
38  void run(uint16 id, uint16 arg0 = 0, uint16 arg1 = 0, uint16 arg2 = 0);
39 
40 private:
41  Myst3Engine *_vm;
42 
43  typedef int32 SymbolCodeSolution[4];
44 
45  struct PegCombination {
46  uint16 movie;
47  bool pegs[5];
48  uint16 pegFrames[3];
49  uint16 expireFrame;
50  };
51 
52  void leversBall(int16 var);
53 
54  void tesla(int16 movie, int16 var, int16 move);
55 
56  void resonanceRingControl();
57  void resonanceRingsLaunchBall();
58  void resonanceRingsLights();
59 
60  void pinball(int16 var);
61  const PegCombination *_pinballFindCombination(uint16 var, const PegCombination pegs[], uint16 size);
62 
63  void weightDrag(uint16 var, uint16 movie);
64 
65  void journalSaavedro(int16 move);
66  int16 _journalSaavedroLastPageLastChapterValue();
67  uint16 _journalSaavedroGetNode(uint16 chapter);
68  uint16 _journalSaavedroPageCount(uint16 chapter);
69  bool _journalSaavedroHasChapter(uint16 chapter);
70  uint16 _journalSaavedroNextChapter(uint16 chapter, bool forward);
71 
72  void journalAtrus(uint16 node, uint16 var);
73  void mainMenu(uint16 action);
74  void projectorLoadBitmap(uint16 bitmap);
75  void projectorAddSpotItem(uint16 bitmap, uint16 x, uint16 y);
76  void projectorUpdateCoordinates();
77 
78  void symbolCodesInit(uint16 var, uint16 posX, uint16 posY);
79  void symbolCodesClick(int16 var);
80  bool _symbolCodesCheckSolution(uint16 var, const SymbolCodeSolution &solution);
81  int32 _symbolCodesFound();
82 
83  void railRoadSwitchs();
84 
85  void rollercoaster();
86 
87  void settingsSave();
88 
89  void updateSoundScriptTimer();
90 
91  void checkCanSave();
92 
93  void _drawForVarHelper(int16 var, int32 startValue, int32 endValue);
94  void _drawXTicks(uint16 ticks);
95 };
96 
97 } // End of namespace Myst3
98 
99 #endif // PUZZLES_H_
Definition: puzzles.h:33
Definition: ambient.h:27
Out move(In first, In last, Out dst)
Definition: algorithm.h:109
Definition: myst3.h:87