[Scummvm-git-logs] scummvm master -> cc4b55224fa34f64de322a1a997f2aca2375664a
neuromancer
noreply at scummvm.org
Wed Jun 18 21:05:00 UTC 2025
This automated email contains information about 6 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
e74f29129c FREESCAPE: better handling of global entrances in eclipse
7107ecdc32 FREESCAPE: fixes for eclipse 2
1a9e193cb5 FREESCAPE: added basic support for c64 release of eclipse 2
efc2e211dc FREESCAPE: added another detection entry for eclipse
670ff871b6 FREESCAPE: refactored some loading data code
cc4b55224f FREESCAPE: lock/hide mouse after reading data
Commit: e74f29129c404c2c179669b71ad65090bf91cf1b
https://github.com/scummvm/scummvm/commit/e74f29129c404c2c179669b71ad65090bf91cf1b
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: better handling of global entrances in eclipse
Changed paths:
engines/freescape/area.cpp
engines/freescape/area.h
engines/freescape/games/eclipse/atari.cpp
engines/freescape/games/eclipse/c64.cpp
engines/freescape/games/eclipse/cpc.cpp
engines/freescape/games/eclipse/dos.cpp
engines/freescape/games/eclipse/eclipse.cpp
engines/freescape/games/eclipse/zx.cpp
diff --git a/engines/freescape/area.cpp b/engines/freescape/area.cpp
index 1f0e81736ff..4473342476d 100644
--- a/engines/freescape/area.cpp
+++ b/engines/freescape/area.cpp
@@ -577,6 +577,14 @@ void Area::removeObject(int16 id) {
_addedObjects.erase(id);
}
+Common::List<int> Area::getEntranceIds() {
+ Common::List<int> ids;
+ for (auto &it : *_entrancesByID) {
+ ids.push_back(it._key);
+ }
+ return ids;
+}
+
void Area::addObjectFromArea(int16 id, Area *global) {
debugC(1, kFreescapeDebugParser, "Adding object %d to room structure in area %d", id, _areaID);
Object *obj = global->objectWithID(id);
diff --git a/engines/freescape/area.h b/engines/freescape/area.h
index fea9e2907d0..fbb1397f93d 100644
--- a/engines/freescape/area.h
+++ b/engines/freescape/area.h
@@ -45,6 +45,8 @@ public:
Common::String _name;
Object *objectWithID(uint16 objectID);
Object *entranceWithID(uint16 objectID);
+ Common::List<int> getEntranceIds();
+
void changeObjectID(uint16 objectID, uint16 newObjectID);
ObjectArray getSensors();
uint16 getAreaID();
diff --git a/engines/freescape/games/eclipse/atari.cpp b/engines/freescape/games/eclipse/atari.cpp
index d33c8985076..67af6cdf4ca 100644
--- a/engines/freescape/games/eclipse/atari.cpp
+++ b/engines/freescape/games/eclipse/atari.cpp
@@ -174,12 +174,6 @@ void EclipseEngine::loadAssetsAtariFullGame() {
loadPalettes(stream, 0x2a0fa);
loadSoundsFx(stream, 0x3030c, 6);
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
-
/*
loadFonts(stream, 0xd06b, _fontBig);
loadFonts(stream, 0xd49a, _fontMedium);
diff --git a/engines/freescape/games/eclipse/c64.cpp b/engines/freescape/games/eclipse/c64.cpp
index 01c86adddcc..69da680f85e 100644
--- a/engines/freescape/games/eclipse/c64.cpp
+++ b/engines/freescape/games/eclipse/c64.cpp
@@ -57,13 +57,6 @@ void EclipseEngine::loadAssetsC64FullGame() {
} else
error("Unknown C64 variant %x", _variant);
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
-
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
-
Graphics::Surface *surf = loadBundledImage("eclipse_border");
surf->convertToInPlace(_gfx->_texturePixelFormat);
_border = new Graphics::ManagedSurface();
diff --git a/engines/freescape/games/eclipse/cpc.cpp b/engines/freescape/games/eclipse/cpc.cpp
index 0e4b88d9f70..d2e41a2581a 100644
--- a/engines/freescape/games/eclipse/cpc.cpp
+++ b/engines/freescape/games/eclipse/cpc.cpp
@@ -94,18 +94,6 @@ void EclipseEngine::loadAssetsCPCFullGame() {
load8bitBinary(&file, 0x626e, 16);
}
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
-
- if (isEclipse2() && it._value->getAreaID() == 1)
- continue;
-
- if (isEclipse2() && it._value->getAreaID() == _startArea)
- continue;
-
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
loadColorPalette();
swapPalette(1);
@@ -135,12 +123,6 @@ void EclipseEngine::loadAssetsCPCDemo() {
loadMessagesFixedSize(&file, 0x362, 16, 23);
loadMessagesFixedSize(&file, 0x570b, 264, 5);
load8bitBinary(&file, 0x65c6, 16);
- for (auto &it : _areaMap) {
- it._value->_name = " NOW TRAINING ";
- it._value->addStructure(_areaMap[255]);
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
loadColorPalette();
swapPalette(1);
diff --git a/engines/freescape/games/eclipse/dos.cpp b/engines/freescape/games/eclipse/dos.cpp
index b1d58391e2e..2b5b549f036 100644
--- a/engines/freescape/games/eclipse/dos.cpp
+++ b/engines/freescape/games/eclipse/dos.cpp
@@ -56,11 +56,7 @@ void EclipseEngine::loadAssetsDOSFullGame() {
loadSpeakerFxDOS(&file, 0x7396 + 0x200, 0x72a1 + 0x200);
loadFonts(&file, 0xd403);
load8bitBinary(&file, 0x3ce0, 16);
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
+
_border = load8bitBinImage(&file, 0x210);
_border->setPalette((byte *)&kEGADefaultPalette, 0, 16);
@@ -85,11 +81,6 @@ void EclipseEngine::loadAssetsDOSFullGame() {
loadSoundsFx(&file, 0xb9f0, 5);
loadFonts(&file, 0xb785);
load8bitBinary(&file, 0x2530, 4);
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
_border = load8bitBinImage(&file, 0x210);
_border->setPalette((byte *)&kCGAPaletteRedGreen, 0, 4);
swapPalette(_startArea);
diff --git a/engines/freescape/games/eclipse/eclipse.cpp b/engines/freescape/games/eclipse/eclipse.cpp
index 13af15f9875..7c3a5277d09 100644
--- a/engines/freescape/games/eclipse/eclipse.cpp
+++ b/engines/freescape/games/eclipse/eclipse.cpp
@@ -113,6 +113,29 @@ void EclipseEngine::initGameState() {
void EclipseEngine::loadAssets() {
FreescapeEngine::loadAssets();
+ Common::List<int> globalIds = _areaMap[255]->getEntranceIds();
+ for (auto &it : _areaMap) {
+ if (it._value->getAreaID() == 255)
+ continue;
+
+ it._value->addStructure(_areaMap[255]);
+
+ if (isDemo()) {
+ it._value->_name = " NOW TRAINING ";
+ }
+
+ for (auto &id : globalIds) {
+ if (it._value->entranceWithID(id))
+ continue;
+
+ Object *obj = _areaMap[255]->entranceWithID(id);
+ assert(obj);
+ assert(obj->getType() == ObjectType::kEntranceType);
+ // The entrance is not in the current area, so we need to add it
+ it._value->addObjectFromArea(id, _areaMap[255]);
+ }
+ }
+
_timeoutMessage = _messagesList[1];
_noShieldMessage = _messagesList[0];
//_noEnergyMessage = _messagesList[16];
diff --git a/engines/freescape/games/eclipse/zx.cpp b/engines/freescape/games/eclipse/zx.cpp
index 57b5e8b6674..dd4c49228d8 100644
--- a/engines/freescape/games/eclipse/zx.cpp
+++ b/engines/freescape/games/eclipse/zx.cpp
@@ -89,19 +89,6 @@ void EclipseEngine::loadAssetsZXFullGame() {
_areaMap[42]->_underFireBackgroundColor = 0;
}
- for (auto &it : _areaMap) {
- it._value->addStructure(_areaMap[255]);
-
- if (isEclipse2() && it._value->getAreaID() == 1)
- continue;
-
- if (isEclipse2() && it._value->getAreaID() == _startArea)
- continue;
-
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
-
_indicators.push_back(loadBundledImage("eclipse_ankh_indicator"));
for (auto &it : _indicators)
@@ -144,13 +131,6 @@ void EclipseEngine::loadAssetsZXDemo() {
} else
error("Unknown ZX Spectrum demo variant");
- for (auto &it : _areaMap) {
- it._value->_name = " NOW TRAINING ";
- it._value->addStructure(_areaMap[255]);
- for (int16 id = 183; id < 207; id++)
- it._value->addObjectFromArea(id, _areaMap[255]);
- }
-
_indicators.push_back(loadBundledImage("eclipse_ankh_indicator"));
for (auto &it : _indicators)
Commit: 7107ecdc32619b14e3e7118f2d3d8c97c96e59b1
https://github.com/scummvm/scummvm/commit/7107ecdc32619b14e3e7118f2d3d8c97c96e59b1
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: fixes for eclipse 2
Changed paths:
engines/freescape/games/eclipse/eclipse.cpp
engines/freescape/language/instruction.cpp
diff --git a/engines/freescape/games/eclipse/eclipse.cpp b/engines/freescape/games/eclipse/eclipse.cpp
index 7c3a5277d09..17274faec67 100644
--- a/engines/freescape/games/eclipse/eclipse.cpp
+++ b/engines/freescape/games/eclipse/eclipse.cpp
@@ -310,6 +310,7 @@ void EclipseEngine::gotoArea(uint16 areaID, int entranceID) {
playSound(_soundIndexStart, true);
if (isEclipse2()) {
_gameStateControl = kFreescapeGameStateStart;
+ _pitch = -10;
}
} if (areaID == _endArea && entranceID == _endEntrance) {
diff --git a/engines/freescape/language/instruction.cpp b/engines/freescape/language/instruction.cpp
index 477d6525d48..e46598bdffa 100644
--- a/engines/freescape/language/instruction.cpp
+++ b/engines/freescape/language/instruction.cpp
@@ -327,7 +327,11 @@ bool FreescapeEngine::executeCode(FCLInstructionVector &code, bool shot, bool co
void FreescapeEngine::executeRedraw(FCLInstruction &instruction) {
debugC(1, kFreescapeDebugCode, "Redrawing screen");
- waitInLoop((100 / 15) + 1);
+ uint32 delay = (100 / 15) + 1;
+ if (isEclipse2() && _currentArea->getAreaID() == _startArea && _gameStateControl == kFreescapeGameStateStart)
+ delay = delay * 10;
+
+ waitInLoop(delay);
if (_syncSound) {
waitForSounds();
}
Commit: 1a9e193cb57c263ed7f8155b6a56291b71dd82d5
https://github.com/scummvm/scummvm/commit/1a9e193cb57c263ed7f8155b6a56291b71dd82d5
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: added basic support for c64 release of eclipse 2
Changed paths:
engines/freescape/detection.cpp
engines/freescape/doodle.cpp
engines/freescape/games/eclipse/c64.cpp
engines/freescape/games/eclipse/eclipse.cpp
engines/freescape/games/eclipse/eclipse.h
engines/freescape/loaders/8bitBinaryLoader.cpp
engines/freescape/movement.cpp
diff --git a/engines/freescape/detection.cpp b/engines/freescape/detection.cpp
index db3dfb6d966..a374f72d328 100644
--- a/engines/freescape/detection.cpp
+++ b/engines/freescape/detection.cpp
@@ -660,6 +660,24 @@ static const ADGameDescription gameDescriptions[] = {
ADGF_NO_FLAGS,
GUIO2(GUIO_NOMIDI, GUIO_RENDERCPC)
},
+ {
+ "totaleclipse2", // Tape release
+ "",
+ AD_ENTRY1s("TOTALECLIPSE2.C64.DATA", "7ab839a4260c197f24b41ef6ab45ef21", 47105),
+ Common::EN_ANY,
+ Common::kPlatformC64,
+ ADGF_UNSTABLE | GF_C64_TAPE,
+ GUIO2(GUIO_NOMIDI, GUIO_RENDERC64)
+ },
+ {
+ "totaleclipse2", // Disk release
+ "",
+ AD_ENTRY1s("TOTALECLIPSE2.C64.DATA", "b1f59bee6a6e1eec6bb2dbbe0bee0e93", 50372),
+ Common::EN_ANY,
+ Common::kPlatformC64,
+ ADGF_UNSTABLE | GF_C64_DISC,
+ GUIO2(GUIO_NOMIDI, GUIO_RENDERC64)
+ },
{
"totaleclipse",
"",
@@ -699,7 +717,7 @@ static const ADGameDescription gameDescriptions[] = {
AD_ENTRY1s("TOTALECLIPSE.C64.DATA", "968fd46b941a00f887741dfc348ac149", 47105),
Common::EN_ANY,
Common::kPlatformC64,
- ADGF_UNSTABLE,
+ ADGF_UNSTABLE | GF_C64_TAPE,
GUIO2(GUIO_NOMIDI, GUIO_RENDERC64)
},
{
diff --git a/engines/freescape/doodle.cpp b/engines/freescape/doodle.cpp
index 0d06cae6c5a..2f5e2864a7b 100644
--- a/engines/freescape/doodle.cpp
+++ b/engines/freescape/doodle.cpp
@@ -39,7 +39,7 @@ bool DoodleDecoder::loadStreams(Common::SeekableReadStream &highresStream,
return false;
}
- if (colorStream1.size() < 1003 || colorStream2.size() < 1003) {
+ if (colorStream1.size() < 1002 || colorStream2.size() < 1002) {
error("DoodleDecoder: Invalid color data size");
return false;
}
diff --git a/engines/freescape/games/eclipse/c64.cpp b/engines/freescape/games/eclipse/c64.cpp
index 69da680f85e..bc1e8a74f5b 100644
--- a/engines/freescape/games/eclipse/c64.cpp
+++ b/engines/freescape/games/eclipse/c64.cpp
@@ -35,7 +35,7 @@ extern byte kC64Palette[16][3];
void EclipseEngine::loadAssetsC64FullGame() {
Common::File file;
- file.open("totaleclipse.c64.data");
+ file.open(isEclipse2() ? "totaleclipse2.c64.data" : "totaleclipse.c64.data");
if (_variant & GF_C64_TAPE) {
int size = file.size();
@@ -43,17 +43,20 @@ void EclipseEngine::loadAssetsC64FullGame() {
byte *buffer = (byte *)malloc(size * sizeof(byte));
file.read(buffer, file.size());
- _extraBuffer = decompressC64RLE(buffer, &size, 0xe1);
+ _extraBuffer = decompressC64RLE(buffer, &size, isEclipse2() ? 0xd2 : 0xe1);
// size should be the size of the decompressed data
Common::MemoryReadStream dfile(_extraBuffer, size, DisposeAfterUse::NO);
- loadMessagesFixedSize(&dfile, 0x1d82, 16, 30);
+ loadMessagesFixedSize(&dfile, 0x1d84, 16, 30);
loadFonts(&dfile, 0xc3e);
load8bitBinary(&dfile, 0x9a3e, 16);
} else if (_variant & GF_C64_DISC) {
- loadMessagesFixedSize(&file,0x1536, 16, 30);
+ loadMessagesFixedSize(&file, 0x1534, 16, 30);
loadFonts(&file, 0x3f2);
- load8bitBinary(&file, 0x7ab4, 16);
+ if (isEclipse2())
+ load8bitBinary(&file, 0x7ac4, 16);
+ else
+ load8bitBinary(&file, 0x7ab4, 16);
} else
error("Unknown C64 variant %x", _variant);
@@ -65,12 +68,12 @@ void EclipseEngine::loadAssetsC64FullGame() {
delete surf;
file.close();
- file.open("totaleclipse.c64.title.bitmap");
+ file.open(isEclipse2() ? "totaleclipse2.c64.title.bitmap" : "totaleclipse.c64.title.bitmap");
Common::File colorFile1;
- colorFile1.open("totaleclipse.c64.title.colors1");
+ colorFile1.open(isEclipse2() ? "totaleclipse2.c64.title.colors1" : "totaleclipse.c64.title.colors1");
Common::File colorFile2;
- colorFile2.open("totaleclipse.c64.title.colors2");
+ colorFile2.open(isEclipse2() ? "totaleclipse2.c64.title.colors2" : "totaleclipse.c64.title.colors2");
_title = loadAndConvertDoodleImage(&file, &colorFile1, &colorFile2, (byte *)&kC64Palette);
diff --git a/engines/freescape/games/eclipse/eclipse.cpp b/engines/freescape/games/eclipse/eclipse.cpp
index 17274faec67..296f4e5b02b 100644
--- a/engines/freescape/games/eclipse/eclipse.cpp
+++ b/engines/freescape/games/eclipse/eclipse.cpp
@@ -92,6 +92,7 @@ EclipseEngine::EclipseEngine(OSystem *syst, const ADGameDescription *gd) : Frees
_endEntrance = 33;
_lastThirtySeconds = 0;
+ _lastFiveSeconds = 0;
_lastSecond = -1;
_resting = false;
}
@@ -107,6 +108,7 @@ void EclipseEngine::initGameState() {
int seconds, minutes, hours;
getTimeFromCountdown(seconds, minutes, hours);
_lastThirtySeconds = seconds / 30;
+ _lastFiveSeconds = seconds / 5;
_resting = false;
}
@@ -752,6 +754,13 @@ void EclipseEngine::updateTimeVariables() {
// This function only executes "on collision" room/global conditions
int seconds, minutes, hours;
getTimeFromCountdown(seconds, minutes, hours);
+
+
+ if (_lastFiveSeconds != seconds / 5) {
+ _lastFiveSeconds = seconds / 5;
+ executeLocalGlobalConditions(false, false, true);
+ }
+
if (_lastThirtySeconds != seconds / 30) {
_lastThirtySeconds = seconds / 30;
@@ -762,8 +771,6 @@ void EclipseEngine::updateTimeVariables() {
if (_gameStateVars[k8bitVariableShield] < _maxShield) {
_gameStateVars[k8bitVariableShield] += 1;
}
-
- executeLocalGlobalConditions(false, false, true);
}
if (isEclipse() && isSpectrum() && _currentArea->getAreaID() == 42) {
diff --git a/engines/freescape/games/eclipse/eclipse.h b/engines/freescape/games/eclipse/eclipse.h
index b5bc09f429c..795cb57dd07 100644
--- a/engines/freescape/games/eclipse/eclipse.h
+++ b/engines/freescape/games/eclipse/eclipse.h
@@ -60,6 +60,8 @@ public:
bool _resting;
int _lastThirtySeconds;
+ int _lastFiveSeconds;
+
int _lastSecond;
void updateTimeVariables() override;
diff --git a/engines/freescape/loaders/8bitBinaryLoader.cpp b/engines/freescape/loaders/8bitBinaryLoader.cpp
index 6364fe2188b..50da03c84f6 100644
--- a/engines/freescape/loaders/8bitBinaryLoader.cpp
+++ b/engines/freescape/loaders/8bitBinaryLoader.cpp
@@ -601,7 +601,20 @@ static const char *eclipseRoomName[] = {
"PHARAOHS",
" SHABAKA",
"ILLUSION",
- "????????"};
+ "????????"
+};
+
+static const char *eclipse2RoomName[] = {
+ "\" SAHARA",
+ "ENTRANCE",
+ "\" SPHINX",
+ "\"SELQUET",
+ "\" OSIRIS",
+ "\" THEBES",
+ "\" BEHBET",
+ "\"'l JINX",
+ "GAME OVER",
+};
Area *FreescapeEngine::load8bitArea(Common::SeekableReadStream *file, uint16 ncolors) {
@@ -665,7 +678,11 @@ Area *FreescapeEngine::load8bitArea(Common::SeekableReadStream *file, uint16 nco
uint8 extraColor[4] = {};
if (isEclipse()) {
byte idx = readField(file, 8);
- name = idx < 8 ? eclipseRoomName[idx] : eclipseRoomName[8];
+ if (isEclipse2()) {
+ name = idx < 8 ? eclipse2RoomName[idx] : eclipse2RoomName[8];
+ } else
+ name = idx < 8 ? eclipseRoomName[idx] : eclipseRoomName[8];
+
name = name + "-" + char(readField(file, 8)) + " ";
int i = 0;
diff --git a/engines/freescape/movement.cpp b/engines/freescape/movement.cpp
index 6936c395241..1b330642507 100644
--- a/engines/freescape/movement.cpp
+++ b/engines/freescape/movement.cpp
@@ -458,10 +458,12 @@ void FreescapeEngine::resolveCollisions(Math::Vector3d const position) {
if (fallen > _maxFallingDistance) {
_hasFallen = !_disableFalling;
- _roll = -90;
- _pitch = 0;
- _yaw = 0;
- changePlayerHeight(0);
+ if (isDriller() || isDark()) {
+ _roll = -90;
+ _pitch = 0;
+ _yaw = 0;
+ changePlayerHeight(0);
+ }
_avoidRenderingFrames = 60 * 3;
_endGameDelayTicks = 60 * 5;
if (isEclipse()) // No need for an variable index, since these are special types of sound
Commit: efc2e211dc6a892ecfbc8bb2961d2c71183a2434
https://github.com/scummvm/scummvm/commit/efc2e211dc6a892ecfbc8bb2961d2c71183a2434
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: added another detection entry for eclipse
Changed paths:
engines/freescape/detection.cpp
diff --git a/engines/freescape/detection.cpp b/engines/freescape/detection.cpp
index a374f72d328..47b1dc77e59 100644
--- a/engines/freescape/detection.cpp
+++ b/engines/freescape/detection.cpp
@@ -678,6 +678,15 @@ static const ADGameDescription gameDescriptions[] = {
ADGF_UNSTABLE | GF_C64_DISC,
GUIO2(GUIO_NOMIDI, GUIO_RENDERC64)
},
+ {
+ "totaleclipse2", // Commodore Format #18
+ "",
+ AD_ENTRY1s("TOTALECLIPSE2.C64.DATA", "6d0ce2c971f7f1fee36bf0851f19721b", 63490),
+ Common::EN_ANY,
+ Common::kPlatformC64,
+ ADGF_UNSUPPORTED | GF_C64_DISC,
+ GUIO2(GUIO_NOMIDI, GUIO_RENDERC64)
+ },
{
"totaleclipse",
"",
Commit: 670ff871b60c1d60e8cb8a242a216fed98b04c0b
https://github.com/scummvm/scummvm/commit/670ff871b60c1d60e8cb8a242a216fed98b04c0b
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: refactored some loading data code
Changed paths:
engines/freescape/games/driller/amiga.cpp
engines/freescape/games/driller/atari.cpp
engines/freescape/games/driller/c64.cpp
engines/freescape/games/driller/dos.cpp
engines/freescape/loaders/8bitBinaryLoader.cpp
engines/freescape/sound.cpp
diff --git a/engines/freescape/games/driller/amiga.cpp b/engines/freescape/games/driller/amiga.cpp
index 14daf539e1b..ad371ae79b8 100644
--- a/engines/freescape/games/driller/amiga.cpp
+++ b/engines/freescape/games/driller/amiga.cpp
@@ -100,14 +100,6 @@ void DrillerEngine::loadAssetsAmigaDemo() {
loadDemoData(&file, 0, 0x1000);
- file.close();
- file.open("data");
- if (!file.isOpen())
- error("Failed to open 'data' file");
-
- load8bitBinary(&file, 0x442, 16);
- loadPalettes(&file, 0x0);
-
file.close();
file.open("driller");
if (!file.isOpen())
@@ -124,6 +116,14 @@ void DrillerEngine::loadAssetsAmigaDemo() {
loadGlobalObjects(&file, 0x3716, 8);
}
+ file.close();
+ file.open("data");
+ if (!file.isOpen())
+ error("Failed to open 'data' file");
+
+ load8bitBinary(&file, 0x442, 16);
+ loadPalettes(&file, 0x0);
+
file.close();
file.open("soundfx");
if (!file.isOpen())
diff --git a/engines/freescape/games/driller/atari.cpp b/engines/freescape/games/driller/atari.cpp
index ed80ca75654..d4e49ccc99a 100644
--- a/engines/freescape/games/driller/atari.cpp
+++ b/engines/freescape/games/driller/atari.cpp
@@ -134,15 +134,6 @@ void DrillerEngine::loadAssetsAtariDemo() {
loadDemoData(&file, 0, 0x1000);
- file.close();
- file.open("data");
-
- if (!file.isOpen())
- error("Failed to open 'data' file");
-
- load8bitBinary(&file, 0x442, 16);
- loadPalettes(&file, 0x0);
-
file.close();
if (_variant & GF_ATARI_MAGAZINE_DEMO) {
file.open("auto_x.prg");
@@ -165,6 +156,15 @@ void DrillerEngine::loadAssetsAtariDemo() {
loadGlobalObjects(&file, 0x3946, 8);
}
+ file.close();
+ file.open("data");
+
+ if (!file.isOpen())
+ error("Failed to open 'data' file");
+
+ load8bitBinary(&file, 0x442, 16);
+ loadPalettes(&file, 0x0);
+
file.close();
file.open("soundfx");
if (!file.isOpen())
diff --git a/engines/freescape/games/driller/c64.cpp b/engines/freescape/games/driller/c64.cpp
index 853f6f4f16d..4209f028e1e 100644
--- a/engines/freescape/games/driller/c64.cpp
+++ b/engines/freescape/games/driller/c64.cpp
@@ -45,10 +45,10 @@ void DrillerEngine::loadAssetsC64FullGame() {
file.open("driller.c64.data");
if (_variant) {
- loadFonts(&file, 0x402);
- load8bitBinary(&file, 0x8b04, 16);
loadMessagesFixedSize(&file, 0x167a, 14, 20);
loadGlobalObjects(&file, 0x1855, 8);
+ loadFonts(&file, 0x402);
+ load8bitBinary(&file, 0x8b04, 16);
/*} else if (_variant & GF_C64_BUDGET) {
//loadFonts(&file, 0x402);
load8bitBinary(&file, 0x7df7, 16);
diff --git a/engines/freescape/games/driller/dos.cpp b/engines/freescape/games/driller/dos.cpp
index e743a5be8ce..0f4a128118c 100644
--- a/engines/freescape/games/driller/dos.cpp
+++ b/engines/freescape/games/driller/dos.cpp
@@ -245,8 +245,8 @@ void DrillerEngine::loadAssetsDOSFullGame() {
loadFonts(&file, 0x07a4a);
loadMessagesFixedSize(&file, 0x2585, 14, 20);
- load8bitBinary(&file, 0x7bb0, 4);
loadGlobalObjects(&file, 0x1fa2, 8);
+ load8bitBinary(&file, 0x7bb0, 4);
_border = load8bitBinImage(&file, 0x210);
_border->setPalette((byte*)&kCGAPalettePinkBlueWhiteData, 0, 4);
swapPalette(1);
@@ -301,8 +301,8 @@ void DrillerEngine::loadAssetsDOSDemo() {
loadFonts(&file, 0x4eb0);
loadMessagesFixedSize(&file, 0x636, 14, 20);
- load8bitBinary(&file, 0x55b0, 4);
loadGlobalObjects(&file, 0x53, 8);
+ load8bitBinary(&file, 0x55b0, 4);
_border = load8bitDemoImage(&file, 0x6220);
_border->setPalette((byte*)&kCGAPalettePinkBlueWhiteData, 0, 4);
diff --git a/engines/freescape/loaders/8bitBinaryLoader.cpp b/engines/freescape/loaders/8bitBinaryLoader.cpp
index 50da03c84f6..33033fdebbb 100644
--- a/engines/freescape/loaders/8bitBinaryLoader.cpp
+++ b/engines/freescape/loaders/8bitBinaryLoader.cpp
@@ -1100,6 +1100,7 @@ void FreescapeEngine::loadMessagesVariableSize(Common::SeekableReadStream *file,
}
void FreescapeEngine::loadGlobalObjects(Common::SeekableReadStream *file, int offset, int size) {
+ debugC(1, kFreescapeDebugParser, "Loading global objects");
assert(!_areaMap.contains(255));
ObjectMap *globalObjectsByID = new ObjectMap;
file->seek(offset);
diff --git a/engines/freescape/sound.cpp b/engines/freescape/sound.cpp
index 37fa398f6f6..e10381fb3d4 100644
--- a/engines/freescape/sound.cpp
+++ b/engines/freescape/sound.cpp
@@ -29,6 +29,7 @@
namespace Freescape {
void FreescapeEngine::loadSpeakerFxZX(Common::SeekableReadStream *file, int sfxTable, int sfxData) {
+ debugC(1, kFreescapeDebugParser, "Reading sound table for ZX");
int numberSounds = 25;
if (isDark())
@@ -231,6 +232,7 @@ void FreescapeEngine::loadSpeakerFxZX(Common::SeekableReadStream *file, int sfxT
}
void FreescapeEngine::loadSpeakerFxDOS(Common::SeekableReadStream *file, int offsetFreq, int offsetTable) {
+ debugC(1, kFreescapeDebugParser, "Reading PC speaker sound table for DOS");
for (int i = 1; i < 20; i++) {
debugC(1, kFreescapeDebugParser, "Reading sound table entry: %d ", i);
int soundIdx = (i - 1) * 4;
Commit: cc4b55224fa34f64de322a1a997f2aca2375664a
https://github.com/scummvm/scummvm/commit/cc4b55224fa34f64de322a1a997f2aca2375664a
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2025-06-18T23:07:19+02:00
Commit Message:
FREESCAPE: lock/hide mouse after reading data
Changed paths:
engines/freescape/freescape.cpp
diff --git a/engines/freescape/freescape.cpp b/engines/freescape/freescape.cpp
index ff980fa973d..e9417ac488d 100644
--- a/engines/freescape/freescape.cpp
+++ b/engines/freescape/freescape.cpp
@@ -747,8 +747,13 @@ Common::Error FreescapeEngine::run() {
initGameState();
loadColorPalette();
- g_system->showMouse(true);
- g_system->lockMouse(false);
+ if (g_system->getFeatureState(OSystem::kFeatureTouchscreen)) {
+ g_system->showMouse(true);
+ g_system->lockMouse(false);
+ } else {
+ g_system->showMouse(false);
+ g_system->lockMouse(true);
+ }
// Simple main event loop
int saveSlot = ConfMan.getInt("save_slot");
More information about the Scummvm-git-logs
mailing list