SequenceQueue
class in OpalScript
Sequences object IDs without eligibility or victory rules. Duplicate IDs are distinct occurrences; Remove ends the active matching occurrence first, then removes the first pending occurrence.
Properties
| Member | Description |
|---|---|
| SequenceQueue.ActiveId | Read-only runtime value. Use component methods to change state. |
| SequenceQueue.Position | Zero-based number of items started since Play/reset. -1 before the first item. |
| SequenceQueue.QueuedCount | Active plus pending occurrences. |
Methods
| Member | Description |
|---|---|
| SequenceQueue.Enqueue | Append one ID occurrence, refusing empty IDs or a queue of 256 occurrences. |
| SequenceQueue.Remove | End the active matching occurrence first, otherwise remove the first matching pending occurrence. |
| SequenceQueue.Next | End the active occurrence and start the next, optionally requeuing the ended occurrence at the tail. |
| SequenceQueue.Clear | End the active occurrence, discard pending occurrences, and reset the started-item position. |
| SequenceQueue.IsEmpty | True when no active or pending occurrence remains. |
| SequenceQueue.HasActive | True when a sequence occurrence is currently active. |
Events
| Member | Description |
|---|---|
| SequenceQueue.itemStart | Emitted after Next commits a new active occurrence. |
| SequenceQueue.itemEnd | Emitted when Next, Remove, or Clear ends an active occurrence. |
| SequenceQueue.empty | Emitted after the queue becomes empty, or Next finds no remaining occurrence. |