How to teach Game Programming


I’m generally unimpressed by specialized game courses at university. Generally I’d be more inclined to trust a traditional CS or CE degree with a strong side-interest in game programming over a specialized game course.

One of the problems is that many game courses either don’t teach any low-level programming at all, or teach it poorly.

Obviously we still all use C++, so it’s crucial that you understand low-level programming, and every so often you actually need to know it for real, and not just because the language is too low level for you (e.g. you definitely need to understand cache misses, maybe TLB misses, definitely know what virtual memory is, etc.). The problem is that many game courses teach C by forcing you to use it for game programming, but most game programming just isn’t that low level – say 99% of it is high level application code. Learning low-level concepts by writing games is thus an exceptionally poor strategy. You’ll eventually pick it up, but it’ll take a lot longer than if you learnt it by writing something that was 100% low-level instead.

So courses that teach low level programming concepts by having their students write all their games in C/C++ are probably not giving them the kind of experience they need with low level concepts. They’re probably doing a better job than courses that omit C entirely and just use Java or C# or something, but the difference between the two is probably a lot less significant then they’d like to think.

The other downside to teach C by programming games in it is that C is not a very productive language, so your students will take much longer to get anything done, which means they’ll get less practical experience with actual game concepts.

The solution is to admit that low level programming and game programming are two skills that are only occasionally overlapping and the best way to teach both is to give up on the idea that games courses should just do things that are strictly related to game development. Have them spend two months implementing a simple OS (or parts thereof) and they’ll learn more about low-level programming then many years of just game programming will teach them. Then the rest of the time they can use C# for the actual game stuff, which means they’ll get more stuff done, and learn more game development topics in the same time.


One thought on “How to teach Game Programming

  1. I think our major is doing some of this… Freshmen and sophomores use C# and AS3 almost exclusively, mostly for algorithms and prototyping. There’s one C++ class that’s usually assigned 2nd or 3rd year. We hardly get past function pointers; there’s not nearly enough time to get down to the nitty-gritty until we can take elective studies (most are borrowed from the CS department)
    We end up with an eye for design (but not art) and a mind for algorithms (but not efficiency).

    Which is why I’m taking a CS minor now, just in case.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s