Commit Graph
55 Commits
Author SHA1 Message Date
Filippos Karapetis fb9a96d0f8 SCI: Add WIP code for saving via GMM and autosaving (still disabled)
We check if the user has control, which seems to be working as intended,
but music is not resumed properly after loading, so it's disabled for
now
2022-01-16 13:54:57 +02:00
Eugene Sandulenko abea37c9bb ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
sluicebox b23daadf00 SCI32: Fix restoring PHANT2 games from overlay
Fixes restoring from overlay while game is in handsOff mode.
For example: room 3310.
2021-01-31 19:37:58 -08:00
sluicebox 5f9111f9ed SCI: Fix LSL6 low-resolution volume synchronization
Applies the LSL6 volume sync to the SCI16 (lo-res) versions as well as
the SCI32 (hi-res) versions.
2020-07-10 14:29:32 -07:00
sluicebox 11065630c0 SCI: Fix CAMELOT menu items when restoring 2019-11-20 14:12:54 -08:00
sluicebox 999f813dc3 SCI32: Add QFG4 character import message box
Adds the ScummVM message box explaining saved character files
to the QFG4 import character screen.
2019-09-25 21:00:48 -07:00
Martin Kiewitz bd94bbc3e3 SCI: Add QfG4 script patch to fix sliding down slope bug #9801
It's quite difficult to patch. I hope this finally solved it.
2017-10-09 01:58:16 +02:00
Colin Snover cd6130cdd6 SCI32: Add audio volume sync support for RAMA 2017-09-28 14:58:17 -05:00
Colin Snover 9c28c25b67 SCI32: Add guest additions save/restore support for RAMA 2017-09-23 20:57:01 -05:00
Colin Snover b038432952 SCI32: Support RAMA's custom save games through kFileIO 2017-09-23 20:56:48 -05:00
Colin Snover 029eeeb803 SCI32: Fix Phant2 "auto-save"
The game has a feature where it will automatically create a save
game when you quit the game through the in-game control panel (or
when you die, for some reason).

Unfortunately, due to bad programming, this automatic save would
just overwrite whatever was in save slot 1 (slot 0 in the original
interpreter). Find this attempt to auto-save the game and redirect
it to the auto-save slot. This might not be totally correct, but
it is at least better than destroying a save game.

Fixes Trac#10201.
2017-09-14 20:45:02 -05:00
Colin Snover 5c3a2cf16a SCI32: Add load from launcher support for Phant2
Adding a hook into kPlayDuck to skip the intro video feels kind of
crappy, but it seemed simpler, consistent with the other hooks for
launch loading, and therefore preferable versus hot-patching the
script or messing with PC in the VM or something.
2017-07-30 19:21:55 -05:00
Colin Snover 49e8f05714 SCI32: Implement Phant2 save/load integration 2017-07-30 19:10:50 -05:00
Colin Snover b13777da8c SCI32: Implement guest additions volume sync for Phant2 2017-07-30 19:10:50 -05:00
Colin Snover 97f7308da3 SCI32: Add music volume UI sync for MGDX 2017-07-24 19:36:38 -05:00
Colin Snover afe344cc1f SCI32: Add guest additions support for LSL7 2017-07-17 22:42:18 -05:00
Martin Kiewitz 26fe96d637 SCI32: Add script patch for lsl7 cheese maker priority bug
This issue also happens when using the original interpreter.
2017-05-24 18:45:16 +02:00
Colin Snover 3d4fb4ccb4 SCI32: Fix mustSetViewVisible for SCI3
In SCI2/2.1, variable indexes are used along with a range encoded
in the interpreter executable to determine whether an object
variable is a view-related variable. Operands to aTop, sTop, ipToa,
dpToa, ipTos, and dpTos are byte offsets into an object, which
are divided by two to get the varindex to check against the
interpreter range.

In SCI3, objects in game scripts contain groups of 32 selectors,
and each group has a flag that says whether or not the selectors
in that group are view-related. Operands to aTop, sTop, ipToa,
dpToa, ipTos, and dpTos are selectors.
2017-04-23 13:07:25 -05:00
Colin Snover 1ed185bbbb SCI: Implement delayed restore for SCI32 and move implementations to GuestAdditions 2017-04-22 13:01:35 -05:00
Colin Snover 3303a88139 SCI: Improve audio volume & settings sync code
This patch includes enhancements to the ScummVM integration with
SCI engine, with particular focus on SCI32 support.

1. Fixes audio volumes syncing erroneously to ScummVM in games
   that modify the audio volume without user action (e.g. SCI1.1
   talkies that reduce music volume during speech playback). Now,
   volumes will only be synchronised when the user interacts with
   the game's audio settings. This mechanism works by looking for
   a known volume control object in the stack, and only syncing
   when the control object is present. (Ports and planes were
   researched and found unreliable.)

2. Fixes audio syncing in SCI32 games that do not set game
   volumes through kDoSoundMasterVolume/kDoAudioVolume, like GK1,
   GK2, Phant1, and Torin.

3. Fixes speech/subtitles syncing in SCI32 games that do not use
   global 90, like LSL6hires.

4. Fixes in-game volume controls in SCI32 games reflecting
   outdated audio volumes when a change is made during the game
   from the ScummVM launcher.

5. Fixes SCI32 games that would restore volumes from save games
   or reset volumes on startup, which caused game volumes to be
   out-of-sync with ScummVM when started.

6. ScummVM integration code for audio sync has been abstracted
   into a new GuestAdditions class. This keeps the ScummVM-
   specific code all in one place, with only small hooks into the
   engine code. ScummVM integrated save/load code should probably
   also go here in the future.

Fixes Trac#9700.
2017-04-21 19:00:27 -05:00
Colin Snover 4cff1e400f SCI32: Add support for alternate graphics selectors
Used by at least Phantasmagoria 2.
2016-12-19 14:46:59 -06:00
Colin Snover 1337cd3dec SCI32: Implement kEditText 2016-03-06 21:34:43 -06:00
Willem Jan Palenstijn 0012390f2a SCI32: Fix index/offset mixup in updateInfoFlagViewVisible 2016-03-01 20:18:29 +01:00
Willem Jan Palenstijn d803847ca1 SCI32: Update InfoFlagViewVisible in VM opcodes 2016-02-27 14:21:14 +01:00
Martin Kiewitz 3e4efdbd27 SCI32: Implement syncing planes+screen items from VM for restore
Fixes restoring saved games, when ScummVM dialogs are patched in
Removing clearing planes+screen items as well, because the scripts
actually did that, but did not clear everything.
Fixes "Invalid screen item" message when entering options menu,
after restoring in SQ6.
2016-02-21 17:21:48 +01:00
Colin Snover 20ccad80bf SCI: WIP GfxText32 code
This at least prevents SQ6 from crashing when going into the
introduction
2016-02-18 13:18:02 -06:00
Colin Snover 75ccabc325 SCI: Implement accurate renderer architecture for SCI32 2016-02-18 13:18:02 -06:00
Johannes Schickel 8fc7d60feb SCI: Make GPL headers consistent in themselves. 2014-02-18 02:39:37 +01:00
Filippos Karapetis 2b50824133 SCI: Add setter/getter methods to reg_t's
No functionality change has been made with this commit. This avoids
setting and getting the reg_t members directly, and is the basis of any
future work on large SCI3 scripts (larger than 64KB)
2012-06-18 05:24:06 +03:00
Filippos Karapetis 398d0ffcef SCI: Check for object visibility, if an object defines it
Fixes the inventory in GK1
2012-05-14 02:30:15 +03:00
Filippos Karapetis f61ea4c9cf SCI: Fixed text background color and text transparency for SCI32 games 2011-10-28 22:20:31 +03:00
Filippos Karapetis 96ce226967 SCI: Proper implementation of text drawing for SCI2+ 2011-10-11 01:25:08 +03:00
Max Horn 88913c0139 ALL: Remove trailing whitespaces
This tries to make our code a bit more compliant with our code formatting
conventions. For future use, this is the command I used:
  git ls-files "*.cpp" "*.h" | xargs sed -i -e 's/[ \t]*$//'
2011-06-20 00:59:48 +02:00
Matthew Hoops eea482fa43 ALL: behaviour -> behavior 2011-05-25 10:50:46 -04:00
strangerke 69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Walter van Niftrik 952d1a084c SCI: Implement Mac iconbar event handling. 2011-03-09 21:05:19 +01:00
Filippos Karapetis bb9b7c24f9 SCI: Added some SCI3 selector related information
- Added a TODO for the usage of the -info- selector in kClone and kDisposeClone in
SCI3 scripts, as it's no longer used in SCI3
- Added information about which of the selectors are missing in SCI3. There are
some more which are missing, but aren't used in SCI2-SCI3 anyway
- Some styling

svn-id: r54291
2010-11-17 14:03:14 +00:00
Martin Kiewitz 87b78b1673 SCI: kClone/kDisposeClone behaviour more accurate
now also checking -info- selector, if object is supposed to get freed. Fixes kq4 early hanging (in intro, when opening door, etc.)

svn-id: r52508
2010-09-03 18:14:59 +00:00
Martin Kiewitz ff7476d9f1 SCI: adding virtual lists for qfg-import rooms
now lists import files of all possible games, adds game title before that, removes game prefixes for all files

svn-id: r52441
2010-08-29 15:13:25 +00:00
Filippos Karapetis d1e45fd5d9 SCI: Removed a now unused selector from the selector cache
svn-id: r52349
2010-08-24 17:12:31 +00:00
Martin Kiewitz 1b69257654 SCI: changing hoyle 4 workaround
fixing hoyle 4 detection entry (not a demo)
adding direct selector fix, maybe we should replace this later with a script patch
adding detailed comment about the issue

svn-id: r51753
2010-08-05 07:49:19 +00:00
Martin Kiewitz 353b0d2993 SCI: support useInsetRect in kFrameout
svn-id: r51251
2010-07-24 17:43:56 +00:00
Martin Kiewitz 15ef4b23a0 SCI: some work on priority in sci32
svn-id: r51134
2010-07-22 10:24:08 +00:00
Martin Kiewitz 90763f6e24 SCI: kDoBresen - save last position of client inside mover - fixes lsl6 tram still shaking while gotten stopped due ego
svn-id: r50931
2010-07-16 05:46:07 +00:00
Filippos Karapetis 58732b9df1 SCI: More changes to the code for loading from the launcher
- Added support for the LSL2 menu bar object
- We no longer need a reference to the init() selector - it's always the first method of the menu bar object

svn-id: r50462
2010-06-28 22:01:26 +00:00
Filippos Karapetis 048ceb73d3 SCI: Removed the hack for loading games from the launcher from run_vm(). This is now done on startup. This should fix loading from the launcher for LSL6
svn-id: r50406
2010-06-27 23:20:08 +00:00
Filippos Karapetis 0a102981f0 Moved the SelectorCache struct inside selector.h, where it belongs, and fixed some header dependencies in the process
svn-id: r50183
2010-06-23 15:23:37 +00:00
Filippos Karapetis cc6f5eb3e4 Unified invokeSelector() and invokeSelectorArgv(), and removed the INV_SEL kludge. Also, removed the selectorInvocation parameter - if invokeSelector() fails, the error is in most cases unrecoverable, and the error description thrown covers all cases where kContinueOnInvalidSelector was used. This uncovered a bug too: in some places, non reg_t parameters were parsed
svn-id: r49564
2010-06-10 09:22:30 +00:00
Filippos Karapetis 67de5b1bd3 Mass renaming of selector-related functions, and removed some defines which were just cloaking functions with a different name
- GET_SEL32 -> readSelector
- GET_SEL32V -> readSelectorValue
- PUT_SEL32 -> writeSelector
- PUT_SEL32V -> writeSelectorValue
Also, changed some selector-related function names and variables to CamelCase

svn-id: r49317
2010-05-29 23:37:15 +00:00
Max Horn 38bf3d0d3c SCI: Make EngineState parameter to INV_SEL explicit
svn-id: r48202
2010-03-08 21:54:07 +00:00