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
Strangerke
f4472d2f0a
DM: Fix GCC warnings
2017-01-31 18:15:31 +01:00
Eugene Sandulenko
dead4aa014
JANITORIAL: Remove trailing spaces
2016-10-09 14:59:58 +02:00
Strangerke
0ee75674fc
DM: Fix two memory leaks
2016-09-20 23:26:23 +02:00
Strangerke
706b1b27a4
DM: Fix 2 GCC warnings, some renaming
2016-09-19 21:52:37 +02:00
Strangerke
67f95ce50d
DM: Some more renaming
2016-09-19 07:58:42 +02:00
Strangerke
421d47db85
DM: Fix some more non-MSVC warnings, remove a useless variable
2016-09-16 23:15:27 +02:00
Strangerke
952abc3243
DM: More renaming in gfx enums
2016-09-16 07:46:10 +02:00
Strangerke
34d636d72e
DM Rename enum members in dm.h and dialog.h
2016-09-11 00:34:44 +02:00
Strangerke
3ecc98e832
DM: Change savegame signature to DM21 instead of DMDM. That breaks savegames compatibility.
2016-09-04 00:01:16 +02:00
Strangerke
e4863c0c73
DM: Polishing in loadsave
2016-09-03 23:59:31 +02:00
Strangerke
8d41bf9ad7
DM: Some more fixes concerning pointer formatting
2016-09-03 21:42:58 +02:00
Bendegúz Nagy
cd3b485952
DM: Clean up includes
...
Swap <> to "" with scummvm files
Add dm/ prefix to dm files
Reorder includes to system files, dm files
2016-09-03 10:38:43 +02:00
Strangerke
361722d459
DM: More renaming in DungeonMan, move some arrays
2016-08-27 23:10:13 +02:00
Strangerke
5ca6975665
DM: Remove custom warning function
2016-08-27 11:07:49 +02:00
Strangerke
42fea91d5d
DM: Finish the renaming of class members
2016-08-26 23:02:22 +02:00
Strangerke
52170d39ae
DM: Rename ObjectMan and ProjExpl members
2016-08-26 23:02:22 +02:00
Strangerke
d2fbd98f3d
DM: Renaming in MenuMan definition
2016-08-26 23:02:22 +02:00
Strangerke
5c81e4f4fd
DM: Rename functions and class members of GroupMan
2016-08-26 23:02:22 +02:00
Strangerke
6a02a571cd
DM: Rename variables and functions of DisplayMan
2016-08-26 23:02:22 +02:00
Strangerke
0d5f9a762e
DM: Rename class members in EventManager
2016-08-26 23:02:22 +02:00
Strangerke
64b1c4fdf1
DM: Rename DungeonMan class members
2016-08-26 23:02:22 +02:00
Strangerke
e728cb706e
DM: Rename functions of DMEngine and DialogMan
2016-08-26 23:02:22 +02:00
Strangerke
857d4e72ed
DM: Renaming of Champion and ChampionMan functions
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
2bdabc3b7a
DM: Add target and original platform to save files
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
2ee50eda35
DM: Add proper save header
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
d97a8905cc
DM: Remove some warnings
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
ca267da97c
DM: Add file error checking for save game
2016-08-26 23:02:22 +02:00
Strangerke
a5b8085c48
DM: Fix regression (pressure plate), fix compilation
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
efac7b5eb0
DM: Add loading from game
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
5cb1d02972
DM: Fix double load when loading from launcher
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
cefc231968
DM: Make ScummVM's save dialog open up when saving
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
c01293162c
DM: Make resume button load up ScummVM's global load dialog
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
fb14fea014
DM: Make thumbnail capture the dungeon
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
bcb067698e
DM: Add support for loading from launcher
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
aacbcc0757
DM: Correct language from GR_GRE to DE_DEU
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
f7ad6488e3
DM: Add localization
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
3fffb08a40
DM: Add missing localization warnings and query function for language
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
a11ae306e4
DM: Add dialog choice to savegame
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
5fb1b3e808
DM: Add missing code related to palettes
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
ead63373ca
DM: Add stub methods, clean up warnings and some comments
2016-08-26 23:02:22 +02:00
Strangerke
f0e037e305
DM: Some renaming, add a couple of STUBS
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
2b2a028332
DM: Add f444_endGame and checks for Common::EVENT_QUIT
2016-08-26 23:02:22 +02:00
Strangerke
133404c635
DM: Fix compilation with MSVC9, some light renaming
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
715ef2d404
DM: Debug loading savegames, add missing save loading parts
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
9fd7c56198
DM: Finish f433_processCommand140_saveGame
2016-08-26 23:02:22 +02:00
Strangerke
b174331e71
DM: refact f293_drawAllChampionStates, f283_viAltarRebirth, f327_isProjectileSpellCast and f326_championShootProjectile. Rename Direction.
2016-08-26 23:02:22 +02:00
Bendegúz Nagy
02c8f286e7
DM: Fix segfault with resume game
2016-08-26 23:02:22 +02:00
Strangerke
af84d233d0
DM: Refactor f322_championPoison, f284_setPartyDirection, f316_deleteScent, f317_addScentStrength, f310_getMovementTicks and f294_isAmmunitionCompatibleWithWeapon
2016-08-26 23:02:22 +02:00
Strangerke
831eca5c42
DM: Refactor f304_addSkillExperience, change _g313_gameTime to int32
2016-08-26 23:02:22 +02:00