Thread-Safe Observable Properties System for Unity
High-performance, GC-friendly reactive state management and property binding library for Unity C# architectures.
- Result
- Zero-allocation reactive state management
- Area
- Unity / Packages
Highlights
- Zero-allocation event dispatch for value types preventing garbage collection spikes
- Automated unsubscription tied to Unity GameObject destruction preventing memory leaks
- Custom Unity Inspector drawers for live runtime inspection and state debugging
Overview
An open-source reactive data-binding system for Unity that eliminates expensive polling in Update() loops, cleanly decouples UI from gameplay state, and prevents memory leaks through lifecycle-aware subscriptions.
See it in action
1 screenshot
Select a screenshot to view it full size; the arrow keys move between them.
The challenge
Game development architectures often degrade into tightly coupled systems where UI scripts poll gameplay state every frame inside Update(), wasting CPU cycles and causing fragile dependencies.
Native C# events are prone to memory leaks when event listeners are not manually detached upon GameObject destruction.
What I built
Engineered a generic ObservableProperty<T> system with automated subscription management tied directly to Unity MonoBehaviour lifecycles.
Implemented zero-allocation value comparisons and event dispatching for primitive and struct types to avoid garbage collection spikes.
Developed custom Unity Editor PropertyDrawers for real-time value inspection and live debugging in the inspector.
Outcome
Open-sourced on GitHub with comprehensive test coverage.
Eliminated UI polling overhead across game components, improving frame budget predictability and architectural modularity.