aboutsummaryrefslogtreecommitdiff
path: root/engines/scumm/file.h
diff options
context:
space:
mode:
authorFilippos Karapetis2014-07-03 00:13:33 +0300
committerFilippos Karapetis2014-07-03 00:13:33 +0300
commit902a140f3e8058c582496296c7c1e0c55b243dda (patch)
tree3b29ba7b03b085eceec9267f575b02d06017361b /engines/scumm/file.h
parent5e78bee2f556466e090d7920b0983a23ea32b9f3 (diff)
downloadscummvm-rg350-902a140f3e8058c582496296c7c1e0c55b243dda.tar.gz
scummvm-rg350-902a140f3e8058c582496296c7c1e0c55b243dda.tar.bz2
scummvm-rg350-902a140f3e8058c582496296c7c1e0c55b243dda.zip
SCUMM: Add support for Steam versions of Indy 3, Indy 4, Loom and Dig
Many Thanks to Ben Castricum for the original patch
Diffstat (limited to 'engines/scumm/file.h')
-rw-r--r--engines/scumm/file.h28
1 files changed, 26 insertions, 2 deletions
diff --git a/engines/scumm/file.h b/engines/scumm/file.h
index d6dbc06ddc..f3eaac5d32 100644
--- a/engines/scumm/file.h
+++ b/engines/scumm/file.h
@@ -53,7 +53,7 @@ public:
};
class ScummFile : public BaseScummFile {
-private:
+protected:
int32 _subFileStart;
int32 _subFileLen;
bool _myEos; // Have we read past the end of the subfile?
@@ -64,7 +64,7 @@ private:
public:
ScummFile();
- bool open(const Common::String &filename);
+ virtual bool open(const Common::String &filename);
bool openSubFile(const Common::String &filename);
void clearErr() { _myEos = false; BaseScummFile::clearErr(); }
@@ -76,6 +76,18 @@ public:
uint32 read(void *dataPtr, uint32 dataSize);
};
+class ScummSteamFile : public ScummFile {
+private:
+ GameSettings _steamGame;
+
+ bool openWithSubRange(const Common::String &filename, int32 subFileStart, int32 subFileLen);
+
+public:
+ ScummSteamFile(GameSettings game) : ScummFile(), _steamGame(game) {}
+
+ bool open(const Common::String &filename);
+};
+
class ScummDiskImage : public BaseScummFile {
private:
Common::SeekableReadStream *_stream;
@@ -120,6 +132,18 @@ public:
uint32 read(void *dataPtr, uint32 dataSize);
};
+struct SteamIndexFile {
+ byte id;
+ Common::Platform platform;
+ const char *pattern;
+ const char *indexFileName;
+ const char *executableName;
+ int32 start;
+ int32 len;
+};
+
+extern const SteamIndexFile steamIndexFiles[];
+
} // End of namespace Scumm
#endif