gaming June 23, 2013 Jack No comments

On “Let’s Play”

I’m stuck in an age where I prefer my information to be conveyed in text. That’s just the way I feel. 90% of the instructional videos on the internet are twenty minutes too long and executed by kids that stumble over their words, get confused, and even waste time figuring out what I’m trying to learn. Minecraft videos are the perfect example. It’s a perfect storm of complexity and the fact that the players are pre-pubescent. Most of the time a simple blueprint or a set of screenshots would do just fine and would let you examine what you’re looking at without fiddling with a Youtube scrubber.

Recently, I started playing Crusader Kings II, which is a very engrossing but very complex game, and for the first time I found benefit in a Let’s Play. I was scouring Reddit, Google, the CK2 wiki, and there was a lot of information and I learned quite a bit, but I still wasn’t really grasping the game. Partially because it’s got a huge amount of DLC that’s vastly changed the game since it was released so there’s a lot of conflicting or half right information out there. There are a few hundred buttons in the interface, a lot of game mechanics in play, and even though there’s (now) a tutorial, it just wasn’t clicking. There are so many different scenarios and little hidden pieces of information that it was hard to just read and put it together.

That’s why watching a Let’s Play on Youtube was so enlightening. I feel like I had all of this information packed into my brain over the last two days, but hardly any information about how to really put it to use. What parts of the game were important, and what parts can be ignored for awhile, etc. Actually watching someone that had a lot more experience than I do use the information I already had was awesome.

So here’s my new position: Let’s Plays are great when

  1. The person doing them already knows (mostly) what they’re doing
  2. They don’t waste your time covering extreme basics (unless that’s what you’re looking for)
  3. When you have a lot of information that needs to be tied together into action OR
  4. When you want to know the thought process behind decisions made

In other words, deep strategy games are perfect for Let’s Plays because you can watch and listen as a more experienced player gets himself into situations you wouldn’t know how to handle. If nothing else, it saves you a lot of trial and error (or save and load).

I can’t even imagine how different my gaming life would be if I could’ve watched them when I was learning Civilization II for the first time. In fact, next time I want to fire up Civ V I’ll probably watch some deity level players Let’s Play before I even open Steam.

EDIT: Just as a shout out. I formed this opinion while watching a number of videos on Youtube, but quill18 was the one that made the new Norse raiding mechanic make sense to me. Thanks.

atheism, books June 18, 2013 Jack No comments

On “Proof of Heaven”

This hasn’t been an extant fact on my blog, but I am an atheist. My parents are (and now pretty much were) Catholic, and I went to a couple of Catholic schools as a kid so I’m extremely familiar with the machinery of Christianity. My wife (who’s a deist) was raised as a free-thinker and we’ve had some quite lively healthy debate over the years. Her mother, however, is now a born-again Pentecostal (last time I checked).

Last Christmas Day, while decorating gingerbread men, we got into a bit of a verbal disagreement about the existence of God and she didn’t really have a leg to stand on. The first, and most viscerally relatable weapon in my arsenal was the Problem of Evil which I further parlayed into the contradictory positions of free will, omniscience, and sin. I was probably in poor form for an early Christmas morning, but I’ve recited these arguments to myself often when I try to re-evaluate my positions on God.

She never really answered my questions, which were answerable (if a bit pointed and more than a little rhetorical), they just force you to redefine the concepts of evil in ways I find dubious and unverifiable or admit that either God doesn’t know everything or we are machine-like automatons with no choice but our destiny.

In the course of that conversation she mentioned a neurosurgeon with a raft of degrees that had come to believe in God – or more directly the afterlife – after having a near death experience. How this was relevant, I don’t know, but I guess it was that there was a man of science (the sort of man I consider myself to be) that had a crisis and came to believe. At the time I dismissed the claim out of hand.

In the meantime, however, she sent me his book. It’s called “Proof of Heaven” by Eben Alexander III, MD.

Praise

There are a few positive things I can say about this work. The first is that his writing style was clear and well thought out purely from an execution-of-a-story point of view. It’s apparent that he’s very smart from his training as a neurosurgeon and his obvious familiarity with medicine. I say this without having checked on his degrees or anything because on this stuff I’m willing to give him the benefit of the doubt. Why? Because if someone really has “proof of heaven” it doesn’t matter if he’s a genius or a vagrant. Proof is proof is proof.

Criticism

There is no proof.


proof /pɹuːf/ n.


2. (uncountable) The degree of evidence which convinces the mind of any truth or fact, and produces belief; a test by facts or arguments which induce, or tend to induce, certainty of the judgment; conclusive evidence; demonstration.


The key words here being “evidence” and “certainty”. This book has only anecdotal evidence and thus conveys no certainty whatsoever.

In addition, I think that the author, Eben Alexander, frequently uses the appeal to authority logical fallacy to great effect. The first ten or twenty pages of the book are just filled with irrelevant details of his education and his unique insight into the human brain. I will grant that he knows a lot more about the brain than I do and he can rattle off the various possible causes for a grand mal seizure in a white man in his 50s a lot quicker than I can, but none of this makes any difference whatsoever for some sort of proof. I kept getting the feeling while reading his opening pages that he was including so much detail (like the names of the drugs he was on, the Latin derivation of cortex, the full name and apparent age of E. coli, the shifts of the nurses and staff, even the Einstein and Kierkegaard type quotes that start a few chapters) that he was including them with the sole intent of saying “Yes, I am smart. I’m a doctor!” and then using that authority to argue his other, totally unrelated claim.

Another facet of the book that I disliked was that it was tacitly and admittedly fiction. The protagonist is in a coma for most of the book so all of the detail he’s added about his family and his appearance during that time is entirely fictionalized (or, at best, hearsay) to weave the personal experiences he had while in this coma into the dramatic story going on in the real world. It’s extremely easy to forget this fact when he’s narrating the story as if he knows exactly what happened. He’s taken quite a bit of artistic license with the story that went on outside of his head and I would be totally fine with that if this book didn’t purport to be “proof” because he’s intentionally blurring the lines between what he knows is real, what he’s heard from others, and this mystical experience that he uses as the basis of this “proof.”

The rest of the book is either rather dry biography (sure, I’ll believe it) or part of this world that he experienced while his body was essentially brain dead. This world, which he gives several rather fanciful names as he progresses through it, is intended to be the “proof” but it reads like an acid trip and falls drastically short of what anyone in the rational world would call proof.

The kicker is that you can believe that every word of this book is true and it’s still not a proof (in the deductive reasoning, mathematical sense) in any way shape or form. I believe that he had a serious illness. I believe that the story he told about his family, his childhood, his adoption, and education is true. I also believe that he made a rare full recovery. I even have no reason not to believe that he hallucinated an entire episode that convinced him that there is an afterlife. For him, that proof must be especially strong because he was supposedly there and experienced it for himself.

Looking at it from the outside, however, there’s nothing here but an anecdote with one huge, enormous, glaringly obvious flaw. Dr. Alexander doesn’t have proof that there’s an afterlife because he isn’t dead. No amount of degrees, dramatic stories, or fantastical journeys through inner space will change the fact that he was most definitely alive the entire time. People who were “dead” for minutes before being brought back weren’t really dead. Why? Because you don’t come back from death, by definition (Christian theology aside).

So, what we have here is yet another book that attempts to build a proof on the foundation of personal experience and, unsurprisingly, it fails to convince.

The Real Lesson

This book has an accidentally scary part to it, I’ll admit. It had nothing to do with the immediate content, but with the trimmings of the book.

First, the praise listed is uniformly from religious folk (who, let’s just say have a horse in this race) or from MD PhD types that are also hawking this sort of book on their own.

Second, the first section after the end of the story (and an unnecessarily long acknowledgements section) is the “reading list” which is just a long list of other semi-related works that (surprise!) include all of the authors that wrote praise for this book. There’s a smattering of real work in there about death and grief and magic mushrooms (see last point), the Dalai Lama even gets a shout out, but at least 50% of them are just more of the same pseudo-science “astral travel” and Native American wisdom.

After that, there’s a statement from an MD that examined him that boils down to “Eben Alexander’s recovery is truly remarkable” which can’t be argued but low probability events happen all the time. For every Eben Alexander there are a few hundred others that, yep, kicked the bucket as expected.

Lastly, there’s a list of theories he considered when trying to debunk his own irrational experience. This is yet another place where he tries to strengthen his fallacious argument. He drags up a lot of facts that I assume are true (because it’s irrelevant) about the effects of hallucinogens, brain chemistry, brain structure, and whether the operational parts of his brain could handle the “ultra-reality” he experienced during his coma. It’s a real shocker that he comes up with various reasons each one can’t possibly explain it. It’s funny coming from a neurosurgeon that acknowledged in the beginning of the book that we can’t explain how the brain works. It’s the height of foolishness to debug a system you don’t understand and, when faced with something you can’t explain, insert divine intervention or miraculous events. Not to mention that some of the arguments rely on “well the parts of my brain that could make this seem so real weren’t working at the time” which is something that couldn’t possibly be ascertained. He admits that he has absolutely no sense of time while in this fantasy world and, as such, how does he know that it didn’t all occur a millisecond before he “woke up” when his brain was 99% of the way back to consciousness? The chapters where he’s in this fantasy are spliced with the story in the real world such that it seems like he spent days of real time there, but that’s totally unknowable and inadmissible in refuting the theory that it was just a hallucination.

In the end, there’s only one thing that I can take from this book. It’s a lesson that I’ve learned before and I’ll probably learn again: smart people can believe some pretty stupid things without any logical underpinning.

baseball June 8, 2013 Jack No comments

On Baseball

Alternatively, this is why baseball is the greatest American sport.

1. It’s a True Team Sport

Oddly enough, baseball is one of the few games where you have to assemble a team of good players instead of being carried by one or two star players. This is a direct result of the fact that baseball is a long term endurance sport. The current regular season in the MLB is 162 games long, which is very near to a game a day for the entire six month season. There’s a rotation from game to game, and each lineup is different. An ace pitcher, for example – even one that could throw a perfect game every time – could only at best hold a .200 average (which is crap) by himself. Even a more realistic pitcher that occasionally allows runs can be betrayed by bad hitting or bad fielding. Routine plays turn into errors and wins turn into losses. The lineup is all important and it’s tough to keep a consistent set of fresh players when you hardly ever have a day you don’t play. There’s a reason that a team’s main roster has 25 men on it: you can’t count on a player playing every game or even for full games.

The endurance aspect creeps up again with the disabled list. While there aren’t a lot of collisions in baseball (though there are a few), there is a lot of repetitive damage. Imagine throwing a baseball at 90mph 100 times in a single game. Then do it every five days, thirty times over a regular season. Imagine being in an outfield making diving plays, or even just sprinting to make a catch. Then do it almost every day for three hours at a time. It’s not that each game is that taxing (although I wouldn’t want to make 100 pitches in a day) it’s that the season all together just wears your body down. And that’s not even counting the fact that each game has no clock! If a game has to go on for 33 innings it will!

The bottom line is that between exhaustion and just plain bodily wear and tear, a baseball team’s talent pool has to be deep in order to keep a consistent record.

Compare this to football where you have a few really key players that carry the team to victory. The hits are harder, but the games are shorter and the regular season is 1/10th as long. Each player also has about a week to recover between games. There are a lot of offensive and defensive players that are completely unknown because in the end their job is to hold the line while these key figures (think Quarterback, Wide Receiver, Running Back) make the actual plays. Not that the rest of the line doesn’t do their jobs, but their performance is aggregate. If the QB gets sacked often, it’s the offense’s fault, but not a single player. Likewise if the opponents score often, it’s the defense’s fault, but no one individual is at fault. There are no errors and no accountability except for that well known core of star players. Don’t believe me? Ask any hardcore football fan to list their team’s entire active roster – they can’t. How do I know? Because a football team active roster has 80-90 players on it, most of which are basically interchangeable. I bet the average fan might not even be able to get past three or four of them. It’s funny, football games (especially in the playoffs) are characterized as these great battles between titan quarterbacks and the two “titans” aren’t even on the field at the same time.

Basketball should get an honorable mention here, however, as the NBA players play an impressive 80 games in the regular season and it’s actually possible to distinguish each individual player’s actions and errors. You still have powerful players that can carry teams, but at least the other members can’t be ignored as integral parts of the whole.

2. Rivalry

Rivalry is part of all team sports, but none of them do it better than baseball. Partially this is just because baseball has the longest history to draw upon. Teams like my hometown Cardinals and the Chicago Cubs have been mortal enemies since the dawn of time (or so I heard growing up in St. Louis). But aside from just history, baseball offers quite a lot of opportunity to flesh out the rivalries. In the 162 game regular season, your team will face any one of its (likely multiple) division rivals in five or even six series of 2-4 games apiece. That’s a lot of games and is especially important because each series in and of itself has its own quirks and flavor instead of being a one-off match.

To give an example. This week, facing the Diamondbacks, in a 14 inning drag out fight, the D-bagsbacks beaned one of our best hitters three times in one game. Now, it didn’t seem to be intentional and fortunately our man shrugged it off and kept playing but the next game retaliation was called for. Or right before that, this weird rain shifted series against the Giants with an unexpected double header. Or this current series with the Reds where they boo our catcher, Yadier Molina (best in the game), for a “brawl” he started with their second base Brandon Phillips three years ago.

Really, there isn’t an opposing team in the division, or even the league, that your team doesn’t have some layered past with and it adds an interesting context to each match up.

Again, compare this to football. Your team will play every other team exactly once, except for one that you’ll play twice in the entire regular season. Sure, there’s bad blood between teams but there’s hardly any new information in each season and these rivalries are generally spawned by playoff snubs or flukes rather than any real long running enmity.

Similarly, in basketball you’ll face a division rival four times for single games across the entire season, in soccer (MLS) it’s three single games in the 35 game season.

Quite simply, none of them can hold up a legitimate rivalry the same way baseball can – to the point where the context of the game is almost as important as the content.

3. Stats

A lot of folks complain that watching baseball is like getting stats thrown at you for a few hours. It’s true, the commentators are constantly talking about it and displaying tables of stats. Truly absurd amounts of detail are recorded about each game and numbers like “Batting average on a day with less than an inch of rainfall, two outs, against a lefty” emerge. Okay, maybe it’s not that bad, but stats exist in all games because they’re the way you judge past, current, and predict future performance. The only difference is that baseball attempts to predict what a particular match up will yield instead of just using stats as a performance metric.

In football, you can judge your star players by things like touchdowns, interceptions, completions, and yards, but these only measure personal performance. These type of stats can tell if your team or player is improving, slipping or staying consistent but they can’t predict performance versus another team or player. Knowing your player ran for 1000 yards and got 30 touchdowns last season only tells you that he’s a strong player, it doesn’t give you any hints about how he, or your team, will do against your opponent other than a vague sense that your players are doing better than their players. Admittedly, keeping detailed records to allow competitive stats doesn’t make sense for a game where a lot of the grunt work is done by a wall of basically anonymous men rather than an individual with definable one on one match ups.

Basketball (points, rebounds, assists, steals, blocks) falls similarly into the personal stats, and soccer barely tracks player stats at all (goals, appearances).

Baseball, on the other hand, attempts to go much farther than that and give stats to predict performance specifically rather than just tally each player’s records. Because just two men, the pitcher and the batter, are the focus of every play you can collect and analyze a much more relevant data set in determining how one will perform against the other. In turn that means that your predictions can be more accurate and your expectations for each at bat are grounded in reality.

So? Who cares? Well having a realistic prediction for a player means that you know when they’re having a great day or a bad night. It means that you can find hope in a tough situation or find amazement when a player pulls off an unlikely feat. Miguel Cabrera’s Triple Crown doesn’t mean anything unless you realize how ridiculously unlikely it is. Seeing your players start a streak, or end a slump, or get a homer in a pitcher’s park, or strike out the best hitter in the league all lose their luster when you don’t acknowledge their probability.

Baseball, if you watch it mechanically, only occasionally replicates the visceral punch or athletic spectacle of the competing sports. But mere observation doesn’t do the game of baseball justice. Baseball rewards understanding instead of observation. Context and probability is an integral part of enjoying the game. This is why baseball may not be the most accessible sport but also why once you wrap your head around the stats you start hanging on every at bat.

All in all, baseball is a sport with a subtle appeal spread over an epic scale. There is no game that offers more to those willing to appreciate its complexity. There is no game more steeped in history or the American experience. There is no game greater than baseball.

books April 17, 2013 Jack No comments

On e-books

I’ll admit, at least when it comes to books, I’m an extreme Luddite. There’s just something that I find comforting about the feel of a book in my hands, the sweet smell emanating from the aging pages of a paperback, or the excitement of getting a crisp new book.

For the past five or six years, I’ve kept an eye on the ebook industry but I failed to find a compelling reason to switch. Even now, the domain of the ebook reader is a weird back alley of tech. The technology looks and feels antiquated. E-ink readers are nice, power efficient, easily read in broad daylight, but for $140 (current Kindle Paperwhite) you get a device whose major selling point is the fact that it has a backlight. Others, like the Nook Glowlight advertise things like “fast page turn” for $120. All of them uniformly espouse power savings with a 6″ screen that reminded me of an old Palm Pilot and a refresh rate reminiscent of scraping a clay tablet.

Also, ebooks are bullshit from a consumer freedom point of view. Look, I know that publishers are out to make money and I don’t expect them to receive, filter, edit, and publish books for nothing but at the same time I see my public library with a wait list and a two week time limit on what amounts to a floppy disk (yeah, those 3.5 inch suckers in the days of yore) worth of data. Maybe a couple of floppies if there are lots of pretty pictures or the author has a problem with going on long irrelevant tangents (Stephenson, damn you). It doesn’t make sense to me, the consumer, that there would be people waiting in line for copies of something that can be copied instantly, perfectly and at no cost.

There has to be a better way that combines the strength of the library (free public service with loads of media) with the strengths of the ebook (ease of duplication and transmission) that still gets the publishers a fair share. Publishers have only traditionally allowed libraries to operate because they posed no threat to sales. If a library buys three copies of a hit new book, then only three of its members can read that book at a time and everyone else either has to be patient or buy a copy and we all know how great the human race is at being patient. Now that actual physical scarcity no longer exists in the world of media, I’m not sure if there is a solution that doesn’t screw at least one of the interested parties (publisher, library, member). Either the publisher takes a loss because the library eliminates scarcity, the library takes the hit because publishers switch to some model where they feel like they get compensated for lost sales, or – as it is now – the member gets screwed because an archaic system is being used to create artificial scarcity.

The library conundrum aside, the fact is that once you “own” an ebook you have fewer rights than owning a physical book. You can’t lend books, for example, or if you can you can only lend them for short periods of time to other registered users. You can’t resell ebooks, or exchange them. You can’t do anything with them but read them (which is admittedly the primary purpose of a book, but nonetheless).

That said, I recently became a somewhat reluctant convert to the ebook.

There are a few salient points that have come into focus over the past year or so.

First, tablets make great ereaders. They don’t go for 28 hours of reading on a single charge, but they also have sharp color screens and are capable of doing a thousand other things. For $60 more than the aforementioned ad-free Kindle Paperwhite you can get a Nexus 7 that will blow it away on all fronts other than power usage and the mythical “I’m using my electronic device on the beach because I’m not afraid of sand or water” usecase. Oh yeah, and the screen is lit and the pages turn fast too. This observation hasn’t been lost on Amazon or Barnes and Noble either since they followed the release of the iPad with the Kindle Fire and Nook HD which are both full fledged tablets rather than ereaders.

Second, I started reading Terry Pratchett’s Discworld series and immediately fell in love. The series is 40 books long. At a brick and mortar book store, new paperbacks of Discworld are $10 apiece. That’s roughly on par with Amazon (+ shipping). Doing the easy math, that’s $400 to assemble a collection of all the Discworld books, assuming that they’re all roughly the same price. Austin is a great town for used books too, but none of the various used book stores have a great number of Discworld books and none of them had any of the first four. In the end, to do used I’d have to go online where used copies range from $3 to $5 a pop so I’d have to spend let’s say $160 (+ shipping) and wait weeks to get the books from a variety of sellers that probably have no issues calling a coffee stained paperback “like new”. Alternatively, I could spend $5 a pop, get untarnished ebooks instantly and spend about half as much. For the $400 I’d spend on a complete collection I could get every ebook and buy a tablet to read them on. Economically both in time and money there’s no contest.

What about the library I was ranting about earlier? Well, the Austin Public Library only had the second Discworld novel (the one I was looking for at the time I made this decision) in ebook form. Some of the other Discworld novels are around, mostly the later ones, but not consistently and it seems like they’re almost all out of copies. For someone that can finish the comparatively short Discworld novels in two or three delicious sittings, the weeks of waiting in between books just isn’t going to work. There’s that artificial scarcity I mentioned working for the publisher.

Lastly, despite the fact that I value my rights as a consumer, it’s impossible to argue that the ebooks don’t have a lot of advantages. I bought Mort, the fourth Discworld novel, after I finished the third, Equal Rites. It was simple, instantaneous, and the ebook looks great. I can read the ebook anywhere (laptop, phone, tablet, random computers), there’s an in-reader dictionary lookup, I can change the font sizes and spacing. In short, there’s a lot more freedom in the acquisition of the books and the act of reading them which, considering I think I’ve lent out two or three books to friends in my entire life and virtually never resell recreational books, vastly outweighs the loss of rights to lend or resell them.

Now… if only I could get my tablet to smell like old paper…

personal February 11, 2013 Jack No comments

Creativity In, Creativity Out

I have never wanted to write a novel as bad as when I was reading a good one. I have never wanted to code as much as when I’ve just discovered a brilliant piece of engineering. I have never wanted to throw down on canvas or clay than when I’ve watched an artist in fugue make masterpieces out of brute ingredients. Architecture, design, poetry, it’s all the same. I cannot help but relay admiration for craftsmanship into abstract effort.

This is the core difference between mastery and competence. A master can use art to inspire.

android January 30, 2013 Jack No comments

Android App: Memoires

I’ve journaled off an on for my entire life. It seems natural to me, but I never seem to get around to it as often as I should. I almost always think about journaling when there’s some great weight on my mind (like moving, switching jobs, Scarlett growing up, parents growing old – you know, the classics) and these topics always require a lot of context, a lot of back and forth and I can never seem to hand write more than two pages before my hand begins to cramp. I guess it’s been too long since I’ve had to do written essays in school =).

So, in a flash of inspiration, I decided that I should look into audio journals. It’s so much easier to capture the spirit of what you’re conveying in words. You get all sorts of extra clues about the state of mind of the speaker. Most importantly, it’s easier to talk for half an hour and hash out your thoughts than it is to write pages and pages.

I wish I could say that I did an exhaustive audit of Android audio recording apps and made a conscious decision but this flash of inspiration I had came at 1:30 in the morning on a night when I had a lot on my mind so I found a well-reviewed app and – so far – it’s been awesome.

Memoires Logo

Memoires

The app in question is “Memoires: The Diary” written by Victor Nakonechny. The title seems a little pompous, is misspelled, and more than a little redundant, but it’s a really nice all purpose journal app. It’s free and it’s on the market.

This is one solid app. You can keep audio snippets, pictures, and text in reverse chronological order. It amends each entry with the GPS location you made it in (which would be especially cool if you were traveling), the weather at the time, any tags you want, and of course the time and date. I can’t personally imagine writing a standard text journal with it, but that’s more because a phone’s keyboard is tedious for long entries – a tablet might make that a lot more feasible.

The best part is the app will occasionally prompt you to backup which is extremely important if you don’t want your journal to be reset by something stupid like phone failure, wipe, or thievery. I only tested the “backup to SD card” option because the other options seem less appropriate for a private, mostly audio journal but there are a lot of other options, like exporting to HTML, RTF, and various Google services. I decided to examine the .zip backup it created to make sure that it wasn’t in some stupid format that might disappear if Memoires ever becomes unmaintained or broken, etc. and I found that it was pretty straightforward: a SQLite 3 database, and a directory including the raw recordings I had made. In short, nothing that couldn’t be reconstructed if need be.

In addition to the backup settings, there are a number of other basic settings like a password – which immediately made me think of those flimsy diary locks I used to see as a kid. There are also themes and other appearance things (font size, etc.) that are just the icing on the cake.

All in all, I’ve been happy with it the few times I’ve had a reason to record in the last couple of weeks and I believe it deserves the high rating it gets on Google Play. If audio journaling is something that interests you, I’d highly recommend it.

gaming, programming, python January 23, 2013 Jack No comments

Fun with Roguelike Generators

I may or may not be tooling around with a roguelike. Not because I think the genre is dead (it most certainly isn’t) but because some programming tasks are made fun just by their subject matter. I haven’t quite gotten to the point where I’m using “mana” and “damage” and etc. as variable names, but that’s not the first fun part. The first fun part is generating a rogue dungeon level.

Now, anybody that’s ever even thought about developing a roguelike should know about ASCII Dreams written by the developer of Unangband, Andrew Doull. I especially found his series on Unangband Dungeon Generation to provide a lot of insight into generating dungeons that are interesting a long with a lot of interesting history and philosophizing.

In the end, though, I wanted to try my own, naive, hand at the dungeon generation problem. I did take a few major things away from Andrew’s discussion however. Mostly that there are a lot of nice rooms that can be generating procedurally with simple tricks and, failing that, having a system for “vaults” (which are various, hand-designed rooms with interesting features) can be interspersed for extra flavor. Also, various features added to rooms, like water, lava, ice, minerals, rubble, etc. compel players to explore.

Most of this I’ll get to later, if ever, with my toy generator. The first problem is generating the topology of the dungeon itself.

My Approach

Now, one thing that I’ve found annoying about classic generation algorithms is that they tend to have a lot of really long tunnels. This is because rooms are generated at random across the static map and then, if they haven’t merged together, are connected by tunnels. This has never felt right to me. I understand that – in universe – a dungeon might not have the most sensible design, but having long winding tunnels are boring. Doing connectivity checks on the rooms is boring as well. While we’re at it, I don’t want to have a predefined playing field (array) to work with. I’ll put a limit on the area of the dungeon level, but if it’s a whole bunch of tiny rooms in a very long line, so be it. Unfortunately, I also want the level to be consistent (i.e. no physics violating overlapping inconsistent geometry) so it seems inevitable that the level will eventually be represented on a global grid, but at least that grid will be bounded and reasonably shaped to the level. If necessary, after the level is fully generated the excess grid could be eliminated just by noting where one room enters into another.

So, what I wanted to do was generate a dungeon level that is both tunnel free (for the most part), consistent and connected a priori. Interesting stuff like themed-features, rivers, lava flows, etc. could then be painted over the level geometry in broad strokes.

Problems vs. Classical

There are some troubles with this approach. The first of which is that it makes multiple level consistency really hard with multiple staircases. For a classical generator, you can randomly place down staircases on one level, and then replicate that pattern with up staircases on the next level and ensure that you have rooms to encompass them. This works when you’re going to manually connect all the rooms in the end, but it doesn’t work so well when you’re building a pre-connected level. As such, either there has to be only a single up and down staircase per level (not a bad idea, really) or you have to throw that level of consistency out the window and just match arbitrary up and down staircases. This means that you could have two down staircases right next to each other that would teleport you to different ends of the next level, but in a gametype that traditionally promotes save scumming (i.e. if you go down the same staircase twice, the level is different each time you descend) I think that’s acceptable.

Another problem is that, without tunnels, the dungeons are more likely to be dense. That’s a good thing in the fact that it gives a lot more interesting rooms close by and the player spends a lot of time in an environment. It’s also a dangerous thing because it means there’s a lot fewer twisty places to get out of sight of pursuing monsters. I think that’s acceptable as well, although it’ll be something to account for if I ever get around to generating monsters.

Implementation

I decided to bang out a proof of concept in an evening. Breaking down the logic, the easiest way to generate in this fashion is to generate one room, which will be the root. Then, generate another room. Connect these two rooms with a doorway, then that whole complex becomes the root “room”. Rinse and repeat until the dungeon is of a certain size.

In order to encompass this, I came up with a class for Space. A Space is any arbitrary portion of the dungeon level. It includes a 2-dimensional array geometry that describes what’s in that space. One Space’s geometry can be added to another Space’s geometry with a set overlapping point. A Room is just a space with a name and whose geometry is likely a single room, but is arbitrary. Then, special types of rooms, like one mentioned in Unangband as the core type, two overlapping rectangles (which results in single rooms, crosses, T-shapes, L-shapes, etc.) are just Rooms with special geometry generation.

Expand Code

I got a little lazy with the execution of __main__. There’s a cleaner way to deal with matching up the direction end-points (hell, just take a random one and rotate the entire room to match, really) but for an evening’s playing around I think the results are actually pretty nice.

Expand Example

Not many long tunnels, and a large number of rooms (which are indicated by different letters. Doorways are +s. There are still, of course, some places the geometry doesn’t make sense. Usually when two joined rooms have a doorway and also have adjacent open blocks (like P and H in the above). However, all in all, not bad for an evening’s screwing around.

gaming December 11, 2012 Jack No comments

On the Steam Box

The Steam Box has been making the news lately, most recently with a confirmation from the venerable Gabe that it’s a thing that may exist in our plane of reality. There’s also been a lot of talk lately about the Steam Linux beta (that I got in to, hooray!) and the release of Steam’s Big Picture which is a console like controller interface intended for big screens (i.e. TVs).

Because of the timing, a lot of these Steam Box announcements, and a lot of the buzz around it has been that this box will run Linux. As such, in the gaming community there’s a lot of “whoa, Linux… what does that mean for us?” and in the Linux community there’s a lot of “finally Linux games!” I love Steam, I own a handful of titles in it, and I’m extremely pleased that they’ve put out a native Linux client (even in beta form). However, I am totally unconvinced that this is going to be a Linux based Steam machine, despite the timing. Here’s my logic.

Why Not Linux?

I think that it’s likely that a Valve console would take advantage of the huge Steam library. They’ve put almost a decade of effort into turning Steam into a slick, painless, even fun experience and they’ve sold millions of games. Steam is now a big release platform for a lot of AAA publishers (Bethesda, id, Eidos, Firaxis, Gearbox, etc.) as well as a load of indie publishers that wouldn’t have found nearly the following if it wasn’t as painless to find out about them and pay them.

It seems to me that Valve would be making a huge mistake if they’re not parlaying that massive, successful library directly into their prospective console. Bringing a handful of AAA launch titles into your living room on day one makes the Steam Box just another console that differentiates itself with maybe a handful of Valve exclusives (Half-life 3, anybody?). Bringing 2000 mature, well-loved and already purchased games into your living room with a cheap box and promising all the future PC releases would be killer. In addition, a Steam Box that was just a Windows machine with a slick interface would suddenly become the defacto PC spec – solving an issue that game devs have struggled with since the very beginning of PC gaming, namely how to deal with the thousands of different hardware and resource configurations. Finally, it would have the added benefit that literally any game that runs on Windows would effectively work out of the box (perhaps with a little tweaking for the spec, or any novel input devices, but without the pain of a full port).

There is a whole lot of greatness in bringing a cheap, well configured and standardized PC into the living room with a giant library of already working and popular games.

Unfortunately, with a Linux based OS on it, this is impossible. Valve titles would be ported, of course (and in fact that seems like it will happen regardless thanks to the Steam Linux beta) and a fair number of indie games already have ports, but what about the library titles that would strengthen a console release? How many developers can Valve convince into doing a free port of an older game? I believe the answer is very few because for most of these old games there’s no profit in it. Technology like Wine could be used, but if your focus is on solid gaming experience that’s a whole new set of problems. As such, using a Linux based OS would almost completely obviate the advantage of the Steam library.

Why I Could Be (And Hope I Am) Wrong

First of all, perhaps I’m overstating the likelihood of the Steam library coming to the living room. A lot of the older, unportable games would not be controller friendly and if they’re aiming for a more traditional controller oriented approach (instead of controller, mouse, and keyboard) they’d be worthless and hard to play even if they ran perfectly. Not to mention the fact that, by definition, the entire existing library already runs elsewhere which doesn’t really give the Steam Box any draw over a gaming PC except perhaps to those without the cash for an expensive pre-built or the know-how to build their own.

In essence, maybe losing compatibility wouldn’t be the worst thing in the world and if that’s the case Linux starts making a whole lot more sense. You get a very mature stack from kernel through display and because you’re targeting a single hardware configuration you can create a stable, well-tested release on top of open source components fairly easily. Compared to the amount of time it would take to custom develop the entire stack, the bugfixing would take a trivial amount of time and effort.

Second, Linux is free as in freedom. What other console developer would be able to glean fixes and features from unpaid volunteers?

Third, Linux is free as in beer. A Steam library compatible approach would have to come packaged with a Windows license which easily adds $100 to the unsubsidized price tag of the device. Ideally, if they chose to go this route, they could get a deal from Microsoft. The Dreamcast, for example, ran a version of WinCE developed by Microsoft that was seamless. That was before the Xbox hit the scene however and I highly doubt Microsoft would be so amenable these days. On the other hand, if the alternative is to have a Linux box running AAA games, they might be better served by giving Valve a deal to maintain their edge in the desktop space. Either way, though the box becomes more expensive and they lose the advantage of the open source stack.

The final, and best fact for the possibility of Linux on the console is that, if they chose to ignore compatibility, and went the more traditional console route with a release in 2014 / 2015, they’d have plenty of time to rally support for Linux titles, get the already existing Linux ports lined up and polished, and – in the end – come to the table with a more extensive library than any of the competitors.

tl;dr

Base PROS CONS
Windows
  • Massive Steam library already polished and working
  • Easy to productize fast
  • Already mature
  • .

  • Take a price hit on licensing / packaging Windows
  • Less fine grain control of software stack
Linux
  • Free (as in beer) – lower end price
  • Open source – get fixes from volunteers
  • Already mature
  • Not many existing ports in the catalog
  • Brand new platform without much industry expertise

I’m still not convinced that this isn’t going to end up being Valve’s effort to further monetize their work on the existing Steam library, but if they are willing to start a serious console from scratch then Linux is cleary the way to go. None of the information we already know about the device seems to indicate which approach Valve is favoring and as such I think it’s premature to make assumptions.

gaming November 25, 2012 Jack No comments

On Intermediate Dwarf Fortress

I’ve been playing Dwarf Fortress a lot these days, after a hiatus and I finally managed to get my first Barony (i.e. a stable fortress that’s got enough imports, exports, and population to get a noble – the first step to a monarchy). This fortress is about five years old, which is a feat in and of itself, but it’s survived four good sieges, a minotaur attack and initially I thought it was cursed and doomed to be a failure (I had a failed strange mood dwarf turn out to be a vampire that went berserk and lost 5 dwarves and damn near tantrum spiralling the remaining 10 and then had some migrants show up pissed off and some dwarven babies die mysteriously and a vampire fishery worker that got elected mayor… I could go on).

I thought I’d take advantage of this milestone to write a few things that I’ve realized in my last year or two of Dwarf Fortress that may not be obvious to even players that have been at it for while and had their share of FUN. As such I won’t be covering basics like food production or embark, but leaning more toward intermediate strategy and surprises.

The first tidbit I have is that Dwarf Fortress is all about supply. Half of your game is spent supplying masons with stone, smelters with ore, forges with bars, food, fuel, water, furniture. You have to look at optimizing the speed at which your supply chains work in order to avoid getting bogged down.

This starts with specialization. First, of the stockpile. General stockpiles have their uses (like keeping all of your workshops uncluttered), but general stone stockpiles will get choked quickly. Even general metal ore stockpiles will get bogged down in tetrahedrite and galena. You need to specialize them even more. For example, getting steel production started. You’re going to need to smelt quite a bit, first iron, then pig iron, then steel. The stockpile around your smelters then should allow just your most common iron ore (i.e. magnetite), and bars of pig iron and iron. Nothing else. If you are going to switch from steel to copper (say to bash out a bunch of copper bolts or bins) then either start a new smelter/stockpile, or change the stockpile settings and mark everything currently in it for dumping.

Why does this make such a difference? Because – especially with the 0.34 hauling changes – you want your haulers to do the hauling and your artisans to do the crafting. If the stockpiles around your workshops are inefficiently loaded, you’ve got your legendary armorer walking up ten flights of stairs and hauling materials back to his shop to get his task done when any idle Urist getting drunk in the hall can do it. Higher skilled workers craft way faster than novices, but if they’re wasting their time hauling it doesn’t matter at all.

Which brings me to the other specialization: of workers. The higher skill a worker the better their output and the faster they produce it. A legendary artisan, mason, smith, carpenter can blink through a full order of items in no time and they’ll be great quality. Once you’ve reached that level, you’re pretty much no longer bound by how fast you can produce the items, but how fast you can supply the craftsman with materials. By ensuring that you’re always focusing on leveling a single dwarf, you’ll reach that point faster than if you throw 10 novice dwarves at it. You take a hit initially (if you’re unlucky and don’t get a decent migrant for the job) but after that single dwarf you drafted gains a few levels, he’ll be moving much faster than the handful of dwarves with less experience would be.

Unfortunately, the basic UI makes this a huge pain in the ass. There’s no good way to get a decent overview of the skills of your fortress and as such it’s too easy to have high level crafters languishing as novices in other fields. As such, I recommend Dwarf Therapist for anyone that wants to have any level of control over their dwarves (and yes, it works on Linux). With Dwarf Therapist when I get a migrant wave, I group by squad (so I can use the “no squad” group) and then sort by skill in each labor ensuring that I have the highest dwarf in each skill assigned and only one or two related skills enabled at a time. For example, I usually only have one or two masons and now, five years in, both of them are “accomplished” (level 10) and they can build walls, bridges, coffins, etc. as fast as I can get them stone. My single legendary + 3 carpenter can make a new brace of 30 beds in no time. My single weaponsmith is also “accomplished” and I started him from nothing – he’s just made literally every weapon and bolt ever produced at the fortress (arming military, hunters, weapon traps, some trade orders). In short throwing dwarves at the problem is almost never the answer.

That said, some labors – like stone smoothing or woodcutting – respond well to having dwarves thrown at them because they are no supply (or one-time supply) and have no workshop. This is why I have 4 wood cutters and 8 detailers (5 of which are legendary).

With this knowledge in hand, I’ve gone from having a massive list of managed jobs that seemed to take forever, to having short bursts of jobs that disappear quickly and it’s made all of the difference not only to my fortress but to my frustration level. I lost many a fortress to not being able to get weapons or ammo out fast enough, or produce coffins, beds, etc.

The next bit of knowledge is that the manager isn’t perfect. Playing DF would really suck without the ability to manage jobs on a higher level than the workshop and the manager does a good job of providing that interface. I almost always have a standing meal and brew order and it’s great for handling bedrooms (queuing beds, rock cabinets, rock doors) and smelting wouldn’t be nearly as painless without it.

However, the longer than chain of actions, the worse the manager performs. I used to draft a half-squad, then queue up a huge amount of jobs for iron then steel, then crafting weapons, armor, and leather clothing. The problem is that the forge jobs get queued at the same time as smelter jobs so that even though you list the squad’s weapons as top priority, those jobs are getting cancelled constantly until you’ve got the supplies to complete them. The result is the first random job that’s queued and has materials gets done so that even though you clearly gave the weapons top billing, you could get a squad that has two weapons, four breastplates, one gauntlet and a mail shirt when you could’ve had them all at least armed and training with the same amount of metal and time.

There are two ways to deal with this. The first is that you queue up chunks of tasks. For example, queueing the fuel creation jobs and waiting, then the smelting jobs, and waiting, then the actual jobs you want done. This works, and because it takes advantage of the manager’s ability to track the items and notify you on completion, it’s the best for large tasks (like outfitting a squad).

The second way is to take manual control of part of the process. The manager blindly queues jobs up in a sort of round-robin manner between workshops, but it will never cancel jobs unless the overall task has been cancelled. That means, if you need something made quickly it’s often better to just go to the workshop, cancel the inactive manager tasks, and insert your own. The manager won’t override you, you don’t have to wait for them to validate the job, and you don’t have to wait for the already queued jobs at the workshop to be completed. This is best for on the fly jobs, like creating more bolts in the middle of a siege, or anything else you want to rush to the front of the line.

Another tidbit is that the military is never enough. Military dwarves are great because they can become mobile killing machines capable of putting down sieges like no other. That takes a long time though, and a lot of hard experience. Even getting decent marksdwarves takes quite awhile even though you can get pretty experienced hunters. In the meantime, it’s perfectly possible to bottle up your fortress – but being forbidden from the surface means your pastures are destroyed, you have no access to huge amounts of trees, or fish (unless you had enough time to get them underground), or hunted meat. Traders will get slaughtered, diplomats leave unhappy. No, you need to be able to capture or kill an onslaught outright.

Personally, I like a two story entry way, with a trap hallway and entrance on the first level, and open space on the second level with fortifications bordering one side. The entrances and fortifications are all behind bridges that can be raised and the whole entry way can then be flooded. This way I can bite off a certain number of invaders by toggling the entrance bridges, deal with them (cage and pit, eviscerate, headshot from above or – worst case – seal off and drown). After they’re dealt with, pit the captured invaders, reset the cage traps, and take another bite.

This automated system works pretty but it’s very rigid as well. A military is still necessary for handling the unexpected forgotten beast that flies up by accident into your lower levels and suddenly appears in your dining room breathing fire. Or for clearing out goblin stragglers, thieves, snatchers etc. In addition to berserk dwarves of which there will be many.

Another brief tidbit is read the magmawiki page on Armor. For a long time I thought that military dwarves only needed one piece of chest, leg, foot, arm, head armor but in the end they need way more than that to be decked out. The difference is staggering.

Last military one is be aware that you can have standing active and inactive orders. I was ignorant of the fact that you can actually have “inactive” squads training and guarding and “active” squads be in position for a siege. This makes calling everyone to battle stations as easy as setting everyone to active on the military alert screen. You switch between active and inactive orders with /. Before, I had my training and guarding on the “active” schedule, and then when a siege came I’d manually position my squads but that’s not nearly as useful because you can’t easily burrow them and you can’t easily control their numbers.

Last bit of knowledge: quality easily trumps quantity. Setting up a great hall with tables, chairs, food, and booze is a necessity that all DFers are familiar with. Maybe you’ve even seen dwarves griping about the lack of chairs if you haven’t gotten to it yet. If you have to choose between 30 rock tables and thrones versus a couple of nice metal (gold, silver, platinum – even lead) go for the nicest ones you can provide. The lack of chairs thought will be easily outweighed by just being in the presence of these nice objects. My current fortress (whose inhabitants are mostly ecstatic) had literally four gold tables and chairs in the hall with 150 dwarves for awhile and not once did I catch a sad dwarf complaining about lack of chairs, but a lot of my others always had “admired a fine seat” in their thoughts.

The same thing is true with other furniture, meals, booze, and virtually all trade goods. Try to put out the best product rather than the most product. This dovetails with the worker specialization I mention above.

Anyway, these are my notes after receiving my first Barony. Hope they help you with your FUN.

politics November 7, 2012 Jack No comments

On Election 2012

I, like many of my colleagues, took a breath of relief last night when Obama won his second term. In addition, a lot of the other interesting races went Democrat as well, Elizabeth Warren most notably, but also Donnelly and McCaskill (seems like the Republicans got bit pretty hard over their rape insanity). The only thing that would’ve made me happier (aside from the entirely unlikely possibility of the Democrats taking the House) is if Jim Graves put Bachmann out to pasture once and for all.

Not all of my colleagues are relieved today, however. Since I started coming in to the office more (new team) in August, and as the pressures of the race started to make it daily conversation, I heard a lot of crazy things coming from engineers that I would otherwise respect. I can’t be sure, but I don’t think that they make 250k a year either. I guess Texas is Texas even in Austin.

We had a lot of nice propositions on the ballot for Austin too and most of them passed which hopefully translates into a lot of new funding for great projects like libraries, museums and – most controversially if you judge by yard signs – a new medical school for UT.

However, returning to the national level, the picture is almost resoundingly positive for we progressives.

The Supreme Court

At least one, if not more of the justices will be replaced in the next 4 years due to death or retirement. Ginsburg is likely who would’ve been replaced by a conservative judge in a Romney universe. Instead a younger liberal judge will be put in place. Other’s like Kennedy or Scalia would be wins for the Democrats, and for sanity, as things like Citizens United, Roe v. Wade, and hopefully new reforms are challenged in our highest court.

The life term limit for the judges makes their influence long reaching and for Obama to get another one or two appointments to the bench would go a long way to avoiding future conflict for major progressive reforms (if we get that far). For the record I don’t advocate violating the Constitution for these reforms, but I do believe that the Constitution was written 200 years ago and must be interpreted to be relevant today.

The Punishment of Liars

The GOP is full of lies and misinformation. There’s no way that you can deny that they’ve been involved in some of the most vapid and factless campaigns in history. From Romney’s 2010 Lie of the Year coming up in a debate two years after it had been thoroughly debunked, to the fact that the Romney campaign “won’t be dictated to by fact checkers” to the bold-faced, consistent and totally idiotic lies from day one of the Obama presidency (i.e. Obama is a muslim/socialist/fascist/anti-christ/gay/communist/Kenyan).

On top of it, Mitt Romney’s campaign promises were many and details were few. While I can’t say he didn’t have a brilliant set of tax deduction eliminations and plugged loopholes to offset his tax cut agenda, I can say that if he did he’s an idiot for not being specific and that lack of details likely means he was bullshitting us all in an attempt to get elected on a mound of empty promises.

If the GOP had been rewarded this cycle with the Presidency or a new majority in the Senate, it would cause them to view lying and empty promises as a valid tactic. Thankfully, that didn’t happen, and in fact the Democrats made gains at every level nationally. I’d be surprised if the GOP does some soul searching and realizes that they need to come up with concrete solutions instead of promises next time around, and I fully expect the next round of utter bullshit is already being cooked up, but if we can establish a pattern over a few more cycles of “crazy and/or liars = unelectable” maybe the Democrats can take the House in 2014 and the Presidency again in 2016 and then after so many cycles of failure, they’ll get the point. Maybe they’ll realize that pandering to the extreme right for the primary and then tacking hard back to center for the general election is a losing strategy. Then perhaps we’ll get a real alternative party or, even better, a party that is willing to cross the aisle and compromise when the American people universally realize that we need progression instead of regression.