diff options
author | Joost Peters | 2003-09-28 15:50:47 +0000 |
---|---|---|
committer | Joost Peters | 2003-09-28 15:50:47 +0000 |
commit | 82fd31618780ce449f1d2ca3794827b4448ca9f3 (patch) | |
tree | 9413816d7e3e31f641354562f5eddf7b2b476343 /queen/resource.h | |
parent | 2d3e97049629c48494ea8d4641e57e699e6a8498 (diff) | |
download | scummvm-rg350-82fd31618780ce449f1d2ca3794827b4448ca9f3.tar.gz scummvm-rg350-82fd31618780ce449f1d2ca3794827b4448ca9f3.tar.bz2 scummvm-rg350-82fd31618780ce449f1d2ca3794827b4448ca9f3.zip |
queen initial import
svn-id: r10462
Diffstat (limited to 'queen/resource.h')
-rw-r--r-- | queen/resource.h | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/queen/resource.h b/queen/resource.h new file mode 100644 index 0000000000..b36d0ad6ef --- /dev/null +++ b/queen/resource.h @@ -0,0 +1,69 @@ +/* ScummVM - Scumm Interpreter + * Copyright (C) 2003 The ScummVM project + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * $Header$ + * + */ + +#ifndef QUEENRESOURCE_H +#define QUEENRESOURCE_H + +#include "common/file.h" + +struct ResourceEntry { + char filename[13]; + uint8 inBundle; + uint32 offset; + uint32 size; +}; + +struct GameVersion { + char versionString[6]; + uint32 resourceEntries; + bool isFloppy; + bool isDemo; + const struct ResourceEntry *resourceTable; +}; + +class QueenResource { + +public: + QueenResource(char *datafilePath); + ~QueenResource(void); + uint8 *loadJAS(); + +protected: + File *_resourceFile; + char *_datafilePath; + const struct GameVersion *_gameVersion; + static const struct GameVersion _gameVersionPE100v1; + static const struct GameVersion _gameVersionPE100v2; + static const struct GameVersion _gameVersionPEM10; + static const struct GameVersion _gameVersionCEM10; + static const struct ResourceEntry _resourceTablePE100v1[]; + static const struct ResourceEntry _resourceTablePE100v2[]; + static const struct ResourceEntry _resourceTablePEM10[]; + static const struct ResourceEntry _resourceTableCEM10[]; + + int32 resourceIndex(const char *filename); + uint32 fileSize(const char *filename); + uint32 fileOffset(const char *filename); + const char *JASVersion(); +}; + +#endif + |