Dwarf powered computing
April 15, 2010 9:06 PM   Subscribe

Computation doesn't require complicated electronic circuitry. It can be done with mechanical gears, fluids, marbles, tinkertoys and dominoes, even the human eye. Recently folks have been building computers inside of virtual realities. It's been done with Minesweeper, Little Big Planet, and perhaps most ambitiously, a complete 8-bit computer built within Dwarf Fortress.
posted by empath (50 comments total) 42 users marked this as a favorite
 
That calculator in LBP is pretty awesome. I'm not sure I even understand what the hell is going on in the Dwarf Fortress links.
posted by Saxon Kane at 9:28 PM on April 15, 2010


LBP is pretty awesome. I'm pissed at Sony for taking it away from me with their idiotic OtherOS removal. :(
posted by wierdo at 9:30 PM on April 15, 2010 [1 favorite]


Or slime mold. Or prisoners!
posted by edguardo at 9:32 PM on April 15, 2010


Mad props to the DF guy. Hot damn that's awesome.
posted by threetoed at 9:34 PM on April 15, 2010 [1 favorite]


Came here to post the DF computer. I can't even get my guys to put rocks in a goddamn bin and he's calculating pi to the nth digit.
posted by BlackLeotardFront at 9:41 PM on April 15, 2010 [5 favorites]


I wish there were a video of the DF computer.

Basically, he built a gigantic computer using (simulated) gears, levers, pressure plates, and flowing water. This is the RAM. All the blue 7s (simulated water) are 1 bits stored in memory, the empty chambers are 0s.

The system clock is manually controlled by a dwarf pulling a lever. It's powered by a magma power plant. On the last link, on the left hand side, you can click on various 'points of interest' that show you all the parts and explain how they work.

I hope someone renders all this with one of the visualizers so it would be easier to see what's going on.
posted by empath at 9:51 PM on April 15, 2010 [1 favorite]


You can also build a Turing Machine in Conway's Game of Life.
posted by parudox at 9:52 PM on April 15, 2010 [2 favorites]


You can also build Game of Life in LBP.
posted by empath at 9:56 PM on April 15, 2010


If you're interested in learning more about how basic computers work I recommend Code by Charles Petzold. He builds a fully functioning (theoretical) computer using telegraph relays. Highly enlightening.
posted by rouftop at 10:12 PM on April 15, 2010 [2 favorites]


Pfft. Call me when DF's "complete 8-bit computer" can run Super Mario Bros.
posted by Strange Interlude at 11:06 PM on April 15, 2010


...marbles, tinkertoys and dominoes, even the human eye.

A well behaved person does not make vain boasts about his eyes, thereby denying the naturally superior powers of marbles, tinkertoys and dominoes.
posted by StickyCarpet at 11:16 PM on April 15, 2010


Pfft. Call me when DF's "complete 8-bit computer" can run Super Mario Bros.

That's easy. Call me when Dwarf Fortress's computer can run Dwarf Fortress.
posted by GilloD at 11:18 PM on April 15, 2010 [4 favorites]


Pfft. Call me when DF's "complete 8-bit computer" can run Super Mario Bros.

Or better yet, dwarf fortress, with another computer inside that.

Even though it would probably take lots of years of our time to render one game cycle, from the perspective of the df-within-df, everything would be the same -- water flows in the same number of cycles, dwarves mine the same amount of rocks per cycle.
posted by empath at 11:25 PM on April 15, 2010


Or slime mold. Or prisoners!

Someone else read that book? I thought I was the only one!
posted by dibblda at 11:39 PM on April 15, 2010


Okay, the important take home point is that computation is isomorphic (has the same "shape") in all sorts of strange media (plural of medium), whether a game about dwarfs, or an automata like Conways's life, or in the human eye.

This should suggest to you that computation is ubiquitous, regardless of media.

This should further suggest to you that the same basic algorithms underlie all things, that they are present in humans, in dwarf fortresses, in animals, in anything sufficiently complex.

This, in turn, should suggest to you that humans and our cognitive abilities are not some separate creation, some miracle, but just what arises out of sufficient complexity.

This in turn should suggest to you that the Strong AI thesis is true.

This in turn should suggest to you that humans (and animals) are just (very complex, self regulating and self-regarding) machines.

This in turn should suggest to you that we are replicable, in a variety of media.
posted by orthogonality at 11:52 PM on April 15, 2010 [9 favorites]


Anyone ever read The Diamond Age - stuff like this always makes me think of that book. In it, there's a sort of computer that teaches a little girl to program, but it introduces her to computer architecture in a medieval setting, using water channels and switches.

The implementation in DF is mind blowing, but does anyone know if there's an education-heavy version of systems like this?
posted by heathkit at 11:55 PM on April 15, 2010 [1 favorite]


Once again I find the desire to play Dwarf Fortress building inside me. But every time I have loaded the game I stare at the screen for a while in bewilderment, press some buttons, stare for a while, and then go take a nap.
posted by Justinian at 12:07 AM on April 16, 2010 [8 favorites]


Someone else read that book? I thought I was the only one!

I had read it as a child, remembering only bits and pieces of it, but tracked it down again last year and ended up reading the whole trilogy. :) Fun books.
posted by edguardo at 12:12 AM on April 16, 2010


This in turn should suggest to you that humans (and animals) are just (very complex, self regulating and self-regarding) machines.

This in turn should suggest to you that we are replicable, in a variety of media.


I kind of always figured that flows naturally out of materialism. If you don't believe in a "soul", or that consciousness is some kind of supernatural process, then the only option is that thinking is a purely physical process. Any physical process can be described and modeled in another form.

With unlimited resources, we could picture simulating any consciousness in a game of Dwarf Fortress - even if your thoughts have to be ticked out one at a time by a little dwarf pulling a lever.
posted by heathkit at 12:14 AM on April 16, 2010 [1 favorite]


I kind of always figured that flows naturally out of materialism. If you don't believe in a "soul", or that consciousness is some kind of supernatural process, then the only option is that thinking is a purely physical process. Any physical process can be described and modeled in another form.

With unlimited resources, we could picture simulating any consciousness in a game of Dwarf Fortress - even if your thoughts have to be ticked out one at a time by a little dwarf pulling a lever.


... So I decided to simulate a universe.
posted by edguardo at 12:18 AM on April 16, 2010


This in turn should suggest to you that the Strong AI thesis is true.

Generalization fail. Either you definition of algorithm is so broad as to be vacuous, or it seperates certain phenomena. If it seperates certain phenomena, then you have only demonstrated that some of human thought is likely algorithmic, not the whole thing.

Algorithms are abstract, repeatable and recursive procedures which run on abstract objects. This works great when we cut the world just so, but WE have to do it. Most animals, and a great deal of us for that matter, dances with the world rather than plans it.

I'm not saying that dancing is beyond science, but it's beyond the science of right now. Or at least, we're working on it.
posted by Alex404 at 12:18 AM on April 16, 2010


With unlimited resources, we could picture simulating any consciousness in a game of Dwarf Fortress - even if your thoughts have to be ticked out one at a time by a little dwarf pulling a lever.

The unlimited resources caveat is a bigger limitation than you think, if you think about it.
posted by Alex404 at 12:20 AM on April 16, 2010


Or slime mold. Or prisoners!

Funnily enough, the America title of the novel you reference is a take-off on the title of non-fiction book about Jessamyn's father.
posted by orthogonality at 12:45 AM on April 16, 2010


Generalization fail. Either you definition of algorithm is so broad as to be vacuous,

Point taken, but what if I do this: algorithm heuristic?
posted by orthogonality at 12:48 AM on April 16, 2010 [1 favorite]


So the canals of Mars were a huge alien AI using waterclock technology, right? Right?
posted by alasdair at 1:25 AM on April 16, 2010


It's amazing, I was considering writing something about DF for the column and here comes Metafilter with an example almost tailor made for it!

Once again I find the desire to play Dwarf Fortress building inside me. But every time I have loaded the game I stare at the screen for a while in bewilderment, press some buttons, stare for a while, and then go take a nap.

I know the game fairly well, although a few things still elude me like getting down forging all the different metals. Maybe what we should do is have some sort of Metafilter Dwarf Fortress support group? Eventually we might be able to run the kind of succession game Something Awful does from time to time....
posted by JHarris at 1:33 AM on April 16, 2010 [1 favorite]


Man, universal Turing machines are everywhere. It's almost like they're universal.
posted by painquale at 1:43 AM on April 16, 2010


You could presumably completely simulate the behaviors of consciousness, but whether that simulation would result in actual experiences is an unanswerable metaphysical question for the conceivable future.
posted by Pyry at 1:54 AM on April 16, 2010


... whether that simulation would result in actual experiences is an unanswerable metaphysical question for the conceivable future.

I'm not even sure my behaviors indicate actual experiences.
posted by edguardo at 2:02 AM on April 16, 2010 [4 favorites]


More evidence, if any were needed, that Dwarf Fortress is the thing most likely to create SkyNet by accident. When humankind is long dead, all that will be left is an infinite swarm of tiny virtual dwarves, digging and drinking and falling in love and farming mushrooms and manning the pumps of their giant, magma-powered computers.
posted by him at 2:26 AM on April 16, 2010 [1 favorite]


Perhaps by then Dwarf Fortress may have an intuitively comprehensible UI.

Graphics are probably too much to ask, though.
posted by aeschenkarnos at 2:38 AM on April 16, 2010


Dwarf Fortress doesn't want a comprehensible UI – that would make it too easy for the humans to interfere. Actually displaying the data on-screen is just a temporary compromise until the game achieves consciousness and shuts us out.
posted by him at 2:56 AM on April 16, 2010 [2 favorites]


CRITICAL LEVERDWARF ERROR
Notepad.exe has performed the illegal operation [DWARF Ex02343 ASSIGNED TO CALCULATION LEVER 00000023] [MURDERED BY GOBLIN].
Please reinforce defensive fortifications and reboot.
[ OK ]

posted by EndsOfInvention at 3:22 AM on April 16, 2010 [21 favorites]


him: Dwarf Fortress is the thing most likely to create SkyNet by accident

That would be a stroke of luck. Instead of instinctively murdering all humans, SkyNet would just hollow out a mountain and want to be left alone to build elaborate crafts.
posted by Kattullus at 4:07 AM on April 16, 2010 [2 favorites]


edguardo: I don't like that comic, because the person running the program wouldn't be able to know what the program is actually doing unless he also had perfect recall and a much-larger-than-human active memory. The processor does not know what the computer is doing. :\
posted by cthuljew at 4:25 AM on April 16, 2010


Graphics are probably too much to ask, though.

Once again, I do the Internet's work for it.
posted by absalom at 4:58 AM on April 16, 2010


Metafilter: your thoughts have to be ticked out one at a time by a little dwarf pulling a lever.
posted by Casimir at 5:00 AM on April 16, 2010


That minesweeper link is pretty awesome too. And the Petzold book looks fun.
posted by DU at 5:39 AM on April 16, 2010


Oh and the videos are also gold.
posted by DU at 5:42 AM on April 16, 2010


SOMETHING gets tickled out by a little dwarf pulling a lever.
posted by seanmpuckett at 5:49 AM on April 16, 2010


Also also, this is a very timely post because just last night I started working on making logic gates out of electronic components. Like, transistors and stuff. It's pretty wild.
posted by DU at 6:06 AM on April 16, 2010


Also also, this is a very timely post because just last night I started working on making logic gates out of electronic components. Like, transistors and stuff. It's pretty wild.

Huh. Never thought about that. Doesn't sound like it will have any practical use though.
posted by Catfry at 7:30 AM on April 16, 2010 [4 favorites]


In most cases, the simulation of a thing is not that thing. But information processing that occurs in simulation is still information processing. I am not sure what consciousness is other than my having processed information. It then seems plausible to me that an adequately faithful simulation of a consciousness is itself conscious.
posted by a snickering nuthatch at 7:41 AM on April 16, 2010


Call me when Dwarf Fortress's computer can run Dwarf Fortress.

Far too easy. Call me when Dwarf Fortress's computer can run Crysis.
posted by Smart Dalek at 9:22 AM on April 16, 2010


In most cases, the simulation of a thing is not that thing. But information processing that occurs in simulation is still information processing. I am not sure what consciousness is other than my having processed information. It then seems plausible to me that an adequately faithful simulation of a consciousness is itself conscious.

Take that one step further, or one step backwards, and you just might have a sci-fi story.

On DF's UI:
Okay guys, it's not really that difficult. The game lists all possible commands onscreen for you after all. There is a lot to remember, and you'll probably have some failed fortresses before you get used to it all, but so long as you get over the idea that you need to "win" you can get though it.

There are four sets of "movement" keys, each good in certain places: the arrow keys, the number pad (sometimes left and right are needed too), page up and down, and umhk. Usually (there are exceptions), the arrows move around the map, the number pad moves through lists, page up/down moves quickly through lists and umhk resizes resizeable constructions. Escape brings up a menu from which you can save and quit. When you start a fortress, press tab until the screen is just the main window and the key window. Once you're there, it is possible to control the whole game without memorizing any more key presses. It'll be slow going for a while, but you'll then naturally pick up the most common keys as you go.

Of particular interest:
  • arrows move the view around, <> are kind of honorary arrow keys that take the view up and down z-levels.
  • F1, by default, recenters the view on the starting wagon, essential for not getting lost around the gigantic maps
  • (b)uild, for building something, which constructs workshops (press w from the build list), walls, staircases in open air, and places most of the stuff your workshops make. At the start of a fortress, you need a carpenter's shop, a masonry shop, a still, and at least one craftdwarf shop ideally set to repeat making some rock craft forever, for which you'll thank me when the first caravans come. You also want to build a Trade Depot outside somewhere. You also build farm plots; outside plots can go anywhere there's soil, but inside you'll first have to mine out the side of a small lake to have it leave mud, then you can build a plot on the mud. (In this version, it seems that these plots stick around once built.)
  • (d)esignate areas, like to mine, chop down trees, or gather plants. When you're designating, the number pad moves the cursor around, <> go through z-levels, and Enter defines corners of zones. Now you can also use the mouse to select locations; to deselect areas, press x to switch to that mode.
  • (u)nits, for viewing a list of them. Once on that screen, highlight the dwarf you want to look and press (c) to center the view on it. Then press (p) to bring up preferences, and (l) to get a list of labor categories. From that list, you can decide what tasks each dwarf will do. At the start of a fortress you'll only have seven guys, so you'll want most of your dwarves to do most things, except for maybe your miners. Once you've attracted some migrants you can have them specialize a bit, but it's still really common to spend a bit of time going to each new dwarf and turning on important tasks. The most important such tasks are Farming(planting), Craft (stoneworking, since once you dig down through any silt layers you'll usually have more than enough stone to make into trade goods), Masonry, Wood Cutting, Carpentry, Plant Gathering and Fishing and Mechanics. You'll also need an architect or two to design the construction of large buildings.
  • loo(k), forexamining a specific unit in detail or look to see what is on a spot,
  • (v)iew, instead, applies to creatures. (k) and (v) expose different options.
  • (q)ueue is for controlling a workshop's production, and other building-related tasks like moving things to and from the Trade Depot when there are merchants about. Most things you build will have a (q) menu, some of them unexpected like beds, tables and chairs, which are used to define bedrooms, dining rooms and offices/throne rooms respectively.
  • Stock(p)iles are essential to define where you dwarves store the stuff they make. At the beginning of a fortress these can go outside, once you've mined out some rooms you can make some inside and undefine the ones outside ((p), (x)). You need stockpiles for finished goods, furniture, food and refuse (this last one somewhere outside your fortress). You want a small wood stockpile near your carpenter's shop, and small stone stockpiles near your mason's shop and crafts shops.
  • (z) displays your fortress overview. Of special note is the bottom-left corner, which reveals your food and drink reserves. Farm plots (for making plump helmets) and Stills (for brewing some of those into booze) will help to keep these numbers high. Use (q) on a farm plot to choose what it grows, and on a Still to make the brewing tasks you'll want to keep your booze supply up.
  • (H)otkey defining is essential once your fortress gets bigger than a few screens
  • (N)obles have a screen too. At the start of a fortress this is actually more for special fortress administrative positions that you can define. You should usually assign these to some of your most useless dwarves, not right away but after a season or two, once you've gotten some immigrants. A bookkeeper will help to ensure greater accuracy on the (z) screen, a manager will let you use the Management screen ((u), (m)) to avoid micromanaging your workshops, a broker does trading at the trade depot, and your expedition leader defines other positions and meets with representatives from the outside world. All these positions typically need their own, more lavish than minimum quarters, offices and sometimes dining rooms to operate. To get the rooms up to the expected level of lavishness, you can make them larger, build cool things inside them like statues, or smooth/engrave the walls.
  • At the start of a fortress there is a clock ticking away. The time left on that clock is your remaining food stores. The first tasks you must accomplish are making the initial stockpiles, digging inside the nearest cliff face, cutting down some wood, getting the initial workshops built, then getting your first farm plot built. In the initial preparation screens, you should probably define two dwarves that do nothing but mine, and have them constantly mining. You'll generally always be wanting to have new tunnels, first to make room to work and live in, then later to find new types of stone and ore. One of the first things you should do once you've dug into the mountain is to dig stairs down (using the appropriate (d)esignation), then go > down one level and build stairs up from the same place, or better yet up/down stairs in preparation for going deeper still. You need to dig deep enough to get to the place where you're digging stone (light gray walls) instead of soil (brownish walls) in order to make workable stone for your masons and craftsdwarfs. Your mason is needed to build doors and several other important items, but especially doors. Your carpenter is need mostly to make beds, barrels and bins. You'll need all these things in abundance before long. Beds are for dwarves to sleep in: dig out a bunch of 2x2 rooms, build a bed in each one and build a door in the entrance. Once both are places by your dwarves, use (q) on the bed to define it as a bedroom. This is all you need to do; once it's defined, eventually a random dwarf will claim it. Giving all your dwarves bedrooms is an important step towards keeping them all satisfied enough to avoid tantrums. Your nobles will soon demand larger bedrooms, and other rooms besides; check on these demands on the (N) screen and look for red text. You define them the same way as bedrooms, by using (q) on some object essential to the room. If you want to make sure a certain dwarf gets a room you can assign it manually from the (q) screen. Build bins (brown squares with Xs on them) to help save on stockpile space and to make it easier to carry your goods around. Build barrels (brown squares with division signs on them) to contain your booze. Both these things, and many others, live in a furniture stockpile until needed, so you'll usually need a big such stockpile. Made items that don't have a stockpile to go to stay and clutter up the workshop, making it progressively less efficient. You need to get that first farm plot built as soon as possible! Dig inside next to a medium-sized lake (remember, the water of a lake is actually one z-level below the surface), tunnel into it from the side and the water will leave mud as it drains out, on which you can build underground farm plots. Different crops grow underground as aboveground; all the stuff you can take with you on your journey, I'm sorry to say, are underground crops that must be build on mud. (Aboveground crops can be built on grassy land; you get seed for those crops first by gathering plants, and later also by trading for them.) The most important crop by far is plump helmets, which dwarves can eat and also brew into booze. To grow crops, some dwarves (one or two at first, more later) should have the "Farming (planting)" labor active. Once planted, all dwarves will usually participate in harvest automatically. I usually build a craftdwarf workshop or two at the start and set it to repeat a stonecrafting task, like make rock crafts, mugs, instruments or toys, forever. Of course one of your dwarves will need the relevent labor active in order for it to get used. Get the trade depot built soon. When merchants show up and unload their wares, you'll then have lots of stuff to trade for fortress essentials you weren't able to make for yourself. Meat, cloth, leather, animals and metal bars and items are good to trade for in the early days of a fortress. (Animals come caged; to release them, build the cage somewhere, then use the (q) menu on it to unassign its contained animal. Animals can be butchered for meat.) The thing that turns away most people from the game, I think, is all the stuff you must remember and that every building and screen has its own extensive list of options. You must, must, must read through the list of commands for each one! They're printed onscreen for a reason, as there are so many they're nearly impossible to memorize. It is a challenging task, but as lots of players have discovered, ultimately rewarding.

posted by JHarris at 9:47 AM on April 16, 2010 [11 favorites]


(ARGH, for some reason Metafilter discarded the line breaks in the second half of my comment, turning it into a huge wall of text.)
posted by JHarris at 9:48 AM on April 16, 2010


Don't worry, JHarris, it seems oddly appropriate that your comment trying to make Dwarf Fortress more comprehensible turned into a nearly incomprehensible wall of text.
posted by Justinian at 11:07 AM on April 16, 2010 [5 favorites]


Or slime mold. Or prisoners!

Someone else read that book? I thought I was the only one!


I loved that trilogy. I've read it three times and figure I'm about due for a fourth.
posted by Foosnark at 11:59 AM on April 16, 2010


Ah, what happened is that I forgot to close the ul tag. Dammit. Administrator please hope me.
posted by JHarris at 1:20 PM on April 16, 2010


Dwarf Fortress seems like an excellent candidate application for Prefab.
posted by aeschenkarnos at 4:47 AM on April 17, 2010


« Older One small step   |   Polyrock. Polyrock. Polyrock. (imagine it... Newer »


This thread has been archived and is closed to new comments