↖️ Blog Archive

Contributing to OpenCiv3

Bradley Gannon

2026-01-16

TL;DR: I contributed some code to the OpenCiv3 project, which is a community clone of Sid Meier’s Civilization III (2002). I played a lot of Civ3 as a kid, and more recently I’ve been playing it through Steam. I first heard about OpenCiv3 in a Suede video, and I started contributing but got distracted by piano work. This week I’ve revived my contributions and gotten some of them merged.

OpenCiv3 and My Small Contributions

The long-term goal of OpenCiv3 is to create a free software project that replicates the features of Civ3 to the greatest reasonable extent while exposing many more interfaces and opportunities for third-party modification. There are already plenty of Civ3 mods, but as I understand it there are certain mod features which are difficult or impossible to build because of how Civ3 is arranged internally. The original game isn’t free software, so there’s no easy way to adjust it to make these mods any easier. OpenCiv3 seeks to change that.

OpenCiv3 is written with the Godot game engine with most of the real logic in C#. This is probably the best choice, if for no other reason than that it allows for easy cross-platform builds.1 I hadn’t written any C# before, but it’s a lot like other languages I already know and hasn’t been too hard to pick up. The garbage collection, strong types, and object orientation make it a solid language for game logic. The only problem I have with it is the weird Microsoft build tools, but that has more to do with my own opinions than the properties of the tools themselves.

One really cool feature of OpenCiv3 is that if you already own a copy of the original game, then you can point OpenCiv3 at it and the game will load in the original assets and use them instead of the free placeholders. This brings the experience much closer to the original game. It relies on a lot of interesting work to parse the old formats that the original game used to store assets.

The particular contributions I’ve made have mostly been related to the logic that tells computer players where to send their settler units to build new cities. The details are too boring to mention (and are documented in the repo anyway), but all the same it was fun to work on. I did a decent amount of the work on my laptop while in a car, which was a neat way to exercise my new ability to log into my home machine from anywhere via VPN. This arrangement prompted me to upgrade my Neovim configuration a bit to add completion support with blink.cmp, as well as the omnisharp C# language server. I’m getting pretty close to considering Neovim to be my primary development environment, with VS Codium as a backup when working locally.

Contributing to Free Software

I wrote my first line of code about 22 years ago. In hindsight, the first ten or twelve years of my time writing little Python scripts and HTML documents didn’t amount to that much real skill. All that time messing around on my own was probably equivalent to a single year of an actual software job or even just formal education. It was fun, but my learning path was slow and winding, and for most of it I had no teachers who could help me. During that period, my skills were so poor that any attempt I would have made at contributing to a free software project would have been a net negative for the maintainers. At some point I became aware of this and decided that the people who could contribute to free software projects were so far ahead of me in their skills that any hope for me of achieving that level was at best a long way off.

Today I have a lot more skill, but I realized recently that I haven’t updated my expectations of myself related to free software. For a long time I’ve built projects alone in part because I didn’t have any practical alternative. Now there are thousands of projects that I could conceivably learn about and contribute to if I decided to commit the time. OpenCiv3 is one of them, but there are many others. I should do this more, and it should become at least as likely for me to contribute to an existing project as it already is for me to start my own. I like the idea of my work being useful, and getting my keystrokes merged into a popular project is a good way to make that happen.


  1. Civ3 is nominally Windows-only, but it does run under Linux with some careful configuration.↩︎