Week 6 progress
This week I continued refactoring my AI spaghetti to use Behavior Trees instead. After some overanalysis of different implementations, including coroutines, functional, OOP and discriminated unions, I settled on the classes approach (I know, how dull) since it offered the best performance and flexibility at the cost of a bit more boilerplate. Just avoiding deeply nested inheritance trees and we’re fine.
And since BTs are very hard to debug without visual tools, I added a small execution visualizer in the game (green - success, red - fail, yellow - running):

I tried adding save/load functionality like in the tutorial, but it’s honestly too painful to do at this point. Between writing custom serializers and making sure nothing breaks after deserializing, it would take way too much time, and I’d rather focus on other things right now.
Like adding a little character selection screen. It’s not much, but each character starts the game with their own different items, and I might give them different stats later on. And I wanted an excuse to use more of Seth’s awesome sprites.

And I finally got around to implementing different input handlers so I could do the level up selection screen:

And the CI job now auto publishes native versions for Win, Linux and Mac along the existing wasm version.
Get RaygueLike 2025
RaygueLike 2025
Following a basic roguelike tutorial
| Status | In development |
| Author | sirdorius |
| Genre | Strategy |
| Tags | No AI, Open Source, Roguelike, sourcecode, Turn-based |
More posts
- Week 7 progress55 days ago
- Week 5 progress69 days ago
- Week 4 progress76 days ago
- Week 3 progress85 days ago
- Week 2 progress91 days ago
- Turn and action resolution - ECS style94 days ago
- Week 1 progress98 days ago
- Tech stack - Graphics API and wasmJul 18, 2025
- Tech stack - ECS and languagesJul 18, 2025
Leave a comment
Log in with itch.io to leave a comment.