Sunken cost-driven development - Or: why would you ever build a game engine?

24 January 2024

A question I get asked a lot is why I decided to build a game engine. All in all, there’s already great commercial engines out there, that, as long as you don’t earn any money, cost nothing.

Unity and Unreal Engine are powerhouses with an abundance of tools and resources built on top of them.

In addition, if commercial engines are not your cup of tea and you wish to go open source, there’s a plethora of options there as well. Godot being the most cited one, but far from the only option.

However, one thing I have experienced when trying to build 3D applications or experiences using these engines that go far beyond a game, the abstraction these engines provide start to work against you, as they make a lot of assumptions on how you want to architect your software, and how to render things on the screen.

At a certain point you’ll be implementing your own custom UI framework on top of the one the engine provides, or you’ll implement a different way the scene should be represented. Want to import assets on runtime into the engine? Now you have assets that are tied to a specific engine version. (Unity’s AssetBundles).

So the game engine becomes a glorified level editor and renderer.

How hard could it be to just write that yourself as well?

Well, as it turns out, really hard. If I would have known how much I would be dealing with platform specific peculiarities or the wondrous world of transpiling shader code, and a seemingly infinite amount of unknown-unknowns, I don’t think I would have embarked on this journey.

But I’m glad I did, because sunken cost fallacy is an amazing thing, and having already sunken 3 months in this process (rookie numbers, I know), I don’t want to quit now.

My reasons have solidified a bit throughout this process and can be summed up by the following points: