43 Commits

Author SHA1 Message Date
Die4Ever
8d77870287
ENGINES: revert accidental changes to metaengine.cpp 2022-02-15 16:58:23 -06:00
Die4Ever
17706734a0
GROOVIE: prevent saving over reserved save slots 2022-02-15 16:38:58 -06:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Orgad Shaneh
e96a72ae87 ENGINES: Fix listSaves for 3-digit savegame patterns 2021-12-11 21:01:06 +02:00
Orgad Shaneh
78ef6203de ENGINES: Fix getSavegameFile for almost all engines
Use kSimpleSavesNames correctly, add where needed, remove where needed.

Trac #12977
2021-11-10 21:49:48 +00:00
Orgad Shaneh
fe104cc337 ENGINES: Use MetaEngine consistently for getting autosave slot
The autosave refactoring that was done in
7adad5aaf5831dc5adcee140f38aacc4a5db2518 used g_engine for identifying the
autosave slot. This worked for in-game save/load, but doesn't fit when
called from the launcher.

Fix by passing MetaEngine to SaveStateDescriptor ctor and using it for this
query.

Amends 7adad5aaf5831dc5adcee140f38aacc4a5db2518.
2021-10-24 16:46:06 +02:00
Orgad Shaneh
1b380a9e0b ENGINES: Fix moving savegames to a new free slot
This was broken for most engines.
2021-09-17 01:58:22 +03:00
Orgad Shaneh
6aeda12247 ENGINES: Warn when overwriting a non-autosave on autosave 2021-08-23 13:34:35 +02:00
Orgad Shaneh
7adad5aaf5 ENGINES: Streamline auto-save write/delete protection
Some engines call setAutosave and some don't. isAutosave is used to
determine if a saved game is an autosave, but in fact, on most cases it
just falls back to comparing the name to "Autosave".

This is wrong for several reasons:
* Older versions of ScummVM used Autosave 0.
* The name "Autosave" is translated, so if you change the language, it
  won't be detected.

Instead of relying on the name, use the well-known getAutosaveSlot() from
Engine/MetaEngine.

Fixes #12735.
2021-08-23 13:34:35 +02:00
Cameron Cawley
d79f1eb55e ENGINES: Remove getExtraGuiOptions from MetaEngine 2021-08-14 13:57:54 +02:00
Eugene Sandulenko
0fcb6aa3e5
METAENGINE: Add optional offset parameter for extended saves 2021-07-16 01:18:56 +02:00
a/
17b2c657ae ENGINES: METAENGINE: Add method to append extended save header to stream 2021-07-16 05:43:27 +09:00
Martin Gerhardy
dfd6b6a9a4 COMMON: moved AchievementDescriptionList into Common namespace
getAchievementsInfo is also moved into the MetaEngine to reduce code duplication
2021-06-16 00:25:14 +03:00
SupSuper
da2de3eee9 COMMON: Simplify MetaEngine::listSaves
Use querySaveMetaInfos to get save metadata
2021-06-07 12:39:15 +02:00
Cameron Cawley
ef0048fa77 COMMON: Add standard actions for mouse button clicks 2021-04-06 11:15:42 +03:00
Paul Gilbert
ae4da8bce0 ENGINES: Make creation of savegame thumbnails an overrideable method 2021-03-07 09:34:33 -08:00
Thierry Crozat
67720ef658 JANITORIAL: Remove obselete references to MetaEngineConnect
At some point when splitting the MetaEngine to a detection
plugin and a static meta engine, the former was called
MetaEngine while the latter was called MetaEngineConnect.
Thus was then later change to MetaEngineDetection and
MetaEngine. But some references were left to the former
names in comments and documentation.
2021-02-14 14:32:36 +00:00
Eugene Sandulenko
7ff34bc9ec PLUGINS: MetaEngineStatic -> MetaEngineDetection 2020-10-11 23:14:39 +02:00
aryanrawlani28
71a820caff ENGINES: Begin class renaming of ME & AME
- ME -> MetaEngineStatic (static parts)
- MEC -> MetaEngine (dynamic parts)
2020-10-03 14:56:36 +02:00
aryanrawlani28
81ba5d5627 ENGINES: ME & MEC: Allow MEC to build engine options widget.
- Rename the one in ME to avoid ambiguity.
- ME is named *static & MEC is named *dynamic.
- This change means that engines  can build 2 types of option widgets.
- The "Engine" tab is created statically regardless if an engine plugin is present or not.
- The in-game options are built using the MEC.
- With this commit, engines/dialogs is no longer dependant on MetaEngine, and instead used MEC all over.
2020-10-03 14:56:36 +02:00
aryanrawlani28
fd1e333100 ENGINES: METAENGINE: Move initKeymaps into MetaEngineConnect.
- Used by Sky, for example.
2020-10-03 14:56:36 +02:00
aryanrawlani28
01efb65931 ENGINES: METAENGINE: Shift save/load related content to MetaEngineConnect
- These include various functions and functionalities related to save/load.
- These are shifted, because the MEC class will house things that can be dynamic in nature.
- The MetaEngine class is fully & only dependent on ScummVM code, so it can always be built into executable.
2020-10-03 14:56:36 +02:00
Paul Gilbert
bf754b76aa ENGINES: Cleanup of get savegame file & patterns 2020-09-19 09:31:49 -07:00
Paul Gilbert
05620460e0 ENGINES: Fix savegame filename format for new-type saves
This also fixes a problem with the Griffin engine, which
although it was using the new type saves, was using a
target.s?? format, so wasn't listing files in the GMM
save dialog
2020-09-18 21:19:32 -07:00
Paul Gilbert
5136ff228e ENGINES: Fix defaults for engines using new extended format
This fixes two issues. First of all, when I was fleshing
out the Quux example engine with save support, I realised
that the default savegame pattern for engines is target.***,
whereas for the meta engine it was target.s**. This was
causing newly created saves not to appear in the savegame list.
The second is a minor convenience nicety.. if an engine is
supporting the new extended format, it means they do have saves,
so it's better to default to 100 slots by default without
requiring the engine to explicity declare it.
2020-09-16 21:52:38 -07:00
Bastien Bouclet
2e20971bab ENGINES: Register all the extra gui options default values on game start
Fixes #11398. This regressed due to the recent configuration dialog
changes.
2020-03-29 20:02:33 +02:00
Bastien Bouclet
bcfb7145fa GUI: Allow engines to define a fully custom tab in the edit game dialog
By implementing MetaEngine::buildEngineOptionsWidget, engines can
instantiate a container widget that will be shown in the Engine tab of
the edit game dialog. The default implementation retains the existing
behavior and shows the extra GUI options.
2020-03-28 07:38:39 +01:00
rsn8887
70a927a260 KEYMAPPER: Map Joy_X to skip lines by default 2020-03-09 22:03:37 -05:00
Paul Gilbert
52b87e7660 ENGINES: Add an autosave flag to the extended savegame data 2020-02-16 15:44:28 -08:00
Paul Gilbert
1687427e8e ENGINES: Mark autosave slots as write protected
If the autosave slot doesn't yet have any file in it, when the
GMM save dialog is open, the autosave slot will show a default
'Autosave' entry which is write-only, to prevent users
accidentally making a savegame in that slot
2020-02-16 15:44:28 -08:00
Le Philousophe
e895296313 ENGINES: Fix incoherent buffer size 2020-02-15 22:06:18 +01:00
Paul Gilbert
9f8c45ac4e ENGINES: Provide a default MetaEngine::hasFeature with extended save options on 2020-02-04 20:04:11 -08:00
Paul Gilbert
b9e598f9e2 ENGINES: Add proper thumbnail saving for extended savegames 2020-02-01 13:13:51 -08:00
Paul Gilbert
df47b705d4 ENGINES: target wasn't properly being used in listSaves 2020-02-01 13:13:51 -08:00
Bastien Bouclet
7ecccd3b30 MOHAWK: RIVEN: Add default joystick action mappings 2020-01-29 08:51:29 +01:00
Bastien Bouclet
e973092aef KEYMAPPER: Enable remapping of the mouse buttons 2020-01-29 08:51:29 +01:00
Bastien Bouclet
519b4a57e2 KEYMAPPER: Allow engines to return multiple keymaps
The idea is that keymaps may be situational. A keymap may be always
enabled, while another one may be enabled only during combat..
2020-01-29 08:51:29 +01:00
Bastien Bouclet
426867f4bc KEYMAPPER: Give human readable descriptions to the keymaps 2020-01-29 08:51:29 +01:00
Bastien Bouclet
32174c9067 KEYMAPPER: Actions can now be bound to joystick buttons 2020-01-29 08:51:29 +01:00
Bastien Bouclet
c131e8f5b9 EVENTS: Use the keymapper for some previously hard-coded key bindings 2020-01-29 08:51:29 +01:00
Bastien Bouclet
14663c4790 KEYMAPPER: Make the keymapper mandatory 2020-01-29 08:51:29 +01:00
Bastien Bouclet
ee8229dc00 ENGINES: Move keymap initialization to MetaEngine
To be able to access the keymap while the engine is not running.
2020-01-26 23:09:08 +02:00
Eugene Sandulenko
4fbf91e829 ENGINES: Extend MetaEngine class with ExtendedSaves support 2019-11-13 22:07:08 +01:00