An Event is an object such as a Fuse or Daemon that is executed according to certain conditions. Game code will normally use one of its subclasses rather than the Event class directly.
class
Event : object
Superclass Tree (in declaration order)
Event
object
Subclass Tree
Event
Daemon
SenseDaemon
Fuse
SenseFuse
TimeFuse
SenseTimeFuse
PromptDaemon
OneTimePromptDaemon
Global Objects
actorSchedule
sceneManager
Summary of Properties
captureText
eventOrder
executed
interval_
isPromptDaemon
nextRunTime
obj_
prop_
senseObj_
senseProp_
Summary of Methods
callMethod
construct
delayEvent
eventMatches
executeEvent
getNextRunTime
removeEvent
Properties
Text captured from callMethod()
Event order - this establishes the order we run relative to other events scheduled to run at the same game clock time. Lowest number goes first. By default, we provide an event order of 100, which should leave plenty of room for custom events before and after default events.
Flag - has this event ever been executed
The interval at which this Event is to be executed.
by default, we're not a per-command-prompt daemon
our next execution time, expressed in game clock time; by default, we'll set this to nil, which means that we are not scheduled to execute at all
The object we're associated with
A pointer to the property of that object to execute
If the senseObj_ property is defined (normally via our constructor), the player character must be able to sense the senseObj_ via the sense defined in senseProp_ for any textual output from obj_.(prop_) to be displayed when this Event is executed.
The sense via which we test whether senseObj_ can be sensed by the player character. This must be given as an appropriate property of the Query object, e.g. &canSee or &canHear.
Methods
Call the method this Event should execute when it's ready to do so
delay our scheduled run time by the given number of turns
does this event match the given object/property combination?
Execute the event. This must be overridden by the subclass to perform the appropriate operation when executed. In particular, the subclass must reschedule or unschedule the event, as appropriate.
Get the next run time, i.e. the next turn on which this Event should execute obj_.(prop_).
Remove this event from the eventManager's list of events.
Adv3Lite Library Reference Manual
Generated on 25/04/2024 from adv3Lite version 2.0