Basics
Guides
API Reference
Basics
Guides
API Reference
[15:7] extends: LocalTimer
Wraps FXGL's OfflineTimer (com.almasb.fxgl.time.OfflineTimer), a persisted-across-restarts capture timer for "24-hour reward" style features. The last capture() time is written to a Bundle so it survives game restarts when the Bundle is persisted via SaveLoadService.
OfflineTimer (string Name = "default", BundleObj = null)
Creates a new OfflineTimer with the given name backed by the supplied Bundle.
Name is the unique key prefix for this timer (e.g. "daily_login").BundleObj is a Bundle wrapper that persists the state.adopt (object Ajo)
Wraps an existing OfflineTimer AussomJavaObject.
Ajo is an AussomJavaObject around an OfflineTimer.A new wrapper.getName ()
Returns the timer name.
capture ()
Records "now" as the last-capture time inside the bundle.
this objectelapsed (double DurationSeconds)
Returns true when the elapsed time since last capture() exceeds DurationSeconds. Auto-captures and returns true on the first call.
DurationSeconds is the threshold in seconds.A bool.
Aussom
Write once. Embed everywhere.
Copyright 2026 Austin Lehman. All rights reserved.