547 Commits

Author SHA1 Message Date
Colin Snover
88981b8db6 SCI32: Script patch priority drawing bug in MGDX
This fixes the horse at the fountain drawing on top of the
fountain instead of behind it.
2017-01-16 12:54:39 -06:00
Colin Snover
0744dc4109 SCI32: Fix spinloop in Hoyle5
Hoyle5 will spin on kGetTime between 15 and 300 ticks in multiple
game scripts in order to delay execution (for example, after
choosing opponents and clicking "okay"). This causes ScummVM to
be unresponsive and wastes CPU time.

This commit patches the spin subroutines to instead call a kernel
function (kWait) that waits without a spin loop. This kernel
function was removed in SCI2, and has been added back in ScummVM
specifically for Hoyle5, so this patch will not work with the
original interpreter.
2017-01-16 12:16:12 -06:00
Colin Snover
d34e5266ed SCI32: Fix bad scroll delta in GK2 inventory
Fixes Trac#9648.
2017-01-12 15:04:45 -06:00
Colin Snover
e18e6399ac SCI32: Fix bad rendering of Sierra logo in MGDX 2017-01-09 19:34:54 -06:00
Martin Kiewitz
a46f3c1625 SCI: Fix kq6 CD audio+subtitle script patch
Original patch caused a text window to be shown at the cliffs
(copy protection), even when audio-only mode was active.
2016-12-21 02:04:11 +01:00
Colin Snover
4b4b8a281b SCI32: Adjust transition timings
Transition timings were originally chosen largely by feel in SQ6,
as there was little other evidence to determine the correct speed.
As additional games started being playable in ScummVM, it became
apparent that these speeds were not quite right.

Additional adjustments may be needed in the future, but these new
timings seem to be somewhat closer to expectations than before.
2016-12-12 15:22:11 -06:00
Colin Snover
774713564d SCI32: Add script patch for Shivers room 35170 2016-11-19 19:06:04 -06:00
Colin Snover
8ba899b46b SCI32: Fix typos
Thanks @OmerMor.
2016-10-27 14:37:13 -05:00
Colin Snover
c30380d0a3 SCI32: Fix LSL6hires script bug
Fixes Trac#9612.
2016-10-27 10:55:30 -05:00
Colin Snover
a05ae2e24a SCI32: Fix slow transitions in SQ6 2016-10-14 19:43:47 -05:00
Colin Snover
8c555200d9 SCI32: Change storage type of int16 arrays to hold reg_ts instead
Memory references and integers in SSCI are both 16-bit numbers,
so game scripts frequently (incorrectly) use an IntArray instead
of an IDArray for holding references. Since references in ScummVM
are 32-bit reg_ts, IntArray entries must be large enough to hold
reg_ts in order to be compatible with game scripts that store
references in integer arrays.

The alternative solution is to find and patch all incorrect use of
IntArray across all games. This is possible, but a bit risky from
a save game stability perspective, since incorrect IntArray usage
is sometimes not apparent until well after the array is
instantiated (like GK1's global interview array).

This change invalidates existing SCI32 save games.
2016-10-09 11:21:13 -05:00
Eugene Sandulenko
dead4aa014 JANITORIAL: Remove trailing spaces 2016-10-09 14:59:58 +02:00
Colin Snover
084dfe9e03 SCI32: Use selector lookup in Torin script patch instead of magic numbers 2016-10-01 14:07:26 -05:00
Colin Snover
7d77a712d3 SCI32: Fix interrogation screen crash in GK1 2016-10-01 14:07:26 -05:00
Willem Jan Palenstijn
d580b64c6e SCI32: Fix build 2016-09-30 09:19:59 +02:00
Colin Snover
015a62976c SCI32: Fix whitespace 2016-09-29 19:39:16 -05:00
Colin Snover
3f6cfff225 SCI32: Fix SQ6 crash in Holocabana control panel 2016-09-29 19:39:16 -05:00
Colin Snover
7011ee8f50 SCI32: Fix Torin inventory crash caused by wrong array type 2016-09-29 19:39:16 -05:00
Colin Snover
2c61569c62 SCI32: Disable "change directory" button in native save/load dialogue 2016-09-29 19:39:16 -05:00
Colin Snover
1847b0f705 SCI32: Fix warnings and incompatible save games when built without SCI32 2016-09-29 19:39:16 -05:00
Colin Snover
c644f817e3 SCI32: Add mark for KQ7 in script patches 2016-09-29 19:39:16 -05:00
Colin Snover
4072714143 SCI32: Increase allowed number of save games in native save/load
This is applied only to games where the standard save/load
dialogue is used; games like KQ7 and Phantasmagoria, which use a
non-standard UI for save games, are still limited to the number of
saves originally supported.
2016-09-29 19:39:16 -05:00
Colin Snover
88de81a72e SCI32: Patch bad calls to IntArray::newWith in Phant1 and SQ6 2016-09-29 19:39:16 -05:00
Martin Kiewitz
2bec9c5a0c SCI: Add qfg1vga script patch to fix bug #9558
This solves a game bug, that also happens when using the original
interpreter, during the time where Brutus and Bruno meet at the
shooting range.
2016-09-18 15:59:38 +02:00
Martin Kiewitz
71d20da1e5 SCI32: Fix GK1 day 5 script patch
The previous patch made ego not getting the drum book anymore.
2016-09-09 00:46:49 +02:00
Martin Kiewitz
858bfdf691 SCI32: Add script patch for fixing game dialogue error on day 5
Special thanks, credits and kudos to sluicebox on IRC, who did a
ton of research on this and even found this game bug originally.
2016-09-08 21:52:10 +02:00
Martin Kiewitz
01327b540d SCI32: Add script patch for Gabriel Knight 1 script bug day 10
Day 10 - when dressing up. Right after that Gabriel turns around,
which went on endlessly in ScummVM. In the original engine
kNumCels is broken and returns in special cases basically random
data instead of 0. We return 0, which caused the cycler to
never end, because the scripts asked to cycle until cel -1.
2016-08-28 22:08:30 +02:00
Martin Kiewitz
d5dfd41ed1 SCI: Update script patch comments 2016-07-11 20:45:19 +02:00
Martin Kiewitz
9dd5ee988b SCI32: Improve kq7 subtitle script patch
Subtitle box should now always use color 255, which should be
white all the time. Normally it uses color 7, which is white
most of the time, but for example pink/purple at the start of
chapter 5.
2016-07-11 19:04:18 +02:00
Martin Kiewitz
eeafe230b9 SCI32: Fix an issue with the KQ7 subtitles script patch
Volume was lowered, but not raised afterwards for certain cases
Original script patch was commited in
b676530528349842ad178d02a2cbe49a0facd68e
2016-07-11 00:26:05 +02:00
Martin Kiewitz
b676530528 SCI32: Add script patch to fix/improve KQ7 subtitles
Needs lots of testing of course
Applies to 1.51 and 2.00
2016-07-10 23:40:29 +02:00
Martin Kiewitz
20ccd3affc SCI: Fix typo in script patch comment (longbow arithmetic bug)
Wasn't bug #6571, but bug #6751
Thanks to omer_mor for spotting it
2016-07-06 19:57:26 +02:00
Martin Kiewitz
ee41f6456e SCI: Adding script patch for longbow arithmetic berry bush bug
Fixes bug #6571
2016-07-04 18:31:40 +02:00
Martin Kiewitz
17b3dc4584 SCI: Fix script patcher, so that it works on BE systems 2016-07-01 15:23:50 +02:00
Filippos Karapetis
9cf3566e27 Merge pull request #766 from OmerMor/qfg3_bounds
SCI: Script patch for QfG3 giant tree bounds
2016-07-01 07:58:55 +03:00
Martin Kiewitz
9f789038b0 SCI: Add script patch for another Colonel's Bequest game bug
Command input stays disabled, when oiling the arm of the armor.
We fix this.
This script bug also happens, when using the original interpreter.

Fixes bug #7154
2016-06-27 21:42:18 +02:00
Martin Kiewitz
80462b3f87 SCI: Fix auto-saving in the fan-made Cascade Quest
Script patch to change the fixed slot 999 to fixed slot 99 in the
game scripts and additional code for kSaveGame, that checks for
Cascade Quest + slot 99 and will then use ScummVM slot 0, which
is our auto-save slot.

Fixes bug #7007

Also added the game name to the other fan-made script patch.
2016-06-25 23:59:01 +02:00
Martin Kiewitz
5385b4eda7 SCI: Script patch for critical Colonel's Bequest game bug
This patch is about an issue, when interacting with the
armor in room 37 (main house, downstairs).

This bug also happened, when using the original interpreter
and effectively froze the game depending on the coordinate
of Laura Bow, when the command was entered.

Fixes bug #7119

Versions affected: English PC/Atari ST/Amiga Floppy
2016-06-25 14:37:49 +02:00
Martin Kiewitz
09d314d3d7 SCI: Fix SQ1VGA script patch, fixes bug #7145
Script patch used "lsg" for one instruction, which should have
been "lag" instead.
Caused issues with the spider droid.
Added more details about this script patch in comments.

Also specified the method for a qfg3 script patch in comments.
2016-06-25 02:24:09 +02:00
Omer Mor
1184c1d0c4 SCI: Script patch for QfG3 giant tree bounds
At the base of the giant tree, when entering from the top east path,
the hero can get out of bounds and walk freely in the room.
This is caused by an incorrect cutoff used to determine whether the
hero entered from the top or bottom path.
The patch changes this cutoff, and prevents going out of bounds.

Fixes bug #6693
2016-05-29 20:54:33 +03:00
Omer Mor
aaf8cbca00 SCI: Script patch for fixing 3 missing points in QfG3
The hero is unable to tell Rakeesh and Kreesha about the Simabani
initiation, which would award him 3 points.
This is caused by a heap bug in room 285: the local array of possible
messages omits this message.
The patch fixes the bug by adding this message to the array.

Fixes bug #7086
2016-05-22 00:41:32 +03:00
Martin Kiewitz
343f1c7f8b SCI: Script patch for ending glitch in multilingual kq5
Game hangs during the magic battle during the ending.
Happened in all multilingual versions because of a script bug
(scripts were waiting for a signal, music didn't set one)
Fixes French, German and Spanish versions of KQ5
Also happened, when using the original interpreter
2016-03-08 01:29:46 +01:00
Martin Kiewitz
94a03b6a45 SCI: Make Freddy Pharkas intro scaling patch more generic
So that hopefully the signature will match for all versions
2016-02-26 00:08:02 +01:00
Martin Kiewitz
8da595366b SCI: Add script patch for Freddy Pharkas intro scaling
Fixes game title views not shown while they are scaled in.
2016-02-25 23:51:08 +01:00
Martin Kiewitz
3cf34d6417 SCI: Add script patch for qfg3 combat speed problem
Fixes bug #6247
2016-02-24 21:36:50 +01:00
Martin Kiewitz
82165bb6f6 SCI: Improve kAnimate fastcast detection, Remove EQ1 hack
- Add "kAnimate fast cast state" to "version" debug command
- Make it possible for script patcher signatures to get fully
used outside of the regular script patcher
- Remove previous fastcast detections and replace them with
a signature heuristic
- Remove object name checking, when fastcast global is set
- Heuristic detects "fast cast" support incorrectly for multilingual
KQ5, but it seems the game never sets the global, so it won't
matter. KQ5 CD (also SCI1 late) has fastcast support.
- Remove hack in GfxView::draw
- Add lots of comments to ScriptPatcher class

This fixes EcoQuest 1 Floppy showing the anemone on top of the
message box (see bug #5170)
2016-02-23 20:17:18 +01:00
Martin Kiewitz
51256ab7bb SCI: Add script patch for Laura Bow 1 easter egg
Fixes view-loop for PC version
2016-02-21 13:06:37 +01:00
Martin Kiewitz
4d5cc05eee SCI: Add script patch kq6 dual mode CD-Audio
Script patch added, so that dual mode uses the same CD-Audio
as regular Speech mode does during the ending (Girl in the Tower)
2016-02-09 14:03:34 +01:00
Martin Kiewitz
1948dce9a5 SCI: Additional info about Mother Goose patches
comments only
2016-02-09 02:22:50 +01:00
Martin Kiewitz
ce595cb92d SCI: Script patch for Mixed Up Mother Goose SCI1
+ Mother Goose SCI1.1
Fixes graphic issues when restoring from GMM
Also make the fix ups for Mixed Up Mother Goose, Jones + PQ2
get applied all the time (debugger command not included)
2016-02-09 01:28:34 +01:00