This was only used by the ps2 backend, and that backend no longer
exists. Also now backends that want to force RTL should use the
kFeatureNoQuit OSystem feature instead.
This config was handled in the DefaultEventManager, but this did not
work for engines that quit the game without using a QUIT_EVENT (such
as SCI). So now it is handled one level up directly in scummvm_main.
Note: It is still also handled in the DefaultEventManager so that we
get the correct confirmation dialog there when "confirm_exit" is true.
Apparently, when reading a movie file name the engine needs to read
an even number of bytes, so if the length of the file name is even
(not counting the terminating 0) it has to read an extra byte. This
was already done, but apparently the String class used to allow you
to add terminators to a string, and these were then counted into
the length of it. Not adding the terminator avoids this disambiguity.
In the castle cellar, when you pull the bung out of the wine cask, a sound is
played for the running wine. However, when the cask runs empty, the sound is
not stopped. Also, when the Skorl starts drinking the wine, the sound is not
restarted when you enter the room, and it is also not stopped when the wine
runs out. These issues exist with the original interpreter as well.
I fixed this by adding the running wine sound when the hotspot script for the
drinking Skorl is in the loop where the Skorl is drinking, and removing the
sound when the hotspot script for the running wine is unloaded and when the
running wine stops in the animation for the drinking Skorl.
When outside in the town, the game plays an ambient sound of twittering birds.
When first entering town after falling through the chute, this sound does not
play; it first starts after you enter and exit a building. This issue is
present with the original interpreter as well.
This change fixes this by calling removeSounds after playing the chute
animation. This function calls the bellsBodge function, which manages the
ambient sounds in town. Because there are no other sounds playing when first
entering town, this has no unwanted side effects.
When entering town after escaping from prison, after a little while bells start
chiming constantly. This does not happen in the original interpreter.
This is caused by a script that generates the ambient thunder sounds in the
prison. After the prison escape the clearSequenceDelayList function is called,
but this did not remove the script because it is not marked as "can be cleared".
Because this script is not running in town in the original interpreter, I think
the clearSequenceDelayList function is supposed to clear all scripts, even the
ones not marked as "can be cleared". The only other scripts that this affects
are two more ambient sound scripts that are now removed after entering the
castle towards the end of the game (the only other place where
clearSequenceDelayList is called). These scripts only play sounds while in town,
so removing them has no effect (but does remove some unnecessary processing).
Some room exit data have the door opening or door closing sound defined as 0
(f.e. the cave doors). This means no sound should be played. ScummVM would play
sound 0 instead, which is the running water sound. This change fixes this by
checking for value 0 and not playing a sound in that case.
ScummVM did not seem to trigger door opening and closing sounds, f.e. the cell
door at the start of the game. The checks in the roomExitAnimHandler compared
hotspot IDs to room numbers, which are different sets of IDs AFAICT. Also, the
door opening part would decrease the frame counter first, then compare to the
set destination frame. The opening sound should often be triggered at the start
of the animation, but because the frame counter is decreased first, it does not
trigger at the first frame. I moved the frame counter decrease after the check
to fix this.