|
wavelength 1.0.0
|
The triggers that wait on one kind of event. More...
#include <triggerevent.h>
Public Types | |
| enum | Type { kTypeBeat = 0 , kTypeTime = 1 , kTypeComponentSelect = 2 , kTypeComponentSelectStart = 3 , kTypeComponentFocus = 4 , kTypeScreenChange = 5 , kTypeButton = 6 , kTypeBegin = 7 , kTypeEnd = 8 , kTypeStageComplete = 9 , kTypeScore = 10 , kTypeHit = 11 , kTypeMiss = 12 , kTypePass = 13 , kTypeGem = 14 , kTypeNewBar = 15 , kTypePhraseEnd = 16 , kTypePhraseCapture = 17 , kTypePhraseMiss = 18 , kTypeNewTrack = 19 , kTypePowerupCapture = 20 , kTypePowerupDeploy = 21 , kTypeNewLeader = 22 , kTypeHealth = 23 , kTypeDyingChange = 24 , kTypeBossJourney = 25 , kTypeLyric = 26 , kTypePathUnlocked = 27 , kNumTypes = 28 } |
| Kinds of event, in the order of the names a trigger file and the debug list use. More... | |
Public Member Functions | |
| void | Fire () |
| Run every handler of the event. | |
| void | Clear () |
| Delete every handler and empty the list. | |
| void | AddHandler (DataArray *pTrigger) |
| Build a handler from an entry of a trigger file and append it. | |
Static Public Member Functions | |
| static int | FindType (DataArray *pArray, int nNode) |
| Find the kind of event a node of a trigger file names. | |
The triggers that wait on one kind of event.
TriggerMgr includes one per Type, indexed by the type. The object is the 8-byte list of its handlers, each built from one entry of a trigger file and owned by the event.
| enum TriggerEvent::Type |
Kinds of event, in the order of the names a trigger file and the debug list use.
|
static |
Find the kind of event a node of a trigger file names.
An unrecognised name produces a warning with the file and the line of the array.
| pArray | The array. |
| nNode | The node with the name. |
| void TriggerEvent::Fire | ( | ) |
Run every handler of the event.
Each handler tests its conditions and starts its actions.
| void TriggerEvent::Clear | ( | ) |
Delete every handler and empty the list.
| void TriggerEvent::AddHandler | ( | DataArray * | pTrigger | ) |
Build a handler from an entry of a trigger file and append it.
| pTrigger | The entry. Node 0 names the event. |