senseContextobject
Sense context output filter. When the sense context doesn’t allow the player character to sense whatever’s going on, we’ll block all output; otherwise, we’ll pass output through unchanged.
senseContext
:
SwitchableCaptureFilter
Superclass Tree (in declaration order)
senseContext
SwitchableCaptureFilter
CaptureFilter
OutputFilter
` object`
Summary of Properties
cached_
isBlocking_
sense_
source_
Inherited from SwitchableCaptureFilter
:
isBlocking
Summary of Methods
isBlocking
recalcSenseContext
setSenseContext
shouldBlock
withSenseContext
Inherited from SwitchableCaptureFilter
:
filterText
Properties
cached_
no description available
isBlocking_
our current cached blocking status, and its validity
sense_
the source object and sense of the sensory context
source_
no description available
Methods
isBlocking ( )
Get our current blocking status. If we’ve already cached the status, we’ll return the cached status; otherwise, we’ll compute and cache the new blocking status, based on the current sensory environment.
recalcSenseContext ( )
Recalculate the current sense context. We will check to see if the player character can sense the current sense context’s source object in the current sense context’s sense, and show or hide output from this point forward accordingly. This can be called any time conditions change in such a way that the sense context should be refigured.
setSenseContext (source, sense)
Set a sense context.
shouldBlock ( )
Calculate whether or not I should be blocking output according to the current game state. Returns true if so, nil if not.
withSenseContext (source, sense, func)
invoke a callback with a given sense context
TADS 3 Library Manual
Generated on 5/16/2013 from TADS version 3.1.3