Skip to content

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 ​

MemberDescription
SequenceQueue.ActiveIdRead-only runtime value. Use component methods to change state.
SequenceQueue.PositionZero-based number of items started since Play/reset. -1 before the first item.
SequenceQueue.QueuedCountActive plus pending occurrences.

Methods ​

MemberDescription
SequenceQueue.EnqueueAppend one ID occurrence, refusing empty IDs or a queue of 256 occurrences.
SequenceQueue.RemoveEnd the active matching occurrence first, otherwise remove the first matching pending occurrence.
SequenceQueue.NextEnd the active occurrence and start the next, optionally requeuing the ended occurrence at the tail.
SequenceQueue.ClearEnd the active occurrence, discard pending occurrences, and reset the started-item position.
SequenceQueue.IsEmptyTrue when no active or pending occurrence remains.
SequenceQueue.HasActiveTrue when a sequence occurrence is currently active.

Events ​

MemberDescription
SequenceQueue.itemStartEmitted after Next commits a new active occurrence.
SequenceQueue.itemEndEmitted when Next, Remove, or Clear ends an active occurrence.
SequenceQueue.emptyEmitted after the queue becomes empty, or Next finds no remaining occurrence.

See also ​