mlindgren.ca

– 🕓 9 min read

Some thoughts on used games and online passes

Online passes are becoming more and more ubiquitous in the games industry. For those who aren't familiar with the terminology, an online pass is essentially a form of digital rights management designed to discourage and devalue used game sales by tying some game content to unique, one-use codes packaged with new copies of games. Online passes are a contentious issue. Some feel that they're a perfectly legitimate way for developers and publishers to ensure that they get their cut of each sale, and to reward those who purchase games new. Others see them as a violation of consumer rights or contend that they inconvenience customers who do buy new (by requiring them to type in long access codes on game controllers) while being of only dubious value to publishers and developers.

Most recently, there's been a bit of an uproar over the inclusion of an online pass in Kingdoms of Amalur: Reckoning, a single-player RPG with no online component. The pass confers seven extra quests on those who purchase the game new, or deprives those who purchased used of them, depending on your perspective.

– 🕓 6 min read

2010 and 2011 in Review

If you'll forgive me for "metablogging," I've been ruminating lately on the purpose of this website.  Up until now, I've been trying to focus exclusively on technology, programming and game design, and to minimize the subjective aspects of my connection to those fields.  Put more simply, I've been avoiding writing about who I am and what I do in favour of producing a series of mostly impersonal tutorials and critiques of technology.  There are a number of reasons for this—the word "professionalism" comes to mind as chief among them.  I'd like this website to be my public face on the Internet, and as every saavy Internet denizen should know by now, there are certain risks associated with maintaining a public persona.  I greatly admire Zed Shaw, for his personality as well as his technical accomplishments, but I have no desire to make myself unemployable as he claims to have done (albeit temporarily).

That said, trying to take a dry, detached and objective approach to creating a personal website presents a number of problems itself.  First and foremost, it's an inherent contradiction; if I don't write about myself in any meaningful capacity, then there is nothing aside from the superficial about this website which makes it mine.  I can't imagine it makes for a very interesting read, either.  Realistically, how many people will come here looking for advice on how to link GLUT?  Readership numbers are of little to no concern to me, mind you, but I can at least endeavour to give this website a purposeful existence.  To that end, I want to start writing more about personal topics, although for the sake of cohesiveness I'm going to continue to focus primarily on those aspects of my life that will be of interest to a technically-minded audience.

– 🕓 2 min read

Ethical Game Design from Gamasutra

I came across a couple excellent articles on Gamasutra which I want to share here. The first, "Contrivance and Extortion: In-App Purchases & Microtransactions" is by Adam Saltsman, creator of Canabalt, among other games. He argues that in-app purchases and so-called microtransactions are being abused by some game developers, "deliberately contriving their designs in the worst way in order to extort money from players, which is unethical and unacceptable design practice." I'll lay my cards on the table and say that I am in complete agreement with Adam.  As he does in his explanatory follow-up, I acknowledge that there are benefits to the "freemium" model, but the techniques commonly associated with that model are often used in a cynical, manipulative and profit-driven manner which I feel is harmful to consumers and the industry. Whether or not you agree, Adam's thoughts on the subject are certainly worth reading.

"Radical Plagiarism: The Ethical Lessons of the Gamenauts Controversy," by Evan Jones, is equally thought-provoking. Evan recounts the cloning of the indie game Radical Fishing by the more established indie studio Gamenauts, and adds his perspective on the cultural impact of the rampant cloning that takes place on mobile app stores. Returning readers may recall that I've previously defended the practice of cloning games. My defense excluded the cloning of smaller titles by established studios, which I've always viewed as morally questionable at best, but Evan's article nevertheless gave me pause. He provides a strong counterpoint to my own thinking on the matter, and while I'm not yet ready to reverse my position, his argument has undeniable weight. If you're at all interested in game development, both articles are well worth your time.

– 🕓 2 min read

How to link GLUT in Qt Creator on OS X

This tutorial is for an extremely specific and possibly unusual set of circumstances, but I'm hoping that it will prove useful to someone. For one of my courses this term, we're building OpenGL apps using Nokia's open source Qt framework. Qt provides some very nice scaffolding, and the Qt Creator IDE is among the best I've used, although I imagine it lacks flexibility for general-purpose applications—that is, you probably wouldn't use it to build non-Qt applications. Qt also allows one to easily write cross-platform C++ GUI applications. That said, linking procedures can be a bit different on different platforms, and as a beginner it's not always immediately obvious how instructions for Windows development translate into other environments.

In particular, I found myself having difficulty linking the OpenGL Utility Toolkit (GLUT) with my project on Mac OS X. After much Googling and some frustration, I came up with the correct way to go about it, which is as follows:

  1. In Qt Creator, open your project file (.pro) in the text editor.  Right click on the text editor pane and select "Add Library..."
  2. Chose "System Library."
  3. Locate the GLUT framework.  On my Mac, running Lion, I used /Developer/SDKs/MacOSX10.7.sdk/System/Library/Frameworks/GLUT.framework. However, it seems there are multiple different copies on the disk that you could use.  If that path doesn't work for you, just search for glut.h in Finder and you'll find a copy of the framework.  The path you enter into Qt Creator should point to a .framework directory.
  4. Qt Creator will generate code in your project file which will link to the correct framework or library depending on which platform the code is being compiled on.
  5. Finally, because Apple loves to be different, the glut.h header path is different on OS X.  You'll need to #include <GLUT/glut.h>, instead of <gl/glut.h> is usually the case.  You can use preprocessor conditional statements to make this inclusion cross-platform:
    #if defined(__APPLE__) || defined(MACOSX)
      #include <GLUT/glut.h>
    #else
        #include <gl/glut.h>
    #endif
    

That's it! If you have any trouble, leave a comment.

– 🕓 2 min read

How to reinstall OS X from a disc image using only one computer

My internship recently ended, and as such, I had to move from Calgary back to Edmonton, where I'll be completing the fourth year of my Computing Science degree at the University of Alberta. I hope to be able to write more about my internship later, but at the moment I want to share a handy trick I discovered for reinstalling OS X. The reason I bring up the move is that after I arrived in Edmonton, I found myself wanting to reformat my Mac Mini and re-install Snow Leopard, but my Snow Leopard disc was nowhere to be found. Luckily, as a semi-paranoid computer scientist with an abundance of disk space, I keep images of important discs on my network-attached storage device for just such occasions.

Unfortunately, however, the Snow Leopard disc image is large enough that it can only be burned to a dual-layer DVD. I don't tend to keep writeable dual-layer DVDs lying around, so I needed a solution which required only the disc image itself. There are a number of methods available for installing OS X over the network, but none of them seemed to work for me—perhaps owing to the fact that I had only one Mac. Luckily, I discovered that you can install OS X from a separate partition on the same disk. Here's how:

  1. First, you'll need to re-partition your disk. Open Disk Utility and select the disk you want to use. Be sure to select the disk itself, rather than one of its partitions, which are indented beneath the disk.
  2. Click the + button to add a new partition, and drag the new partition's section in the disk layout graph upwards until it's large enough to store your operating system disc image. Apply the changes. It may take some time for the disk to be re-partitioned.
  3. Now, select the new partition from the list on the left. Go to the Restore tab, and restore your operating system disc image to the new partition.
  4. Once the restore is complete, restart your computer, holding Option (Alt) at start-up. This should bring up a list of available start-up disks. Choose your new partition.
  5. You should now be at the installer, and you can re-install to your primary partition. Once the installation is complete, delete your installation disc partition to and resize the primary partition to reclaim the extra space.

That's it! In retrospect, it's completely obvious, but I haven't seen these instructions anywhere else on the web. This technique might be particularly useful for owners of Macs without disc drives.

– 🕓 7 min read

In Defense of Clones

[2015-10-10]: I made some minor edits to this post to remove some content that I now feel is superfluous. These edits did not change the substance of the post.

With the phenomenal and growing successes of the iPhone App Store, the Android Market, and the Xbox Live Indie Games marketplace, gamers have seen an unprecedented number of titles which could be described as "clones" of more successful games—or rip-offs, if you're feeling less kind. Along with these titles has come a veritable tsunami of hatred for their developers, from game critics and anonymous Internet commenters alike. The commercial success of some of these titles, such as Angry Birds,1 has shown that average gamers are happy to patronize any developer who can provide a fun experience, regardless of originality. However, any mention of a new clone on a gaming blog or podcast inevitably brings about a stunning amount of vitriol from gamers who, presumably, are upset that their favorite megacorporations aren't getting their due.

– 🕓 2 min read

What are lambdas good for, anyway?

I had a discussion today about what lambda functions are used for, how they differ from regular functions, and why they're important. I thought I'd reproduce it here, as it seems that lambdas are often thought of as confusing and obscure. The truth is that they're very simple, and also quite powerful. While they can reduce readability if used incorrectly, they do serve an important purpose, and those who understand them should have nothing to fear from them. This discussion pertains specifically to lambda functions as they're implemented in Python, but they're very similar in other languages where they're available.

– 🕓 9 min read

I'm considering switching back to iOS. Here's why.

In September of last year I ditched my iPhone 3G and switched to the Android-powered HTC Desire (which I later sold in order to purchase a Desire Z, which sports a physical keyboard.) I'm sad to report that I'm now considering switching back to iOS, after less than a year on the Android platform.  The following is an excerpt from an e-mail I wrote to a friend of mine whom I'd describe as a fervent Android evangelist, detailing some of the frustrations I have with the operating system and why I feel that I might be better served by iOS.  I've edited it slightly to make it more readable for anyone who might come across this blog.

I really want to like the Android platform, and writing this gave me no joy. There are two reasons I'm posting it here, though. The first is simply that the purpose of this website is for me to post about my programming and my experiences with technology (as well as whatever else catches my fancy.) The second is that I hope that sharing my honest opinion about Android might be helpful to anyone considering a phone purchase.

– 🕓 3 min read

Android UI/UX gripes

The week before last, whilst browsing Reddit I came across a blog by the name of "Android Gripes." The name is perhaps a bit misleading, as it's not actually a blog by an Android user hoping to spur Google into making UI improvements, as I would have expected. It is, rather, a blog by a self-proclaimed Apple fanboy (though he's recently edited his about page to remove that admission) complaining about Android for the sake of... well, complaining about Android.

– 🕓 2 min read

Android NDK Stack Trace Script

I've finally started doing some Android development in earnest, and because I have a stubborn dislike of Java, I've decided to use the Native Development Kit. The native development kit allows you to write "performance-critical" parts of your application in C or C++ code, which is then compiled to platform-native ARM or MIPS instructions. The NDK is something of an unfriendly beast; it makes interaction with most regular Android libraries very difficult, and debugging native code on Android is none too easy. Although Google provides a script which can attach gdb to your native code, I've not yet figured out how to use it properly; every time I execute it, gdb complains about missing debugging symbols and libraries and seems to be unable to do anything useful. (I don't imagine it's too difficult, but I haven't spent much time on it—I've not needed to do much debugging yet.)