[Scummvm-git-logs] scummvm master -> 19ac3bfcf2b743cd7533c42f04df8bc8a3e2c8dc
neuromancer
noreply at scummvm.org
Fri Jun 12 16:03:11 UTC 2026
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .
Summary:
0c1eb71a69 SCUMM: RA2: do not preserve explosion animations after game over/restart
19ac3bfcf2 FREESCAPE: correctly parsed/executed SWAPJET in Amiga/Atari
Commit: 0c1eb71a699699498092303788bc8c48d773089c
https://github.com/scummvm/scummvm/commit/0c1eb71a699699498092303788bc8c48d773089c
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2026-06-12T14:18:20+02:00
Commit Message:
SCUMM: RA2: do not preserve explosion animations after game over/restart
Changed paths:
engines/scumm/insane/rebel2/rebel.h
engines/scumm/insane/rebel2/runlevels.cpp
diff --git a/engines/scumm/insane/rebel2/rebel.h b/engines/scumm/insane/rebel2/rebel.h
index 24810696bf1..ee2924471fa 100644
--- a/engines/scumm/insane/rebel2/rebel.h
+++ b/engines/scumm/insane/rebel2/rebel.h
@@ -435,6 +435,7 @@ public:
void resetLevelPhaseState(bool clearEnemies);
void clearEmbeddedHudFrames();
void resetLevelWaveState();
+ void resetExplosions();
void resetHandler7FlightState();
// Random number helper (emulates FUN_004233a0)
diff --git a/engines/scumm/insane/rebel2/runlevels.cpp b/engines/scumm/insane/rebel2/runlevels.cpp
index b0e9a677f18..09a450264a7 100644
--- a/engines/scumm/insane/rebel2/runlevels.cpp
+++ b/engines/scumm/insane/rebel2/runlevels.cpp
@@ -46,6 +46,7 @@ int InsaneRebel2::runLevel1() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
// Reset bit table before gameplay starts - FUN_00423880 calls FUN_00423a00(0)
// This ensures all enemies are visible (not skipped by SKIP chunks)
@@ -280,6 +281,7 @@ void InsaneRebel2::resetLevelAttemptState(int initialPhase) {
_rebelAutopilot = 0;
_rebelDamageLevel = 0;
_rebelControlMode = 0;
+ resetExplosions();
_enemies.clear();
for (int i = 0; i < 512; i++) {
@@ -330,6 +332,18 @@ void InsaneRebel2::resetLevelWaveState() {
_rebelWaveState = 0;
}
+void InsaneRebel2::resetExplosions() {
+ for (uint i = 0; i < ARRAYSIZE(_explosions); ++i) {
+ _explosions[i].active = false;
+ _explosions[i].counter = 0;
+ _explosions[i].x = 0;
+ _explosions[i].y = 0;
+ _explosions[i].width = 0;
+ _explosions[i].height = 0;
+ _explosions[i].scale = 0;
+ }
+}
+
void InsaneRebel2::resetHandler7FlightState() {
_hitCooldown = 0;
_flyShipScreenX = 0xd4;
@@ -674,6 +688,7 @@ int InsaneRebel2::runLevel3() {
_playerShield = 255;
_playerDamage = 0;
_currentPhase = 1;
+ resetExplosions();
clearEmbeddedHudFrames();
@@ -728,6 +743,7 @@ int InsaneRebel2::runLevel3() {
_playerShield = 255;
_playerDamage = 0;
_playerScore = phase1Score;
+ resetExplosions();
clearEmbeddedHudFrames();
@@ -791,6 +807,7 @@ int InsaneRebel2::runLevel4() {
_playerShield = 255;
_playerDamage = 0;
_currentPhase = 1;
+ resetExplosions();
// Reset bit table before gameplay starts
clearBit(0);
@@ -845,6 +862,7 @@ int InsaneRebel2::runLevel5() {
_playerShield = 255;
_playerDamage = 0;
_currentPhase = 1;
+ resetExplosions();
// Reset bit table before gameplay starts
clearBit(0);
@@ -910,6 +928,7 @@ int InsaneRebel2::runLevel6() {
while (!_vm->shouldQuit()) {
// FUN_00407d10 â reset shot/hit counters
clearBit(0);
+ resetExplosions();
// DAT_0047ab9c = 0xffffffff â init phase state
_rebelPhaseState = 0xffffffff;
@@ -958,6 +977,7 @@ int InsaneRebel2::runLevel6() {
_currentPhase = 2;
_playerScore = phase1Score;
clearBit(0); // FUN_00407d10
+ resetExplosions();
debugC(DEBUG_INSANE, "Level 6 Phase 2");
if (!playLevelSegment("LEV06/06PLAY2.SAN", 0x28))
@@ -1023,6 +1043,7 @@ int InsaneRebel2::runLevel7() {
_playerDamage = 0;
_deathFrame = 0;
reachedFork = false;
+ resetExplosions();
clearBit(0);
@@ -1088,6 +1109,7 @@ int InsaneRebel2::runLevel8() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
@@ -1147,6 +1169,7 @@ int InsaneRebel2::runLevel9() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
@@ -1215,6 +1238,7 @@ int InsaneRebel2::runLevel10() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
@@ -1494,9 +1518,7 @@ int InsaneRebel2::runLevel11() {
// ----- PHASE 3 SECOND HALF: P3/11P03_X (G-L) -----
// Reset shots/explosions (FUN_0041ca6a equivalent)
- for (int i = 0; i < 5; i++) {
- _explosions[i].active = false;
- }
+ resetExplosions();
_enemies.clear();
// Preserve only bits 1-3 of phase state (original: DAT_0047ab9c &= 0xe)
@@ -1885,6 +1907,7 @@ int InsaneRebel2::runLevel13() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
@@ -1954,6 +1977,7 @@ int InsaneRebel2::runLevel14() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
@@ -2021,6 +2045,7 @@ int InsaneRebel2::runLevel15() {
_playerShield = 255;
_playerDamage = 0;
_deathFrame = 0;
+ resetExplosions();
clearBit(0);
Commit: 19ac3bfcf2b743cd7533c42f04df8bc8a3e2c8dc
https://github.com/scummvm/scummvm/commit/19ac3bfcf2b743cd7533c42f04df8bc8a3e2c8dc
Author: neuromancer (gustavo.grieco at gmail.com)
Date: 2026-06-12T18:02:53+02:00
Commit Message:
FREESCAPE: correctly parsed/executed SWAPJET in Amiga/Atari
Changed paths:
engines/freescape/language/8bitDetokeniser.cpp
engines/freescape/language/instruction.cpp
diff --git a/engines/freescape/language/8bitDetokeniser.cpp b/engines/freescape/language/8bitDetokeniser.cpp
index e78455e9a28..80a2f653346 100644
--- a/engines/freescape/language/8bitDetokeniser.cpp
+++ b/engines/freescape/language/8bitDetokeniser.cpp
@@ -364,7 +364,10 @@ Common::String detokenise8bitCondition(Common::Array<uint16> &tokenisedCondition
currentInstruction = FCLInstruction(Token::SWAPJET);
conditionalInstructions->push_back(currentInstruction);
currentInstruction = FCLInstruction(Token::UNKNOWN);
- bytePointer++;
+ // The 16-bit Amiga/Atari token stream stores SWAPJET without a
+ // padding argument. The 8-bit data has one unused byte here.
+ if (!isAmigaAtari)
+ bytePointer++;
numberOfArguments = 0;
break;
diff --git a/engines/freescape/language/instruction.cpp b/engines/freescape/language/instruction.cpp
index ccff0398fba..4ecf47b01e9 100644
--- a/engines/freescape/language/instruction.cpp
+++ b/engines/freescape/language/instruction.cpp
@@ -860,7 +860,7 @@ void FreescapeEngine::executeSwapJet(FCLInstruction &instruction) {
if (_flyMode) {
debugC(1, kFreescapeDebugCode, "Swaping to ship mode");
- if (areaID == 27) {
+ if (areaID == 27 && !(isAmiga() || isAtariST())) {
traverseEntrance(26);
_lastPosition = _position;
}
@@ -877,7 +877,7 @@ void FreescapeEngine::executeSwapJet(FCLInstruction &instruction) {
} else {
debugC(1, kFreescapeDebugCode, "Swaping to tank mode");
_playerHeightNumber = 0;
- if (areaID == 27) {
+ if (areaID == 27 && !(isAmiga() || isAtariST())) {
traverseEntrance(27);
_lastPosition = _position;
}
More information about the Scummvm-git-logs
mailing list