ScummVM API documentation
martian_resources.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 ACCESS_MARTIAN_RESOURCES_H
23 #define ACCESS_MARTIAN_RESOURCES_H
24 
25 #include "common/scummsys.h"
26 #include "access/resources.h"
27 #include "access/font.h"
28 
29 namespace Access {
30 
31 namespace Martian {
32 
33 extern const int SIDEOFFR[];
34 extern const int SIDEOFFL[];
35 extern const int SIDEOFFU[];
36 extern const int SIDEOFFD[];
37 
38 extern const int SIDEOFFR[];
39 extern const int SIDEOFFL[];
40 extern const int SIDEOFFU[];
41 extern const int SIDEOFFD[];
42 
43 extern const byte CREDIT_DATA[];
44 extern const byte ICON_PALETTE[];
45 
46 extern byte HELP[];
47 extern const char *const ASK_TBL[];
48 extern const char *const TRAVDATA[];
49 
50 extern const char *const SPEC7MESSAGE;
51 
52 extern const byte CAN_TRAVEL_MATRIX[];
53 extern const int16 PICTURE_RANGE[][2];
54 extern const int16 DUCT_ARROW_BUTTON_RANGE[][2];
55 
56 struct DuctMapPoint {
57  int16 ptType;
58  int16 shapeType;
59  int16 x;
60  int16 y;
61 };
62 
63 extern const DuctMapPoint DUCT_MAP_DATA[];
64 
65 
66 struct Point3 {
67  int16 x;
68  int16 y;
69  int16 z;
70 };
71 
72 struct DuctShape {
73  int16 numPts;
74  int16 array2Len;
75  const Point3 *points;
76  const uint16 *data;
77 };
78 
79 extern const DuctShape *DUCT_SHAPE_DATA[];
80 
81 class MartianResources : public Resources {
82 protected:
86  void load(Common::SeekableReadStream &s) override;
87 public:
88  MartianFont *_font1;
89  MartianFont *_font2;
90  MartianBitFont *_bitFont;
91 public:
92  MartianResources(AccessEngine *vm) : Resources(vm), _font1(nullptr), _font2(nullptr), _bitFont(nullptr) {}
93  ~MartianResources() override;
94 
95  const byte *getCursor(int num) const override;
96  const char *getEgoName() const override { return "TEX"; }
97  int getRMouse(int i, int j) const override;
98  int inButtonXRange(int x) const override;
99 };
100 
101 #define MMRES (*((Martian::MartianResources *)_vm->_res))
102 
103 } // End of namespace Martian
104 } // End of namespace Access
105 
106 #endif /* ACCESS_MARTIAN_RESOURCES_H */
Definition: font.h:120
Definition: resources.h:44
Definition: martian_resources.h:72
Definition: access.h:139
Definition: martian_resources.h:66
Definition: stream.h:745
Definition: font.h:135
const char * getEgoName() const override
Definition: martian_resources.h:96
Definition: martian_resources.h:81
Definition: martian_resources.h:56
Definition: access.h:62