Canopy is a declarative 2D game engine built for Kotlin developers.
It rethinks how games are structured by combining:
- 🌲 Declarative structure → declare how your game is structured via node-based DSL
- ⚡ Reactive state → changes propagate automatically
- 🧩 Composable behaviors → logic is modular and reusable
Instead of manually orchestrating update loops and state syncing, you describe your game, and Canopy handles the flow.
Traditional engines revolve around:
“What runs every frame?”
Canopy flips that into:
“What is the structure of my world, and how does it react to change?”
Build your game using a clean Kotlin DSL:
EmptyNode("level") {
Player("player") {
behavior(PlayerController())
}
Enemy("enemy")
UI("ui")
}.asSceneRoot()No manual update loops. No tangled systems.
👉 Just structure + behavior.
You describe what exists, not how to update it. You do it via our node-based system
Example
EmptyNode("level"){
Player()
Enemy{
at(200f, 100f)
behavior(EnemyController())
Weapon("gun")
}
UI()
}State changes automatically propagate through your game.
No manual wiring. No hidden dependencies.
val onKilled = event()
// Stateful events
val health = signal(100)
// Derived signals
val healthPercentage = computed{ "${health() / 100}%" }
// Derived callbacks
effect{
log.info{ "Life: ${healthPercentage()}" }
if(health() <= 0)
onKilled.emit()
}- Organized like a tree
- Extensible like a framework
- Not locked into rigid engine patterns
Built from the ground up for Kotlin:
- Modern language features
- DSL-driven APIs
- No Java-first compromises
Canopy is built with a few strong principles:
-
Clarity over cleverness → Code should be readable and predictable
-
Composition over inheritance → Build systems by combining behaviors
-
Reactivity over manual syncing → State drives behavior automatically
-
Structure over chaos → Your game should scale without becoming messy
-
Freedom without fragmentation → Flexible, but still coherent
Canopy is work in progress and not yet production-ready.
- 🧪 Headless runtime (terminal-based execution)
- ⚡ Reactive system foundations
- 🌲 Core node architecture
This allows:
- fast iteration
- simulation-driven development
- debugging without rendering overhead
👉 See the roadmap: Roadmap
- Kotlin 2.3.10+
Canopy tracks modern Kotlin releases closely.
MIT License — see LICENSE-MIT
APACHE License - see LICENSE-APACHE
Canopy Engine • 2026
