Max Horn
d020922846
SCUMM: Make REDUCE_MEMORY_USAGE slightly more effecive (saving ~1kb ram)
2011-05-17 15:50:11 +02:00
Max Horn
82343f6649
SCUMM: Remove some unused var warnings (see bug #3293800 )
2011-05-14 23:50:43 +02: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
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
75b9deb185
SCUMM: Get rid of the MemBlkHeader hack
...
This uncovered at least one potentially serious bug in the inventory
code, which still needs to be investigated and fixed.
2011-05-13 11:47:10 +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
0ce2ca4e00
COMMON: Replace MKID_BE by MKTAG
...
MKID_BE relied on unspecified behavior of the C++ compiler,
and as such was always a bit unsafe. The new MKTAG macro
is slightly less elegant, but does no longer depend on the
behavior of the compiler.
Inspired by FFmpeg, which has an almost identical macro.
2011-04-12 16:53:15 +02:00
Max Horn
55e65cee80
SCUMM: Cleanup
2011-04-05 15:18:08 +02:00
Max Horn
a12dada822
SCUMM: Fix off-by-one mistakes in out-of-bounds checks; name some constants
2011-04-05 15:18:08 +02:00
Max Horn
6eeebfb191
SCUMM: Check for cutSceneStackPointer underflows
2011-04-04 09:56:50 +02:00
Max Horn
a7248a0601
ENGINES: Replace many printfs by warning/debug/debugN
...
svn-id: r54031
2010-11-01 21:37:47 +00:00
Max Horn
6175c2bb19
SCUMM: Fix potential bug in ScummEngine::resStrLen.
...
In particular, it might happen that ScummEngine::resStrLen is called
while the _scriptPointer is stale. In that case, it would be working
with the stale pointer. If the code calling it then uses fetchScript*()
methods to read the string whose length was just computed, then it would
read potentially *different* data (e.g. copyScriptString or
loadPtrToResource could have been affected).
I am not sure if this actually could have caused bugs somewhere; it might
even be provable that a script relocation cannot happen in all places
that invoke resStrLen. But for now it's much easier to make the code
safe than to verify that theory ;).
Also simplified some related code.
svn-id: r53572
2010-10-18 18:55:24 +00:00
Max Horn
d69a63c145
SCUMM: Move common code from ScummEngine::fetchScript* to new method.
...
The new method is called refreshScriptPointer(). Also renamed
getScriptEntryPoint() to resetScriptPointer() in an attempt to highlight
both the similarity and difference between the two.
svn-id: r53571
2010-10-18 18:43:13 +00:00
Max Horn
5602b2cf81
SCUMM: Move setResult/getResultPos to script_v5.cpp
...
svn-id: r52129
2010-08-16 19:57:35 +00:00
Max Horn
b8ee574e40
SCUMM: _resultVarNumber and related methods are specific to v0-v5
...
svn-id: r51974
2010-08-11 12:49:16 +00:00
Travis Howell
0702bdab82
Fix regressions in Let's Explore the Jungle with Buzzy.
...
svn-id: r47622
2010-01-28 00:28:08 +00:00
Travis Howell
4350f7b8c0
Fix objects structure and object scripts in PCE version of Loom.
...
svn-id: r45335
2009-10-22 11:33:05 +00:00
Max Horn
d91d68a9ca
SCUMM: Fix verb/sentence handling in Indy3 mac (there, a double click must be used to trigger a verb/sentence)
...
svn-id: r42907
2009-07-29 20:35:50 +00:00
Max Horn
2205541e86
SCUMM: Enable looping in Indy3Mac sound effects
...
svn-id: r42898
2009-07-29 18:35:34 +00:00
Max Horn
fcdd3b0310
SCUMM: Rewrote ScummEngine::inventoryScriptIndy3Mac for clarity
...
svn-id: r42889
2009-07-29 11:48:20 +00:00
Travis Howell
c02ad3b7bf
Add patch #2821100 - MM C64 Objects / Verb fixes, with minor clean up applied.
...
svn-id: r42737
2009-07-25 06:27:41 +00:00
Travis Howell
9c06549d31
Hack is no longer required, due to revision 42498.
...
svn-id: r42499
2009-07-15 05:00:59 +00:00
Johannes Schickel
59aa80b2d2
Fix mismatching format arguments.
...
svn-id: r42105
2009-07-04 18:54:27 +00:00
Max Horn
99df028d35
SCUMM: Got rid of o6_invalid
...
svn-id: r39957
2009-04-16 09:27:02 +00:00
Max Horn
432e7917a5
SCUMM: Switched opcode tables to use Common::Functor0 (a bit like Kyra does it)
...
svn-id: r39956
2009-04-16 09:26:37 +00:00
Max Horn
6f4b567124
SCUMM: Split intern.h into multiple headers
...
svn-id: r39567
2009-03-20 16:33:58 +00:00
Travis Howell
241d995586
Clear cutsceneOverride for all scripts (except current), when restarting any game, fixes bugs:
...
#1923193 - MONKEY: cannot restart during the intro
#2518226 - FT demo: debugger at end of demo
svn-id: r38398
2009-02-17 09:41:21 +00:00
Travis Howell
501b321532
Revert talkspeed changes, while still only using the game specific talkspeed setting (if it exists). And clarify the talkspeed differences between games in the README.
...
svn-id: r36299
2009-02-13 10:04:17 +00:00
Max Horn
32f735a228
cleanup
...
svn-id: r35131
2008-11-20 13:50:53 +00:00
Max Horn
3a3698f960
Fix for bug #2251765 : FT: Talk speed inconsistency
...
svn-id: r35082
2008-11-15 13:54:16 +00:00
Max Horn
d4853dd9e8
Patch #2060517 : SCUMM: engine sets incorrect talkspeed value
...
svn-id: r34596
2008-09-17 18:56:13 +00:00
Max Horn
eb649983fc
SCUMM: Renamed inventoryScript -> inventoryScriptIndy3Mac
...
svn-id: r33654
2008-08-06 09:13:57 +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
0723e3e24a
Introduced ClickArea enum, some related cleanup in runInputScript and checkExecVerbs
...
svn-id: r27778
2007-06-29 23:08:15 +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
Travis Howell
d1d5579549
Fix script error in PC Engine version of Loom.
...
svn-id: r25958
2007-03-04 00:44:04 +00:00
Travis Howell
8e70329ce3
Fix level selection in PC Engine version of Loom.
...
svn-id: r25954
2007-03-03 23:02:54 +00:00
Travis Howell
d64d6bcb7e
Add stopObjectCode() differences in SCUMM 1 - 5 games. The nested script stack wasn't been checked.
...
svn-id: r24751
2006-11-20 03:21:09 +00:00
Travis Howell
3789828993
The script freezeCount isn't used by SCUMM 1/2 games at all
...
svn-id: r24741
2006-11-19 00:38:37 +00:00
Travis Howell
5d4543a59c
Fix bug #771499 - ZAK: Lotto numbers never picked. The freezeCount isn't checked in runScriptNested(), when restarting script in SCUMM 1/2.
...
svn-id: r24575
2006-10-30 01:53:19 +00:00
Max Horn
083a7c2549
SCUMM: The didexec flag did not exist in V0-V2; minor cleanup
...
svn-id: r24571
2006-10-29 18:42:28 +00:00
Torbjörn Andersson
bcd4591da4
Workaround for bug #1555938 ("MI2: Inventory object cloning"), as suggested by
...
Fingolfin.
svn-id: r24080
2006-10-02 21:38:39 +00:00
Max Horn
d02e4d7f7c
Removed CHECK_HEAP
...
svn-id: r23979
2006-09-23 11:29:32 +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
e1ea1b90a2
Fix string formating in Russian versions of HE72+ games
...
svn-id: r23820
2006-09-02 12:47:29 +00:00