Commit Graph
137148 Commits
Author SHA1 Message Date
Filippos Karapetis 79b5284a3e SAGA2: Pass game description to the engine
This will be needed to adapt the game and resource loading code for
multiple targets
2021-09-11 12:23:41 +03:00
Filippos Karapetis cf0e380517 SAGA2: Update comments in the Shorten decoder 2021-09-11 12:23:41 +03:00
Filippos Karapetis f360509c1f SAGA2: Remove SAGA1 game file types 2021-09-11 12:23:41 +03:00
Filippos Karapetis d3df1b09a1 SAGA2: Adapt some C syntax to C++ 2021-09-11 12:23:32 +03:00
Matthew Duggan e4ece2a62c ULTIMA8: Allow turning while retreating in Crusader
The original game allows you to turn while retreating, but that was not
previously possible.

To make the turn always possible, step() now does not wait for the movement
animation.  This should work as AvatarMoverProcess::run terminates early if the
Avatar is busy.
2021-09-11 13:58:13 +09:00
Matthew Duggan e91dda10ff ULTIMA8: const correctness 2021-09-11 13:56:54 +09:00
cadihowley 879ebd4d6c DOCS: edits FAQ to fix numbering/headings 2021-09-10 23:52:02 +02:00
cadihowley 156d312597 DOCS: adds FAQ question about compiling ScummVM 2021-09-10 23:52:02 +02:00
cadihowley 060630f520 DOCS: adds FAQ questions 2021-09-10 23:52:02 +02:00
cadihowley 6c3b69f633 DOCS: adds numbering + extra FAQ questions 2021-09-10 23:52:02 +02:00
Martin Gerhardy a0ea8dc7f3 TWINE: renamed class to Movies
as it now also playing smacker videos for lba2
2021-09-10 19:20:56 +02:00
Martin Gerhardy 4b512d64b8 TWINE: added lba2 intro support 2021-09-10 19:20:56 +02:00
Martin Gerhardy 1fb91752e1 TWINE: fixed lba2 array sizes for body models 2021-09-10 19:20:56 +02:00
Martin Gerhardy 0a33eb7496 TWINE: some scene change logic is lba1 specific 2021-09-10 19:20:56 +02:00
Orgad Shaneh c8c429a425 ENGINES: Document -1 as return value of getAutosaveSlot when not supported 2021-09-10 19:38:39 +03:00
Kai Knoblich 3101573007 SLUDGE: Fix build with Clang >= 11.0.0
Clang 11 and newer check the types of return values more strictly and
generate an error if there is a discrepancy.

However the "bool loadGame()" function, returns the value "NULL", if
loading of a savegame was unsucessful, whereas Clang expects a return
value of type "bool".

Remedy the issue by using "false" as return value instead of "NULL".
2021-09-10 19:38:12 +03:00
athrxx 48fb15812d SCUMM: (DIG) - fix workaround for Russian version so as not to write outside the expected scope
I experienced weird string modifications while trying to improve the text code. Turns out that this workaround will kick in even for 0 length strings and will lead to values being written to "negative" (before the original dst ptr argument) offsets.
2021-09-10 18:21:41 +02:00
Matthew Duggan bc8eab27fc ULTIMA8: Fix Crusader targeting slightly
There were two differences to the original which caused occasional targeting
mishaps:
1.  The reticle and actual shots were using different starting positions for
the shot (Avatar centre vs Avatar corner)
2. Z difference was not being taken into account when finding the "best" target

This fixes both problems.
2021-09-10 22:07:12 +09:00
Coen Rampen f9630d6981 AGS: Fix MIDI volume control
MIDI user volume setting was not applied until the start of the next track.
Fixed this by implementing Engine::syncSoundSettings.
2021-09-10 15:02:27 +02:00
Coen Rampen be5d8f2b0c AGS: Fix hanging sustained notes
Some AGS games (f.e. 5 Days A Stranger) use sustain controller events in their
MIDI data. When stopping playback in the middle of a track, sustained notes
will hang unless sustain is turned off. This commit fixes this issue by turning
on the "send sustain off on notes off" option of the MIDI parser. This fixes
issue #12905.
2021-09-10 14:46:58 +02:00
alxpnv a92db2a843 ASYLUM: add more entries to the respack patch list 2021-09-10 12:37:40 +03:00
Orgad Shaneh b7413e9a42 ENGINES: Do not attempt autosave when the autosave slot is -1 2021-09-10 09:26:15 +03:00
Paul Gilbert 83f4b713bc AGS: Fix turning off flashlight in Maniac Mansion Deluxe 2021-09-09 21:47:59 -07:00
Paul Gilbert 5f3004b94e AGS: Fix loading standalone AGS Maniac Mansion Deluxe saves
It seems the older version of AGSFlashlight didn't persist
it's fields in the savegame like the latest version does.
I decided against trying to explicitly figure out which
version of AGSFlashlight different games used, and instead
simply have fallback handling if the savegame doesn't
have the data.

The only minor disadvantage is that this means that whilst
savegames are portable from standalone AGS to ScummVM for
the game, it won't in the other direction. But I don't
think that's too major an issue, since it's only for the
few games that do use the old AGSFlashlight
2021-09-09 20:14:27 -07:00
antoniou79 d474ee3003 AGS: Change a few char variables to int8
In order to specify that they should be treated as signed

Some ports may treat an (unspecified) "char" as unsigned by default. Android does this for its ARM architectures and while we did fix this by enforcing -fsigned-char to its compiler, the issue may come up for other ports. Also it should be better to clarify in the engine when a variable is not actually storing string characters.

I've spotted and changed the most "safe" cases I could find for this. As far as I can tell, out of these, only the Outline field and fontoutline array could potentially be assigned valid negative values which would cause bugs for ports treating chars as unsigned.
2021-09-09 19:27:49 -07:00
0992fa9c3b COMMON: Change PRNG Function to Xorshift* (#3341)
The old RNG method had non-standard periods, ranging from some seeds looping on themselves (seed = 1184201285) to some seeds having periods as low as 11 or 48, as listed in https://github.com/scummvm/scummvm/pull/3340. This is a problem even for games that run the RNG once a frame, as the possibilities for random events is greatly reduced should the initial seed be in one of these sets of small periods.

Xorshift* is a standard, fast, non-cryptographic PRNG with academic backing that has period 2^32-1 (all seeds lead to another seed except 0, which is excluded from the initial seeds).  Many different flavors are possible, as listed in the paper, but the choice implemented in this pull request uses only a single 32-bit integer as a state, like the old PRNG.

Co-authored-by: Thierry Crozat <criezy@scummvm.org>
Co-authored-by: Filippos Karapetis <bluegr@gmail.com>
2021-09-09 21:46:08 +03:00
sluicebox 17917f3613 SCI: Add QFG1VGA Mac workaround for Brigands 2021-09-09 12:39:17 -05:00
sluicebox 4be3f914b2 SCI: Replace QFG1VGA fetch workaround with script patch
Spell animation now travels towards the intended plant as in the
original, and also fixes Mac version
2021-09-09 12:39:17 -05:00
Martin Gerhardy a8446da4ea TWINE: removed unused left-over from disassembly 2021-09-09 19:32:09 +02:00
Scott Percival 666f241d29 EVENTRECORDER: Remove backwards compatibility 2021-09-09 19:32:02 +02:00
Scott Percival fb421a0ca7 EVENTRECORDER: Change file format to big-endian
Previously the file format had all chunks, offsets and values stored in
little-endian format. The one exception was screenshots, which used the
existing THMB code in graphics/thumbnail.cpp, that is entirely
big-endian. Any tooling which attempts to parse the Event Recorder file
format must make a special exception for THMB chunks, and read the chunk
size and contents as big-endian.

In the interests of making the file format more consistant
to parse, and given that backwards compatibility is not required for
this iteration of Event Recorder, this patch changes everything to
big-endian.
2021-09-09 19:32:02 +02:00
Scott Percival 1040bd2862 EVENTRECORDER: Fixes based on feedback 2021-09-09 19:32:02 +02:00
Scott Percival 29d6758c0d EVENTRECORDER: Add update mode
This new mode is functionally identical to playback mode, however
a new recording file is used to track the actual output of ScummVM.
This feature can be used to update a suite of existing recordings after
a renderer or a timing change.
2021-09-09 19:32:02 +02:00
Scott Percival 84707ec828 EVENTRECORDER: Prevent recursive call to warpMouse 2021-09-09 19:32:02 +02:00
Scott Percival 0112fab176 EVENTRECORDER: Filter GUI redraws from the logs 2021-09-09 19:32:02 +02:00
Scott Percival 13a20e11e6 EVENTRECORDER: Disable autosave in record/playback mode 2021-09-09 19:32:02 +02:00
Scott Percival 5cbcd98963 EVENTRECORDER: Add screen update tracking
Screen update boundaries are now used as sync points.
Screenshots are now processed on a screen update boundary.

This change increments the version of the Event Recorder
file format to 2; version 1 files will still play back as
before, without synchronising to screen updates.
2021-09-09 19:32:02 +02:00
Scott Percival 40aadcf139 EVENTRECORDER: Add --screenshot-period to the CLI 2021-09-09 19:32:02 +02:00
Scott Percival 16545f9cd9 LOG: Prevent Log::printTimeStamp() from creating an event
This fixes a stack overflow when EventRecorder is used and debug logging is switched on.
2021-09-09 19:32:02 +02:00
Scott Percival bd7b605552 EVENTRECORDER: Allow --record-file-name for record mode 2021-09-09 19:32:02 +02:00
Scott Percival c29a62b05d EVENTRECORDER: Ignore hash check for targets with no MD5 records
This is required for Director to allow testing arbitrary files that
aren't part a game, e.g. Lingo Dictionary.
2021-09-09 19:32:02 +02:00
Matthew Duggan df0fd1eb4f ULTIMA8: Fix Crusader shield hit damage
The `shieldCost` field from the firetype table should be used to subtract from
shields, not the weapon damage.  Normally shieldCost is a larger value, so it
affects game difficulty a lot.
2021-09-09 23:31:43 +09:00
Matthew Duggan 9aa5b19675 ULTIMA8: Fix Crusader NPC weapons in No Remorse difficulty
The NPCs should get randomly harder weapons at No Remorse difficulty level, but
this never happened because I missed a line in the original to reset the "alt"
weapon type in this case.
2021-09-09 23:27:13 +09:00
Matthew Duggan 196f63e883 ULTIMA8: Fix where Crusader BA-40 ammo is used
After rechecking, the original game has expendable BA-40 ammo on every
difficulty above *1*, not *2*.  Confirmed in dosbox and the disassembly
(function at 13c8:2975).
2021-09-09 23:04:07 +09:00
Matthew Duggan 5cda13cb40 ULTIMA8: Limit BA-40 ammo in high Crusader difficulties
Bug #12880.  The BA-40 should consume ammo in the higher 2 difficulty levels
for Crusader: No Remorse.  A similar change is probably needed for No Regret,
but it will be done separately.
2021-09-09 22:20:27 +09:00
Matthew Duggan 40baa571e8 ULTIMA8: Constify some variables 2021-09-09 22:15:35 +09:00
alxpnv b77b24487d ASYLUM: update namespace comment 2021-09-09 11:06:11 +03:00
Torbjörn Andersson 8ba69ec278 SDL: Silence signed/unsigned warning 2021-09-09 07:20:04 +02:00
Martin Gerhardy 20a9d03cee TWINE: godmode is only for attacking the hero now 2021-09-09 07:12:32 +02:00
Paul Gilbert 1e76c86ff4 AGS: Fix display of plugin function names in script dumps 2021-09-08 21:54:40 -07:00