[Scummvm-git-logs] scummvm master -> 661434fa362ae84feeb0b999e08ab899d16df640
AndywinXp
noreply at scummvm.org
Thu Jun 19 16:52:58 UTC 2025
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
661434fa36 LASTEXPRESS: Add InstallShield archive reader
Commit: 661434fa362ae84feeb0b999e08ab899d16df640
https://github.com/scummvm/scummvm/commit/661434fa362ae84feeb0b999e08ab899d16df640
Author: Torbjörn Andersson (eriktorbjorn at users.sourceforge.net)
Date: 2025-06-19T18:52:54+02:00
Commit Message:
LASTEXPRESS: Add InstallShield archive reader
The Interplay release of the game put HD.HPF in an InstallShield
archive. Allow the game to be played without unpacking that. This code
is largely adapted from the Nancy engine.
Changed paths:
engines/lastexpress/detection.cpp
engines/lastexpress/lastexpress.cpp
engines/lastexpress/lastexpress.h
engines/lastexpress/metaengine.cpp
diff --git a/engines/lastexpress/detection.cpp b/engines/lastexpress/detection.cpp
index 136513b2def..53ba46e8ec3 100644
--- a/engines/lastexpress/detection.cpp
+++ b/engines/lastexpress/detection.cpp
@@ -102,6 +102,23 @@ static const ADGameDescription gameDescriptions[] = {
GUIO2(GUIO_NOASPECT, GUIO_NOMIDI)
},
+ {
+ "lastexpress",
+ "Interplay Release",
+ {
+ {"CD1.HPF", 0, "8c86db47304033fcff32c69fddd5a920", 525522944},
+ {"CD2.HPF", 0, "58aa26e782d10ec5d2231e539d2fe6a2", 669581312},
+ {"CD3.HPF", 0, "00554fbf78a2ad391d98578fbbbe1c48", 641128448},
+ {"data1.cab", 0, "895ba6eec49346245e468553ba7a64fb", 42775756},
+ {"is:data1.cab:HD.HPF", 0, "A:bcc32d977f92bb52c060a0b4e8589cac", 30715904},
+ AD_LISTEND
+ },
+ Common::EN_ANY,
+ Common::kPlatformUnknown,
+ ADGF_TESTING | GF_COMPRESSED,
+ GUIO2(GUIO_NOASPECT, GUIO_NOMIDI)
+ },
+
// The Last Express (Demo - English) - Broderbund
// expressw.exe 1997-08-14 14:09:42
// express.exe 1997-08-14 14:19:34
diff --git a/engines/lastexpress/lastexpress.cpp b/engines/lastexpress/lastexpress.cpp
index ab72a5080a5..5ff5f58c77d 100644
--- a/engines/lastexpress/lastexpress.cpp
+++ b/engines/lastexpress/lastexpress.cpp
@@ -38,6 +38,7 @@
#include "common/error.h"
#include "common/fs.h"
#include "common/timer.h"
+#include "common/compression/installshield_cab.h"
#include "engines/util.h"
#include "engines/advancedDetector.h"
@@ -136,6 +137,14 @@ void LastExpressEngine::soundTimerHandler(void *refCon) {
}
Common::Error LastExpressEngine::run() {
+ // Allow HD.HPF to be read directly from the InstallShield archive
+ if (isCompressed()) {
+ Common::Archive *cabinet = Common::makeInstallShieldArchive("data");
+ if (cabinet) {
+ SearchMan.add("data1.cab", cabinet);
+ }
+ }
+
// Initialize the graphics
const Graphics::PixelFormat dataPixelFormat(2, 5, 6, 5, 0, 11, 5, 0, 0);
initGraphics(640, 480, &dataPixelFormat);
diff --git a/engines/lastexpress/lastexpress.h b/engines/lastexpress/lastexpress.h
index 878dd844199..97ed8be85a8 100644
--- a/engines/lastexpress/lastexpress.h
+++ b/engines/lastexpress/lastexpress.h
@@ -94,6 +94,10 @@ class VCR;
struct Extent;
+enum {
+ GF_COMPRESSED = 1 << 0
+};
+
typedef struct Item {
uint8 mnum;
uint16 closeUp;
@@ -551,6 +555,7 @@ public:
bool isDemo() const;
bool isGoldEdition() const;
+ bool isCompressed() const;
Common::String getTargetName() const;
diff --git a/engines/lastexpress/metaengine.cpp b/engines/lastexpress/metaengine.cpp
index 5e592e598bd..6689cab35d9 100644
--- a/engines/lastexpress/metaengine.cpp
+++ b/engines/lastexpress/metaengine.cpp
@@ -50,6 +50,10 @@ bool LastExpressEngine::isGoldEdition() const {
return (Common::String(_gameDescription->extra) == "Gold Edition");
}
+bool LastExpressEngine::isCompressed() const {
+ return (bool)(_gameDescription->flags & GF_COMPRESSED);
+}
+
bool LastExpressMetaEngine::hasFeature(MetaEngineFeature f) const {
return f == kSupportsListSaves
|| f == kSupportsDeleteSave;
More information about the Scummvm-git-logs
mailing list