[Scummvm-devel] readline support for debugger :)
Tom Dunstan
tommyd at senet.com.au
Sat Nov 17 07:46:04 CET 2001
Hi folks
Firstly, I just want to say how amazingly impressed I was when I first
saw scummvm about a week ago. My jaw just dropped the first time I ran
it. Major kudos to all involved.
I've been having a bit of a play, trying to work out how it all works,
which hasn't been easy given the current state of docs and comments. :)
So I was playing with the debugger and got annoyed that I had to keep
typing the same thing in over and over again. They say that every open
source project starts by scratching someone's personal itch... well, I
got fed up and implemented readline support with minimal command
completion and editing history.
Here's a zip file with the changed files. If you want me to contribute
code in another way, let me know what to do (unified diffs or something?).
Notes:
- Readline gives you a dynamically allocated string rather than using a
static fixed length buffer, so I needed to modify the source a little
bit to allow both the currect default behaviour and using readline.
- I've never programmed anything using readline before, so I've
probably made some horrible gaffs. It Works For Me (TM) though.
- Readline comes as a default install on linux distros... for you poor
souls running win32 (and listening to the music, damn you :) ) you're
probably out of luck, unless you want to install readline yourself. The
gcc distro that I've got for windows here doesn't include it.
All comments / criticism / flames welcome. Yes, I know it's a bit silly
to implement command completion when the commands are currently
optionally one letter long. Maybe not always.
I'd like to be able to check out actor / room / object data using
symbolic names if at all possible (and completion could then be added to
the readline code). Is it possible? I can't find any fields in the
structs that I'm looking at which are obvious name fields or anything.
Is such metadata present in the game files at all, or was it compiled
into oblivion before the games shipped?
Thanks
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: debugrl.zip
Type: application/zip
Size: 4300 bytes
Desc: not available
URL: <http://lists.scummvm.org/pipermail/scummvm-devel/attachments/20011117/283d439e/attachment.zip>
More information about the Scummvm-devel
mailing list