The main change consists in using a separate byte array for the sentence
removal flags, move some functions from the GameManager to the Room class,
and add a few additional functions to manipulate this new array. This
allows to clarify some code related to dialogs.
This change also allows to switch the _shown array back to a bool array.
OSystem::setShakePos(int) can only take positive offset (as documented).
Passing a negative offset caused memory issues in the drawing code and
some random crashes.
We can now press the mouse button to leave the title screen instead
of having to press a key. Since the mouse cursor was visible, not
being able to press the mouse button was strange. Especially as it
was possible to use the mouse button earlier in the title screen.
Also we can now use the mouse button or any key other than escape
during the cutscene to move to the next sentence. And the code is
more reactive to pressing the Escape key (we don't need to wait
for the current annimation to finish) to exit the cutscene.
wait2() is used for updating events all over the code with a parameter
of 1, so to be sure there's at least one update it is wrapped in a
do-while now.
GameManager::airless() determined if the space suit could be taken off
by comparing the current room pointer to the allocated room objects.
This led to indeterministic behavior as sometimes airless() would
falsely return true as the dynamic allocation of the Room objects cannot
be expected to be in a certain order.
Implementing the corresponing RoomID to a Room objects solves this
problem.
roomBrightness() saw the greatest change by ripping out dimColors().
I compared the result with the original game and I cannot see any
difference by just reducing the palette brightness to 60%.
Before edit() cleared the input on screen by overdrawing it from x to
the right side of the screen. This works fine for terminals but for
example setting the watches alarm time it does not.
The text font is 5x8 so overdrawing the max input length + 1 * 5 is
sufficient to clear the screen from our input and the cursor. Also if
the value ends up being too big it is clamped to the right side
of the screen.