Commit graph

770 commits

Author SHA1 Message Date
Filippos Karapetis
6e3473a2b7 TRECISION: Remove unused events
These events are not used by the engine code or game scripts, so they
are dead code which can be safely removed
2021-05-29 21:24:54 +01:00
Filippos Karapetis
203d4818be TRECISION: Improve mouse responsiveness
We now process only the mouse button up events, and immediately clear
them, which improves mouse responsiveness. The relevant static
variables that were used to track inventory refresh changes have been
moved to TrecisionEngine. Also, removed some mouse related scheduled
events and call the corresponding functions directly
2021-05-29 21:24:54 +01:00
Filippos Karapetis
c7cc235e29 TRECISION: Simplify inventory moving left/right 2021-05-29 21:24:53 +01:00
Filippos Karapetis
e49abd0f0c TRECISION: Fix loading from the launcher 2021-05-29 21:24:53 +01:00
Filippos Karapetis
3db90c3546 TRECISION: Remove initScript()
The scripts initialized within that function are loaded from data.nl
in loadAll(), so this seems to be a leftover debug function
2021-05-29 21:24:53 +01:00
Filippos Karapetis
4cfe5365de TRECISION: Use the new event wrappers, remove the quit event 2021-05-29 21:24:53 +01:00
Filippos Karapetis
873644ffd4 TRECISION: Use the new event wrappers, remove the start/quit events 2021-05-29 21:24:52 +01:00
Filippos Karapetis
11d064fc6c TRECISION: Use the new event wrappers 2021-05-29 21:24:52 +01:00
Filippos Karapetis
7b8671d04c TRECISION: Fix the parameter names of startCharacterAction() 2021-05-29 21:24:52 +01:00
Filippos Karapetis
e02888e37e TRECISION: Add wrappers for some game events
This makes the code that uses these events more readable
2021-05-29 21:24:52 +01:00
Filippos Karapetis
1c322c5dde TRECISION: Fix memory leak with _stepLeftStream and _stepRightStream 2021-05-29 21:24:52 +01:00
Filippos Karapetis
6b34141e77 TRECISION: Whitespace fixes 2021-05-29 21:24:51 +01:00
Filippos Karapetis
f944214240 TRECISION: Remove dead code
This code is actually overwritten by the calls to setupAltRoom() and
mouseOperate(), which places Joshua at the correct position in room 21
(platforms), i.e. below the grating instead of outside the door.
Thanks to Strangerke for his cooperation on this :)
2021-05-29 21:24:51 +01:00
Strangerke
ab2bebda6a TRECISION: Simplify a couple of checks 2021-05-29 21:24:51 +01:00
Filippos Karapetis
8931782996 TRECISION: Remove the setRoom() wrapper 2021-05-29 21:24:51 +01:00
Filippos Karapetis
e1ad7c1318 TRECISION: Remove waitEndFading() 2021-05-29 21:24:51 +01:00
Filippos Karapetis
e5eca4a84f TRECISION: Remove unintentional switch fallthrough
It was a bug which sometimes resulted in both the left and the right
step sound to be played
2021-05-29 21:24:50 +01:00
Filippos Karapetis
9e67c95a69 TRECISION: Add some missing DisposeAfterUse flags 2021-05-29 21:24:50 +01:00
Filippos Karapetis
8a04137fb0 TRECISION: Refactor the sound playing code
The following changes have been made:
- Fade in/out functionality has been removed (it was never really used
  properly)
- Removed references to audio streams - they are disposed after use now
- Removed the room sound list - only 4 different sounds are actually
  played simultaneously
2021-05-29 21:24:50 +01:00
Strangerke
3857501467 TRECISION: Fix syncGameStream for v104 savegames 2021-05-29 21:24:50 +01:00
Filippos Karapetis
04ce40a1fa TRECISION: Cleanly separate original saved games from the ScummVM ones
This breaks compatibility with saved games created during development.
We know that versions 103 and 104 were used by the original engine, so
version 110 is a safe one for ScummVM
2021-05-29 21:24:50 +01:00
Filippos Karapetis
8fd5ffbbdf TRECISION: Remove unused saved game fields
The fields synced in SoundManager::syncGameStream() were never changed
2021-05-29 21:24:49 +01:00
SupSuper
d71d2a9e51 TRECISION: Free memory allocated to sound files 2021-05-29 21:24:49 +01:00
SupSuper
7f18f17185 TRECISION: Free sounds on room load 2021-05-29 21:24:49 +01:00
Filippos Karapetis
4dd9b52613 TRECISION: Fix memory leaks reported by Valgrind
Thanks to eriktorbjorn for reporting these
2021-05-29 21:24:49 +01:00
Filippos Karapetis
df5a7ccf39 TRECISION: Fix drawing after an animation has been restarted 2021-05-29 21:24:48 +01:00
Filippos Karapetis
60ecdfa399 TRECISION: Cleanup 2021-05-29 21:24:48 +01:00
Strangerke
fa55ae2fc6 TRECISION: Revert, change the way _compBuffer is allocated 2021-05-29 21:24:48 +01:00
Strangerke
1df6a9b138 TRECISION: Fixhow _compStream is deleted 2021-05-29 21:24:48 +01:00
Strangerke
68f8780a65 TRECISION: return in drawCharacter when _flagShowCharacter is false, rename a couple of variables and initialize a couple of others 2021-05-29 21:24:48 +01:00
Strangerke
0f1640eb92 TRECISION: Fix some uninitialized values 2021-05-29 21:24:47 +01:00
Strangerke
b31272d9a9 TRECISION: Remove some unused includes 2021-05-29 21:24:47 +01:00
Strangerke
de2662084f TRECISION: Fix spacing in one line in dialog 2021-05-29 21:24:47 +01:00
Strangerke
b9f4b7ef84 TRECISION: Move Microprose head fix in a separate function 2021-05-29 21:24:47 +01:00
D G Turner
8abd7ae2b1 TRECISION: Add Missing Detection Entry for 3-CD English Windows Version 2021-05-29 21:24:47 +01:00
D G Turner
fad3639d6d TRECISION: Further GCC Warning Fixes 2021-05-29 21:24:46 +01:00
D G Turner
b94dca4c91 TRECISION: Fix Various GCC Warnings 2021-05-29 21:24:46 +01:00
D G Turner
5cd8050e14 TRECISION: Fix Codacy issue
This was authored by bluegr, but accidently removed by force-push so
am restoring this change.
2021-05-29 21:24:46 +01:00
D G Turner
febb68456d TRECISION: Fix Various GCC Warnings
These include several sequence-point issues in 3d.cpp.
2021-05-29 21:24:46 +01:00
SupSuper
c9c2bca44f TRECISION: Translate last comment 2021-05-29 21:24:46 +01:00
D G Turner
a1c24252ca TRECISION: Fix Several GCC Warnings by Removing Errant Semicolons 2021-05-29 21:24:45 +01:00
Filippos Karapetis
56f9939c68 TRECISION: Simplify entry searching in FastFile, fix Codacy issues 2021-05-29 21:24:45 +01:00
Filippos Karapetis
71c827c7cc TRECISION: Simplify string handling in TextManager, fix Codacy issues 2021-05-29 21:24:45 +01:00
Filippos Karapetis
b55a9c12e4 TRECISION: Fix Codacy issues 2021-05-29 21:24:45 +01:00
SupSuper
f91cf55126 TRECISION: Missing potfiles 2021-05-29 21:24:44 +01:00
Filippos Karapetis
e267361ad9 TRECISION: Fix drawing objects and actors on top of animated backgrounds 2021-05-29 21:24:44 +01:00
Filippos Karapetis
08e8f5bfc5 TRECISION: Remove redundant pixel format transformation call 2021-05-29 21:24:44 +01:00
Filippos Karapetis
4abd23ffb6 TRECISION: Move surface format conversion inside GraphicsManager 2021-05-29 21:24:44 +01:00
Filippos Karapetis
a5a7d40f42 TRECISION: Move the shadowing pixel code inside GraphicsManager 2021-05-29 21:24:44 +01:00
Filippos Karapetis
6fe9b587ac TRECISION: Move resource loading code inside resource.cpp 2021-05-29 21:24:43 +01:00