Project: Keen Dreams
The Nightdive train keeps rolling along! This one was a Mac and Linux port of the "lost episode" of the Commander Keen series. This was on Steam at some point, until there was some sort of disagreement between Valve and the publisher, apparently, and it went away. 

This project was another "hey, can you get this compiling real fast?" thing--in fact, one of my patrons did a ton of Linux work on the original Steam builds (hi David!)--and I picked it up from there, ripping out the OpenGL code for an SDL2-based renderer.

The original code I was given did something clever with OpenGL, which I had also tried with Postal 1 many years ago: You have a 1D texture of the game's palette, and write out the 8-bit graphics as a GL_RED texture. Then you have a pixel shader that looks up the proper colors from the former based on values in the latter. Once you were there, it was easy to scale the game to a higher resolution, and get Steam Overlay support, etc.

In practice, at least years ago, this was an awesome solution...on Linux. On Windows, it was painful. People didn't have OpenGL drivers. People didn't have OpenGL drivers that could do shaders, or framebuffer_blit for scaling. People had OpenGL drivers with crazy optimization panels that would make it misread that palette texture!!

Eventually, I replaced this in Postal with SDL2's render API. I slashed out hundreds of lines of code--the game didn't even _link_ against OpenGL anymore, and on Windows, it just quietly used Direct3D instead, and all the bug reports stopped immediately.

So I was well-prepared to do this for Keen Dreams. It only took a little effort, and now the game uses Direct3D, OpenGL, or a software renderer with the flip of a switch and no renderer-specific code in the game. We're hoping to land a Vulkan renderer backend in SDL soon, and then you're going to be witnessing the most technologically advanced CGA game ever made!

Keen Dreams is on Steam right now. It's under new management, with Nightdive Studios taking control of the game. It is reusing the same appid as it originally had, so if you owned it before, you still do, and your achievements will remain unlocked, etc. If you don't own it, it's available for Mac, Linux, and Windows right over...here!

There will be other games coming this month, but we're off to a running start for November so far.  :)


By becoming a patron, you'll instantly unlock access to 3 exclusive posts
3
Writings
By becoming a patron, you'll instantly unlock access to 3 exclusive posts
3
Writings