Holding the Line with Scope Creep

Dave Voyles recently posted 0 to Indie in 5 Easy Steps on ArmlessOctopus, a distillation of a panel at PAX 2011.  My favorite advice bit from the five was “manage your scope.”  This is such an important step to take, though for me, not an easy one.

In the last few weeks, Escape Goat has really come together, and everyone who’s played it so far has liked it.  I’m very proud of that.  Yet a lot of play testers also have a few features they’d like to see… and really, how long would they take to add?  I’ll explain the specifics after the game’s out and I do my multi-part postmortem on the process, but for now, even the smallest extra features have got to wait until the sequel.  I’m holding the line.

I’m in a situation I reach frequently when composing music.  I’ve got a pretty good sounding song, but I think that with some more time it’ll get better.  Sometimes it does, and sometimes it gets worse.  Refining can easily become tinkering.  Then, there’s nothing to show for your lost time.  That’s kind of where I’m at with this project: I don’t want to tinker much more, because something might be spoiled.

What if I miss some great opportunity?  There’s always the sequel.

 

Staging Code Tasks on Notepad

I’ve tried dozens of organization apps and software, and Notepad is still my favorite.  Its biggest drawback used to be accessibility–having to keep the text files with you if you work on more than one computer.  DropBox fixed that.

I tend to keep a text file of tasks so I know where to pick up tomorrow.  It’s vital that one of those tasks is immediately accessible and not too abstract.

  • OK: “Fix overlapping blocks collision bug.”  
  • Better: “Reproduce overlapping blocks bug by building a test room.”

Today was one of those coding days where every fix reveals yet another fix that’s needed.  My initial task list was about 15 items but I probably checked in over 40 changes today.  It’s frustrating to have done so much more work than I thought was needed, and still not be where I thought I would be today.  But, I’m still generally on track, and things had moved forward a lot.  It could be worse, I could have attempted a major refactoring and broken things so badly that I had no choice but to revert to the last update in source control.  It’s happened, but not today.  Today was just a steady unraveling of long-dormant bugs and tiny features that insisted on their existence at the last minute.

Notepad kept me sane.  Minor bugs kept cropping up, and I would just jot them into the text file.  As I fixed them, I would cut them out and paste them into the source control check-in log.  I’m down to about 3 right now, nothing major, and if I weren’t superstitious about this sort of thing I would say I’ve totally got it handled tomorrow.

 

Steven Pressfield’s The War of Art – Applied to Indie Game Development

This morning I finished The War of Art by Steven Pressfield.  I started a couple months ago with his much shorter Do The Work, which a friend bought for me.  When I read DTW, I didn’t know at the time that this was the same author who brought us Gates of Fire, probably the most badass book I’ve ever come across, but it makes sense.  Pressfield has an approach to work that is both dutiful and selfless, with a bit of mysticism thrown in.  Just as the Spartans would have liked it.

Why would I read this?  I’m making games, not writing novels.  Well, there’s a lot of similarity.  Consider that writers and indie developers both:

  1. Work  alone
  2. Spend time placing words on a page, whether in English or C#
  3. Make their own schedule and set their own deadlines
  4. Struggle with the same fears about creating something and having it judged by the world
  5. Creativity is vital
  6. Games have stories and dialog too!

It’s too early for me to give specifics on how this book has helped me with my work, since I’ve only had one workday since finishing it.  I get the sense that the lessons in this book are more long-term in the way they adjust your outlook.  I’ll be sure to follow up this post in a couple months to see where I stand with it.  So far, I can say I highly recommend The War of Art to anyone else who works solo (especially game developers).

The central theme of the book is very close to a talk Elizabeth Gilbert gave on creativity, which I saw two years ago and found life-changing.  This is by far my favorite TED talk, so watch it next chance you get.  Both Gilbert and Pressfield propose a different way to look at the artist at work.

The conventional view is of the troubled, emo, starving genius, possibly manic depressive, withdrawn, emerging every so often to do work when inspiration strikes, but most of the time fretting about the situation.  Enough artists are famous for mental issues, suicide and depression that this has become the stereotype.

How about a different model?

What if being an artist has nothing to do with your talent, beyond your talent to get yourself to sit down and get to work every day?  What if your works of genius weren’t coming from you, but rather were the work of an immortal creature not unlike Dobby the house elf, who lives in the crawlspace of your office and only emerges every few days to bless whomever is nearby with a momentary stroke of genius?

As nuts as this sounds, it’s a VERY helpful way to approach work.  Think about it: it’s no longer on you to be brilliant day-in-day-out.  All you have to do is show up consistently.  Log hours.  The muse (or Dobby) may or may not appear for weeks on end, but as Gilbert says, at least you can say you showed up.  You did your part.  In other words, genius is a function of time spent at work.  Waiting for the muse to hit you while not working is pointless.  Just get started.

So if Dobby is on our side, using us to channel his brilliant ideas to the human world through our work, he must have a nemesis.  Indeed.  Pressfield spends more than half the book on Resistance–the force continually pulling us away from the simple state of being at work, where we are more likely to be given a stroke of genius.

How can you overcome this force?

According to Pressfield, it means becoming a Professional.  By that he means “warrior.”  Grit your teeth, do it anyway, get started now, love the challenge, do it for love, do it even when you don’t want to do it, enough excuses.  Feel the fear, every time if you need to, it’s normal, and do it anyway.  You’ve chosen the artist’s path to bring something special into the world.  Now recognize that you’re in the middle of a war, and steel yourself.

I’ve read a couple other books on creativity, and many of them talk about Meaning. (28,000 hits on Amazon by the way.)  Pressfield doesn’t use this word once, and it’s a breath of fresh air.  Meaning is a dangerous road to take.  It relies on external validation, and worse yet, it’s so vague.  It demands some impossible concoction of enjoyment of the process, brilliance and relevance, and it’s all about ego.  I much prefer the warrior-workhorse model.  Show up, spend time, do it for yourself.

Was there anything troubling about the book?  Since I’ve read so many books in this style, I’ve become a bit skeptical, because literally every one has a subtle promise of solving your every problem by taking their advice.  What matters more to me now is data–how do I know this advice goes beyond the author’s experience, and has successfully helped others?  With The War of Art, the only data is in the 280+ reviews and 4.5 star rating on Amazon.  I’d love to see a more comprehensive study done and hear more stories from artists who’ve changed their work habits based on these principles.

If you’re such a person and have read this far, please comment!  Everyone else, buy the book.

 

Squish Detection in Platformers

Top: Direct hit, kill. Bottom: Gentle nudge out of the way.

I’m amped.  I started writing a post on game production and teamwork versus working solo, but it’s just not something I can do tonight–draft saved.  Right now I just have to celebrate the squashing of an ancient, pernicious demon bug from hell in the Escape Goat code.  Could it even be called a bug?  It never even revealed itself in that mortal form.  It stayed for weeks, months even, as the Feature that Wouldn’t Be.

It was creature squish detection.

Here’s the situation in a nutshell:  If a block falls on you, or you get mashed between two moving walls, you get squished and have to restart the room.  Makes sense.  And detecting this is easy enough: if after resolving all collisions (clipping creatures to the edges of walls) a creature is still intersecting with a wall, you’ve got a squish happening.  That means one wall clipped the creature into another wall and it can’t be pushed away.

There was a problem with this.

Getting squished by a single pixel of falling block was annoying.  So was getting crushed when you were only barely inside a moving wall.  Come on, that should just nudge you out of the way… it’s barely grazing the goat’s tail!  You can’t make me restart this whole puzzle for that.

But… I also can’t take out squishing.  What if you get crushed by a block, do you just get to clip through the top of the block?  Or through the floor below?  That’s no good.  Squishing machines are a great hazard device in this game.  I’m not giving that up.  There has to be a balance… you need to be able to tolerate a few pixels of squishing and “nudge” the player out of the way in those situations.

I tried about 5 different methods of handling this.  And just a couple hours ago, after intense frustration and perseverance, I found the solution:

  1. Do all clipping of creatures to walls and world obstacles
  2. If any creatures are still intersecting with walls, start a crush timer on that creature, which lasts for 5 frames
  3. If the crush timer reaches 0, kill the creature.  (It took too many frames to resolve it to a safe position.)
  4. If the creature is not intersecting, store its position as a “safe position”
  5. If the creature is no longer intersecting, reset the crush timer, and compare its new position to the safe position that was stored before.  If the distance is greater than the squish tolerance (I set it to 5 pixels in either axis), kill the creature.

Essentially, give the game 5 frames to resolve a safe position for the creature after being crushed.  If this new position is too far from the start position, well, I can only be so forgiving.

Top: Direct hit, kill. Bottom: Gentle nudge out of the way.

When you face a feature from hell, stick with it, draw pictures, and try solving it from a variety of angles.  You’ll get it eventually and it’ll feel great.