Commit Graph

2854 Commits

Author SHA1 Message Date
Adrian Frühwirth
25ef2b83a3 KYRA: Mark always-false condition as TODO 2018-05-06 11:36:17 +02:00
Adrian Frühwirth
49116b4ae7 ALL: Use CLIP to clip volumes 2018-05-05 17:57:31 +02:00
Adrian Frühwirth
9bee9e1ba6 JANITORIAL: Fix whitespace 2018-04-19 12:08:31 +02:00
Adrian Frühwirth
00e59a3122 ALL: Load savegame thumbnail only when necessary
This commit introduces the following changes:

1. Graphics::loadThumbnail()

   Now returns a boolean and takes a new argument skipThumbnail which
   defaults to false. In case of true, loadThumbnail() reads past the
   thumbnail data in the input stream instead of actually loading the
   thumbnail. This simplifies savegame handling where, up until now,
   many engines always read the whole savegame metadata (including
   the thumbnail) and then threw away the thumbnail when not needed
   (which is in almost all cases, the most common exception being
   MetaEngine::querySaveMetaInfos() which is responsible for loading
   savegame metadata for displaying it in the GUI launcher.

2. readSavegameHeader()

   Engines which already implement such a method (name varies) now take
   a new argument skipThumbnail (default: true) which is passed
   through to loadThumbnail(). This means that the default case for
   readSavegameHeader() is now _not_ loading the thumbnail from a
   savegame and just reading past it. In those cases, e.g.
   querySaveMetaInfos(), where we actually are interested in loading
   the thumbnail readSavegameHeader() needs to explicitely be called
   with skipThumbnail == false.

   Engines whose readSavegameHeader() (name varies) already takes an
   argument loadThumbnail have been adapted to have a similar
   prototype and semantics.
   I.e. readSaveHeader(in, loadThumbnail, header) now is
   readSaveHeader(in, header, skipThumbnail).

3. Error handling

   Engines which previously did not check the return value of
   readSavegameHeader() (name varies) now do so ensuring that possibly
   broken savegames (be it a broken thumbnail or something else) don't
   make it into the GUI launcher list in the first place.
2018-04-07 09:26:20 +02:00
Eugene Sandulenko
84f22f2891 KYRA: Add method override statements 2018-03-28 12:13:05 +02:00
Matan Bareket
9cb2e43577 LOL: Fix detection entry for LOL Japanese (Bug #9828) 2017-12-26 20:31:14 +01:00
Matan Bareket
844c343f29 KYRA: Added detection entries for LOL Japense PC9821 version - Bug #9828 2017-12-26 20:31:14 +01:00
Matan Bareket
6db791a2c4 KYRA: Added detection entries for LOL German version - Bug #9557 2017-12-26 20:31:14 +01:00
Matan Bareket
dbc6e827a2 KYRA: Added detection entries for LOL Chinese Floppy version - Bug #7893 2017-12-26 20:31:14 +01:00
Matan Bareket
61e3bdcd2a KYRA: Added detection entries for LOL Spanish Floppy version - Bug #9699 2017-12-26 20:31:14 +01:00
Thierry Crozat
2b00829f09
Merge pull request #1041 from criezy/variadic-undefined
Fix undefined behaviour in variadic functions
2017-11-10 22:20:54 +00:00
Colin Snover
432fd522d2 ENGINES: Remove default1x scaler flag
This flag is removed for a few reasons:

* Engines universally set this flag to true for widths > 320,
  which made it redundant everywhere;
* This flag functioned primarily as a "force 1x scaler" flag,
  since its behaviour was almost completely undocumented and users
  would need to figure out that they'd need an explicit non-default
  scaler set to get a scaler to operate at widths > 320;
* (Most importantly) engines should not be in the business of
  deciding how the backend may choose to render its virtual screen.
  The choice of rendering behaviour belongs to the user, and the
  backend, in that order.

A nearby future commit restores the default1x scaler behaviour in
the SDL backend code for the moment, but in the future it is my
hope that there will be a better configuration UI to allow users
to specify how they want scaling to work for high resolutions.
2017-10-07 12:30:29 -05:00
Thierry Crozat
51df06523e KYRA: Fix undefined behaviour in variadic functions
Passing a type that undergoes default argument promotion as last
argument of a variadic function results in undefined behaviour.
2017-10-06 01:01:16 +01:00
Torbjörn Andersson
70a2ca8b7d JANITORIAL: Silence more GCC 7 warnings
All these fall through were marked as deliberate, so again I've only
changed the comment to silence GCC.
2017-08-06 13:30:51 +02:00
Bastien Bouclet
ec49730711 VIDEO: Allow setting the mixer sound type used to play audio tracks 2017-07-27 06:40:07 +02:00
Ben Castricum
ebaab44cd1 ALL: Leave out instructions for engine data issues 2016-12-08 13:38:56 +01:00
Ben Castricum
0e47d71928 ALL: replace 2 more 'download engine data' instructions 2016-12-06 14:50:04 +01:00
Ben Castricum
e95c2cc3ff ALL: save file => saved game 2016-11-29 21:10:59 +01:00
Ben Castricum
6f38c1e55d ALL: game state => saved game 2016-11-29 20:15:20 +01:00
rootfather
2fa75b0728 KYRA: Update POTFILES 2016-11-26 11:14:02 +01:00
Alexandre Detiste
f8388db32b JANITORIAL: Typos
I've not fixed this one, maybe it's on purpose:

RELASE -> RELEASE

engines/mads/staticres.cpp:const char *const kGameReleaseTitleStr =
"GAME RELASE VERSION INFO";
2016-10-31 09:56:43 +01:00
Willem Jan Palenstijn
b4515d0872 KYRA: (LOL) Fix buffer overflow in _lastOverridePalFile
It was storing filenames of length 12 in a char[12] buffer.
Fixes bug #9627.
2016-10-25 23:13:22 +02:00
Thierry Crozat
a87a702eb2 ALL: Homogeneize use of 'saved game' in messages 2016-09-18 16:40:34 +01:00
Eugene Sandulenko
bfbfbd3e1a Merge pull request #788 from Tkachov/cloud
ALL: Add Cloud storage support
2016-08-30 13:54:12 +02:00
athrxx
1694680ace KYRA: (LOL) - fix #7183 (LOL-CD: game crashes and exits when looking/picking item) 2016-08-27 22:09:37 +02:00
Alexander Tkachev
b665fc933d ALL: Make simpleSaveNames() a MetaEngineFeature
Added it into hasFeature() of all engines which returned `true` in
simpleSaveNames() before.

As mentioned in #788, SCI is not always using simple names, so it
doesn't have such feature now.
2016-08-24 16:07:55 +06:00
Alexander Tkachev
2d3cfffa84 KYRA: Fix openSaveForWriting() to return OutSaveFile 2016-08-24 16:07:55 +06:00
Alexander Tkachev
aee713141b CLOUD: Make OutSaveFile start saves sync
It had to become a proxy class in order to do that.
finalize() starts the saves sync.
2016-08-24 16:07:55 +06:00
Alexander Tkachev
ab1d160ec8 ALL: Add MetaEngine::simpleSaveNames()
Engines with "simple" savenames would support "Run in background" in
save/load dialog and gradual save slots unlocking. Other engines
save/load feature would be locked until save sync is over.
2016-08-24 16:07:55 +06:00
Eugene Sandulenko
f3e77b242d KYRA: Bump kyra.dat version for updated Italian EOB1 changes 2016-07-30 02:31:31 +03:00
Eugene Sandulenko
921efd6880 KYRA: Remove redundant code.
item variable value is less than 33, that is, 32 max. item+1 is never > 33.
Thus, the clapping code is redundant.
2016-05-17 19:12:14 +02:00
Johannes Schickel
2317e3fa58 KYRA: Simplify Kyra1 audio track filename handling 2016-05-15 16:13:25 +02:00
Johannes Schickel
18193d170e Revert "KYRA: Plug memory leak"
This reverts commit 9909cc615d.

This will likely cause invalid memory reads because it frees the last output
buffer which is used to keep files in memory. There is a possible memory leak
here, when the input data is not well formed. However, fixing this takes some
more effort than the solution in the reverted commit.
2016-05-15 15:48:17 +02:00
Johannes Schickel
3664caa29c KYRA: Silence analysis tools about possible memory leaks 2016-05-15 15:45:05 +02:00
Johannes Schickel
109c54c95b Revert "KYRA: Plug memory leak"
This reverts commit c22ca8ffb5.

This revision caused invalid memory reads in Kyra1 DOS+FM-TOWNS.
2016-05-15 15:39:05 +02:00
Eugene Sandulenko
c22ca8ffb5 KYRA: Plug memory leak 2016-05-15 13:19:27 +02:00
Eugene Sandulenko
9909cc615d KYRA: Plug memory leak 2016-05-15 13:14:37 +02:00
Johannes Schickel
30cae4d12d KYRA: Initialize variable before usage.
Thanks to salty-horse for reporting.
2016-04-15 00:26:17 +02:00
Ori Avtalion
3564032330 JANITORIAL: Reduce audio header dependencies 2016-04-14 16:10:21 +03:00
Ori Avtalion
253e18c440 JANITORIAL: Reduce GUI header dependencies 2016-04-14 13:30:14 +03:00
athrxx
97a69022fd KYRA: (LOL) fix bug #7104 (LOL-CD: mixing sfx and voice mode does not work) 2016-04-03 13:06:16 +02:00
Matthew Hoops
aa6ff44440 BACKENDS: Only expose one set of functions for AudioCDManager
Engines should only have to call one set of functions and not decide between the two. In fact, the 'emulation' API was documented to just call the 'real CD' API.
2016-03-13 13:57:19 +01:00
Matthew Hoops
fc8480c845 KYRA: Ensure openCD() is called 2016-03-13 13:53:20 +01:00
Johannes Schickel
9059189e35 KYRA: Formatting fixes. 2016-02-27 17:28:01 +01:00
Johannes Schickel
e8847195b9 KYRA: Remove ADGF_TESTING from EoB 1+2. 2016-02-27 17:28:01 +01:00
Johannes Schickel
56fc42c2f7 KYRA: Let listSaves return list sorted on slot numbers. 2016-02-25 21:39:45 +01:00
Alexandre Detiste
6c298e964f JANITORIAL: Typos detected with lintian & grep 2016-02-15 18:27:02 +01:00
Johannes Schickel
4012482561 KYRA: Run astyle on sound.cpp. 2016-02-09 09:54:04 +01:00
Johannes Schickel
a74341508f KYRA: Cleanup listing of actual save slots in GUI::updateSaveFileList. 2016-01-26 17:00:38 +01:00
Johannes Schickel
4d7dda0b5c KYRA: Only request actual save slots in listSaves. 2016-01-26 16:35:30 +01:00