libGlobalobjectmisc.t[1409]

Library global variables

libGlobal :   object

Superclass Tree   (in declaration order)

libGlobal
        object

Summary of Properties  

actorVisualAmbientCache  allSenses  canTouchCache  connectionCache  curAction  curActor  curIssuingActor  curVerifyResults  exitListerObj  footnoteClass  hintManagerObj  lastActorForUndo  lastCommandForUndo  libMessageObj  parserDebugMode  playerChar  pointOfView  pointOfViewActor  povStack  scoreObj  senseCache  totalTurns 

Summary of Methods  

disableSenseCache  enableSenseCache  invalSenseCache 

Properties  

actorVisualAmbientCachemisc.t[1465]

Actor visual ambient cache - this keeps track of the ambient light level at the given actor.

allSensesmisc.t[1519]
List of all of the senses. The library pre-initializer will load this list with a reference to each instance of class Sense.

canTouchCachemisc.t[1453]
Can-Touch cache - we keep CanTouchInfo entires here, keyed by [from,to]. This cache is the touch-path equivalent of the sense cache, and is enabled and disabled

connectionCachemisc.t[1459]
Connection list cache - this is a cache of all of the objects connected by containment to a given object.

curActionmisc.t[1606]
no description available

curActormisc.t[1604]
Current command information. We keep track of the current command's actor and action here, as well as the verification result list and the command report list.

curIssuingActormisc.t[1605]
no description available

curVerifyResultsmisc.t[1607]
no description available

exitListerObjmisc.t[1610]
the exitLister object, if included in the build

footnoteClassmisc.t[1563]
The global Footnote class object. We use a global for this, rather than referencing Footnote directly, to allow the footnote module to be left out entirely if the game doesn't make use of footnotes. The footnote class should set this during pre-initialization.

hintManagerObjmisc.t[1613]
the hint manager, if included in the build

lastActorForUndomisc.t[1597]
Most recent target actor phrase; this goes with lastCommandForUndo. This is nil if the last command did not specify an actor (i.e., was implicitly for the player character), otherwise is the string the player typed specifying a target actor.

lastCommandForUndomisc.t[1588]
Most recent command, for 'undo' purposes. This is the last command the player character performed, or the last initial command a player directed to an NPC.

Note that if the player directed a series of commands to an NPC with a single command line, only the first command on such a command line is retained here, because it is only the first such command that counts as a player's turn in terms of the game clock. Subsequent commands are executed by the NPC's on the NPC's own time, and do not count against the PC's game clock time. The first command counts against the PC's clock because of the time it takes the PC to give the command to the NPC.

libMessageObjmisc.t[1430]
The current library messages object. This is the source object for messages that don't logically relate to the actor carrying out the comamand. It's mostly used for meta-command replies, and for text fragments that are used to construct descriptions.

This message object isn't generally used for parser messages or action replies - most of those come from the objects given by the current actor's getParserMessageObj() or getActionMessageObj(), respectively.

By default, this is set to libMessages. The library never changes this itself, but a game can change this if it wants to switch to a new set of messages during a game. (If you don't need to change messages during a game, but simply want to customize some of the default messages, you don't need to set this variable - you can simply use 'modify libMessages' instead. This variable is designed for cases where you want to *dynamically* change the standard messages during the game.)

parserDebugModemisc.t[1572]
flag: the parser is in 'debug' mode, in which it displays the parse tree for each command entered

playerCharmisc.t[1524]
The current player character

pointOfViewmisc.t[1539]
The current perspective object. This is *usually* the actor performing the current command, but can be a different object when the actor is viewing the location being described via an intermediary, such as through a closed-circuit TV camera.

pointOfViewActormisc.t[1531]
The current perspective actor. This is the actor who's performing the action (LOOK AROUND, EXAMINE, SMELL, etc) that's generating the current description.

povStackmisc.t[1546]
The stack of point of view objects. The last element of the vector is the most recent point of view after the current point of view.

scoreObjmisc.t[1554]
The global score object. We use a global for this, rather than referencing libScore directly, to allow the score module to be left out entirely if the game doesn't make use of scoring. The score module should set this during pre-initialization.

senseCachemisc.t[1446]
Sense cache - we keep SenseInfo lists here, keyed by [pov,sense]; we normally discard the cached information at the start of each turn, and disable caching entirely at the start of the "action" phase of each turn. We leave caching disabled during each turn's action phase because this is the phase where simulation state changes are typically made, and hence it would be difficult to keep the cache coherent during this phase.

When this is nil, it indicates that caching is disabled. We only allow caching during certain phases of execution, when game state is not conventionally altered, so that we don't have to do a lot of work to keep the cache up to date.

totalTurnsmisc.t[1566]
the total number of turns so far

Methods  

disableSenseCache ( )misc.t[1484]

disable the cache

enableSenseCache ( )misc.t[1468]
enable the cache, clearing any old cached information

invalSenseCache ( )misc.t[1502]
Invalidate the sense cache. This can be called if something happens during noun resolution or verification that causes any cached sense information to become out of date. For example, if you have to create a new game-world object during noun-phrase resolution, this should be called to ensure that the new object's visibility is properly calculated and incorporated into the cached information.

TADS 3 Library Manual
Generated on 9/15/2006 from TADS version 3.0.12