Repository navigation
v0.11.0
[0.11.0] – 2025-09-22
Breaking Change
Moved from ISaveable to ISaveable<TState> to provide compile-time type safety, safer JSON deserialization (no type names), and clearer save/restore contracts. All saveables must now define a serializable TState and implement CaptureState(): TState and RestoreState(TState state).
Serialization & Safety
- JSON now deserializes directly to each saveable’s
TState(no type names emitted), reducing polymorphic-deserialization risk. - Existing save files that match the new
TStateshape should continue to load; files that relied on polymorphicobjectstates will need a one-time migration.
Async/Awaitable & Concurrency
- Replaced single-iteration “while not cancelled” wrappers with clear guard clauses.
- Fixed a rare operation-queue race by making enqueue/start atomic behind a lock;
IsBusyis reset in afinallyblock. - Broader cancellation: operations link
destroyCancellationTokenwithApplication.exitCancellationToken. - Exception surfacing: errors are logged and rethrown so callers can observe faults when awaiting.
- Logging helpers include a Unity context only when on the main thread; background-thread logs remain safe.
Miscellaneous
FileHandlerkeeps the public API and formatting; small internal cleanups (consistent use of computedfullPath, clearer errors on delete).- Updated all Samples to the
ISaveable<TState>pattern.
Migration notes
- Replace ISaveable with
ISaveable<TState>and define a serializableTState(struct or class). - Update methods to
TState CaptureState()andvoid RestoreState(TState state).