Cinematic Trigger Chain
cinematic trigger chain
cinematic-trigger-chain in ~90 seconds.One press of the captain's wheel and the beached galleon's intro cinematic rolls, then seamlessly kicks off the treasure race.
We chain devices together by subscribing to one device's event to fire the next trigger, letting the UEFN editor handle the actual cinematic playback while Verse orchestrates the sequence.
We declare our button and two triggers as editable fields, write handlers that call Trigger to pass the baton, and subscribe to their events in OnBegin to lock in the chain.
Reach for a trigger chain when you need Verse to sequence complex editor-wired cinematics and game phases without hardcoding the device logic.
galleon_chain := class(creative_device):
@editable
StartButton : button_device = button_device{}
@editable
IntroTrigger : trigger_device = trigger_device{}
@editable
RaceTrigger : trigger_device = trigger_device{}
OnButtonPressed(Agent : agent) : void =
IntroTrigger.Trigger()
OnIntroDone(Agent : ?agent) : void =
if (A := Agent?):
RaceTrigger.Trigger()
OnBegin<override>()<suspends>:void =
StartButton.InteractedWithEvent.Subscribe(OnButtonPressed)
IntroTrigger.TriggeredEvent.Subscribe(OnIntroDone)
Build your own lesson with cinematic-trigger-chain
Generate a personalized, compile-checked lesson grounded in this exact reference.
Build a lesson →