Commit Graph

495 Commits

Author SHA1 Message Date
D G Turner
13b501825e PEGASUS: Fix Switch Fallthrough GCC Compiler Warnings 2021-03-18 23:37:05 +00:00
Eugene Sandulenko
adaf5bb3b9 PEGASUS: Import the DVD version patch from GOG.com
Co-Authored-By: Keith Kaisershot <keithkaisershot@gmail.com>
Co-Authored-By: Matthew Hoops <clone2727@gmail.com>
Co-Authored-By: Bastien Bouclet <bastien.bouclet@gmail.com>
2021-03-17 17:32:53 +01:00
Cameron Cawley
4ced49acd4 ENGINES: Changed AdvancedMetaEngine::createInstance to return a Common::Error 2020-12-04 20:57:14 +00:00
Eugene Sandulenko
7ff34bc9ec PLUGINS: MetaEngineStatic -> MetaEngineDetection 2020-10-11 23:14:39 +02:00
Eugene Sandulenko
7ea6781043 PLUGINS: PLUGIN_TYPE_METAENGINE -> PLUGIN_TYPE_ENGINE_DETECTION 2020-10-11 23:12:32 +02:00
aryanrawlani28
d26bbe521c ENGINES: ALL: Finish renaming ME & AME classes
- ME -> MetaEngineStatic (static parts)
- MEC -> MetaEngine (dynamic parts)
2020-10-03 14:56:36 +02:00
aryanrawlani28
a56dc094b9 ENGINES: ALL: Move detection_enums -> detection.h
- Cleans up headers quite a bit.
2020-10-03 14:56:36 +02:00
aryanrawlani28
29ceb07959 ENGINES: ALL: Revert detection submodule to be directly present in the engine directory
- DETECT_OBJS are present and added inside an engine's modules.mk file.
2020-10-03 14:56:36 +02:00
aryanrawlani28
f3b9477893 ENGINES: ALL: Add header guards for the new detection-header files. 2020-10-03 14:56:36 +02:00
aryanrawlani28
8189a05316 ENGINES: ALL: Adapt to changes for new plugins by defining a new detection module
For each engine:
- Make a new folder detection
- Move detection-related files inside the folder
- Add a new module "enginename/detection"
- Add DETECT_OBJS here
- Adjust the normal engine module to remove detect_objs
- Adjust every file for the new changes.
2020-10-03 14:56:36 +02:00
aryanrawlani28
8f751aa359 PEGASUS: Split detection features & adapt to new plugins. 2020-10-03 14:56:36 +02:00
aryanrawlani28
4b6976c558 GUI: U32: Reduce number of files changed and fixes
Up until last commit, everything was working fine but the amount of files changed was too large. This commit tries to reduce the changes.

- Add a fake constructor to Keymap, text-to-speech, setDescription (save-state)
- Redirecting functions for PopUpWidget::appendEntry, ButtonWidget::setLabel, GUIErrorMessage
- Use the above functions and constructors to reduce changes in Engines
- Fix warnings being in unicode. Only output english text in - Warnings, Errors, etc.
- Mark some strings as "translation" strings. (Not yet added to POTFILES)
- Remove some CP related things from po/modules.mk
- Previously used some Common::convertToU32 where it was not necessary, replace this with u32constructor
2020-08-30 14:43:41 +02:00
aryanrawlani28
e22b32abfe GUI: U32: Use Common::U32String::format where necessary and GUIError to u32
- Where necessary as in, where translated messages are used.
- GUIErrorMessage now takes in U32String
- error messages across some engines use U32Strings. they are changed because they show a message dialog.
2020-08-30 14:43:41 +02:00
aryanrawlani28
bed05ea134 GUI: U32: Fix compilation errors across entire project
After the initial changes just to scummvm/gui for u32, this commit includes the whole project

- Widget creations now always have u32 descriptions, labels, or tooltips
- Message dialogs make use of default arguments instead of providing the same argument explicitly
- encode String::format properly before passing on as argument where necessary
- Modify hugo utils (yesNoBox and notify box) to use u32
- Also provide fake constructors for the above which redirect to the u32 constructor
- Convert all keymap descriptions to u32 across all engines
- showConfirmationDialog in mohawk now uses u32
- showScummVMDialog also uses u32
- Scumm engine has dialogs now which use u32
- General fixes and wrapping convertToU32String for setLabels and related functions
- Add a fake constructor to MesssageDialog which redirects to the u32 constructor
2020-08-30 14:43:41 +02:00
mataniko
581a6ec7d6 JANITORIAL: Rename kSupportsRTL to kSupportsReturnToLauncher 2020-05-12 10:36:38 +02:00
Henrik "Henke37" Andersson
c970106234 PEGASUS: Use PauseToken 2020-05-10 23:39:31 +02:00
Henrik "Henke37" Andersson
59702fae9b PEGASUS: Use PauseToken 2020-05-10 23:39:31 +02:00
Paul Gilbert
9f175c4053 ENGINES: Cleanup of savegame filenames generation
This removes filename methods when it matched the Engine method.
Secondly, ensuring there was an overriden getSaveStateName method
for engines that didn't do the standard target.00x save filenames
2020-02-16 15:44:28 -08:00
Paul Gilbert
a00e44ba6c ENGINES: Merge saveGameState virtual methods into a single one 2020-02-16 15:44:28 -08:00
Bastien Bouclet
06e6176285 PEGASUS: Remove the debugger keymapper action
Opening the debugger is now in the global keymap.
2020-02-16 15:35:31 +01:00
Paul Gilbert
118e024bdd PEGASUS: Refactor to use Engine debugger 2020-02-16 13:07:19 +02:00
Bastien Bouclet
88091fcbba PEGASUS: Add override keywords 2020-02-09 12:43:16 +01:00
Eugene Sandulenko
0a852831ac PEGASUS: Added override keywords 2020-02-05 16:03:44 +01:00
Paul Gilbert
5b80320525 ENGINES: Adding override keyword to hasFeature methods 2020-02-04 20:04:11 -08:00
Eugene Sandulenko
4187038c62 PEGASUS: Added override keywords 2020-01-31 14:03:58 +01:00
Bastien Bouclet
7ecccd3b30 MOHAWK: RIVEN: Add default joystick action mappings 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
376a77e735 PEGASUS: Add default joystick action bindings 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
85f476070b PEGASUS: Use custom engine actions for key input 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
Bastien Bouclet
19de568e24 KEYMAPPER: Untangle the dependencies between Action and Keymap 2020-01-26 23:09:08 +02:00
Bastien Bouclet
d60190b12e ENGINES: Define default bindings for the existing engine keymaps 2020-01-26 19:07:53 +01:00
Bastien Bouclet
9c0bc2b633 KEYMAPPER: Simplify the way keymaps are enabled and disabled 2020-01-26 19:07:53 +01:00
Bastien Bouclet
ac44469558 KEYMAPPER: Remove the domain class 2020-01-26 19:07:53 +01:00
Bastien Bouclet
e197a75829 KEYMAPPER: Action can generate only a single event 2020-01-26 19:07:53 +01:00
D G Turner
b7c397412d PEGASUS: Fix Missing Default Switch Cases
These are flagged by GCC if -Wswitch-default is enabled.
2019-12-01 21:41:21 +00:00
Bastien Bouclet
bb813719b5 ENGINES: Change targets to have an 'engine ID'
The engine ID identifies which engine should be used to launch the target.
Also remove the 'single ID' system. Different games from engines that used
that system now have different game IDs.

Also-By: Matthew Hoops <clone2727@gmail.com>
2019-11-03 11:43:00 +01:00
Bastien Bouclet
9c8bd056d6 ENGINES: Stop using 'single id' 2019-11-03 11:43:00 +01:00
Bastien Bouclet
4b42112721 ENGINES: Add an engine ID to all the engines 2019-11-03 11:43:00 +01:00
Henrik "Henke37" Andersson
3d55cec3b5 PEGASUS: Game does not use MIDI, mark it as such. 2019-09-29 19:34:16 +03:00
Cameron Cawley
4cf9d1815c COMMON: Open the main menu when the joystick START button is pressed 2019-07-08 01:24:55 +03:00
Cameron Cawley
cf107e7f90 PEGASUS: Implement joystick support 2019-07-08 01:24:55 +03:00
Filippos Karapetis
87e13a5048 PEGASUS: Fix MSVC warnings
- Add a float suffix in convertScreenHToSpaceX/Y
2019-05-27 14:53:41 +03:00
D G Turner
c006f405f3 PEGASUS: Fix Fall Through Compiler Warnings. 2018-11-13 08:50:08 +00:00
Eugene Sandulenko
378d9153b6 PEGASUS: Add override specifier 2018-03-28 12:29:28 +02:00
Colin Snover
d087c9605f BASE: Remove bad casts between incompatible Plugin types
Previously, a C-style cast was used to convert a
Common::Array<Plugin *>, populated with pointers to StaticPlugin
and DynamicPlugin instances, to a
Common::Array<PluginSubclass<T> *>, but PluginSubclass<T> is a
*sibling* class to StaticPlugin/DynamicPlugin, so this cast was
invalid and the results undefined. The methods for retrieving
subclasses of plugins can't be easily changed to just generate an
array of temporary wrapper objects that expose an identical API
which dereferences to the preferred PluginObject subclass because
pointers to these objects are retained by other parts of ScummVM,
so the wrappers would needed to be persisted or they would need to
just re-expose the underlying Plugin object again. This indicated
that a way to solve this problem is to have the callers receive
Plugin objects and get the PluginObject from the Plugin by
explicitly stating their desired type, in a similar manner to
std::get(std::variant), so that the pattern used by this patch to
solve the problem.

Closes gh-1051.
2017-12-03 20:26:38 -06: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