Difference between revisions of "Debug Modes"

From AGI Wiki
Jump to navigationJump to search
 
(102 intermediate revisions by the same user not shown)
Line 4: Line 4:
 
== <br />Introduction ==
 
== <br />Introduction ==
  
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 pushing 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.
+
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|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|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 ([[w:PC booter|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 [[w:PC booter|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|Manhunter  series]] and a certain version (v2.10) of [[The Black Cauldron]]. Some demos also use [[AGI3]]. The rest of the games use [[AGI2]].
 +
 
 +
&nbsp;
 +
 
 +
== 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.
 +
 
 +
&nbsp;
 +
<blockquote>
 +
=== 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!
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Game!!width="625"|Debug Phrase
 +
|-
 +
| [[King's Quest II]]||"fast speak" (activated on room change)
 +
|-
 +
| [[The Black Cauldron]]||Alt+D
 +
|}
  
 
&nbsp;
 
&nbsp;
  
== Standard AGI Debug Mode Commands ==
+
===  Activating AGI2/AGI3 Debug Modes ===
 +
 
 +
Of all the AGI games, it is unknown whether the [[King's Quest IV: The Perils of Rosella AGI|KQ4AGI 256K version]], [[Manhunter: New York|Manhunter 1]], [[Manhunter 2: San Francisco|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. [[Manhunter 2: San Francisco|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. [[Manhunter: New York|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:
  
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!Command!!Result
+
!width="175"|Game!!width="625"|Debug Phrase
 
|-
 
|-
| TP||Teleport to room.
+
| [[Gold Rush!]]||"bird boy" or "bird man"
 
|-
 
|-
| SHOW PRIORITY||Displays the current rooms priority bands and control lines.
+
| [[King's Quest 1]]||Alt+D
 
|-
 
|-
| GET OBJECT||Get any inventory item.
+
| [[King's Quest II]]||"fast speak" or Alt+D
 
|-
 
|-
| GIMME GIMME||Get all inventory items.
+
| [[King's Quest III]]||"rats ass" (v2.14) or Alt+D
 
|-
 
|-
| SHOW FLAG||Displays one of the 256 flags.
+
| [[King's Quest IV AGI]]||Alt+D
 
|-
 
|-
| SET FLAG ||Set one of the 256 flags.
+
| [[Leisure Suit Larry 1]]||Alt+D
 
|-
 
|-
| RESET FLAG||Clear one of the 256 flags.
+
| [[Police Quest 1]]||"stink bug" or "stink bugs" (v2.0G)
 
|-
 
|-
| SHOW VAR||Displays one of the 256 variables.
+
| [[Space Quest 1]]||"backstage" or "dbg"
 
|-
 
|-
| SET VAR||Change the value of one of the 256 variables.
+
| [[Space Quest II]]||"dbg" or Alt+D
 +
|}
 +
</blockquote>
 +
 
 +
&nbsp;
 +
 
 +
== Debug Mode Commands ==
 +
 
 +
&nbsp;
 +
=== AGI1 Debug Mode Commands ===
 +
 
 +
After the debug mode is activated, the following commands are available:
 +
 
 +
<blockquote>
 +
==== Room and Ego Commands ====
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
| POSITION||Change egos position.
+
!width="175"|Command!!width="625"|Result
 
|-
 
|-
| SHOW POSITION||Show egos current screen coordinates.
+
| ROOM||Displays room number
 
|-
 
|-
| OBJECT NUMBER||Displays list of all the objects and their object numbers.
+
| TP (room number)||Teleport to specified room (change room/scene/script)
 
|-
 
|-
| OBJECT ROOM||Displays which room an object is found in.
+
| SP||Shows position of ego *
 
|-
 
|-
| ROOM||Displays room number.
+
| SHOW POSITION||Show ego's current screen coordinates *
 
|-
 
|-
| SET PRIORITY||et the priority of ego.
+
| POSITION + (new coordinates)||Change egos position
 
|-
 
|-
| RELEASE PRIORITY||Release the last priority that ego was set to.
+
| 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
 
|}
 
|}
 +
 +
<nowiki>*</nowiki> Does not work with King's Quest 2
 +
 +
==== Flag  and Variable Commands ====
 +
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|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 ====
 +
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|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
 +
|}
 +
 +
<nowiki>*</nowiki> There are 256 variables and 256 flags
 +
 +
==== Misc Debug Commands ====
 +
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|Result
 +
|-
 +
| QUIT||Quit game (originally, but now locks up)
 +
|}
 +
</blockquote>
  
 
&nbsp;
 
&nbsp;
  
== AGI Game Specific Debug Modes ==
+
===  AGI2/AGI3 Debug Commands ===
  
Of all the AGI games, it is unknown whether the KQ4 256K version, MH1, MH2 and Mixed Up Mother Goose have a debug mode or not. KQ4 will almost certainly have one, while MUMG probably doesn't even though its words.tok file has all the debug words contained in it. Manhunter 2 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. Manhunter: New York probably has the same debug mode.
+
<blockquote>
 +
After the debug mode is activated, the following commands are available:
  
To access the debug mode in King's Quest I-III (in the newer versions of the game most of the debugging options won't work) while playing press '''Alt+D'''. Two information boxes will appear. Press Enter to get rid of them. Enter the right command to enter debug mode.
+
==== Room and Ego Commands ====
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|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
 +
|}
 +
 
 +
<nowiki>*</nowiki> Does not work with King's Quest 2
 +
 
 +
==== Flag  and Variable Commands ====
  
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!Game!!Command
+
!width="175"|Command!!width="625"|Result
 +
|-
 +
| SHOW FLAG||Displays a specified flag (one of 256 flags)
 
|-
 
|-
| Gold Rush||type "bird man".
+
| SET FLAG||Sets a specified flag (one of 256 flags)
 
|-
 
|-
| Kings Quest I||Alt+D and Enter twice
+
| RESET FLAG||Clears specified flag (one of 256 flags)
 
|-
 
|-
| Kings Quest II||Alt+D and Enter twice
+
| SHOW VAR or SHOW VARIABLE||Displays one of the 256 variables
 
|-
 
|-
| Kings Quest III||type "rats ass" or Alt+D
+
| SET VAR or SET VARIABLE||Change the value of one of the 256 variables
 +
|}
 +
 
 +
==== Object/Inventory Debug Commands ====
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
| Kings Quest IV AGI||Alt+D and Enter twice
+
!width="175"|Command!!width="625"|Result
 
|-
 
|-
| Leisure Suit Larry 1||Alt+D and Enter twice
+
| OBJECT NUMBER||Displays list of all the objects and their object numbers
 
|-
 
|-
| Police Quest 1||type "stink bug".
+
| OBJECT ROOM||Displays which room an object is found in
 
|-
 
|-
| Space Quest 1||type "backstage" or "dbg".
+
| GET OBJECT||Get specified object and adds to inventory
 
|-
 
|-
| Space Quest 2||Alt+D and Enter twice
+
| GIMME GIMME||Get all inventory items
 
|}
 
|}
  
 +
<nowiki>*</nowiki> There are 256 variables and 256 flags
 +
 +
==== Misc Debug Commands ====
 +
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|Result
 +
|-
 +
| QUIT||Quit game (locks up with most later games)
 +
|-
 +
| [SCROLL LOCK]||Trace mode*
 +
|}
 +
 +
<nowiki>*</nowiki> Only works with AGI v2
 +
</blockquote>
 
&nbsp;
 
&nbsp;
  
== AGI Game Specific Debug Commands ==
+
=== Game Specific Debug Commands ===
 +
 
 +
''Note: Not all of these commands will work with all versions of the games''
  
 
&nbsp;
 
&nbsp;
  
 
<blockquote>
 
<blockquote>
=== King's Quest III ===
+
==== The Black Cauldron ====
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|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
 +
|}
 +
 
 +
&nbsp;
 +
 
 +
==== Donald Duck's Playground ====
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|Result
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen
 +
|}
 +
 
 +
&nbsp;
 +
 
 +
==== Gold Rush! ====
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
! width="175"|Command!!width="625"|Result
 +
|-
 +
| ROOM NUMBER||Shows room number
 +
|-
 +
| SHOW POSITION ||Shows coordinates of ego
 +
|-
 +
| SHOW MEM||Shows available memory
 +
|-
 +
| SHOW OBJECT||Gives information on objects on screen
 +
|-
 +
| ALT + S||Gives information on objects on screen
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority *
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen
 +
|}
 +
 
 +
&nbsp;
 +
 
 +
==== King's Quest II ====
 +
 
 +
Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
! width="175"|Command!!width="625"|Result
 +
|-
 +
| CHECK OUT FLAG||Shows certain status information
 +
|-
 +
| F8||Shows priority screen
 +
|-
 +
| F10||Shows available memory
 +
|}
 +
 
 +
&nbsp;
 +
 
 +
==== King's Quest III ====
  
 
Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:
 
Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:
Line 91: Line 320:
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!Command!!Result
+
! width="175"|Command!!width="625"|Result
 +
|-
 +
| ALT + I||Gives information on objects on screen
 +
|-
 +
| EXAMINE OBJECT||Gives information on objects on screen
 
|-
 
|-
| enchanter status||Were wizard is, when he'll return, etc.
+
| OBJECT ROOM||Shows in which room certain object is located
 
|-
 
|-
| do chore||To have your task done for you.
+
| GET OBJECT||Adds selected object to inventory
 
|-
 
|-
| sleep enchanter||To put him to sleep.
+
| GIMME GIMME||Adds all objects to inventory
 
|-
 
|-
| bye bye enchanter||To kill him.
+
| ROOM NUMBER||Shows room number
 +
|-
 +
| ALT + P||Shows priority screen *
 +
|-
 +
| F6||Shows priority screen **
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen ****
 +
|-
 +
| ROOM||Shows coordinates of ego
 +
|-
 +
| ALT + E||Shows position of ego
 +
|-
 +
| ALT + X||Shows coordinates of ego
 +
|-
 +
| EXAMINE POSITION||Shows coordinates of ego **
 +
|-
 +
| FIND||Shows position of ego
 +
|-
 +
| F10||Shows available memory ***
 +
|-
 +
| ALT + M||Shows available memory *
 +
|-
 +
| ENCHANTER STATUS or WIZARD STATUS||Gives a detailed status of Manannan.
 +
|-
 +
| HERE ENCHANTER or HERE WIZARD||Gives a detailed status of Manannan.
 +
|-
 +
| SLEEP ENCHANTER or SLEEP WIZARD||Manannan goes to sleep.
 +
|-
 +
| BYE BYE ENCHANTER or BYE BYE WIZARD||Kills Manannan.
 +
|-
 +
| DO CHORE||Sets assigned task flag as done.
 +
|-
 +
| PUT UP SPELL||Gives all inventory items.
 +
|-
 +
| PUT UP MOUNTAIN||Changes game state to arrival at the kingdom of Daventry
 +
|-
 +
| PUT UP BOAT||Changes game state to the beginning of the sailing trip
 +
|-
 +
| GIMME SPELL||Gives all magical items
 
|}
 
|}
 +
 +
<nowiki>*</nowiki> King's Quest 3 has several versions and some these commands won't work, or will use different keys like F6 or F10 (e.g. v1.01)<br />
 +
<nowiki>**</nowiki> King's Quest 3 v1.01<br />
 +
<nowiki>***</nowiki> Not King's Quest 3 v. 2.14<br />
 +
<nowiki>****</nowiki> "Enter" to return to normal visual screen for v. 2.14<br />
  
 
&nbsp;
 
&nbsp;
  
=== King's Quest 4 AGI ===
+
==== King's Quest IV AGI ====
  
While playing, press Alt+D. Two information boxes will appear. Press enter to get rid of them (in the newer versions of the games though, most of the debugging options won't work).
+
Note: In the newer versions of the game most of the debugging commands do not work
  
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!Command!!Result
+
!width="175"|Command!!width="625"|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
 
|-
 
|-
| TP||Teleport to room.*
+
| ALT + E||Shows position of ego
 +
|-
 +
| ALT + X||Shows coordinates of ego
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen
 +
|-
 +
| CREATE DAY||Turns the game into day
 +
|-
 +
| CREATE DARK||Turns the game into night
 +
|-
 +
| TIME||Gives in-game time
 +
|-
 +
| TRACE||Trace mode (originally, but does not work)
 
|}
 
|}
  
Line 119: Line 429:
 
&nbsp;
 
&nbsp;
  
=== Leisure Suit Larry 1 ===
+
==== Leisure Suit Larry 1 ====
  
 
Press ALT+D and press enter twice to enable Debug Mode.
 
Press ALT+D and press enter twice to enable Debug Mode.
Line 125: Line 435:
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!width="150"|Command!!width="650"Result
+
!width="175"|Command!!width="625"|Result
 +
|-
 +
| TP (room #*)||Teleport to specified room.
 +
|-
 +
| OBJECT NUMBER||Shows list of objects in game
 
|-
 
|-
| TP (room #)||Teleport to room.*
+
| OBJECT ROOM||Shows in which room certain object is located
 
|-
 
|-
| OBJECT NUMBER||Show a list of items and numbers
+
| ALT+I or SP (object #)||Shows information about screen objects
 
|-
 
|-
 
| GET OBJECT (item #)||To get specified object
 
| GET OBJECT (item #)||To get specified object
 
|-
 
|-
| GIMME GIMME||Obtain all objects
+
| GIMME GIMME||All objects get added to inventory
 
|-
 
|-
| OBJECT ROOM (object #)||Specifies room where an item is
+
| ROOM NUMBER||X/Y Coordinates and current room number
 
|-
 
|-
| ROOM NUMBER||X/Y Coordinates and current room number
+
| EXAMINE POSITION||Shows coordinates of ego
 +
|-
 +
| FIND||Shows position of ego
 +
|-
 +
| ALT + P (ALT+V or PRIORITY **)||Shows 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
 
| SHOW VAR or SV||Display value of variable
Line 149: Line 473:
 
| RESET FLAG||Reset a flag
 
| RESET FLAG||Reset a flag
 
|-
 
|-
| ALT+M||Display heapsize
+
| ALT+M||Display heap size
 
|-
 
|-
| ALT+I or SP (object #)||Shows information about screen objects
+
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority
 
|-
 
|-
| ALT+V or PRIORITY||Displays priority screen
+
| RELEASE PRIORITY||Returns to normal visual screen
 
|}
 
|}
  
==== Leisure Suit Larry 1 Room Numbers ====
+
<nowiki>*</nowiki> For a list of room numbers, [[Leisure Suit Larry 1 Rooms|see here]].<br />
 +
<nowiki>**</nowiki> Not v 1.00
 +
 
 +
&nbsp;
 +
 
 +
==== Police Quest ====
 +
 
 +
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|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
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen
 +
|}
  
* &nbsp;6 - Starting Screen
+
==== Space Quest I ====
* &nbsp;8 - Sierra Lab
 
* &nbsp;9 - Bad Alley
 
* 10 - Taxi Cab
 
* 11 - Outside Lefty's Bar
 
* 12 - Lefty's Alley
 
* 13 - Lefty's Bathroom
 
* 14 - Lefty's Hallway
 
* 15 - Lefty's Bar
 
* 16 - Lefty's Storeroom * Pimp's Hideout -
 
* 17 - Lefty's Upstairs Bedroom
 
* 19 - Suicide Screen * Dying -
 
* 20 - Boss Key Screen
 
* 21 - Quiki Mart
 
* 22 - Outside Quiki Mart
 
* 23 - Outside Disco
 
* 24 - Disco
 
* 25 - Fawn Screen
 
* 31 - Casino
 
* 32 - Outside Casino
 
* 33 - Outside Quiki Wed
 
* 34 - Quiki Wed
 
* 35 - Casino Lobby Elevator
 
* 36 - Casino Cabaret
 
* 37 - Casino Slots
 
* 38 - Casino Blackjack
 
* 40 - Casino Hotel 4th Floor
 
* 41 - Casino Hotel Honeymoon Suite
 
* 42 - Casino Hotel 8th Floor Desk
 
* 43 - Casino Penthouse Hot Tub
 
* 44 - Casino Penthouse Living Room
 
* 45 - Casino Penthouse Bedroom
 
* 55 - Help Screen
 
  
&nbsp;
+
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 +
|-
 +
!width="175"|Command!!width="625"|Result
 +
|-
 +
| OBJECT||Gives information on objects on screen
 +
|-
 +
| SHOW MEMORY||Shows available memory
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| tester||Displays EGO's screen coordinates.
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority
 +
|-
 +
| RELEASE PRIORITY||Returns to normal visual screen
 +
|-
 +
| CASH||Change amount of money
 +
|-
 +
| DRINK CLOTHES||Changes ego to normal outfit
 +
|-
 +
| BE ALIEN||Changes ego to alien outfit
 +
|-
 +
| DRINK JET PACK||Changes ego to wear jetpack
 +
|-
 +
| NO HELMET||Changes ego to alien (without helmet)
 +
|}
  
=== Space Quest I-II ===
+
==== Space Quest II ====
  
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
{| class="wikitable sortable" border="1" cellspacing="0" width="800"
 
|-
 
|-
!Command!!Result
+
!width="175"|Command!!width="625"|Result
 +
|-
 +
| OBJECT||Gives information on objects on screen
 +
|-
 +
| SHOW MEMORY||Shows available memory
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| tester||Displays ego's screen coordinates.
 +
|-
 +
| SHOW PRIORITY||Shows priority screen
 +
|-
 +
| SET PRIORITY||Sets priority
 
|-
 
|-
| tester||Displays Rogers screen coordinates.
+
| RELEASE PRIORITY||Returns to normal visual screen
 
|}
 
|}
 
</blockquote>
 
</blockquote>
Line 206: Line 575:
  
 
[[Category:Debugging]]
 
[[Category:Debugging]]
 +
[[Category:Heap]]
 +
[[Category:Memory]]

Latest revision as of 21:20, 13 September 2016

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 (locks up with most later games)
[SCROLL LOCK] Trace mode*

* Only works with AGI v2

 

Game Specific Debug Commands

Note: Not all of these commands will work with all versions of the games

 

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

 

Donald Duck's Playground

Command Result
SHOW PRIORITY Shows priority screen
RELEASE PRIORITY Returns to normal visual screen

 

Gold Rush!

Command Result
ROOM NUMBER Shows room number
SHOW POSITION Shows coordinates of ego
SHOW MEM Shows available memory
SHOW OBJECT Gives information on objects on screen
ALT + S Gives information on objects on screen
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority *
RELEASE PRIORITY Returns to normal visual screen

 

King's Quest II

Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:

Command Result
CHECK OUT FLAG Shows certain status information
F8 Shows priority screen
F10 Shows available memory

 

King's Quest III

Here are a few interesting tricks to help you deal with that intolerable wizard in debug mode (). Type:

Command Result
ALT + I Gives information on objects on screen
EXAMINE OBJECT Gives information on objects on screen
OBJECT ROOM Shows in which room certain object is located
GET OBJECT Adds selected object to inventory
GIMME GIMME Adds all objects to inventory
ROOM NUMBER Shows room number
ALT + P Shows priority screen *
F6 Shows priority screen **
SHOW PRIORITY Shows priority screen
RELEASE PRIORITY Returns to normal visual screen ****
ROOM Shows coordinates of ego
ALT + E Shows position of ego
ALT + X Shows coordinates of ego
EXAMINE POSITION Shows coordinates of ego **
FIND Shows position of ego
F10 Shows available memory ***
ALT + M Shows available memory *
ENCHANTER STATUS or WIZARD STATUS Gives a detailed status of Manannan.
HERE ENCHANTER or HERE WIZARD Gives a detailed status of Manannan.
SLEEP ENCHANTER or SLEEP WIZARD Manannan goes to sleep.
BYE BYE ENCHANTER or BYE BYE WIZARD Kills Manannan.
DO CHORE Sets assigned task flag as done.
PUT UP SPELL Gives all inventory items.
PUT UP MOUNTAIN Changes game state to arrival at the kingdom of Daventry
PUT UP BOAT Changes game state to the beginning of the sailing trip
GIMME SPELL Gives all magical items

* King's Quest 3 has several versions and some these commands won't work, or will use different keys like F6 or F10 (e.g. v1.01)
** King's Quest 3 v1.01
*** Not King's Quest 3 v. 2.14
**** "Enter" to return to normal visual screen for v. 2.14

 

King's Quest IV AGI

Note: In the newer versions of the game 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
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority
RELEASE PRIORITY Returns to normal visual screen
CREATE DAY Turns the game into day
CREATE DARK Turns the game into night
TIME Gives in-game time
TRACE Trace mode (originally, but does not work)

* 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 (ALT+V or PRIORITY **) Shows 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
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority
RELEASE PRIORITY Returns to normal visual screen

* For a list of room numbers, see here.
** Not v 1.00

 

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
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority
RELEASE PRIORITY Returns to normal visual screen

Space Quest I

Command Result
OBJECT Gives information on objects on screen
SHOW MEMORY Shows available memory
SHOW PRIORITY Shows priority screen
tester Displays EGO's screen coordinates.
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority
RELEASE PRIORITY Returns to normal visual screen
CASH Change amount of money
DRINK CLOTHES Changes ego to normal outfit
BE ALIEN Changes ego to alien outfit
DRINK JET PACK Changes ego to wear jetpack
NO HELMET Changes ego to alien (without helmet)

Space Quest II

Command Result
OBJECT Gives information on objects on screen
SHOW MEMORY Shows available memory
SHOW PRIORITY Shows priority screen
tester Displays ego's screen coordinates.
SHOW PRIORITY Shows priority screen
SET PRIORITY Sets priority
RELEASE PRIORITY Returns to normal visual screen