Commit Graph
34 Commits
Author SHA1 Message Date
Le Philousophe 137b51d7ac SCUMM: Don't use unsafe sprintf and vsprintf 2022-10-23 22:46:19 +02:00
Donovan Watteau b23d45b9ba SCUMM: Only print invalid index blocktypes in hex in resource_v4.cpp
If an invalid blocktype is encountered, there is no guarantee that its
character representation would be ASCII-printable, and very strange
results could happen. Just print it in hex, as in resource.cpp (using
tag2str would be safe since it handles non-printable characters, but it
only works on four-byte values).

Also make the error message closer to the less ambiguous one from
resource.cpp.
2022-09-27 12:13:53 +02:00
Donovan Watteau 8a1f9c06af SCUMM: Fix a-grave character in French Monkey1 904.LFL font
In the French floppy EGA/VGA versions of Monkey Island 1, the 904.LFL
font has a duplicate `ç` glyph where the `à` letter is expected,
breaking some lines such as "Non!  Ce n'est pas tout \x85 fait \x87a."
if one fails the very first copy protection screen.

Fortunately, the `à` does exist in this font, but not at the right,
usual code point of CP850.  So we can work around this by exchanging a
couple of glyphs while loading this particular font (while keeping the
same size as the original charset resource).

In order not to break anything else, and since we directly patch some
hardcoded offsets, this is only done when the faulty 904.LFL has been
detected and when playing a French version (some other glyphs are wrong
in this font, but it's the only one which matters for French).

The other fonts and the CD version of Monkey Island 1 are not affected.
2022-04-20 07:23:22 +03:00
Eugene Sandulenko abea37c9bb ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Orgad Shaneh ed5489929c SCUMM: Use nullptr
Using clang-tidy modernize-use-nullptr
2021-11-14 15:51:59 +02:00
D G Turner 59b639ed4d SCUMM: Fix Missing Default Switch Cases
These are flagged by GCC if -Wswitch-default is enabled.
2019-12-23 11:56:16 +00:00
Johannes Schickel 3847465163 SCUMM: Make GPL headers consistent in themselves. 2014-02-18 02:39:38 +01:00
Max Horn 9ec64a66fe SCUMM: Turned ResTypeData into a Common::Array<Resource>, subsuming its _resource member 2011-05-13 14:48:01 +02:00
Max Horn 45207a52d4 SCUMM: Remove ResTypeData::_num 2011-05-13 14:12:00 +02:00
Max Horn dfd6112403 SCUMM: Rename resTypeFromId -> nameOfResType 2011-05-13 14:04:59 +02:00
Max Horn 649f8e0a84 SCUMM: Rename ResTypes->ResType, introduce ResId typedef, change code to use both 2011-05-13 14:02:53 +02:00
Max Horn c02420df43 SCUMM: Add a Resource class, refactor res code around it 2011-05-13 11:47:13 +02:00
Max Horn 0342ab3f1b SCUMM: Rename ResTypeData::num to _num 2011-05-13 11:47:11 +02:00
Max Horn 45e65d7ea0 SCUMM: Refactor how resource (types) are srepresented
Previously, we had a couple of arrays of size N (where N = number of
resource types), one for each attribute of a resource type (such as as
the number of resources of that type.

Now, we have one array of size N, whose elements are a record
aggregating all the attributes of each resource type.
2011-05-13 11:47:08 +02:00
strangerke 69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
Max Horn 7ce3719587 SCUMM: Move _heV7RoomIntOffsets from ScummEngine to ScummEngine_v70he 2011-04-05 15:18:09 +02:00
Travis Howell 982950941c The layout of global object data is different in the PCE version of Loom.
svn-id: r44779
2009-10-08 09:33:20 +00:00
Willem Jan Palenstijn f9208f1bb0 Make ScummFile::eos() consistent with Stream::eos().
Remove usage of ioFailed from SCUMM engine.
Fix reading up to the end of a SCUMM SubFile.
This hopefully fixes #2820957.

svn-id: r42632
2009-07-20 20:55:28 +00:00
Torbjörn Andersson 0999534749 The error() and warning() functions add ! and newline automatically. (I didn't
look at debug() and debugC(), since I'm really bored with this now. :-)

svn-id: r41061
2009-05-31 10:02:16 +00:00
Max Horn 6f4b567124 SCUMM: Split intern.h into multiple headers
svn-id: r39567
2009-03-20 16:33:58 +00:00
Max Horn 088a1c0806 ScummFile: Don't use the File::_ioFailed flag, rather track the io status separately; also, changed eof() -> eos()
svn-id: r34389
2008-09-06 20:34:21 +00:00
Nicola Mettifogo 258901bab9 Merged common/stdafx.h into common/scummsys.h. All referencing files have been updated.
svn-id: r28966
2007-09-19 08:40:12 +00:00
Max Horn 218e132e37 Updated legal headers in source files, based on what Pidgin (the IM client formerly knowns as Gaim) does; added new (incomplete) COPYRIGHT file; updated copyright dates in a few spots
svn-id: r27024
2007-05-30 21:56:52 +00:00
Max Horn 2447752a51 Reverted my roomoffs changes (broke the Loom intro), and instead added the constant RES_INVALID_OFFSET to indicate an invalid room offset
svn-id: r26353
2007-04-01 15:58:34 +00:00
Max Horn a08feb9f70 Got rid of some 0xFFFF -> 0xFFFFFFFF conversions and similiar nonsense by using a clever technique called 'signed ints' for room offsets (and this won't cause any regressions; any you may encounter are merely the products of a deranged imagination)
svn-id: r26331
2007-03-31 14:00:34 +00:00
Max Horn 8fa6a1ffd5 Removed the (useless, thanks to resTypeFromId) 'name' parameter from readResTypeList
svn-id: r25828
2007-02-24 19:29:40 +00:00
Max Horn 04a18dd7c4 SCUMM: cleanup (moved small header specific code from ScummEngine::readResTypeList to ScummEngine_v4::readResTypeList)
svn-id: r25827
2007-02-24 19:20:15 +00:00
Max Horn 51017cf1b2 Renamed ScummEngine::res to _res and allocate the ResourceManager on the heap (i.e. _res is a pointer now)
svn-id: r23922
2006-09-17 20:36:48 +00:00
Max Horn b860f002b2 Replaced checkRange by assertRange, which has (a) an (IMO) more logical order of parameters, and (b) removes lots of useless duplicate information in error messages
svn-id: r23885
2006-09-16 13:38:43 +00:00
Travis Howell 31fa4fbad8 Fix bug #1515345 - INDY3 (FM-TOWNS): Black screen upon start (Amiga)
svn-id: r23372
2006-07-05 22:27:11 +00:00
Max Horn bac32d1a5c Moved ScummFile etc. to the new file.cpp / file.h
svn-id: r21038
2006-03-03 15:16:02 +00:00
Max Horn 87fd6957ac Got rid of the 'tag' parameter for readResTypeList()
svn-id: r20864
2006-02-25 02:22:17 +00:00
Max Horn e389bcf497 Replaced _gameId, _version, _heversion, _features, _midi, _platform with a simple ScummGameSettings instance: _game
svn-id: r20795
2006-02-20 16:51:30 +00:00
Max Horn 26ee630756 Moved engines to the new engines/ directory
svn-id: r20582
2006-02-11 22:45:04 +00:00