Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Developer console

The Glide console accepts 82 registered commands with short aliases, plus 13 cheat names handled separately.

Command dispatch and syntax

Press F12 to open the console. Command names are case-insensitive. Each registered command has exactly the long name and short alias listed below. Other abbreviations are not accepted. The commands command, also spelled ?, lists the 82 command pairs; oracle lists the 13 cheat names and their raw state values. There is no literal cheat prefix command.

The engine also has a programmatic command entry point. It accepts the long registered names and the cheat names, but does not look up short aliases.

Input is lowercased and normalized before dispatch. A semicolon ends the input; it does not separate commands to execute in sequence. Arguments are parsed by each handler. Spaces and commas are not interchangeable: for example, use load 1,0,0, item add,ID, setflag NAME,VALUE, and object attr attr_health = 100. Square brackets in this reference indicate optional arguments and are not typed.

Most numeric handlers accept decimal integers, negative decimal integers, 0x hexadecimal values, named equates, and named SOUP flag values. An unresolved symbolic value prints a diagnostic and substitutes 1. The percent-prefixed binary-input path returns zero for ASCII binary digits. Quoted numeric input reads the first four bytes following the quote as a little-endian 32-bit value; it is not general string evaluation. delay uses decimal conversion directly.

Decimal and hexadecimal conversion consume the numeric prefix and stop at the first non-digit for that radix. Arithmetic wraps to 32 bits. A leading minus selects decimal conversion even when no digits follow, yielding zero in that case. 0x without hexadecimal digits also yields zero. A leading plus does not select numeric conversion through the console reader.

Symbol lookup checks equates, console variables, then SOUP flags. Both definition loading paths release the temporary equate table before returning. The normal console therefore has no retained definition equates, and its console-variable table is empty. SOUP flag lookup reads the current raw value, without invoking the flag’s latch operation. Flag names are matched case-insensitively; the name list is built in reverse definition order, so the last duplicate name wins.

The console keeps a selected object, a monitored object, a selected rope and a selected light. These are separate selections. An object selected for inspection does not become the monitor target until object monitor is used.

Interactive presentation and editor

The interactive console covers the game viewport with SYSTEM/PAPER.GXA. At widths of at least 640 pixels, its standard font is the FNT named by SYSTEM.INI [system] gui_low_font. The console draws that font with a single ink color rather than the glyph palette colors. Its header and left text margin start at the scaled equivalent of eight pixels in a 640 by 480 viewport. The header identifies the development console and reports memory usage; a horizontal separator precedes retained output and the command prompt.

Standard settings use palette entry zero for editing and header text. Report text uses the GUI color nearest to six-bit RGB (0, 42, 0) in the active palette. Palette matching examines entries 1 through 255 in six-bit RGB. An exact match wins immediately. White entries whose component sum is 189 are otherwise skipped. For each component, the difference is target minus candidate when nonnegative, and candidate minus target minus one otherwise. Candidates with all three differences below nine are compared by the absolute difference of their weighted RGB sums, using weights 19661, 38666 and 7209. Equal scores select the later entry. If this pass finds no candidate or its score exceeds 24, a second pass minimizes the sum of the three component differences, again preferring later ties. The sixteen console GUI color targets, in index order, are palette entry zero, then six-bit RGB (62,62,62), (42,42,42), (32,32,32), (22,22,22), (12,12,12), (32,51,63), (19,33,44), (10,17,26), (53,3,23), (49,0,0), (60,0,0), (0,30,0), (0,42,0), (0,0,0) and (24,0,28). The first index uses palette entry zero directly; the others use the matching procedure above, including black at index fourteen.

The standard GUI font’s linked font points to itself after startup. The alternate console font is a copy of that same font, with its link pointing to the copy. At widths of at least 640, font zero selects the standard font and font one selects its linked font. Below 640, font zero selects the linked font and font one selects the alternate copy. Changing the console font selector therefore does not load a different FNT file.

The console has 512 retained lines, with at most 100 characters in each editable command line. A > prompt distinguishes command lines from report lines.

F12 and Escape leave the interactive console. Left and Right move the cursor; Backspace removes the preceding character and Delete removes the following character. Typing inserts printable characters at the cursor. Up and Down select retained lines, including report lines; report lines are not editable. Tab copies a preceding command into the current editable line. Home moves to the start of the line, then to the oldest retained line when already at the start. Page Up and Page Down move through retained output. Enter dispatches an editable command. The interactive console runs its own input and drawing loop before returning to the caller’s game loop.

With shadows enabled, the Glide glyph path draws a black glyph copy before the main glyph. The console selects a two-pixel offset in each axis at widths of at least 640 and one pixel below that threshold. The standard console font uses main alpha 255; the shadow alpha is (255 * 200) >> 8, or 199.

The cursor uses two report-colored vertical-bar glyphs, four scaled pixels above and below the insertion position. It is visible while a key is being handled or when the low bit of the console clock counter is set. On the normal BIOS-clock path, the counter increments once whenever accumulated elapsed time reaches 18 BIOS ticks, retaining the remainder modulo 18. A delayed update increments it once even when several such intervals elapsed. An input iteration without a key clears the forced-visible state.

Console preferences are stored in REDGUARD.CPF.

Registered commands

Each row is one command. The alias invokes the same handler from the interactive console.

Console and diagnostics

CommandAliasArguments and behavior
commands?commands. Lists the 82 registered commands and their aliases. The 13 cheat names are listed separately by oracle.
showshshow <topic>. Reports engine, world, player, object, memory, hardware, sound, and navigation information. Some topics toggle debug displays or write GRID.LOG. See subcommands.
consoleconconsole <option>. Changes console appearance, clears history, exports output, and saves console preferences.
printlptprint page / all. Sends the visible console page or retained output to a DOS printer. This is printer output, not an on-screen print command.
hexxhex [address / last]. Displays memory as hexadecimal bytes and characters; omission continues the previous dump.
recoverrrecover. Requests recovery from the recoverable error state. Refuses when there is no error or system integrity is considered bad.
breakbbreak. Enters the engine error path with the critical-drive-error code. Not a general-purpose script breakpoint.
pokeppoke address,byte[,byte...]. Validates an address and byte values, then displays one line of memory. Contains no memory write. Values outside -128 through 255 are rejected.
restartrsrestart video / xngine. Restarts the video subsystem or the rendering engine. Does not start a new game.
delaydldelay [number]. Sets an artificial delay in the main loop; omission or zero clears it.

State and scripts

Name patterns are case-insensitive. An asterisk accepts the remainder immediately, including any following pattern text. A question mark accepts one character; extra trailing question marks also match after a nonempty name ends. Empty patterns match in the shared matcher, although flag commands require a nonempty pattern.

CommandAliasArguments and behavior
getgget pattern. Looks up console variables by name pattern. The Glide build has an empty console-variable table, so no variables match.
setsset pattern,value[,value...]. Parses assignments to console variables. The same empty table prevents assignments in this build.
getflaggfgetflag pattern. Lists matching SOUP flags, their types, values, and set status.
setflagsfsetflag pattern,value[,status]. Changes matching SOUP flag values and optionally their status. A nonzero status sets the set bit. Zero XORs the metadata byte with 239; it does not clear the set bit.
scriptscscript log / disable [name] / block. Writes a script log, suppresses updates for actors using a named script, or advances the script block list. disable without a name clears the suppression; this is not an arbitrary SOUP-expression evaluator.

Objects and inventory

CommandAliasArguments and behavior
objectoobject <operation>. Selects, inspects, edits, monitors, or teleports to objects; also provides an interactive kill mode. Includes attribute assignment and subcommands missing from help. See subcommands.
logplayerpllogplayer off / console / screen. Disables player diagnostics or toggles their console/screen output.
logmonitormllogmonitor off / console / screen. Disables monitored-object diagnostics or toggles their console/screen output.
roperprope heap / select / general. Lists ropes, interactively selects one, or reports the selected rope and its attached objects.
itemiitem <operation>. Lists inventory definitions or player items, adds or removes one item, or drops a specified amount.
playerdistpdplayerdist. Reports the distance between the selected console object and the player.
cameradistcdcameradist. Reports the distance between the selected console object and the camera.

World and navigation

CommandAliasArguments and behavior
loadlload world[,marker][,angle]. Requests a world load with optional marker and angle. Omitted marker and angle default to zero.
setmarkersmsetmarker number. Saves the current player/camera placement as a user marker in REDGUARD.MRK.
getmarkergmgetmarker number. Restores a user marker for the current world from REDGUARD.MRK.
setnetmarksnmsetnetmark number. Saves a user marker in the configured shared marker file. Uses a file path from SYSTEM.INI; it is not a multiplayer command.
getnetmarkgnmgetnetmark number. Restores a user marker from that configured shared file.
openputnodeopopenputnode [filename]. Opens the PUT-node authoring system, optionally with a file.
saveputnodespsaveputnode [filename]. Writes the PUT nodes to the supplied filename or the filename used when opened.
closeputnodecpcloseputnode. Closes the PUT-node authoring system.
getmapmarkergmmgetmapmarker number. Moves the player to a marker authored in the current map.
walkwwalk [filename]. Generates a walk map from PUT nodes. Requires at least two nodes and a filename; enters the generation workflow and then exits through the engine shutdown path.
nodennode <operation>. Inspects navigation maps/nodes, toggles diagnostic displays, logs node data, and clears node occupancy. The help-only spelling showinuse is not accepted.

Developer tests

CommandAliasArguments and behavior
testttest. Writes and reloads the player object through OBJECT.SAV, then compares its state. This changes live object state and writes files.
test2t2test2. Writes GRID1.LOG and GRID2.LOG around an internal world save/load test. Also uses GRID.LOG and the internal save/load workflow.
test3t3test3. Writes and reloads the monitored object through OBJECT.SAV, then compares its state. Requires a monitored object; changes live object state and writes files.

Rendering and visibility

CommandAliasArguments and behavior
renderrdrender on / off / static. Enables/disables rendering or toggles static-object rendering.
scenesnscene. Enters an interactive scene inspection mode with information under the pointer.
pvotreeinfopvoipvotreeinfo. Reports the loaded potentially-visible-object tree, lists, and patch count.
pvoaddpatchpvoapvoaddpatch. Interactively picks an object to add to the PVO patch list.
pvodeletepatchpvodpvodeletepatch. Interactively picks an object to remove from the PVO patch list.
pvoonoffpvopvoonoff. Toggles the PVO visibility-system switch. Requires a loaded PVO tree.
pvopatchsavepvospvopatchsave. Saves the current PVO patches.
pvotreeloadpvolpvotreeload filename. Loads another PVO tree. The command first requires a PVO tree to be loaded already.

Lighting editor

CommandAliasArguments and behavior
fxlightflaglffxlightflag. Activates the light-editing controls and selects a light, or clears/restores the light selection.
fxsavelightsslfxsavelights. Writes the current world light definitions to its world light file.
fxgolightfxglfxgolight number. Moves the player to a numbered light and selects it. Requires lights and the light-editing mode.
fxselectfxselfxselect. Interactively selects a light.
fxeditredfxerfxeditred value. Sets the selected light’s red channel. Clamped to -255 through 255.
fxeditgreenfxegfxeditgreen value. Sets the selected light’s green channel. Clamped to -255 through 255.
fxeditbluefxebfxeditblue value. Sets the selected light’s blue channel. Clamped to -255 through 255.
fxeditradiusfxeradfxeditradius value. Sets the selected light’s radius. Negative input becomes zero; storage is 16-bit.
fxlightmovefxlmfxlightmove value. Sets the light editor’s movement-step value.
fxincstepfxisfxincstep value. Sets the light editor’s increment-step value.
fxmanualxfxmxfxmanualx value. Sets the selected light’s X coordinate. Requires an active light editor and selected light.
fxmanualyfxmyfxmanualy value. Sets the selected light’s Y coordinate. Requires an active light editor and selected light.
fxmanualzfxmzfxmanualz value. Sets the selected light’s Z coordinate. Requires an active light editor and selected light.
fxscriptnamefxsnfxscriptname name. Assigns the selected light’s script name. Retains at most eight characters; requires an active light editor and selected light.

Sky, lighting and water

Sky scale and level read signed 32-bit console numbers and convert them to float for rendering. Wave amplitude, speed and frequency do the same conversion. These five commands do not clamp their inputs. Sky speed uses the full signed value divided by sixteen for immediate scrolling, stores its low byte in the world configuration, and chooses a new random scrolling direction.

CommandAliasArguments and behavior
fxtexturelistfxlfxtexturelist start. Lists up to 40 texture entries starting at an index. A starting index is required despite the brackets in the built-in usage text.
fxshowtexturefxshfxshowtexture [number]. Shows a texture and its metadata; omission disables the texture preview.
fxsunanglesangfxsunangle value. Sets the sun angle. Clamped to 0 through 2048.
fxsunskewsskewfxsunskew value. Sets the sun skew. Clamped to 0 through 2048.
fxsunscalesscalefxsunscale value. Sets the sun-image scale.
fxsunredsredfxsunred value. Sets the sun lighting red channel. Clamped to -255 through 255.
fxsungreensgrefxsungreen value. Sets the sun lighting green channel. Clamped to -255 through 255.
fxsunbluesblufxsunblue value. Sets the sun lighting blue channel. Clamped to -255 through 255.
fxsunbrightnesssbrifxsunbrightness value. Sets sun-light brightness. Stored as a signed 16-bit value.
fxsunimgredsiredfxsunimgred value. Sets the sun image red channel. Clamped to -255 through 255.
fxsunimggreensigrefxsunimggreen value. Sets the sun image green channel. Clamped to -255 through 255.
fxsunimgbluesiblufxsunimgblue value. Sets the sun image blue channel. Clamped to -255 through 255.
fxskyscaleskyscfxskyscale value. Sets the current world’s sky scale.
fxskylevelskylfxskylevel value. Sets the current world’s sky level.
fxskyspeedskyspfxskyspeed value. Sets the current world’s sky scrolling speed.
fxfogredfredfxfogred value. Sets the fog red channel. Clamped to -255 through 255.
fxfoggreenfgrefxfoggreen value. Sets the fog green channel. Clamped to -255 through 255.
fxfogbluefblufxfogblue value. Sets the fog blue channel. Clamped to -255 through 255.
fxambientredaredfxambientred value. Sets the ambient light red channel. Clamped to -255 through 255.
fxambientgreenagrefxambientgreen value. Sets the ambient light green channel. Clamped to -255 through 255.
fxambientblueablufxambientblue value. Sets the ambient light blue channel. Clamped to -255 through 255.
fxwaveampwampfxwaveamp value. Sets the current world’s wave amplitude.
fxwavespeedwspfxwavespeed value. Sets the current world’s wave speed.
fxwavefreqwfrqfxwavefreq value. Sets the current world’s wave frequency.

Subcommands

Comma-separated names in the first column denote separate alternatives unless the row shows an argument form such as add,id.

show

Subcommand or argument formBehavior
memory, freeMemory and heap reports.
worldCurrent world configuration, including sky, lighting and wave settings.
videoVideo subsystem report.
objectsObject and model totals.
playerPlayer position, animation, combat and item state.
xngineCamera and renderer settings.
aiLoaded AI script files.
3dLoaded ROB models.
libraryObject-library entries.
registryResource registry, archives and open-file information.
grid [number / all]Grid contents; the all form also writes GRID.LOG.
mapGrid/object information with GRID.LOG output.
soundSound-system state.
group number, user numberMembers of a group or user group, numbered 1 through 255.
active, list, activelistObject-chain reports.
manager [handle]Model-cache report, optionally for a handle.
machineMachine and DOS environment information.
rainRain-system state.
remapObjects in the remap list.
marker [flats]Toggles marker display; flats selects the flat-marker display.
allRuns the main collection of diagnostic reports.

console

Subcommand or argument formBehavior
clearClears console history.
writeWrites retained output to CONSOLE.LOG.
fontSwitches the console font choice.
shadowToggles text shadow.
saveSaves console preferences to REDGUARD.CPF.
col0, col1, col2, col3Separate subcommands that cycle edit, report, on-screen and paper colours respectively. col3 requires paper to be off.
hex,numberSets the number of lines in a hex dump.
limit,numberSets the screen limit, from 0 through 300.
paperToggles the paper background.
showReports console preferences.

object

Subcommand or argument formBehavior
selectInteractively picks an object.
closestSelects the closest eligible object to the player.
playerSelects the player.
master numberSelects a master object, numbered 1 through 255.
search script-patternFinds objects by script name; one match is selected automatically.
address, "name"Alternative selection forms using a numeric address or a library object name.
general, quick, coordGeneral state, a short status report, or coordinates.
animReports the current animation frame.
sizeReports object size information.
combat, vcollideCombat state or vertex collision spheres.
matrix, locals, locations, strings, script, familySeparate reports for the corresponding object data.
attrLists named attributes and their values.
attr name = valueAssigns an attribute byte; the equals sign is optional.
monitorMakes the selected object the monitor target, or clears it if already monitored.
gotoMoves the player to the selected object.
dieEnters interactive object-killing mode.
zap amountThe supplied-amount form reports a missing argument. The handler has a reversed presence check.

item

Subcommand or argument formBehavior
playerLists item types with a nonzero player count.
show[,id]Lists all item definitions or one item.
add,idAdds one item to the player.
sub,idRemoves one item from the player.
drop,id,amountDrops the requested amount.

node

Subcommand or argument formBehavior
mapsLists loaded node maps.
monitorToggles node-marker display for the monitored object.
monitor dnodeReports the monitored object’s destination node.
monitor nodeReports the monitored object’s current node.
monitor logToggles node logging for the monitored object.
shownodeToggles object-node markers.
showmapToggles node-map display.
playerToggles player-node and route display.
log map-id node-numberWrites the chosen node report to NODE.LOG.
inuseReports repeated node-occupancy IDs.
sweepClears node occupancy throughout the loaded maps.

script

Subcommand or argument formBehavior
logOpens SCRIPT.LOG, enables script logging, and requests a return from the console.
disable [name]Suppresses the actor update path for the matching script basename. Omission clears it; basenames must be one through eight characters.
blockAdvances to the next entry in the engine’s script-block list.

rope

Subcommand or argument formBehavior
heapReports all ropes.
selectInteractively picks a rope.
generalReports the selected rope and its attached objects.

restart

Subcommand or argument formBehavior
videoRestarts the video subsystem.
xngineRestarts the rendering engine.

render

Subcommand or argument formBehavior
on, offEnables or disables rendering.
staticToggles static-object rendering.

logplayer

Subcommand or argument formBehavior
offClears both logging destinations.
console, screenSeparately toggles each output destination.

logmonitor

Subcommand or argument formBehavior
offClears both logging destinations.
console, screenSeparately toggles each output destination.

Cheat names

These 13 names are also accepted as console commands: oracle, nodemarker, moonraker, task, animation, magiccarpet, savecheats, drevil, drno, goldfinger, neversaydie, oddjob, and yeahbaby.

oracle and savecheats perform actions. The remaining names accept a toggle or name = value. Their numeric activation conditions differ. See Cheat system for the effects and per-cheat rules.

Differences between help and command behavior

  • show accepts rain, free, map, list and activelist even though its usage list omits them.
  • object anim and object size are accepted but omitted from the object usage list.
  • The node help lists node showinuse, but the handler does not accept that spelling. node inuse is accepted.
  • fxtexturelist requires an index despite the brackets in its usage message. fxshowtexture without an index turns its preview off.
  • poke has no memory-write operation. Successful byte validation is followed by a one-line hex display.
  • get and set use an empty console-variable table in the Glide build. SOUP flag access through getflag and setflag is separate and uses names loaded from SOUP386.DEF.
  • object zap tests argument presence backwards. Supplying an amount produces its missing-argument message; omitting it reaches decimal conversion of the empty token.
  • The optional zero status in setflag XORs the flag metadata with 239, leaving the set bit unchanged and flipping the other bits. A nonzero status sets the set bit.

External references