Commit Graph
91 Commits
Author SHA1 Message Date
Donovan Watteau 908f638d85 SCUMM: DEBUGGER: Add OBIM and OBCD offsets to objects command 2022-09-29 02:24:10 +03:00
AndywinXp 8f744954c3 JANITORIAL: SCUMM: Improve readability of AKOS code
This is part of an on-going effort on my end to document the AKOS code, and fix strange stuff
such as integers being used as booleans, and variable_names instead of variableNames
2022-09-27 00:14:26 +02:00
AndywinXp 7fb79ea697 SCUMM: AKOS: Document opcodes
It was getting painful to go through the AKOS system without proper opcodes documentation, so here it is.
This was checked against COMI and SCUMM HE code, for names consistency.
2022-09-26 19:07:07 +02:00
AndywinXp 9e5661fcd1 SCUMM: DEBUGGER: Fix debugger being able to crash DIG at startup 2022-09-17 09:39:19 +02:00
AndywinXp 1d97c535c2 SCUMM: DEBUGGER: Fix DiMUSE instruction creating audio bugs when opening the menu during sequences 2022-09-15 23:54:57 +02:00
BLooperZ 3776b4c384 SCUMM: HE: dump costume script 2022-08-29 21:51:37 +02:00
Donovan Watteau 15f0d06bfe SCUMM: Document all the available actor commands in the debugger 2022-08-20 00:05:51 +03:00
Donovan Watteau c3b30b75a6 SCUMM: Add a grail command to the debugger
This prints the number of the real Grail object when counting from the
left in the final room with the knight in Indy3.

May be useful since there are many Grails, choosing the wrong one kills
you and makes you restart the 3 trials again, and the hints to find it
require the original manual and taking notes during the game.
2022-06-13 20:22:51 +03:00
Donovan Watteau aa0db1a597 SCUMM: Handle getObjOrActorName() NULL strings in the debugger
getObjOrActorName() may return a nullptr, but giving a null pointer to
printf()-like functions is undefined, and OpenBSD complains about it.

Hardcode "(null)" in that case; that's the default value on Windows,
macOS and Linux.
2022-05-30 08:33:33 +03:00
Eugene Sandulenko 5e05f93f36 ALL: Remove Symbian port 2022-05-28 12:32:29 +02:00
Torbjörn Andersson ff1957196d SCUMM: Fix draft name in "drafts" debug command
It's "Straw Into Gold", not "Straw to Gold".
2022-04-26 18:04:15 +02:00
Andrea Boscarino 6b0b516d56 SCUMM: Fix debug print in DiMUSE debugger 2021-12-29 16:04:34 +01:00
Andrea Boscarino c3aa652998 SCUMM: DiMUSE: Add debugger/audio player 2021-12-29 14:26:53 +01: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
sluicebox f2f28c4549 COMMON: Rename DebugManager methods, update comments 2021-06-14 12:42:38 -05:00
D G Turner ee79aba82d SCUMM: Fix GCC Duplicated Condition Warning
These are flagged by GCC if -Wduplicated-cond is enabled.
2019-10-04 07:58:10 +01:00
Adrian Frühwirth d433aedf37 SCUMM: Improve 'imuse play' debugger command error handling
This commit introduces the following (seemingly non-invasive) changes
to make the 'imuse play' debugger command more useful (i.e. don't crash
when trying to load the wrong kind of (sound) resource.

* ScummEngine::readSoundResource()
  Instead of fatally error()'ing upon hitting a non-sound resource type,
  e.g. a room header (0x524d4844 aka RMHD), we now only issue a warning().
  This enables the already existing dead code which properly returns 0
  (aka no resource loaded).

* ResourceManager::validateResource()
  Instead of fatally error()'ing upon hitting an illegal glob type we now
  only issue a warning() and return false (also existing dead code).
  All methods calling validateResource() check its return value so this
  seems like the right thing to do anyway.

* ScummDebugger::Cmd_IMuse()
  Instead of directly calling ensureResourceLoaded() we now call
  getResourceAddress() instead (which in turn calls ensureResourceLoaded()
  and handles other edge cases) and only attempt to play a sound if the
  returned pointer actually is valid.

Fixes Trac#10527.
2018-06-03 19:38:52 +01:00
Ori Avtalion cfeae98eb0 SCUMM: Add actor/object names to debug output 2016-07-02 12:22:50 +03:00
Torbjörn Andersson d582c8492c SCUMM: Fix argc check in Cmd_Script() 2015-03-22 12:22:30 +01:00
Johannes Schickel 8b7672b64c ALL: Introduce typesafe Debugger::registerVar functions.
This also adds a FIXME to SCI which registered an enum type as int...
2014-05-27 02:04:08 +02:00
Johannes Schickel 30d64edac4 ALL: Make Debugger command function names conform to our guidelines. 2014-05-27 02:04:08 +02:00
Johannes Schickel ae4ffe01f0 ALL: Rename Debugger::DCmd_Register to Debugger::registerCmd. 2014-05-27 02:04:08 +02:00
Johannes Schickel 0adca2c579 ALL: Rename Debugger::DVar_Register to Debugger::registerVar. 2014-05-27 02:04:07 +02:00
Johannes Schickel daa8d57a86 ALL: Rename Debugger::DebugPrintf to Debugger::debugPrintf. 2014-05-27 02:04:07 +02:00
D G Turner e065b24d56 SCUMM: Remove "level" command from debugger. Replaced by "debuglevel".
This required a small amount of extra code changes to ensure that
_debugMode is kept in sync when the debugger is used to change the
level.
2014-05-13 15:14:54 +01:00
Johannes Schickel 3847465163 SCUMM: Make GPL headers consistent in themselves. 2014-02-18 02:39:38 +01:00
Johannes Schickel 6485b291e9 SCUMM: Fix Loom (and some other graphics regressions).
These are regressions from c05cb7f3bb. They were
caused by VirtualScreen::getPixels differing from Surface::getBasePtr and I
accidently used the former in some cases in the conversion.

I also fixed a bug in debugger.cpp which exchanged x and y.
2013-08-04 02:29:13 +02:00
Johannes Schickel c05cb7f3bb SCUMM: Prefer getBasePtr over direct Surface::pixels access. 2013-08-03 02:52:31 +02:00
Torbjörn Andersson 38b2a8518f SCUMM: Fix the "drafts" debugger command for Mac Loom
Mac Loom's drafts appear to be stored from variable 55 and upwards.
I'm working under the assumption that there's either only one
version of Loom for the Mac, or that they all behave the same. I
could be wrong about that.
2012-11-16 22:13:23 +01:00
Torbjörn Andersson 8658d008d5 SCUMM: Remove obsolete part of the "drafts" debugger command
It was never quite clear exactly what "drafts fix" did. It wasn't
guaranteed to work on all versions of Loom - or at all - and I
haven't heard any reports about the data structure getting
corrupted for years.
2012-11-16 21:30:56 +01:00
Johannes Schickel 89abab97e3 JANITORIAL: Remove trailing whitespaces.
Powered by:
git ls-files "*.cpp" "*.h" "*.m" "*.mm" | xargs sed -i -e 's/[ \t]*$//'
2012-09-26 04:17:55 +02:00
Tobias Gunkel 96f8fc6ca9 SCUMM: Fix actor ID handling in v0
Some object functions allow actor IDs and object IDs as parameters. They are easily distinguishable in engines > 0 as actor IDs are < _numActors and object IDs are bigger. In v0 this is not the case as there are objects with IDs like 3 and 5 (e.g. the hamster). So object ID handling was unified for v0 and the other engines by introducing objIsActor(), objToActor() and ActorToObj().
2012-02-11 08:29:13 +01:00
Tobias Gunkel 347035385e SCUMM: merge object v0 id and type into one object var 2012-02-11 08:28:49 +01:00
Tobias Gunkel c138ef6709 SCUMM: merge _activeObjectNr/_activeObjectType and _cmdObjectNr/_cmdObjectType 2012-02-11 08:28:46 +01:00
Tobias Gunkel f2309998ff SCUMM: fix debugger for v0 2012-02-11 08:28:44 +01:00
Eugene Sandulenko 55b95e3f50 SCUMM: Fix copy/paste errors 2011-11-03 01:34:53 +00:00
Max Horn dc85f5c473 SCUMM: Show actor visible height in debugger 2011-05-14 16:30:30 +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 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
Max Horn b37463fe59 SCUMM: Move class ResourceManager to its own header 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
Ori Avtalion 9414d7a6e2 JANITORIAL: Reduce header dependencies in shared code
Some backends may break as I only compiled SDL
2011-04-28 15:08:58 +03:00
Max Horn 6bd180646d SCUMM: Extend debug command 'object' to allow querying state 2011-04-04 13:04:17 +02:00
Max Horn 2d1c8a3533 ALL: Fix whitespaces / indention
svn-id: r55818
2011-02-07 23:01:06 +00:00
Max Horn 6edc86a19b DEBUG: Let GUI::Debugger::preEnter and postEnter (un)pause the engine
svn-id: r54815
2010-12-07 18:54:21 +00:00
Max Horn d2a7a840c7 SCUMM: Move class Player_V2CMS to its own header file
svn-id: r53829
2010-10-25 16:41:39 +00:00
Max Horn c975ed11a1 ALL: Fix various typos (patch #3093266)
svn-id: r53762
2010-10-24 13:04:33 +00:00