Friday, September 2, 2016

Dwarf Fortress, not just a game a way of life

Dwarf Fortress
Grade: A+ and D-, yes both
Platform: Windows, Linux
Genre: Godsim
Website: Free (donations appreciated)
Wiki:  you'll need it
Released: 2006

Dwarf Fortress is one of those games where even if you haven't played it you've felt it's influence.  It has changed the face of modern gaming and even if you haven't played it odds are very good that the person who wrote the last game you loaded did play it.  There are the direct copies and knock offs like Gnomoria, Craft the World, and A Game of Dwarves, and games clearly inspired by it like Rimworld.  But the influence of DF spreads far beyond the games more obviously inspired by it.  No Man's Sky, Minecraft and many others were both influenced in more subtle ways by DF.

It is a game I both love and hate.

I have played Dwarf Fortress almost since it was first released, it came out in August of 2006, I started playing in October of 2006 and I've never stopped.

The reason for DF's popularity, cult following, and widespread influence in the gaming word is due to the fact that it is an amazingly, shockingly, complex and detailed game. Which surprises some people, because it's also an ASCII game.  There are graphics packs available, the Lazy Noob Pack bundles both graphics and a few very useful mods and upgrades.  But I started with the ASCII and I've gotten so used to it that the idea of playing with a graphics pack seems absurd.  I don't even see the ASCII anymore, it's just elf, dwarf, goblin.

Because the graphics are so simple, DF can turn all of your computer's processor towards running an absurdly complicated simulation.  Combat, for example, does not have abstract hit points, instead for every blow the damage to skin, muscle, nerves, and bones is computed based on a multitude of factors and as a result teeth are knocked out, fingers, toes, and limbs hacked off, survivors may be crippled for life or merely take time to heal, all shown in an explosion of red commas, semicolons, and grave quotes, and the ASCII smiley face of a dwarf turning dull as their life bleeds out turning the periods of the ground red.

Temperature is calculated for each object and changes per the laws of thermodynamics, magma flows melt ice, burn their way through flammable objects, and can be guided through pipes made of durable enough material.  Wind and weather are computed not merely for your locale, but establishing broad weather patterns across the entire virtual world.  Caravans travel from location to location, kingdoms war, all of which matters.

The world is built, a process that even on a relatively powerful computer takes ten minutes or so, and centuries of history are simulated, kingdoms rise and fall, necromancers learn the secrets of life and death from dark gods and write them in books that may, or may not, survive until your fortress is completed.  When you enter the game a history already exists, important figures have been born and died, wars have been fought and your dwarves will engrave significant historic events on the wall in the awkward and stilted prose of procedurally generated text.

Tarn Adams, Toady One on the internet, is the coder.  And yes, the definite article applies.  Over the past ten years he has created dwarf fortress single handedly [1].  And he has taken procedural generation much further than most games, even big AAA behemoths like Daggerfall, ever took it.

All the processing power that the average game devotes to graphics, Toady has directed to both a robust simulation, and a massive and complex procedural generation system.

Or.... Well, almost all the processing power.  Actually closer to around 1/4 of the processing power on most computers, and depending on how many cores you have on your CPU maybe less.

Here is where my love affair with DF runs into problems.  Because, before he was able to devote his life to Dwarf Fortress, Toady was Dr. Tarn Adams, a man with a Ph.D. in mathematics from Stanford, and he learned to program not by taking actual programming (much less game programming) classes, but by picking it up as he did his math work.  And, well, as a programmer he makes a great theoretical mathematician.  The fact is that the code for DF sucks mightily, beginning with the fact that it only uses a single processor.  Which means that you will have one processor running at around 100%, and the others will be idle.

Once you've learned how to survive and you aren't having Fun! [2] because everyone is starving or dying in goblin invasions, every game of Dwarf Fortress ends the same way: you quit because the game has slowed down so much you can't stand it.

Toady is very protective of his code, as DF gained popularity and fame a great many game programmers begged for permission to help him sort out some of the massive, huge, problems. He turned them all down. The code is his, no one else may look at it or contribute.

As a result, the game is a mess.  Not just the user interface (which is staggeringly awful, but eventually it gets burned into muscle memory), but the fact that it keeps getting slower, and slower, and slower, and there's still huge problems that have to be resolved with unofficial hacks (dfhack is all but mandatory if you don't want to go mad) because Toady keeps getting ideas for new features to add and won't take time off from adding them and bloating the code even more to even try to optimize things and make it run faster.

Yet, despite knowing that it will end with my fort becoming unplayable due to lag, on my computer another instant has dragged slowly past, a dwarf warrior has just hit a goblin invader with her silver warhammer, and he flies comically across the screen in an explosion of ASCII gore.

Dwarf Fortress is the best, and worst, game I have ever played and I cannot stop playing.  And you should try it too.

[1] Well, sort of.  He did actually, once, deign to permit some people to help with a graphics rendering issue.  And he claims the venture is a collaboration with his brother, Zach, who contributes ideas.

[2] The unofficial motto of Dwarf Fortress is "losing is fun", and thus massive death and destruction is often called "fun" by us players.

No comments:

Post a Comment