diff options
author | Max Horn | 2005-04-03 15:06:08 +0000 |
---|---|---|
committer | Max Horn | 2005-04-03 15:06:08 +0000 |
commit | b507231f7135f0af2a27b047f1982685736e0e7b (patch) | |
tree | 433e1dca1aa39631e819bad11fd2a08aa0aa1dc8 /scumm/intern.h | |
parent | f63b35381b4b8e50cefb08103498dc195e38c29b (diff) | |
download | scummvm-rg350-b507231f7135f0af2a27b047f1982685736e0e7b.tar.gz scummvm-rg350-b507231f7135f0af2a27b047f1982685736e0e7b.tar.bz2 scummvm-rg350-b507231f7135f0af2a27b047f1982685736e0e7b.zip |
ScummEngine_v4 used to be a subclass of ScummEngine_v3, now it is the other way around; added a new class ScummEngine_v3old, for GF_OLD_BUNDLE games; took advantage of the new inheritance structure and turned various methods into virtual methods which then are overriden in subclasses
svn-id: r17346
Diffstat (limited to 'scumm/intern.h')
-rw-r--r-- | scumm/intern.h | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/scumm/intern.h b/scumm/intern.h index eb0a816e2d..944276c7ae 100644 --- a/scumm/intern.h +++ b/scumm/intern.h @@ -187,13 +187,14 @@ protected: void o5_walkActorToObject(); }; -class ScummEngine_v3 : public ScummEngine_v5 { +class ScummEngine_v4 : public ScummEngine_v5 { public: - ScummEngine_v3(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]) : ScummEngine_v5(detector, syst, gs, md5sum) {} + ScummEngine_v4(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]); protected: void readIndexFile(); void loadCharset(int no); + void loadRoomObjects(); void readMAXS(); void readGlobalObjects(); @@ -201,15 +202,25 @@ protected: void setupRoomObject(ObjectData *od, const byte *room, const byte *searchptr = NULL); }; -class ScummEngine_v4 : public ScummEngine_v3 { +class ScummEngine_v3 : public ScummEngine_v4 { public: - ScummEngine_v4(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]) : ScummEngine_v3(detector, syst, gs, md5sum) {} + ScummEngine_v3(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]); protected: void loadCharset(int no); }; -class ScummEngine_v2 : public ScummEngine_v3 { +class ScummEngine_v3old : public ScummEngine_v3 { +public: + ScummEngine_v3old(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]); + +protected: + void readIndexFile(); + void initRoomSubBlocks(); + void loadRoomObjects(); +}; + +class ScummEngine_v2 : public ScummEngine_v3old { protected: void readIndexFile(); void readClassicIndexFile(); // V1 @@ -226,7 +237,7 @@ protected: const OpcodeEntryV2 *_opcodesV2; public: - ScummEngine_v2(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]) : ScummEngine_v3(detector, syst, gs, md5sum) {} + ScummEngine_v2(GameDetector *detector, OSystem *syst, const ScummGameSettings &gs, uint8 md5sum[16]); virtual void scummInit(); |