r/haskell
•
u/TheOneExpert
•
4h ago
announcement Mischief - The Haskell Game Engine. Now with Rendering, Assets, Input.
Hey. so I just published all my work on Mischief on Hackage. It's a free, open-source, ECS Game Engine written in Haskell that I've been working continuously on for the past 6+ months.
It is a modular, decentralized, customizable game engine that leverages functional programming and data-oriented design to create a fresh experience for game devs. It prioritizes making weird, unique, personal games with a strong focus on creativity and human expression. The engine itself is also what I'd consider to be one of my greatest artistic feats and acts of creation. You can find more about the community and engine's values here.
On top of the ECS (which I've previously posted about but almost entirely reworked since), it now has input support (via SDL) and hot-reloadable assets.
It also has a strongly-typed rendering abstraction that I've built on top of WGPU. It allows you to define extendable shaders / materials directly in Haskell and integrate them into the your app pretty easily. You can easily write low-level rendering code without the usual layers of boilerplate surrounding it. Note that you could also just use the pre-defined materials (such as the sprite material) and skip past the low-level stuff, it's up to you.
There's a lot of cool utilities and tooling that's documented in the official books (link below), so I really encourage anyone interested to give it a try and at least go through the introductory chapters. I consider it to be a pretty unique and creative spin on a lot of the game engines we've seen over the years in other languages. Each little thing is meant to be "what if you had something as good as X from engine Y, but it was entirely functional?".
You don't really need any previous Haskell, ECS or game dev experience to use it. The books will slowly ease you into it.
You can read more details and catch up on the official docs here.
I also encourage you to join the official discord community server if you are at all interested in the engine or just seeing and discussing cool apps written in Haskell, or chatting with people passionate about it, or just supporting me and Mischief.
As a side note, no "generative AI" such as LLMs was used in making this and I plan to keep it that way (see the "AI" policy). Discussion of "AI" is also greatly discouraged on the official community places. I am burnt out on the subject and want to create a small safe haven for people that are as well.
Additionally, the official repo can be found here (I moved it to Codeberg recently). Don't hesitate to request features, file bug reports, or contribute in some other way.
Also, here's a video of a little example where I spawn a few sprites, move them around, and mess with their animations live (sorry for the bad framerate / quality, I had to make it a gif):

