Difference between revisions of "Debug Modes"
Line 247: | Line 247: | ||
|- | |- | ||
| ALT + D||Exits debug mode (BC) | | ALT + D||Exits debug mode (BC) | ||
+ | |- | ||
+ | | SHOW PRIORITY||Shows priority screen | ||
+ | |- | ||
+ | | SET PRIORITY||Sets priority * | ||
+ | |- | ||
+ | | RELEASE PRIORITY||Returns to normal visual screen | ||
|} | |} | ||
Revision as of 20:41, 24 October 2013
Partially based on the On-Line Debug Mode FAQ by HWM
Introduction
This debug mode is solely script related. A debug script is located directly in the game logic itself, not in the interpreter (although the interpreter of course offers the commands to use in the script). If a game does not have the debug script in its logic, it will not work. However, pretty much all the games have a debug mode, except for Mixed-Up Mother Goose and the Manhunter series. The latter does have some unused messages relating to a debug mode in it, but it's likely removed from the final release. The AGI demo packs and other demonstrations also don't include a debug mode.
AGI1 is an old and uncommon interpreter. The only games using it are the rare first (booter) versions of King's Quest 2 and The Black Cauldron. However, the AGI1 games do have a debug mode, so they're included here. Donald Duck's Playground is also a booter game, but in many aspects more like AGI2, including the version number given by Sierra (v2.001), so it's listed under AGI2. The first release of King's Quest 1 is sometimes listed as AGI0, but technically this more a container category for the first versions of the first release of King's Quest, not really one interpreter.
AGI2 and AGI3 have few differences and have similar debug functions. Debug-wise the only major difference is that AGI3 does not contain the trace-function. AGI3 games are Gold Rush!, King's Quest 4 AGI, the Manhunter series and a certain version (v2.10) of The Black Cauldron. Some demos also use AGI3. The rest of the games use AGI2.
Activating Debug Modes
Most AGI games still have the debug code that developers used while the games were being developed. Most of the games activate their debug modes by simply pressing the [ALT-D] key combination. The other games use a "magic phrase" to enter the debug mode. Once activated, here are commands that can be used.
Activating AGI1 Debug Modes
In King's Quest 2, the debug mode is activated by entering "FAST SPEAK" at the command line. It will be activated on room change. In The Black Cauldron, the debug mode is activated by pressing [ALT + D]. This would eventually become the standard way of activation. The debug mode will be deactivated on room change. Also, activating the debug mode multiple times will generate multiple input/output lines!
Game Debug Phrase King's Quest II "fast speak" (activated on room change) The Black Cauldron Alt+D
Activating AGI2/AGI3 Debug Modes
Of all the AGI games, it is unknown whether the KQ4AGI 256K version, Manhunter 1, Manhunter 2 and Mixed-Up Mother Goose have a debug mode or not. KQ4 will almost certainly have one, while Mixed Up Mother Goose probably doesn't even though its WORDS.TOK file has all the debug words contained in it. MH2 has some kind of debug mode which allows you to teleport and change variable values because there are text messages in the first LOGIC file along these lines. MH1 probably has the same debug mode.
Again, the debug mode is usually activated by pressing [ALT + D]. However, there are some alternative ways/exceptions with some games. These games require a certain sentence to be typed in; perhaps this was done to access the debug mode on other platforms, without redefining keys in the code. The games and their sentences are:
Game Debug Phrase Gold Rush! "bird boy" or "bird man" King's Quest 1 Alt+D King's Quest II "fast speak" or Alt+D King's Quest III "rats ass" (v2.14) or Alt+D King's Quest IV AGI Alt+D Leisure Suit Larry 1 Alt+D Police Quest 1 "stink bug" or "stink bugs" (v2.0G) Space Quest 1 "backstage" or "dbg" Space Quest II "dbg" or Alt+D
Debug Mode Commands
AGI1 Debug Mode Commands
After the debug mode is activated, the following commands are available:
Room and Ego Commands
Command Result ROOM Displays room number TP (room number) Teleport to specified room (change room/scene/script) SP Shows position of ego * SHOW POSITION Show ego's current screen coordinates * POSITION + (new coordinates) Change egos position SHOW PRIORITY Displays the current rooms priority bands and control lines SET PRIORITY Set the priority of ego RELEASE PRIORITY Release the last priority that ego was set to * Does not work with King's Quest 2
Flag and Variable Commands
Command Result SHOW FLAG Displays a specified flag (one of 256 flags) SET FLAG Sets a specified flag (one of 256 flags) RESET FLAG Clears specified flag (one of 256 flags) SHOW VAR Displays one of the 256 variables SET VAR Change the value of one of the 256 variables Object/Inventory Debug Commands
Command Result OBJECT NUMBER Displays list of all the objects and their object numbers OBJECT ROOM Displays which room an object is found in GET OBJECT Get specified object and added to inventory GIMME GIMME Get all inventory items * There are 256 variables and 256 flags
Misc Debug Commands
Command Result QUIT Quit game (originally, but now locks up)
AGI2/AGI3 Debug Commands
After the debug mode is activated, the following commands are available:
Room and Ego Commands
Command Result ROOM Displays room number TP (room number) Teleport to specified room (change room/scene/script) SP Shows position of ego * SHOW POSITION or POSITION? Show ego's current screen coordinates * POSITION + (new coordinates) Change egos position SHOW PRIORITY Displays the current rooms priority bands and control lines SET PRIORITY Set the priority of ego RELEASE PRIORITY Release the last priority that ego was set to * Does not work with King's Quest 2
Flag and Variable Commands
Command Result SHOW FLAG Displays a specified flag (one of 256 flags) SET FLAG Sets a specified flag (one of 256 flags) RESET FLAG Clears specified flag (one of 256 flags) SHOW VAR or SHOW VARIABLE Displays one of the 256 variables SET VAR or SET VARIABLE Change the value of one of the 256 variables Object/Inventory Debug Commands
Command Result OBJECT NUMBER Displays list of all the objects and their object numbers OBJECT ROOM Displays which room an object is found in GET OBJECT Get specified object and adds to inventory GIMME GIMME Get all inventory items * There are 256 variables and 256 flags
Misc Debug Commands
Command Result QUIT Quit game (originally, but now locks up) [SCROLL LOCK] Trace mode* * Only works with AGI v2
Game Specific Debug Commands
The Black Cauldron
Command Result GIMME GIMME All objects get added to inventory OBJECT ROOM Shows in which room certain object is located SHOW OBJECT Gives information on objects on screen (BC) ALT + P Shows priority screen ALT + M Shows available memory ALT + I Gives information on objects on screen ALT + E Shows position of ego ALT + D Exits debug mode (BC) SHOW PRIORITY Shows priority screen SET PRIORITY Sets priority * RELEASE PRIORITY Returns to normal visual screen
King's Quest III
Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:
Command Result GIMME GIMME All objects get added to inventory OBJECT ROOM Shows in which room certain object is located OBJECT Gives information on objects on screen (PQ & KQ4) ROOM Shows coordinates of ego ALT + P Shows priority screen * ALT + M Shows available memory * ALT + I Gives information on objects on screen ALT + E Shows position of ego ALT + X Shows coordinates of ego enchanter status Were wizard is, when he'll return, etc. do chore To have your task done for you. sleep enchanter To put him to sleep. bye bye enchanter To kill him. * King's Quest 3 has several versions and with some this command won't work, or will use different keys like F6 or F10 (e.g. v1.01)
King's Quest IV AGI
Note: In the newer versions of the games most of the debugging commands do not work
Command Result TP Teleport to room * GIMME GIMME All objects get added to inventory OBJECT ROOM Shows in which room certain object is located OBJECT Gives information on objects on screen ROOM Shows coordinates of ego ALT + P Shows priority screen ALT + M Shows available memory ALT + I Gives information on objects on screen ALT + E Shows position of ego ALT + X Shows coordinates of ego * For a list of room numbers for KQ4, see the King's Quest IV Room Maps.
Leisure Suit Larry 1
Press ALT+D and press enter twice to enable Debug Mode.
Command Result TP (room #*) Teleport to specified room. OBJECT NUMBER Shows list of objects in game OBJECT ROOM Shows in which room certain object is located ALT+I or SP (object #) Shows information about screen objects GET OBJECT (item #) To get specified object GIMME GIMME All objects get added to inventory ROOM NUMBER X/Y Coordinates and current room number EXAMINE POSITION Shows coordinates of ego FIND Shows position of ego ALT + P Shows priority screen ALT+V or PRIORITY Displays priority screen ????????????????? ALT + M Shows available memory ALT + I Gives information on objects on screen ALT + E Shows position of ego SHOW VAR or SV Display value of variable SET VAR or CHANGE VAR Change value of variable SET FLAG or SF Set a flag VIEW FLAG or SHOW FLAG See flags RESET FLAG Reset a flag ALT+M Display heap size * For a list of room numbers, see here.
Police Quest
Command Result GIMME GIMME All objects get added to inventory OBJECT ROOM Shows in which room certain object is located OBJECT NUMBER Shows list of objects in game OBJECT Gives information on objects on screen ROOM Shows coordinates of ego ALT + P Shows priority screen ALT + M Shows available memory ALT + I Gives information on objects on screen ALT + E Shows position of ego ALT + X Shows coordinates of ego Space Quest I-II
Command Result tester Displays Rogers screen coordinates.