aboutsummaryrefslogtreecommitdiff
path: root/engines/gob/gob.h
diff options
context:
space:
mode:
authorSven Hesse2007-07-24 23:24:40 +0000
committerSven Hesse2007-07-24 23:24:40 +0000
commit09c2ea82de295fab011bcddcc7c2bf0ba6dd72d7 (patch)
tree9115db53480da201ae3c124123a63ab6d8d28d80 /engines/gob/gob.h
parent38b282b31312b827dce14f64cbbd88b74783741c (diff)
downloadscummvm-rg350-09c2ea82de295fab011bcddcc7c2bf0ba6dd72d7.tar.gz
scummvm-rg350-09c2ea82de295fab011bcddcc7c2bf0ba6dd72d7.tar.bz2
scummvm-rg350-09c2ea82de295fab011bcddcc7c2bf0ba6dd72d7.zip
- Separated game type and features
- Added feature constants for a 640x480 resolution and adlib - Added support for game with a 640x480 resolution. Woodruff now inits the screen before it segfaults svn-id: r28185
Diffstat (limited to 'engines/gob/gob.h')
-rw-r--r--engines/gob/gob.h39
1 files changed, 31 insertions, 8 deletions
diff --git a/engines/gob/gob.h b/engines/gob/gob.h
index 97ee312bff..8c9583c95d 100644
--- a/engines/gob/gob.h
+++ b/engines/gob/gob.h
@@ -78,14 +78,22 @@ class Adlib;
#define VAR(var) READ_VAR_UINT32(var)
#define VAR_ADDRESS(var) ((uint32 *) VARP((var) << 2))
-enum {
- GF_GOB1 = 1 << 0,
- GF_GOB2 = 1 << 1,
- GF_GOB3 = 1 << 2,
- GF_WOODRUFF = 1 << 3,
- GF_BARGON = 1 << 4,
- GF_CD = 1 << 5,
- GF_EGA = 1 << 6
+enum GameType {
+ kGameTypeNone = 0,
+ kGameTypeGob1,
+ kGameTypeGob2,
+ kGameTypeGob3,
+ kGameTypeWoodruff,
+ kGameTypeBargon,
+ kGameTypeWeen
+};
+
+enum Features {
+ kFeaturesNone = 0,
+ kFeaturesCD = 1 << 0,
+ kFeaturesEGA = 1 << 1,
+ kFeaturesAdlib = 1 << 2,
+ kFeatures640 = 1 << 3
};
enum {
@@ -165,6 +173,9 @@ protected:
int go();
int init();
+ bool initGameParts();
+ void deinitGameParts();
+
bool detectGame();
public:
@@ -172,9 +183,15 @@ public:
Common::RandomSource _rnd;
+ GameType _gameType;
int32 _features;
Common::Language _language;
Common::Platform _platform;
+
+ uint16 _width;
+ uint16 _height;
+ uint8 _mode;
+
char *_startTot;
char *_startTot0;
bool _copyProtection;
@@ -211,6 +228,12 @@ public:
void validateLanguage();
void validateVideoMode(int16 videoMode);
+ GameType getGameType() { return _gameType; }
+ bool isCD() { return (_features & kFeaturesCD) != 0; }
+ bool isEGA() { return (_features & kFeaturesEGA) != 0; }
+ bool is640() { return (_features & kFeatures640) != 0; }
+ bool hasAdlib() { return (_features & kFeaturesAdlib) != 0; }
+
GobEngine(OSystem *syst);
virtual ~GobEngine();
};