118 Commits

Author SHA1 Message Date
sluicebox
9be84837b3 SCI: Add speed_throttle debug command
Allows testing the speed throttler for possible improvements
and to demonstrate what it affects and what it doesn't.

`speed_throttle 0` disables kGameIsRestarting throttling.
(Except for game-specific workarounds.)

This command is possible due to several recent cleanups of other
throttling mechanisms that overlapped and were absorbed by this one.
2022-08-12 00:33:20 -04:00
sluicebox
82a16d71a9 SCI: Add debugging commands for Game Flags 2022-05-22 11:20:41 +03:00
Eugene Sandulenko
abea37c9bb
ALL: Update ScummVM project license to GPLv3+ 2021-12-26 18:48:43 +01:00
Paul Gilbert
ba147f5ad5 SCI: Refactor to use Engine debugger 2020-02-16 13:07:19 +02:00
Zvika Haramaty
ac87c01895 SCI: debugger: disasm - added 'bcc' parameter, to use in C code
'bcc' is based on 'bc', but prints in format that's can be used in
C code for patches - just copy and paste (without the address column).
2020-02-13 23:42:06 +02:00
Bastien Bouclet
553d2968bb SCI: Add override keywords 2020-02-09 12:43:16 +01:00
Filippos Karapetis
941869c466 SCI32: Remove reg32_t and use reg_t in all cases
reg32_t was a transitive solution, before reg_t's were
adapted to use 32-bit addresses internally, and before
support for SCI3 was added. It was introduced as another
way to handle large script offsets in SCI3, and was only
used for the program counter (PC). It's no longer
needed, as we now support SCI3 script offsets using
reg_t's, so we can use make_reg32 in all cases where
we need to access offsets over 64KB
2018-08-25 12:39:12 +03:00
Colin Snover
836f1bdf44 SCI32: Add audio dump debugger command 2017-09-19 19:54:29 -05:00
Colin Snover
29b338fff7 SCI: Add resource integrity dump command to debugger 2017-09-08 16:02:32 -05:00
Colin Snover
67fcb0bdaf SCI: Allow deep inspection of objects in debugger 2017-09-04 15:19:59 -05:00
Colin Snover
8bab5a3467 SCI: Resolve offset names when disassembling object methods 2017-07-23 10:35:13 -05:00
Willem Jan Palenstijn
0f0ecff0b8 SCI: Print breakpoint info on creation 2017-06-10 21:32:35 +02:00
Willem Jan Palenstijn
423ecde8e0 SCI: Move printObject from console to scriptdebug 2017-06-10 21:32:35 +02:00
Willem Jan Palenstijn
8e683db72b SCI: Add break/log/backtrace actions for triggered breakpoints
The action can be set using the new console command bp_action/bpact.
2017-06-10 21:32:35 +02:00
Colin Snover
8bdfb78895 SCI32: Add debugger command to list digital audio samples 2017-04-23 13:07:25 -05:00
Colin Snover
fcaf15aa50 SCI: Add alloc_list command to debugger
This command lists all resources that are currently loaded into
memory, plus the number of locks that exist on each loaded
resource.
2017-04-22 19:38:13 -05:00
Colin Snover
4814682d5f SCI: Improve disassembly output
1. pushi opcode now displays decimal value and selector value (if
   one exists) in-line
2. lofsa, lofss, and super opcodes now display resolved
   object/class names
3. Opcode arguments are visually aligned
2016-11-20 12:31:44 -06:00
Colin Snover
9380b54120 SCI: Add code-address breakpoints to debugger 2016-11-20 12:31:43 -06:00
Colin Snover
a605a891bb SCI: Add reference dump to disk in debugger
This allows references in memory to be dumped to disk for
examination by other tools. In the case of SCI32 bitmaps, data
is output in 8-bit TGA format without transparency, which allows
the current palette to also be examined. (The alternative would
be to use 32-bit TGA to display transparency, and lose the
palette, or dump to a more complicated format that supports 1-bit
transparency.)
2016-11-02 11:27:22 -05:00
Colin Snover
d0ec919fb7 SCI: Fix crash when attempting to view invalid list, array, bitmap references 2016-10-09 13:52:04 -05:00
Colin Snover
13f2a2c3bd SCI32: Add debugger command to view screen items in the visible plane list 2016-03-07 16:46:25 -06:00
Lars Skovlund
98878d69b8 SCI: Add vocab994 console command
This is intended for early SCI2, but should work with older SCI too,
not that we need it.
2016-02-29 16:00:13 +01:00
Colin Snover
75ccabc325 SCI: Implement accurate renderer architecture for SCI32 2016-02-18 13:18:02 -06:00
Martin Kiewitz
bfab4c4cbe SCI: debug commands scro, scrs and script_said
implement string collecting for SCI3
implement object offset collecting for SCI0-SCI2
implement said-str offset collecting for SCI0-SCI1
add new debug command scro / script_objects
add new debug command script_said
string without terminating NUL now a warning
the latter happens in qfg2 for amiga room 84
2015-05-14 20:33:21 +02:00
Martin Kiewitz
ed7007162a SCI: Scripts: identify strings + debug command
debug command is called "script_strings" / "scrs"
2015-05-04 21:19:05 +02:00
Martin Kiewitz
9a9f569f3b SCI: debugger / fix diskdump + list commands
diskdump: support for audio36+sync36
list: always show tuple for audio36+sync36
2015-03-18 23:30:32 +01:00
Johannes Schickel
8fc7d60feb SCI: Make GPL headers consistent in themselves. 2014-02-18 02:39:37 +01:00
Willem Jan Palenstijn
3f8d2fae8a SCI: Remove unused variable 2013-04-15 20:58:22 +02:00
Filippos Karapetis
20b6770808 SCI: Change the program counter (PC) to be a 32-bit variable
This is needed for future support of large SCI3 scripts. The program
counter is isolated and does not interfere with other parts of the VM,
plus it does not get stored in saved games, so it's pretty straightforward
to convert
2012-06-23 21:45:26 +03:00
Filippos Karapetis
6cda15ba8e SCI: Added two new debug commands, plane_list and plane_items
These can be used to debug drawn items in SCI32
2012-05-21 01:30:10 +03:00
Willem Jan Palenstijn
50176e7c5f SCI: Add saved_bits/show_saved_bits console commands 2011-06-12 01:55:30 +02:00
strangerke
69b1485a22 GIT: Clean up: Suppress SVN tags, now useless 2011-05-12 01:16:22 +02:00
md5
4df049f4d7 SCI: Added a new console command "window_list" or "wl"
This can be used to see a list of the currently open windows. Also, added
a sanity check for the "al" command and performed some minor cleanup
2011-03-20 14:56:13 +02:00
md5
1e68000def SCI: Added a new console command, "animate_list" or "al"
This shows the current animation list, along with object properties,
positions and the scripts they belong to
2011-03-20 04:10:29 +02:00
Willem Jan Palenstijn
6fe95780d3 SCI: Continue disasm until no jumps go past the current opcode
This should ensure disasm will disassemble an entire function, and
not stop at an intermediate ret opcode.
2011-03-12 23:46:32 +01:00
Filippos Karapetis
6f9ac84f77 SCI: Converted the robot decoder into a regular video decoder, and decoupled it from the
SciEngine class

- Robot videos are now shown in frameOut(), like they should, and kRobot(sync) is only
used for syncing with the game scripts
- Hooked video playing into the "play_video" console command

svn-id: r55801
2011-02-07 12:24:09 +00:00
Filippos Karapetis
512bcf8b90 SCI: Rewrote the robot playing code in a way similar to other video decoders
- The code now streams videos instead of loading them in memory, without utilizing seeking
- Removed the sound-related robot code from the graphics classes
- Started implementing the code for the sound in robot videos (still not finished)

svn-id: r55772
2011-02-04 17:51:59 +00:00
Lars Skovlund
dc27a22026 SCI: Added stub for playing robot audio from the console
svn-id: r55424
2011-01-22 13:12:01 +00:00
Filippos Karapetis
6b250f8c9b SCI2/2.1: Improvements to the find_callk debug function, and some kernel function updates
- Improved the find_callk function to properly find the end of script objects, by
monitoring jump calls
- Added three extra special calls to find_callk: find kernel function calls to dummy,
unused and unmapped kernel functions
- Updated several kernel function calls because of the above functionality
- The above functionality has also uncovered a VM bug in some SCI2/2.1 opcode - added 
a FIXME for it

svn-id: r55151
2011-01-07 18:25:38 +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
Filippos Karapetis
9d318497f7 SCI: Unified the functionality and parameters of the disasm and disasm_addr commands
svn-id: r54276
2010-11-17 08:05:11 +00:00
Filippos Karapetis
c2d9c1b06b SCI: Added the ability to display original script bytecode in the "disasm" console command
svn-id: r54275
2010-11-17 00:05:09 +00:00
Filippos Karapetis
dca3c8d8bf SCI: Play time related changes
- Added support for savegame play time
- Removed obsolete variables for calculating the play time (EngineState::gameStartTime and Console::_enterTime)
- Renamed some variables to camelCase

svn-id: r53974
2010-10-31 01:45:24 +00:00
Filippos Karapetis
3a4647dc50 SCI: Several changes related to MT-32 -> GM mapping
- Changed C - style comments in map-mt32-to-gm.h to C++ - style comments
- Added a new dynamic MT-32 -> GM mapping, complementary to the normal one, which can be done on the fly using the new console command "map_instrument"
- The "show_instruments" command has been moved to the music section and now displays the instruments of the game which aren't in the MT32-> GM mapping

svn-id: r53902
2010-10-28 12:48:51 +00:00
Filippos Karapetis
3d85d6804b SCI: Added a new debug command, "find_callk"
This command can be used to find the object methods (including their
corresponding objects and owner scripts) that call a specific kernel
call. This shall aid us track all the spots where a particular kernel
function is called from, therefore it'll be a bit easier to find
examples where unimplemented kernel functions are called

svn-id: r53646
2010-10-20 17:31:29 +00:00
Filippos Karapetis
4e27844fef SCI: Some changes regarding resources
- Renamed the debug command "resource_size" to "resource_info", as it now provides
the location of where a specified resource is found (i.e. the resource.xxx file, or
the file name itself, if the resource is a patch)
- "duskdump" shows the original location of dumped resources
- loadResource() now shows the location of files that couldn't be loaded

svn-id: r52667
2010-09-10 14:07:32 +00:00
Martin Kiewitz
cf3289ee3f SCI: adding "bpr" and "bpw" debug commands
"bpr" breakpoint on reading of selectors
"bpw" breakpoint of writing of selectors
"bpx" is now breakpoint on executing of selectors only

svn-id: r52490
2010-09-02 09:05:08 +00:00
Martin Kiewitz
fcede4680a SCI: adding bpk debug command
currently removing or listing such breakpoints is not yet supported

svn-id: r51710
2010-08-03 19:06:40 +00:00
Matthew Hoops
142fb8a1f1 SCI: Don't include the time running the debugger in the game running time
svn-id: r51548
2010-07-31 19:18:35 +00:00
Martin Kiewitz
3a45e47c5c SCI: adding new debug command logkernel
svn-id: r51220
2010-07-23 20:47:15 +00:00