⌚
Timeflow
  • ⌚Introduction
  • 📗User Guide
    • â–ļī¸Getting Started
      • ✅Requirements
      • âŦ‡ī¸Installation
      • 🚀Quick Start
      • âœī¸Workflow
      • đŸŽŦRender Pipeline
      • â¯ī¸Editor vs Runtime
      • đŸĻŋHow it Works
      • â›‘ī¸Potential Issues
      • ⚡Optimization
      • 🔨3rd Party Tools
      • đŸ”ĸUpgrading Guide
    • â„šī¸Timeflow Editor
      • đŸŽ›ī¸Menu Bar
      • â˛ī¸Time
      • Local Time Scope
      • 🧰Work Area
      • âš™ī¸Settings
      • âŗUpdate Settings
      • đŸ“ēDisplay Lists
      • đŸ”ģMarkers
      • đŸ”ĩObject
      • 🏭Managed Objects
      • ⚡Quick Select Objects
      • âš’ī¸Tools
    • đŸŽŦTimeflow View
      • 🔩Toolbar
        • 🔑Auto Keyframing
        • â¯ī¸Play Controls
        • đŸĨ…Work Area
        • â¯ī¸Current Time
        • đŸŽŧMusical Timing
        • 🌐Grid and Snap
        • 🔸Keyframe Values
        • đŸ”ģMarkers
      • â˛ī¸Timeline
      • 📐Time Navigation
      • Local Time Scope
      • 🎏Track View
      • â†˜ī¸Selection
      • 📰Object Panel
      • đŸ“ēDisplay Lists
      • 🍱Channels
      • đŸŖProperties
      • 🔗Channel Link
      • đŸšĨSwitches
      • 📅Values Column
      • đŸ›¤ī¸Tracks
      • 🔸Keyframes
      • đŸ“ļAlignment Tools
      • ⌛Time Offset
      • đŸ”ĸInfo Panel
      • 📉Graph View
      • âœ‚ī¸Keyframe Tools
    • 🍰Menus & Shortcuts
      • 📃Context Menus
        • â†–ī¸Select Menu
        • 📰Object Menu
        • 🍱Channel Menu
        • đŸ›¤ī¸Tracks Menu
        • 🔸Keyframes Menu
        • đŸ”ģMarkers Menu
        • 📰View Menu
        • 📰Events Menu
        • đŸĨ…Work Area Menu
      • đŸ—ƒī¸File Menu
      • âš’ī¸Timeflow Menu
        • đŸ•ēAdd Behavior
        • đŸ”ļAnimation
        • 🍱Composition
        • đŸ“ēDisplay
        • ⏊Jump To
        • 👨‍đŸ‘Ļ‍đŸ‘ĻHierarchy
        • 🌐Mesh
        • 👉Select
        • 📚Tracks
        • 🌈Track Colors
        • â†”ī¸Transform
        • đŸ‘ī¸Visibility
        • đŸ› ī¸Editor
      • đŸ”ĩGame Objects Menu
      • đŸŽ›ī¸Presets
      • âš™ī¸Preferences
        • Assets
        • ⌛Time
        • đŸŗī¸â€đŸŒˆTracks
        • âšĒObjects
        • 🧮Channels
        • đŸ”ļKeyframes
        • 🔠Input
        • đŸ“ĨImport
        • đŸ–ŧī¸Rendering
        • đŸŽ›ī¸Overrides
        • 🍱Extras
      • *ī¸âƒŖKeyboard Shortcuts
        • Managing Shortcuts
      • âœ´ī¸Quick Menu
  • Reference
    • đŸ”ĩTimeflow Object
      • đŸĸTracks
      • 🏭Behaviors
      • ⏰Events
      • đŸ—ƒī¸Channels
    • 💃Timeflow Controller
      • đŸŽžī¸Timeflow Playback
    • đŸĒ„Behaviors
      • đŸŽžī¸Animation
        • 🔸Keyframer
        • â†”ī¸Tween
        • 🔀Blend
        • đŸŽĸMotion Path
        • đŸ‘¯Animation Clips
        • 🌴Animator Blend Trees
        • 😁Blend Shapes
      • 🤖Automation
        • 🛸Auto Bank
        • 🧭Auto Rotate
        • 📐Distance
        • ⏰Event
        • đŸ›Šī¸Flyby
        • 🏃Follow
        • 👀Look At
        • đŸŽ¯Look At Target
        • 🎲Noise
        • 🚊Place On Path
        • đŸī¸Place On Surface
      • 🔊Audio
        • 🔊Audio Track
        • đŸŽŧAudio Spectrum
        • đŸŽĩAudio Sample
        • đŸŽ™ī¸Audio Reactive
      • 🎹MIDI
        • 🎹Midi File
        • đŸĨMidi Tween
        • 📡Midi Receiver
          • đŸŽ›ī¸Minis Setup (New Input System)
          • đŸšĨMidiJack Setup (Legacy Input)
      • 🏁Rendering
        • đŸŽžī¸Render To Disk
        • 📋Render Queue
        • đŸ“Ŋī¸Video Encoding
        • 💡Tips & Optimizations
        • âēī¸Unity Recorder
      • 🔧Tools
        • â„šī¸Animator Info
        • 🧮Align Children
        • đŸ’ŦComment
        • #ī¸âƒŖFPS Counter
        • 📈Graph
        • 🔗Property Link
        • 🔄Rotator
        • ✨Particle System Update
        • 🌈Trail Renderer Update
        • đŸ“ēVideo Player Update
    • đŸ—ƒī¸Precomposing
    • 🏭Prefabs
    • đŸŽ›ī¸Editor Overrides
      • 🏹Transform Editor Override
    • 🔌Integrations
      • đŸ§™â€â™‚ī¸Adventure Creator
      • đŸŽ›ī¸MIDI Jack | Minis
      • đŸ¤ēSpine Animation
      • đŸ“Ŋī¸Unity Timeline
      • ➰Unity Splines
    • đŸĒSamples
      • đŸ•šī¸Demo App
      • đŸŽžī¸Cutscenes
      • 🏓Physics
      • 🍧Shader Properties
      • ⚡Visual Effect Graph (VFX)
    • 📖Glossary
    • 📗Scripting
    • đŸ“ŖPublished Works
    • âš ī¸Known Issues
    • 🆘Support
    • đŸ§ĒBeta
    • Roadmap
    • đŸ”ĸVersion History
    • ÂŠī¸Terms & Privacy
Powered by GitBook
On this page
  • Editing Events in the Info Panel
  • Event Editor
  • Menu Bar
  • Event Name
  • Triggered
  • Trigger Now
  • Trigger Time
  • Set to Current Time
  • Lock
  • Trigger Limit
  • Send Message To
  • Function and Parameter
  • OnTrigger()
  1. Reference
  2. Behaviors
  3. Automation

Event

Trigger a function or event at a specific time during playback

PreviousDistanceNextFlyby

Last updated 7 months ago

Events provide a way to invoke function calls during playback to implement custom behaviors. This is primarily used to initiate or end a state related to game play or other interactive applications.

Events only execute during playback

An event is only triggered when Timeflow is playing continuously. This does not require entering Play Mode in Unity, unless the function being invoked is a runtime-only feature.

Add an Event by right-clicking on the object in the Timeflow view and selecting: Add Automation > Events > Timeflow Event Alternatively:

Select a track section in the Track View and right-click to select Events.

Note that Events do not have any channels and instead appear like a keyframe on the track channel, as shown above.

Editing Events in the Info Panel

Multiple events may be selected at once for bulk editing in the Info Panel.

Goto

Click the Goto button in the Info Panel or double-click on the event in the Track View to jump to the time of the event.

Event Editor

Select the game object to view Event settings in the Inspector. Events, like all other behaviors, are applied as components, with no limit on the number of events applied to each object.

Menu Bar

Event Name

Enter a name to help manage and identify events. This is for organizational purposes and is not required nor does it affect functionality.

Triggered

Indicates when the event has been fired (checked) or not (unchecked). This gets reset upon start and when rewinding the timeline in edit mode.

Setting the Triggered checkbox manually overrides the internal tracking of whether or not the event has been fired. This may be useful while testing to allow or prevent an event from firing.

Trigger Now

Use this to invoke the event function immediately bypassing any restriction on limit. This is used only for testing events.

Trigger Time

Sets the time the event is to be triggered during playback.

Set to Current Time

Assigns the event time using the current time of the playhead.

Lock

Trigger Limit

Events may be limited to perform only a certain number of times during each run. This value may be left at 0 for the event to be fired without limit.

Under normal circumstances, Timeflow plays through just once and the limit is not needed. However, when looping sections of time or rewinding to replay from the beginning, this may be needed to ensure certain actions aren't repeated.

Trigger Limit is primarily used for interactive applications. For example, it could be used to display instructions to a user only the first time playing through a scene, but skipped on replays (during the same session). Or it could be used with other interactive contexts that limits the number of times a user is allowed to repeat actions.

Trigger Limit is enforced at runtime only When playing back Timeflow in edit mode, event triggers are reset each time rewinding the scene so that they fire each time played. This is much better for creative workflow while editing. However, during runtime (Play Mode) triggers are only initialized at start and never reset when rewinding or looping so that the Trigger Limit may be enforced.

Send Message To

Note that the named function is invoked for every component on the Target object that implements it. If no component with the function is found, then it fails silently.

Function and Parameter

Enter the exact name of the class method and leave blank or enter a parameter value to pass to the function when invoked. Below are examples showing how to implement methods in a component script.

public void MyMethod()
{
    Debug.Log("MyMethod");
}

public void MyMethod(string value)
{
    Debug.Log("MyMethod:" + value);
}

OnTrigger()

Trigger State Reset

Note that there is no automatic mechanism to reset or undo actions performed by events, unless you add them in some manner. As in the example above, the Spaceship object is deactivated by the event, so would require another event or other mechanism to reactivate it. Otherwise, it will remain inactive. Whenever creating events that make unidirectional changes, it is recommended to have an initialization process or add another event that resets objects to their default states at the appropriate times.

Event Timing and Latency

During playback, the precise time of an Event may not exactly align to the current time due to frame rates and timing intervals. To determine when an event is triggered, Timeflow checks whether the event time falls within the last update time and the current time (ignoring explicit jumps in time).

In most cases the discrepancy between the set trigger time and the actual time triggered is microseconds. However, in cases where frame rate has dropped or playback is skipping for other reasons, the actual event time triggered may be delayed.

Testing Events

Event Scripting

Events have similar editing features to and are included with operations.

Click on an event in the to view its settings in the . Please see the editor section below for more options and further explanation of each setting.

Events do not allow to be customized, otherwise it may not perform as expected or events may not trigger at all.

Please refer to for common features.

Trigger Time is in local time which may be affected by .

Enable lock to prevent the event time from being changed. This also prevents dragging events in the .

Uses to invoke the named method and optional parameter. This works in edit mode if the target method does.

Use to trigger any object or property value.

To test whether an event is firing, enable in the Menu Bar and then play Timeflow uninterrupted over the event. The console log should output a message when the event is reached.

You may also press at any point to fire an event, regardless of any limits set.

The behavior is officially named TimeflowEvent so as to avoid ambiguity with other event types in Unity. Custom event implementations may also be created using TimeflowEvent as a base class. See TimeflowEvent.cs and for more information.

đŸĒ„
🤖
⏰
Track View
Info Panel
Update Settings
Menu Bar
Time Offset
Track View
GameObject.SendMessage
Unity Events
Scripting
Trigger Now
keyframes
Related Keyframe
To make sure an event only fires once, enter 1. Or enter any number the event is allowed to be retriggered.
Example using a trigger to deactivate an object. Use the + button to add more functions to the event.
Events are added at the current time and displayed as a small flag icon on the object .
Track
debug logging