Advanced Timer
This node provides a high-precision timer with start, stop, pause, and reset functionality.
The Advanced Timer node is a versatile timing tool for animations, cooldowns, and game loops.
The Advanced Timer node counts time up or down. It offers precise control over playback and emits signals at specific intervals or upon completion.
Configuration
| Data | Description |
|---|
| Duration | The target time in milliseconds. Default: 1000. |
| Loop | Boolean. If true, the timer restarts automatically when finished. |
Actions
| Signal | Description |
|---|
| Start | Starts the timer. |
| Stop | Stops the timer and resets to 0. |
| Pause | Pauses the timer at current time. |
| Resume | Resumes from paused state. |
| Reset | Resets time to 0 without starting. |
Outputs
Status
| Data | Description |
|---|
| Current Time | The elapsed time in milliseconds. |
| Progress | Normalized progress (0 to 1). |
| Is Running | Boolean status. |
Events
| Signal | Description |
|---|
| Finished | Triggered when the timer reaches Duration. |
| Tick | Triggered every frame (or update interval) while running. |
Usage
Cooldown
- Set Duration to 5000 (5 seconds).
- Trigger Start when an ability is used.
- Disable the ability button while Is Running is true.
- Re-enable when Finished triggers.
Progress Bar
- Connect Progress to a Slider or Animate To Value node to visualize time passing.
Detailed Behavior
- Precision: Uses for high accuracy.
- Ticker: Integrates with the application's main loop to ensure smooth updates.
Troubleshooting
- Not Stopping: If Loop is true, Finished will trigger, but the timer will immediately restart. Use Stop to halt it completely.