Categories
Game Development Personal Development

The Internal Struggle on Doing Game Development Right

There are a lot of conflicting thoughts in my head about how I want to approach my efforts at creating games. Some of these conflicts are from seemingly contradictory pieces of advice I’ve received over the years, and some are just related to fear, uncertainty, and doubt due to inexperience.

On the one hand, I want to be prolific.

I want to quickly get a minimum viable product out there in the hands of customers, get their feedback, and similarly very quickly make an informed decision to either tweak the existing game or abandon it for a completely different project. If I can do this quickly enough, I have more chances to earn enough money to make these efforts sustainable.

On the other hand, I don’t want to put out junk. I don’t want to release half-finished ideas, non-workable games, or projects that aren’t anywhere near ready. I want the projects to have a chance, and in order to be proud of what I put out, I need to finish my games.

But on the third hand, I don’t want to work on my project forever, constantly tweaking, adding, and removing inconsequential features. You might call it “feature creep,” but I don’t think that name really describes the issue I’m worried about. It’s more like being so afraid of pulling the trigger that you distract yourself into thinking there’s more development work to do to avoid thinking about the hard work of actually releasing the game to the public.

There’s always unimplemented features and more balancing work that could be done in a game, right? As a developer, I KNOW how to do that kind of stuff. It’s easy to stay in the comfort zone of being the technician.

And when you work by yourself, it’s easy to forget to take off your Developer’s hat, put on your Producer’s hat, and think about deadlines and what work is optional versus what work is core to what your game needs. You need to ship.

On the fourth hand, I will become a better game developer if I work on more games more often. There’s that story from Art & Fear by David Bayles and Ted Orland about the ceramics teacher who split his class into two groups. One group was graded on the quality of a single pot on the last day of class, and the other group was graded on the quantity of pots produced by the last day of class.

It turned out that the group that produced the higher quality pots was the group graded on quantity, mainly because the experience of creating each pot also gave them insights into how to make the next pot better. Meanwhile the quality group spent more time merely thinking about how to make a quality piece of pottery, and when it came time to actually put in the work, they were not necessarily up to the task.

So, if I focus on making more games more often, I’ll make better and better games.

Of course, on the fifth hand, I don’t want to make throwaway entertainment that people pay little or no money for and pay little or no attention to. I want my games to have meat on their bones. I want my games to be the kinds of games I’d play.

On the sixth hand, I am not my customers, and I need to make sure I create games with a target audience in mind. I should find out what THEY want to play.

On the seventh hand, I’m creating these games, and the message these games put out reflects what I want to see in the world. I own my art, and they’re not “just games.”

On the eighth hand, I’m not working on games in a vacuum. There are other games being made by other developers, and I should make sure to spend some time playing those games.

I should research other implementations, see what other developers have tried, learn what works and what doesn’t, all without spending the effort myself.

I should listen to podcasts, watch presentations online, and read blogs more regularly.

I can leverage the experience of other people.

On the ninth hand, I’m a part-time indie game developer. There’s only so many hours in a day that I dedicate to being a game developer, and if I spend it playing other people’s games and watching other people talk about how they do their work, I won’t have time to do my own work and put out my own games. I barely participate in online forums anymore, and I finally understand all of those people who complained about the lack of time to participate in forums. Where does anyone in my position find the time?

There’s a difference between doing and learning how to do, and there is always more to learn.

There’s also always more to do, and doing is the hard part.

On the tenth hand, I hate that I’m ill-informed about what’s going on in the world of games and their development. I was blown away to learn that multiple people were making virtual reality games for the most recent Ludum Dare 48-hour game development competition, as it sounds like the kind of thing that still requires a huge upfront investment. Clearly I’m out of the loop.

On the eleventh hand, I’m an indie game developer, which means I define my own rules of engagement.

It’s not a race, despite the realities of opportunity costs and trends, and despite the realities of impending life events that change everything.

Success isn’t defined by money but by accomplishing goals, despite the fact that earning a significant income from this effort would be a great side-effect of those goals being accomplished, one that could help me set and achieve bigger and better goals. Money isn’t a goal, but it can be a measure of progress. But it also doesn’t have to be.

When you’re starting out, you look to people who already know what they are doing to provide some guidance. And they are often more than willing and able to share what they think works.

But in the end, it’s easy to get stressed out about meeting someone else’s expectations if you don’t take care to set your own expectations.

I’ve had people tell me what I should do and what I shouldn’t do. I’ve had people question decisions I made and ask why I didn’t make a better decision on a choice I didn’t know I had.

There is no wrong or right way to go about this process, though.

Some people swear by putting out prototypes daily. Others like to work in secret for months or years at a time.

Some people like to explore one game mechanic fully, and others like to experiment with lots of different concepts.

Some people like to put out fully formed games to be consumed, and others like to release early development builds for people to nibble on.

Some people throw spaghetti at a wall to see what sticks, and other people like to plan out an entire evening with a multiple course gourmet meal.

If I use the same criteria for the spaghetti-thrower’s efforts that EA uses for their heavily-invested and marketed blockbusters, it’s going to look like a lot of failures and flops are being thrown at a wall. That’s not the way to make a blockbuster hit!

But the spaghetti-thrower has different goals entirely. They’re not trying to put out blockbuster hits. They might not even be trying to make something commercially. They’re trying to gauge interest in prototypes, seeing if there is a significant amount of interest in something before putting a lot of time, effort, blood, sweat, and tears into a more substantial work.

Following EA’s playbook is probably not going to help them achieve their goal. They’ll probably stress out way too much to be useful if they somehow get it in their head that EA has the truth about How Games Are Made(tm) and that they are not following it.

While other people might have great advice for their own expectations of how things work, it’s a lot less stressful (although still pretty stressful) if you politely ignore them and create your own expectations. You have enough to worry about without second-guessing if you didn’t make games similar enough to how some celebrity game developer did.

It’s fine to seek out and get advice, and it can all be really great advice, but don’t forget to make your own path.

Categories
Game Development Personal Development

The Satisfaction of Building It Yourself

I like building my games with my own tech.

There was a game jam in which I used Stencyl, but otherwise, all of my projects have been based on my own hand-coded C++ with libSDL. I spent time figuring out how to write a basic game loop, how to design my software architecture, how to create simple buttons to interface with, and more.

It’s time I could have been spending designing games rather than implementing them. I know this fact.

And yet, I persist.

Over the years, I’ve been told to switch to Flash, or use an engine like Torque 2D or Unity. When XNA was released, I remember wondering if C# was going to become the dominant programming language in game development.

But my C++ game engine is still with me, and still relevant. Granted, it’s not as full-featured as some systems, and the asset pipeline is still a manual effort. But what it does feature is well-tested, and I know how it works.

There’s something about learning how to build it from scratch that makes development more enjoyable. My A* pathfinding algorithm might make oddly suboptimal paths, but learning how the algorithm works and figuring out how to implement it was a fantastic experience.

Debug Path

As you can see from this 2010 development shot of what ultimately became Stop That Hero!, the AI hero should have followed something like that yellow line rather than the path it actually took.

It’s sort of like doing my own home repairs. There are some things I’ll leave to well-paid experts, but other things shouldn’t be too difficult to do. For instance, replacing the toilet’s fill valve and flapper took a small trip to the hardware store to get a replacement part and then a few minutes of work.

A bigger project I finished recently involved putting lockable doors on shelves we have in the basement. My wife and I are getting licensed to become foster parents, and part of the requirements for our home’s safety include keeping flammable materials such as paint in a locked storage area.

Rather than buy a big expensive cabinet, I thought, “We already have these wooden shelves in the basement. How hard could it be to put up a piece of wood with some hinges and a padlock?”

Basement Shelf With Paint Cans

I measured the area I needed to cover. I bought the wood and had the guy at the store cut it for me as I didn’t own a power saw myself. I learned the screws for the hinges were longer than the wood was deep, and I found that you could get 1x4s to frame the wood to make it look nice while also giving the door the thickness needed for those screws.

Gizmo helping with 1x4s

Plywood, 1x4s, and a drill

Framed plywood

Spray painted doors

Door mounted with hinges

Finished product

In the end, the doors looked nice enough and were functional, although they are not perfectly centered, as you can see. It turned out that the dimensions I measured didn’t take into account parts of the shelf protruding in ways that would prevent the doors from fitting perfectly. The good news is that they look homemade. B-)

Now, it took some time. I had to go to the hardware store a couple of times to get all of the materials, and I had to spend time on it when I could have been doing something more important, like working on finishing my game before we have foster children in the house. Did this time and effort translate into a better return on investment than the $90 cabinet I thought we could avoid buying?

No. In fact, we probably overspent on the wood and other materials for other projects.

But there are some benefits to having done it myself.

One, I learned 1x4s are not actually 1 inch by 4 inches. I never knew this fact, but when you buy wood, you need to expect your 1x4s will be 0.75 inches by 3.5 inches. It’s about how the wood is when it is cut and rough versus when it is dry, planed, and made ready for sale. It’s just one of those things that I now know for future projects. Luckily, the screws I had to attach the 1×4 to the plywood weren’t too long, but that could have been another trip to the hardware store since I was expecting the nominal dimensions to be the actual dimensions.

Two, I discovered that I can improvise a carpentry job. I had not made plans, yet I was able to put together some decent looking doors. When I ran into trouble, such as finding out that the doors wouldn’t fit where I expected them, I was able to shift them to different parts of the existing shelf and keep going. I could easily have given up when I found out that the doors were just a little too big, but I made it work. If I was doing kitchen cabinetry, I would have been more careful, but this project was more about the functionality than the aesthetics.

Three, I have the pride of saying, “I built that myself.” There’s nothing like that feeling.

My game development efforts might result in projects that are somewhat askew like my basement shelf doors are. It might take me longer. The end result might be less than what I could have gotten had I leveraged someone else’s efforts.

I know.

But I am a much stronger developer than I was in the past mostly because of all of the from-scratch efforts I have put in. I did the research myself. I explored from first principles rather than taking the shortcut of an existing path. I understand the trade-offs involved in design decisions rather than accepting decisions made for me.

And in the end, when I release a game, I can say proudly, “I built that myself.”

It won’t likely be important to my customers. And it won’t likely be important to you. But as an indie game developer, I don’t have to pay attention to your criteria for what’s the best approach.

I can build it myself, a process I enjoy.

And next time, I will be more experienced and knowledgeable than I was before.

Categories
Marketing/Business Personal Development

Shoveling Someone Else’s Manure

In 2009, when I was running my own indie game development business full-time, I thought I would invest in my own education and paid for the premium subscription content of a popular Internet business and marketing podcast.

I thought that I would get through the material quickly as I had the freedom to dedicate all of my time to it. Then I could cancel it after one month of payments. Maybe two.

I ended up sticking around for much longer, and I can’t say it wasn’t useful, but the entire time I felt frustrated by the format. I can’t quickly peruse audio and video, and that was what most of the content consisted of. And as for the content itself, I felt like I had to get through lots of “witty” banter between the hosts to get to the gold nuggets, if there were any.

But I can’t complain too much about the content. I was clearly not their target customer. It was meant for people who might have no experience with software or computers, so it might work for other people just fine.

There were forums populated with such apparently satisfied customers who wanted to learn what it takes to run a successful business, and some made some good success based on applying what they learned.

Except it seemed like almost each and every one of them was making their success by taking what they learned from the premium subscription and repackaging and selling it to others in their respective niches.

One person was doing OK with selling on eBay before she took up the lessons, and by the end of it, she was making a good living selling an info product on how to run a successful Internet business with basically all of the same lessons from this premium subscription. You know, but geared towards eBay.

And she was just one example. It seemed like no one wanted to apply the lessons to run their own existing business more effectively. Instead, they seemed to have stopped doing whatever they were struggling with before and started their new business as Internet marketing experts based on what they learned from a premium subscription information product about being an Internet marketing expert.

To be fair, in the land of the blind, the one-eyed man is king. To the right audience, these people WERE experts. They now knew something that most other people didn’t. I’m not a C++ expert when compared to the people who speak at CppCon, but I am expert enough when it comes to where I am employed, and especially when it comes to my family who are “not computer people” at all.

But the thing that bothered me about the other subscribers to the premium subscription was that their expertise wasn’t really theirs. They learned some tricks and techniques from somewhere else, but they didn’t apply it to their own businesses. So what do they really know?

At least I spend a significant amount of time actually using my expertise, so when someone asks me something about C++, I have some real authority and experience to back it up. They basically turned around and shoveled their new marketing know-how to the ignorant people who were willing to pay them for the information. “If you want to be successful, uh, here’s what these other guys told me.”

And boom. Now not only are they experts, but they’re commercially successful experts with a paying audience, which only grows their authority.

The personal development field sometimes has a bad reputation in this regard. Some people are great successes who might be trying to share some insight into how they became great successes.

But other so-called successful people really only seemed to have become a success when they started writing books and giving speeches telling other people how to be successful.

I subscribe to Sunday Dispatches by Paul Jarvis, and in this past Sunday’s newsletter he talked about the “advice gold rush”. Apparently seven years later the problem I described above has only gotten worse, and in many industries. Jarvis linked to a colorfully-titled article complaining about it called The Creative World’s Bullshit Industrial Complex:

Being industry famous should be the result of some contribution to the world that the industry respects and wishes to learn from. Or insights unique and useful that it genuinely makes people’s lives better.

Increasingly “creative coaches” and people with “keynote speaker” in their Twitter bios are making their quest to earn authority a higher priority than the very reason they got into this in the first place. Fueling the Complex is alluring catnip that feels like you’re advancing your career the same way answering a bunch of emails just feels productive.

I’m not innocent. I know I’ve done my share of contributing to the Complex on this blog, especially early on. I shared advice as if I had some experience actually applying that advice in my own work, and in reality I was just shoveling someone else’ manure.

But my most satisfying and gratifying work is when I wrote about my own hard-won experiences. When I write about my own failures no matter how huge or my own successes no matter how minor, they’re mine to share. I can say I know what I’m talking about and have some small chance that I’m right.

When I have those experiences, often that’s when I truly understand what someone else was saying all along. That’s when I can make the associations between someone’s advice and my reality.

Categories
Personal Development Politics/Government

Being a Real Ally for Marginalized People in the Game Industry

I’m a white, straight, cisgender man. But I didn’t used to be.

In the past, I was just me. A unique individual human being just living his life like everyone else.

Then I started becoming aware of the fact that as a man, I live a completely different life compared to women.

I had my butt pinched once. It was by a woman passing by in a club when I was in Cancun on spring break in high school. It was such a novelty that I didn’t know how to react at the time other than with curious amazement that it happened.

All women, on the other hand, have experienced unwanted harassment from men. Some have experienced quite a bit, and some have received unwanted physical contact, and some have been physically hurt for resisting, and some have died.

And that’s just one general way in which we live different lives.

Then I started becoming aware of the fact that as a white man, I live a completely different life compared to people of color.

I got pulled over for speeding when I was in high school. I was nervous, and I got off with a warning. I had been pulled over for speeding maybe four more times, and I got a warning almost every time. One time I recall two officers on each side of my car, and another squad car appearing, and I wondered why there was so much overwhelming force. Everything was fine, though.

Black men, however, have to tell their children how to behave when, not if, they get pulled over so as not to give the officer any reason to believe they are in danger and an excuse to shoot first, ask questions later. Black drivers may drive the speed limit even if traffic is speeding around them to avoid getting into such dangerous situations in the first place. Some still get pulled over for Driving While Black. Some get harassed, some get physically hurt, and some die.

And that’s just one general way in which we live different lives.

Then I started becoming aware of the fact that as a cisgender man, I live a completely different life compared to transgender people.

One time in middle school I accidentally walked into the girls’ bathroom. It was on a different floor, and I didn’t realize I was in the wrong bathroom until I was washing my hands and noticed the lack of urinals and some strange dispensers on the wall. If I had been caught, I probably could have explained that it was an accident, and if I got in trouble anyway, it would probably have been a minor punishment.

Transgender people have entire states passing laws preventing them from peeing where they are most comfortable, which is scary because just peeing in a public bathroom has been a dangerous situation historically for them. Some have been physically beaten and some have died because other people became uncomfortable that someone different was in their bathroom.

And that’s just one general way in which we live different lives.

I used to just be a regular human being, but then I became aware of my privilege.

Privilege is about Society, not You Personally

I have a lot of privilege. I don’t have to pay attention to any of those things happening to people who aren’t white, male, and cisgender. I can continue to live my own life oblivious to it, because horrible things just generally don’t happen to me merely by virtue of me existing, and if something happens to a friend who happens to not be white or male or cisgender, well, it was probably a one-off because if it happened to me, it would be a one-off.

That’s privilege. It doesn’t mean I was given anything in life. It means societal norms are such that when I was born, I get to play the game of life on easy mode. No extra obstacles are thrown in my way due to me being me. No one is out to put me in my place, because my place by default is on top. I still have to play the game and exert effort, but I don’t have to work twice as hard to get half as much. People don’t look at me and assume I can’t possibly know what I need to know to do a job, so job interviews for software development positions don’t require nearly as much effort by me to impress as it might be for, say, a woman.

I don’t have to feel guilty about being privileged, as I didn’t specifically do anything to obtain that privilege. But I should be aware of it because how I tolerate the systems that allow that privilege means I’m basically tolerating the status quo for all of the marginalized people out there.

As uncomfortable as it may be to acknowledge this, my passive tolerance does, in fact, make me part of the problem.

But being made aware of it wasn’t easy.

Privilege is Invisible

I think it’s a much more profound challenge than it seems at first blush. It’s hard to communicate with people who have a very different frame of reference in life.

People with privilege don’t recognize that they have it, and so when they come into contact with someone who isn’t in their privilege bubble, it’s a jarring shock.

Privileged people see the world as meritocratic, and the idea that anyone has a disadvantage due to systemic issues is ridiculous specifically because they don’t see the system. To them, it’s just How Things Are.

They say things like “Why don’t you do what I did and work hard to get what you want instead of whining and hoping someone will give it to you?” without realizing that they were given the opportunity to work hard to get what they wanted without having to ask for it. They don’t see themselves as privileged because they worked hard.

They don’t see how what might be a minor and temporary inconvenience for them is yet-another-blow to someone’s dignity and welfare.

There’s that saying, “He was born on third base and acts like he hit a triple.” In a way, that’s everyone who has privilege. For people without privilege, many weren’t even allowed in the lineup.

For some (many?), being told that they need to go back to the plate to swing the bat and hit the ball before they can take a base, just like everyone else, is a setback.

Oh, and by the way, now there are more people who are allowed to participate.

It doesn’t feel like equality so much as the privileged person losing something. They start looking wistfully to the past as when things were better (specifically for them), and without getting too political about it, that’s how certain politicians seem to get so much traction with passionate voters by appealing to their bigotry.

People without privilege are much more aware of it because it is a constant issue in their lives. To them, someone with privilege must seem very obtuse. “How can they possibly not see what I see?”

It’s because their privilege is invisible to them.

So you have privileged people who don’t know they are privileged who might not have a mean bone in their bodies, and they might think of themselves as genuinely good. Yet they are part of the system. Being made aware of this fact, that they have privilege and there are systemic problems for people who don’t, and they should take some responsibility for being part of that system that allows for it, is a potentially ugly process.

Many go into denial because, hey, they are genuinely good people and don’t hate anyone! Some of their best friends are [insert non-privileged group here]! They didn’t personally do anything wrong!

And they might even be right on all of those counts, but it’s uncomfortable for them to believe that they fell down on the job of being more active in terms of even acknowledging privilege exists because it sounds like they should feel personally guilty about it.

So, if they ignore their privilege, the world goes back to the way it was when everything was a matter of pure merit and hard work, and it’s not their fault that other people are less well off.

Privilege is invisible to those who have it. Confirmation bias helps. And communication and spreading awareness is an uphill battle as a result.

Ok, You Have Privilege. Now What?

I think one challenge I’m finding is what to do now that I am aware of my privilege.

And I mean do, because being aware and not changing how I behave and act feels like it is worse than being unaware and blissfully ignorant.

I’ve been doing some research, partly for my own growth, and partly as research for my church’s efforts to ensure they are a welcoming organization for transgender people. A lot of the action steps I’m finding out there for allies are along the lines of “Don’t say this, don’t assume that, do make space.” All good, but after that, I feel like there should be more to it.

Like, ok, I get it. Don’t be a jerk, and treat everyone you meet as a human being. Learning about hurtful and appropriate language and micro aggressions and existing systemic oppression are details, but there has to be more to it, right?

I’m not saying my education is complete, nor do I want to downplay the importance of those details, but it’s one thing to see and recognize privilege, and another to do something about it.

But I feel like there’s a next step that I’m responsible for figuring out because no one is talking about it.

Most articles I’ve found for allies boil down to one of either two things: a list of do’s and don’t’s to help you be aware of your privilege, or a diatribe about how allies are failing at being real allies. It seems like every ally-related article I find focuses exclusively on the “be aware” part, or it laments how allies are falling short of actually doing more than making themselves feel better about being so progressive. There’s almost nothing out there that feels like set of a tangible actions and behaviors that would make a lasting difference.

The video game industry struggles like many industries with marginalized identities. Mattie Brice is a games critic and activist I’ve followed on Twitter for a long time who has written about this topic often. Recently she tweeted a link to her article which captures why things haven’t improved substantially despite the number of marginalized voices creating games these days.

Brice argues that despite progress on a number of fronts, it seems the status quo is still pretty much what it was, and it seems to be because that’s what supposed activists actually want.

That is, people asking for more diverse representations in games expect to play the same games we’ve always played. You know, only this time Ubisoft could figure out how to budget for the production of female models.

Right now liberal games people find the values of marginalized perspectives quaint, nice flavor that could be adapted or added on to what we already have, but not the main dish. So they aren’t necessarily against radical viewpoints, and definitely encourage them to exist, but only unsupported so change is as slow as possible.

This forces people who have the most to lose and are currently in danger to take the majority of the weight of moving things along.

This idea that marginalized people shoulder the brunt of the work of rising up against the systemic problems is something I was made aware of while talking about ways transgender people could feel more welcome at my church. I didn’t want to speak for these people as I worried it wasn’t my place to do so, but it’s exhausting for them to do everything on their own because they are fighting an uphill battle.

If I had to constantly talk about being a white, straight, cisgender man, and constantly defend every action or thought as a white, straight, cisgender man, it would, in fact, be exhausting. But since society sees me as the default, I don’t have to exert that energy.

So as an ally, what I could do is amplify marginalized voices rather than merely sit back silently. They have their own voices, and I can do much more than wait for them to feel comfortable enough to speak in a hostile environment. I can make the environment more friendly. I could share what they say.

But I could also do more.

We know that these people get less resources, both from games and society as a whole, and not changing how you consume and practicing what you value continues that divide. Said liberal masses are forcing marginalized creators into critical positions by being apathetic at best about the literal support the give while contributing to entities that maintain the status quo.

Marginalized creators don’t often have access to the marketing might of major publishers, and as a person of privilege, it’s easy for me to not even be aware that these creators exist, which contributes to their marginalization without my awareness.

From this article, I’m thinking that one of the tangible things I can do as someone with privilege is to make the extra effort to find marginalized voices. So when I think about buying a new science fiction book, for instance, rather than choose from a bestsellers list or merely on Amazon’s recommendations, I could actively seek out science fiction books written by authors I might not know about.

That’s not a difficult thing to do, but until Brice’s article, it hadn’t occurred to me to do it.

And if I address this in each aspect of my life, from where I eat to what I read children before bedtime to what movies I decide to watch to what I personally create, then I’m hopefully doing more than mere awareness and actually practicing what I value.

I’m going to continue to look for more, but being more conscious about where my dollars go is one tangible, impactful thing I can do to make privilege more visible. It doesn’t sound so hard, but I’m surprised there isn’t more about it out there.

Being that I have the awareness of my privilege to ignore injustice, it’s a moral decision not to ignore it. Being in a position of privilege, I feel obligated to do more than the bare minimum of merely not being a jerk. It will probably be exhausting work, but it’s already exhausting for the people who don’t have the privilege to avoid the work. It is wrong to sit on the sidelines and think I’m still a good person while other people suffer indignity, harassment, injustice, and death.

Categories
Marketing/Business Personal Development

Rami Ismail: You Don’t Stand a Chance in Indie Game Development

If you’re a new indie game developer hoping to make a living in the current market, you’re doomed. Supposedly.

At Control Conference 2015, Rami Ismail of Vlambeer, creators of Super Crate Box and Nuclear Throne, spoke about how unlikely a new indie game studio will survive its first game’s release.

He compared the ease of indie game development to the ease of photography. At some point in its history, photography became available to the masses, and professional photographers had to compete with amateur photographers who could point and shoot with results that were often good enough. It shook up the market for photographers. I’m sure somewhere there is an archive of articles about the photopaclypse.

Some of his arguments sounded familiar, and it is because they are. He makes the same argument that Jeff Tunnell made 10 years ago in his blog post Five Foundational Steps to Surviving as an Indie Game Developer, the biggest one being “Don’t quit your day job.”

Ismail highlighted specific aspects of running an indie game development business that most new indies haven’t thought about or don’t know very well.

Whether it’s underestimating how much funding is needed, overestimating the number of people needed to work on a game, or not giving enough attention to your sales plan (or your personal health for that matter), you are ill prepared to do at all well in the market.

Quite frankly, the arguments he made, as insightful as they are, are depressing to hear.

But then he reminded you that this isn’t about making a living from your first game. It’s about surviving to make that next game. And the next.

It’s about building upon your successes and your failures. It’s about learning all of those things he said you don’t know so that you go from having no chance to having some chance.

A bit of insight into that kind of hard-earned learning comes early in another talk from Control Conference 2015. Vogelsap’s Jeroen Van Hasselt gave a presentation on why the highly-anticipated The Flock failed in the market:

You can catch something interesting at 1:34 seconds in.

During his introduction, we hear: “Vogelsap is a studio that specializes in making thrilling 3-D experiences that we present in an event and adventurous-like manner.”

Part of the presentation talks about how the student-run studio grew up, and I recognized that statement above as a mission statement.

Most new businesses don’t give enough attention to vision, mission, and purpose, and in fact Ismail says “vision” is just a word that doesn’t mean anything, but it’s clear that the people at Vogelsap at some point learned about them in the course of their own thrilling adventure while creating and releasing The Flock.

Worrying about vision, mission, and purpose isn’t bureaucratic corporate mumbo-jumbo. It’s not a pointless exercise to pretend you’re running a real grown-up business.

Vogelsap is not just making games. They have a focus, which most indies don’t have. When you hear about a new game with their name attached to it, you are going to have some idea of what to expect, and it won’t be a casual match-3.

What’s great is when indies share their learning and hard-earned lessons with the rest of us. Sometimes we pick up the lesson easily because it is intuitive. Other times, we might not grok them until we go through the experience for ourselves and come out the other side with a realization that this was exactly what they warned you about.

Your goal is to grow your indie game development knowledge, which is why it’s important to, as Ismail suggested, prepare for failure while aiming for success. Experience is infinitely more valuable as a teacher.

But keep your day job in the meantime.

Or don’t. I didn’t, ran out of money after a couple of years, and eventually got a day job again. I was stressed more than I have ever been stressed before, but I learned much more rapidly.

You’re an indie. You get to decide your path.

Categories
Game Development Geek / Technical Personal Development

Interview with Scott Anderson of Sledgehammer Games

Scott “Impossible” Anderson is an engineer at Sledgehammer Games, having worked on Call of Duty: Advanced Warfare, and was recently interviewed at We Are Game Devs, a site that highlights the various unsung and underrepresented talent who help create some of the fastest growing interactive entertainment on the planet.

Aside from his day-to-day responsibilities and advice for people who want to learn how to be programmers, he talked about his time as an indie game developer.

He touched on being part of Chicago’s early indie game development scene before his time as co-founder of Enemy Airship, working with Steve Swink on Shadow Physics.

And did that bring back memories!

I remember going to the Chicago Indie Game Dev meetings and Chicago-chapter IGDA meetings starting back in 2005. Reading my blog posts from that time is kind of embarrassing, but I guess that means I have grown.

Back then, Anderson was part of the duo that was Maw!soft, and I remember him as one of the key fixtures in the scene. If there was a game developer event in town, he was likely to be there.

During those years, he always had advice to share, a lot of which I ignored at my own peril, such as his comments on my goal for trying to use the IGF submission deadline as my project’s deadline or that I should release early and often with quick prototypes to find the fun.

I always enjoyed our meet-ups because if there was a fun idea to discuss, it was probably his, such as what a casual FPS would look like.

I hadn’t been keeping track of what the members of the old indie scene have been doing, but every so often I’d see Anderson’s name pop up in industry news, usually with me thinking, “Oh, I didn’t know he was doing that now.”

And now it sounds like Anderson will be working for Funomena soon?

Good luck, Impossible!

Categories
Game Development Marketing/Business Personal Development

2016 Will Be Different

I know I’m a bit late to the New Year-themed posts, but I spent the last week thinking and working on my plan for the new year.

But first, I’d like to talk about 2015.

What Went Well in 2015?

First, I learned about a lot of stuff.

I read 54 books, which is a little more than one book a week. In 2013 and 2014, I read around 40 books each, so I’m proud of finally hitting this book-per-week accomplishment.

Audiobooks from the library and a 20 minute commute to the day job helped. Ebooks on my tablet to read during lunch and other periods of downtime also helped. Most of the ebooks were obtained through Project Gutenburg, Pragmatic Programmers, and the Humble Book Bundle. And I also enjoyed reading a huge stack of Terry Pratchett books that a friend lent me shortly before Pratchett’s death.

Only six books were directly related to either game development or personal development. The rest were fairly evenly split between fiction and non-fiction.

That isn’t to say that I didn’t learn much. I learned about the Prohibition era, the Wright brothers, and Charles Lindbergh’s historic flight over the Atlantic. I learned about the history of chess, and I learned about Phil Jackson and Michael Jordan’s leadership on the Bulls. I learned about prostitution in Chicago’s Everleigh Club, and I learned about how humanity’s understanding of information as a concept has changed over the centuries. I allowed myself to get fascinated with biographies and histories, and I think the exposure to all of these ideas and knowledge can only help my creativity.

Another thing that went well in 2015 was that I remembered my goals.

In the past, I would make goals for the beginning of the year, and then I would find myself at the end of the year remembering that I had set goals almost a year prior. I would lose sight of the big picture because I was focused on the actual details of work for a long period of time, or I would just forget that I had a goal and so not remember to make plans to achieve it. Some people hate New Year’s resolutions because they never keep them, and I would feel this frustration with my goals.

If I got sick, it would sometimes set me back so much that I had a hard time getting back into whatever daily habit I had established. It was too easy to get knocked off of my routine and keep me off.

Last year, however, I think I did a very good job of keeping my goals in front of me. I may not have actually MET my goals, but throughout the year I was making progress on them or at least being fully aware when I CHOSE not to give them a priority.

I made highly visible reminders for my quarterly game development and writing quotas I was trying to meet, my monthly “big deals” I wanted to accomplish, and my weekly outcomes.

At any given time, I knew what I was supposed to be focusing on. As an example of one result, I put in a lot more game development hours than I have in the past.

Considering that many business owners say that focus is one of their greatest challenges, I’d say that 2015 was a win in this area.

What Went Wrong in 2015?

Last year was the first year my business made no income.

That’s exactly $0.

It’s not hard to see why. The main reason was because I didn’t publish a game.

An entire year went by without me creating and publishing a commercial game, and a commercial game should be my primary way of trying to earn income for my business.

Now, I worked on a project during this time. I had some false starts with it, though, and I changed direction, and it took me awhile to get the design down to something manageable. I did paper and digital prototypes, and I did some infrastructure/technical work as well.

What’s frustrating is that I made an effort to put in more time towards game development. I have a day job and a family, and so taking advantage of my limited “spare” time to make progress on my game project required discipline and effort.

And quite frankly, THAT part worked out fairly well. As I mentioned above, I set quotas for myself, and I managed to spend more hours on game development in 2015 than on game development and writing combined in either 2013 or 2014. So, good job, Self.

The problem is that I didn’t have a specific plan. I had tried to make a plan, but it was little more than a list of tasks that weren’t necessarily well thought out.

This kind of a minimalist plan might be more than enough for some game developers, but since I didn’t set deadlines or milestones for myself, it was easy for me to take a task and work on it for way longer than I needed to. That game menu could be generalized and data-driven, right? I could write my own “simple” physics engine, right?

I tried not to worry about estimates or deadlines, and instead I focused on just making progress every day. The thinking was that eventually I would finish.

The thinking turns out to have a flaw. Basically, I was focused primarily on effort, and it didn’t get me anywhere very quickly.

In the past, I made some money through Google AdSense and Amazon affiliate links. Not much, but more than enough to pay for my web hosting.

These days, my blog isn’t as popular as it once was, and ad revenue has almost completely dried up. I used to make an order of magnitude more per month, and I could expect to get a check from Google every six months or so. Now, it’s been a couple of years since they last paid me because I haven’t hit their minimum threshold yet.

And according to my projections, they won’t pay me this year, either.

How Will 2016 Be Different?

In 2015, I set a goal of publishing at least one game by December 31st. I fully expected to publish one much earlier, but I gave myself that long deadline as a very generous cushion.

Every month, I would find myself realizing that I was getting closer to that deadline without much to show for it. Then it was December, and then it was 2016. Oof.

So, that generous cushion was stupid. I never felt any urgency.

At dsmAgile in September, I saw Geoff Wilson give a presentation called “Barely Manage to Lead”. He talked about a game project that failed after working for a year and a half before getting user feedback. Today, one of his keys to success is to create and deliver a Minimum Viable Product in 90 days or less.

I found that even though I actually had about 90 days after his talk to focus on creating this MVP, I still didn’t accomplish it.

The lack of a solid plan was my real failing. I erred on the side of too little formality. After all, it was just me in my business. It’s not like I needed to do any kind of formal reporting to a stakeholder about progress or release projections.

But remember, last year showed me that keeping my goals in front of me helped me remember to keep working on them. I realized what I needed to do was focus on impactful results instead of effort.

Since a more laid-back kind of project plan (or the lack of one) didn’t help, I’m going to swing the pendulum the other way and do more formal planning.

2016 Plans

I spent almost nine hours over the last week creating a project backlog, identifying all of the features and goals I have for my project. I created a project roadmap for the first time in my life, which helped me identify roughly what I’ll be working on and when. I created an initial release plan based on my rough estimates, breaking down what I’ll be working on each week for the next three months. And I have my first week’s tasks based on the items in my backlog that I will be working on.

I’ve never had such a plan in place for myself. The closest I came was when I was working on Stop That Hero! and had created a backlog with items allocated to sprints, but I allowed myself to slip self-imposed deadlines too often instead of doing the needed reprioritizing and replanning. I felt like I needed to do real work instead, and I never realized how much creating a prioritized plan IS real work.

This project plan, however, fills me with confidence that I will have something to show for my efforts in a few months. For the investment of a few hours, I’m sure I’ll save plenty of time and will be able to hit my goal.

I also want to direct my learning a lot more, and so I will create a skill-development plan.

I want to repeat my book-a-week accomplishment this year, but I want to be more conscious and deliberate about what I read in service of my skill-development goals. For example, if I want to improve my cooking skills, I’ll seek out multiple culinary books and audiobooks and read them all in a row.

My outcome focus also means I’m open to other ways to accomplish this learning besides reading. As another example, one of my goals is to learn more about Machine Learning, and aside from reading about it, I know I can watch Caltech’s Machine Learning lectures that a colleague told me about.

So, bottom-line: 2016 will be different because my focus will be on outcomes as opposed to effort and putting in hours. Those things will still be needed, especially as I’m a part-time indie game developer with a day job and family, but those efforts will be aimed at targets rather than be seen as good for their own sake.

I will take what I did well in 2015 and harness it way better. I’m excited about 2016, and I can’t wait to tell you how I succeeded.

Happy new year! B-)

Categories
Game Design Game Development Geek / Technical Personal Development Post-mortem

LD33: Free Me, You Idiots! Post-mortem #LDJam

Ludum Dare #33 is months old, and the next Ludum Dare is about to begin. It’s about time I wrote a post-mortem about the game I submitted.

The theme was “You Are the Monster”, which, as usual, caused a lot of panic among the participants who worried that it was impossible to make a game based on that theme in two days. And once again, despite such worries, there were almost 2,000 entries submitted, so people found a way to do it.

I ended up making a fairly compelling, somewhat humorous, non-violent strategy game about being an imprisoned evil using its influence to escape. I called it Free Me, You Idiots!

What Went Right

  1. Quantity Over Quality: Fleshing Out Concepts and Designs Early

    It’s easy to want to get started right away. You only have 48 hours, and every second counts. But I also knew from experience that it helps to spit out as many concepts as possible early on, then pick the one that seems most promising. You are more likely to have a good idea picking the best of a thousand ideas versus the best of ten ideas.

    So I spent the first couple of hours thinking, doodling, and discussing with people on IRC.

    The theme had a lot of obvious and not-so-obvious applications. The obvious choice is to harvest ideas from classic movie monsters, such as vampires, werewolves, and ghosts. It’s direct, and you could have monsters who are genuinely scary or you could have them be misunderstood by the populace.

    The next-most-obvious choice is to think about metaphorical monsters, such as people who have the most evil and disturbing thoughts. It could be a psychological thriller in game form.

    I thought about characters, origin stories, and settings, and I had a lot of fun thinking up ideas as varied as space aliens and beings frozen in the Arctic for centuries.

    I went with the idea of the incarnation of evil imprisoned in a tree for centuries. With no previous story, I was free to write my own with no preconceptions.

    I fell in love with the idea, which really helped me drive the development of the game. If I hadn’t spent time upfront thinking, I might have settled for a merely OK idea, and I might not have found myself as passionate to work on it.

    I spent quite a bit of time thinking about this concept. I threw out a lot of ideas early on and managed to find the core of the game. I had originally thought about having a bunch of stones surrounding the tree that you were imprisoned in that had to be removed by the nearby villagers under your influence. I mocked them up and played with the idea for awhile.

    Concept: An imprisoned evil

    Imprisoned Evil prototype

    Imprisoned Mock Up

    The idea was that rock-gathering was an activity for the villagers, and the villagers would grab these forbidden rocks.

    I’m glad I threw it out because I ended up having entities that did hardly anything but explore and pray. I would have run out of time without a way to remove those rocks and finish the game.

    I think if I had more than two days that those rocks would still be in the game and the entities would be mining, chopping down trees, and more, but because I had a wealth of ideas to choose from, discarding some didn’t feel like I was gutting the game of its essence.

  2. Iterate Like You Mean It

    In the previous Ludum Dare, I spent a lot of my time on animations and art, but not much at all on game play. By the end of that compo, which had a theme of “An Unconventional Weapon”, I had a monster that could chase around the player when you got his attention either by shouting at him or by crossing his line of sight. I wanted the monster’s head to turn separately from the body, and there was going to be this idea that the monster can trip over itself when it is moving in the opposite direction that it was looking. I spent a too much time creating the complex animation system when I could probably have gotten away with something simpler, and as a result, what I submitted wasn’t anywhere near a finished game.

    I didn’t want to make that mistake again in Ludum Dare #33. Even so, I didn’t start writing code until the compo was well underway. While I was worried that I wasn’t going to make everything I wanted by the deadline, my approach meant I was always going to have something to submit.

    My first focus was on interactivity. If the player can do something, I can build upon it, even if I have to cut most features or change the direction of the game design completely.

    It meant I was also playing the game frequently. I would make a change and immediately see how it felt. I can identify things that may be buggy or hard to understand, and I can fix them immediately or prioritize them.

    For instance, when clicking on an entity in the game, an arrow appears over them. This was a simple bit of polish that I thought seemed important enough to add early on. With a bunch of entities moving about, this arrow meant it was easy to identify which entity you were looking at.

    But moving around the world was a bit jarring. You click, and the camera centers to that location. I knew I wanted to add interpolation to smooth the camera’s movement, but I also knew that what I had was passable and could be fixed if I had time for polish later. So the working yet jarring camera movement stayed throughout the rest of the game’s development.

    What was exciting was that by making small yet meaningful changes, it allowed me to add a relatively complex economy without much effort.

    LD#33 Game Play

    The game features a few variables that are interdependent and make it feel quite rich to explore. For instance, the player has Evil Energy to use to influence villagers. Evil Energy replenishes one point every second.

    The number of followers influences the amount of maximum Evil Energy a player has. More followers meant more maximum Evil Energy, which opened up options for the player.

    When you have followers, they will pray to you. When the total amount of prayer time exceeds 10 seconds, the player gets an extra point in Prayer Energy, which can be spent on upgrades and ultimately on the ESCAPE option, which ends the game in victory.

    I originally didn’t intend to add so much because I was worried about spending too much time on balancing all these variables, but without all of these different values and their interactions with each other, the game felt very simplistic.

    I’ll admit feeling worried that I might find that the whole thing was unworkable and would result in nothing but wasted time. Learning about and playing with game economies from the book Game Mechanics: Advanced Game Design by Ernest Adams and Joris Dormans gave me some confidence I could pull it off by adding pieces of it throughout development and building upon them iteratively. Each addition was relatively risk free and easy to fiddle with.

    I was very pleased with the results, and so were the people who played the game. I was surprised by how many actually played it all the way to completion!

  3. A Goal for Being Cool

    I realized that back in pre-20 Ludum Dare compos, it was easy for me to play almost everyone’s games because there was less than 100 entries. There would be a burst of game development activity for a weekend, and then maybe a week of playing and rating games, and then going back to regular life. Plus, back then you didn’t need to rate games to get your game rated.

    Today, with thousands of entries, it takes much more of a commitment. Your game won’t show up in the random sampling for entrants to rate if you don’t also rate other games. It’s a fair system.

    After the compo, I was on vacation from the day job and so I spent the next few weeks playing games. I set myself a Coolness goal. I figured that if I played a handful of games a day consistently for the next couple of weeks, I would be able to hit it.

    And when I rate games, I like to give feedback to the developer. I don’t just post “Nice!” or leave no comment at all, so I wasn’t going to allow myself to speed through reviews in order to quickly increase my Coolness. I was going to play games, give them a fair shot, and give an honest review with constructive feedback.

    LD33 Coolness Result

    I only got 63% Coolness, but it was enough to earn me a bronze medal. I don’t understand how that percentage is calculated. I know I didn’t rate anywhere near 63% of the nearly 1,199 games submitted, yet it seems like I could have hit 100% with only a few more handfuls of rated games if my math was correct.

    But I know that if I hadn’t set a Coolness goal, I would have either made the mistake of not rating enough games, resulting in my own game not getting rated by many participants as in past recent compos, or I would have spent a lot of my waking hours doing nothing but playing LD games, ignoring my other responsibilities. I think I had the balance mostly right.

What Went Wrong

  1. No Polish and No Sound Effects Again

    In an effort to speed development along, I did the opposite of what I did in the previous Ludum Dare compo and ignored animation and polish as much as I could. It wouldn’t matter how cool something looked if the player had nothing interesting to do.

    As a result, the game lacks life. The entities move around without turning or animating, and there is no indication when a player successfully influences someone. The grass tiles had markings which were too subtle and resulted in a sea of green that made it difficult to tell if the player was actually moving the camera.

    Now, it wasn’t completely bad. The prayer bubbles added a nice touch, as did the Evil Energy ball in the HUD scaling quickly when it replenishes. The flavor text had some humor and lore.

    But no sounds, no animations, and no special effects left the game feeling like a lot was missing.

  2. Buggy Engine Code

    There were a few problems with the custom engine I was using. One was something I saw in the last Ludum Dare in which tiles would seem to separate as you moved the camera around. It turned out to be a floating point error that resulted in me accidentally scaling the tiles so they would sometimes be one pixel smaller in width and/or height. I must not have pulled in the fix when I was putting the project together, so I easily fixed it, but it still took me some time to figure out what exactly I was missing.

    Early on I noticed that entities seemed to walk over the tree. They should look like they are in front of the tree when standing in front of it and behind the tree when they were behind it.

    So why were they always appearing on top of the tree no matter where they were?

    I recently ported my code from libSDL to libSDL2, and sprite rendering was done differently to accommodate scaling and rotation. Unfortunately, I introduced a Z-ordering bug which, after spending time on figuring out what was going on, I decided to ignore for this compo rather than spend more time trying to fix it.

    The risks of using your own code instead of a ready-to-go engine such as Unity or Game Maker is that infrastructure bugs like this are not only likely but also might be something you feel inclined to fix immediately. If Unity had a bug, I’d work around it because I’d have no other choice. If my own code has a bug, I’d feel like I could fix it while working on my game and might underestimate the effort it would take to do so.

    So while it wasn’t fatal, I had buggy infrastructure code that slowed me down and prevented me from making a better game.

  3. Missing: Some Features and Any Challenge

    One of the upgrades in the game is CAUSE FEAR. Do you know what it does?

    If you guessed it caused the villagers to be afraid, you would be wrong.

    It does nothing. Why?

    Because I never got around to it. I had ideas for what CAUSE FEAR would do, but since so much of the game didn’t get made, such as the mining and wood cutting I mentioned earlier, there was no real reason to cause villagers to be afraid. Maybe it would make them pray harder for a bit, and so CAUSE FEAR was similar to trading Evil Energy for Prayer Energy but in an indirect way.

    I had a few ideas, but none of them got implemented. Unfortunately, I left the option in even though it did nothing. Whoops. B-(

    Similarly, because there was no real conflict in the game, there was no challenge. There is nothing in the game that prevents you from converting every villager, getting all of the energies you need, and winning the game.

    I wanted the good villagers to try to convert back your followers. I wanted different kinds of villagers, such as priests and acolytes, and have their presence force you to change your tactics. Perhaps if your followers got numerous enough, the other villagers would go to war with them.

    Something. Anything.

    But instead, there’s nothing. There’s enough economy and variety that it seems to hide this lack of conflict, but without conflict, I can’t really say I have a complete game.

What I Learned

  1. A Design Document Is Key

    Throughout the compo, I set myself goals. I set an initial goal of settling on a concept within two hours. I set a goal of having interactivity early on instead of waiting until the end. I set a goal for rating games after the compo.

    Each goal gave me some control over the outcome. I was able to focus on what was needed and ignore what wasn’t. While the lack of polish hurt, it wouldn’t have hurt nearly as much as having a fairly incomplete experience.

    What really helped in setting goals was having a design document for the project. Now, I’m not talking about a 300 page document that no one reads. I’m talking about a living document that changed throughout the 48 hours I used it to help guide me.

    Everything I thought of went into that document, which allowed me to assess what was a priority and what was nice to have and what didn’t need to be there at all.

    I could see what was left and compare it to how much time I had left, and I could make intelligent decisions about feature cuts and what had to be there no matter what.

    I credit Hybrid Mind’s Ludum Dare #29 timelapse for In the Black for showing me how effective a design document can be for even a short 48-hour project. Thanks, Dave!

  2. A Game’s Economy Can Have a Big Impact on the Game’s Appeal

    I was glad I decided to risk adding more to the economy of the game. Evil Energy and Prayer Energy play off each other in an intuitive way, which makes the game more compelling.

    I think people kept playing because throughout the game there was always something to aim for. Converting a follower resulted in an upgrade being made available, which required Prayer Energy to attain, which in turn allowed more followers to be converted more easily, all with the aim of using ESCAPE to end the game.

    I could have had a simpler economy. If I eliminated Prayer Energy and made things more directly available, it could have worked, but it might have felt too simplistic.

    What I’m not happy about is that the richer economy hides a lack of challenge. I don’t want to use economic designs to act as a bandage on a fundamentally broken game.

    But I did learn that doing a decent job designing an economy can result in a great return on investment.

  3. Keep Your Nose to the Grindstone

    During the 48 hours of Ludum Dare #33, I slept, I ate, I showered, I talked with my wife, and I blogged.

    But most of my time during the 48 hours was spent on design and implementation.

    According to my records, I did a little over 24 hours of game development between Friday and Sunday. Just over half of the time spent on the compo was spent doing actual game development, and I’m pretty sure that because I lived and breathed this project, I was even making progress while showering or eating.

    Even with the failings I mentioned, I can see that this laser focus was the real reason why I was able to get a decent game finished.

    I’ve done compos in which I was distracted, and they didn’t always end well. Either I was dealing with poor health, in which I couldn’t sit at my desk for long periods of time, or I was going to a party or a soccer match.

    For this Ludum Dare, I made sure that I was 100% focused on the compo with no outside commitments to keep me from doing anything but game development that weekend.

    It was grueling and exhausting, but that concentrated effort made things move along so much more quickly than if I had spread out the development effort with frequent and potentially long breaks.

    I’m not saying breaks are bad. I took breaks.

    I am merely saying that my mind was focused on game development and not on how to interact with other human beings in a social situation or how frustrating it is when your team is losing due to the same blunders they always make.

    I rested when I needed to rest, but I didn’t allow myself to procrastinate or do much of anything other than participate in this compo.

Summary

The results of this compo were very encouraging to me:

LD33 My Results

Out of 1,199 entries, my game was rated in the top 36% overall and top 8% in innovation. My only rating that was in the bottom half of the group was for graphics, and even then it was at the top of the bottom half. B-)

I credit my ability to focus that weekend on game development almost exclusively, and all of the tools that allowed me to leverage that focus, such as my design document and setting milestones.

The main complaint from players is that there was a lack of music and sound, followed by the noticed lack of challenge. For future compos, I’ll want to focus on not only interactivity but also adding real conflict.

I may want to experiment with adding audio iteratively. Normally I add it at the end, and an informal survey indicated that a lot of other game developers add it at the end as well. I wouldn’t want to spend time on something that might get thrown out before the end.

Still, the idea is that if I can have a playable game early on in a compo, I can also have a playable game with audio early on in a compo, too.

Categories
Geek / Technical Personal Development

Global Day of Coderetreat is This Saturday

A couple of years ago I attended my first Global Day of Coderetreat, a day to celebrate software craftsmanship and practice software development with like-minded developers outside of the context of a normal work environment.

I had a great time then, and so when I learned at the last minute that there was one coming up, I signed up for it right away. It’s a free local event, so there’s no excuse not to take advantage of it.

Last time we paired with different people in multiple iterations of developing John Conway’s Game of Life, with each iteration forcing us to throw away our old code and work under different constraints.

For example, one iteration asked us to avoid using primitives. At the time, I struggled to understand what it meant since you can’t create a custom class without using primitives at some point.

But the spirit of the exercise is that your solution shouldn’t expose implementation details. If you are using integer values to represent states, you could use a typedef:

typedef int State;

And then use State instead of int where appropriate. In this way, your code reads better because the way you model it is part of the language of the code.

Note how even with bad single-character variable names that

void update(GridPosition g, State s);

communicates intent a lot better than

void update(int x, int y, int s);

And ever since that coderetreat, I’ve been able to use that experience to write more readable code than I used to.

I’m looking forward to Saturday’s Coderetreat here in Des Moines, IA. It should be fun.

Are you attending a Coderetreat near you? Are you hosting?

Categories
Geek / Technical Personal Development

You Are NOT a Code Monkey, So Stop Acting Like One

I lead a C++ lunch-and-learn group at my day job. Its audience is either non-developers interested in learning some basic programming, or developers who have experience with a different language and are still getting to grips with C++’s basic syntax.

One of the things I try to stress is the need to be conscious when coding. Software development is an intellectual activity. The most important aspect is not coding. It’s thinking.

So I often stop my group and ask them to justify a code change. Too often I see someone copy and paste code in the hopes that it will “work”. It then becomes trial-and-error in getting the magic incantation of semi-colons, curly braces, and keywords in the right order in an attempt to appease the compiler so that the developer can continue.

It’s what I call Hope-and-Pray-based Development, and while a million code monkeys eventually might be able to hack out the equivalent of Shakespeare’s works using this method, it’s not what a software engineer should be doing when trying to create customer value through code.

Now, it’s one thing to leverage the compiler. If you type out some code, and you’re not sure if it is right, the compiler will happily tell you why faster than you can formulate a guess. But you’re not just typing and pasting code in different ways in the hopes that the compiler will shut up.

The key is that you are testing a hypothesis and getting feedback and, most importantly, learning.

But sometimes the lesson is subtle.

Recently we’ve been working on the Prime Factors Kata by Uncle Bob Martin. It’s a short kata in Java that we’ve translated to C++ as we’ve gone through it, but because of my insistence on being conscious developers, it has taken a few sessions to get through the first few tests.

The first unit test says that you get an empty collection when you ask for the prime factors of the number 1. The second unit test asks you to return the number 2 when you ask for the prime factors of 2. So after the second test passes, the code looks something like:

std::vector<int> primeFactors(int number)
{
  std::vector<int> factors;
  if (number == 2)
  {
     factors.push_back(2);
  }
  return factors;
}

The third test is about the prime factors of the number 3. Once it passes, the code looks like:

std::vector<int> primeFactors(int number)
{
  std::vector<int> factors;
  if (number == 2)
  {
     factors.push_back(2);
  }
  if (number == 3)
  {
     factors.push_back(3);
  }
  return factors;
}

The third part of the test-driven development cycle is refactoring, and my group wanted to refactor this code to look like:

std::vector<int> primeFactors(int number)
{
  std::vector<int> factors;
  if (number == 2 || number == 3)
  {
     factors.push_back(number);
  }
  return factors;
}

The tests still passed, but I asked the group to justify their refactoring. I got responses about how it is more readable this way, or that there are fewer lines of code.

I said that those reasons are all well and good, but I fear they’ve lost something in terms of intent. I said that the variable number is the input. We’re asking for the prime factors of number, and giving back number as output happens to work but isn’t really what we’re doing when we’re providing the prime factors of a number. I argued that this change is hiding the intent of the code and that explicitly returning 2 for 2 and 3 for 3, while more lengthy, didn’t assume anything about the input as output.

This discussion/debate went on for the last 10 minutes of the session. Afterwards, they read ahead in the kata’s slides and saw that the refactoring in the slides does, in fact, do the refactoring as they did.

So was I wrong?

The prime factors of a number are directly related to the number, so it makes sense that the code can be written to return values that are defined in terms of that inputted number. So, ultimately, yes, the code will reflect this fact.

But I wasn’t focused on the code’s correctness. I was focused on the correctness of the thinking behind the code.

The developers in my group didn’t argue that the refactoring’s validity is due to the number being its own prime factor. They were focused on removing what they saw as duplication, on making the code shorter.

Effectively, they saw a change they could make and made it without concern about how it will be read later or how it will impact changes later. It was a change made for its own sake, mimicking changes they’ve seen elsewhere. It “worked” in this other context, so it must “work” here.

In other words, I recognized that this otherwise fine code change was happening for the wrong reasons.

Another example is when we passed our second unit test and decided to refactor the tests. We created a fixture, and the code originally looked like:

class PrimeFactorsFixture : Test
{
};

The compiler didn’t like it: error: ‘static void testing::Test::SetUpTestCase()’ is inaccessible
static void SetUpTestCase() {}

After the developers eventually read the error message and tried to figure out why this function was even relevant to their code, someone suggested that sometimes the keyword public is put in front of the base class.

So they tried it, and it “worked”. The compiler built the code and we were able to run the unit tests.

Rather than continue on with the refactoring, I spent the next few minutes (re)explaining how inheritance works in C++, and that there is a difference between private and public inheritance, and that what they saw was a compiler error as our unit test was expecting PrimeFactorsFixture to have functions that Test provides but because we were inheriting from it privately, those functions were not available.

I spent that time because it is important that they understand WHY it worked. I want them to get out of the habit of throwing spaghetti at a wall and seeing if it sticks. I don’t want them to be satisfied with waving a dead chicken to get past a compiler error. I want them to think beyond “I saw this other code that looked like it might work here” and get to “we need this code because of this good reason.”

Trial and error is fine if you are actively learning from your errors, but if you don’t stop to find out why the errors happen, you won’t learn how to avoid them in the future. You’ll just leave behind a trail of horrible half-functioning code that appears to “work” at the time you wrote it without you being able to explain why.

If your development process could be replaced by a script that generates copy and pasted code or shifts values around at random until the compiler works, you aren’t acting like a software developer. You are acting like a code monkey.

Code monkeys bang on the keyboard until things seem to work, even if the code doesn’t in fact work as they think it does. They focus on getting past compiler errors without worrying about why the errors happened or if the code changes they made to “make it work” are even sensible in terms of what they are trying to accomplish.

Software developers think through what code is needed, and once they implement it, they know with some level of confidence that their code actually does in fact work. They learn from their mistakes. It’s not about getting it working. It’s about getting it working correctly.

And since I want my group to be made up of software developers, I often stop my lunch and learn group and force them to justify what they were thinking when they made a change. I won’t tolerate random code changes to appease the compiler. Instead, I want them to think the code through. I want them to be able to predict accurately how the compiler will react to their code when they write it.

I want them to put down the dead chickens and think.