Visual Studio Achievements - Remember Kids They're Just For Fun

I followed a neat project for the last couple of months which today became a reality, Visual Studio Achievements. Achievements are something the gaming world are very familiar with. They're milestones of recognition to meet like "Blowing up 30 Enemies with 1 Grenade" or "Destroy a Super Tank playing the Classic Game". There are a lot of sites around the Internet to track them including one dedicated to just XBox 360 ones here.

They're fun and you get a bit of an internal high when you see this on your screen:

The Visual Studio Achievements follows the same idea and, once installed, are based on your activity as you work. Achievements are measured and discovered in the background when you compile. And hey, it's cool and fun to see this after a compile:

However when you look through the list of achievements one thing jumps out to those that try to follow good coding practices. These are certainly not that. In fact if I caught you writing a class with 10 levels of inheritance I would rip you a new one at the next daily stand up that would make even the likes of Gordon Ramsay shake in his knees.

Ahh but you say these are for fun. Yes, yes they are and far from me to be the party pooper. What sparked me to write this blog response is to emphasize F-U-N and not practice. Seriously you won't believe (or maybe you will) how many developers I talked to around me that thought this was a cool thing to install in their work environment.

Wait. Let's think about this for a minute.

  1. Install achievemnts add-on in work environment.
  2. Do work
  3. Get achievment

Okay, the first step is fine. The second step is what we do. The third step? Hang on. Didn't I just say that having 10 levels of inheritance is a bad thing? So if you get the achievement during your daily work it should be a *bad* thing, not something to celebrate.

It's like breaking the build (which we all do at some point and certainly people get ridiculed for it, it's all fun right). Breaking the build is a bad thing but it's a good spin. It means we recognize something went wrong and whatever mechanism you have to let you know (since everyone on the team should get notified) means you get up, rally around, and fix the problem. Good stuff. Build fixed, work continues.

Where's the rallying here? The only thing that will happen is the dev will see the achievement, pat himself on the back and have a chuckle then what? What *should* happen if you installed this and got an achievment should be:

  1. Do work
  2. Get achievement
  3. Chuckle
  4. Silently say "Oh shit"
  5. Fix problem
  6. Lather, Rinse, Repeat

Hopefully this is the case, but again I've asked a few people and they miss the point of the fun aspect here. This shouldn't be something you strive to achieve, the achievements here (as they stand currently) should be something to avoid. In fact it should set of an internal whoop-whoop alarm and cause you to think "What the Hell was I thinking".

Before you dismiss me, I'm all for fun. I'm the guy that has robot zombies and posters of Close Encounters in my cubicle and challenges developers to games of magnetic Angry Birds after stand-up. I'm all that. However I just want people to be aware that this is fun and there might be a message here. Keep focused on good practices and not bad ones. In the game achievement world, we *try* to achieve these tasks. Heck when I get a game and I'm bored I look through the achievements and set myself up to try to accomplish it (mostly failing since I literally suck at almost every game).

However developers should not be looking at these achievements as something they should be striving for (except just to get the achievement and make it onto the site). What would I really like to see? Some actual achievements that developers can strive for and be proud to achieve. How about "Eliminate 10% of the codebase without removing functionality" or "Mock a service and pass 10 unit tests against it" as achievements.

Herein lies the real problem though. Getting the *fun* achievements is easy. They're tangible and simple to measure. How do you measure "good code"? Can you scan code with a computer and determine separation of concern? Or if your code follows SOLID principles or not? Somethings are detectable but most of the good stuff is not. That's the real trick here (and if you figure it out in a system where you can automatically detect it and award and achievment for, all the better).

Like I said, have fun with this addon. It's neat and I applaud the developers for coming up with it. I don't discourage its use but keep in mind what it is and what the message behind it is. Hopefully one day with might have some positive achievements to strive for as well as the fun ones.

6 Comments

  • This sounds rather backwards: if the achievements are rewarding bad practices, it sounds like you've got the wrong achievements. The right achievements would reward good behavior such as "50 Successful Builds in a Row".

    I introduced my own version of this to a client of mine a few years ago and, yes, mine included both bad and good "achievements". However, an "Achievement" isn't meant to be an isolated badge, with your total badge count equating to your rank or awesomeness. Instead, we had a Leaderboard with Top and Bottom leaders in all categories: Top Builder, Top Build Breaker, etc.

    That is the kind of gamification that motivates people!

  • I had the exact same reaction to this announcement. As incredibly hard as it is to teach and encourage good programming practices "in the wild", I am VERY disappointed that the VS team (I guess?) is taking this gigantic step backward by encouraging bad practices, without even an attempt to distinguish between "good" and "bad" achievements or offer links to material that explains why a particular anti-pattern is considered so heinous as to be included as an "achievement" in jest.

  • The people that will see these "achievements" as encouragement to perform poorly are the people that are ALREADY using the bad practices prior to this addon.

    If anyone doesn't take this in jest, then it's on them. It's fairly obvious to anyone who knows anything about programming that this is a fun addon to get some laughs, and maybe help someone realize that they've done a bad thing. Thinking that people are going to be "encouraged" towards bad practices seems unrealistic to me.

  • Then again, many games have achievements for the most 'team kills' and other 'opposing success' achievements.

    As long as we all ridicule and laugh at the 'bad achievements' it ensures that when developers do hit them, they laugh and recognize that they weren't positive in nature. :)

    Just an alternate spin, though I agree as with all v1 implementations MS could greatly improve.

  • I had exactly the same reaction as you. The list they have is a fine start, as long as they start adding achievements that encourage good practices. The ones that expose bad dubious practices have there place too, but they should *remove* points and be an indicator that some fixing needs to happen.

  • What scares me is that there are guys who have *obviously* gamed it and sought to fully capture every achievement on the list.

    Adventures in not getting it?

    I have two so far: "Signed up" and "Lonely". Not my fault on that second one, Delta scrubbed my flight ;o)

Comments have been disabled for this content.