Advertisement
Roundups

40+ Fantastic Game Development Tutorials From Across the Web

by

The indie gamedev community is awesome: so willing to share tips, tricks, advice, and even detailed tutorials explaining important concepts. Here, I've rounded up a few dozen of my favourite examples from around the internet, covering coding, maths, game design, and being a game developer. This is the quality of content that we aspire to achieve at Gamedevtuts+.


Coding

Using Potential Fields in an RTS Scenario

Best Game Development Tutorials

This AI tutorial takes an interesting approach to pathfinding. In the image above, suppose that the green dot is a computer-controlled character, the white E is its target destination, and the brown blocks are impassable mountains. The basic technique is to make the target generate a positive field and the mountains generate negative fields - as if they were positive and negative electric charges. The fields are then added, as represented by the varying shades of blue, and the green dot simply moves to the adjacent position with the highest "pull" (i.e. the lightest shade of blue).

The tutorial dives in to much more detail, showing how to deal with enemy units, local minima, and other situations.

Conway's Game of Life for Curved Surfaces


A demo of the final result.

You might have seen Stephane Beniak's tutorial about the classic Game of Life here at Gamedevtuts+. This tutorial, by Mikola Lysenko, discusses an interesting new variant: a generalisation of the Game of Life for smooth spaces, applied to arbitrary curved surfaces.

Mikola doesn't just give the steps required to recreate his version; he dives deep into the maths and concepts required to understand it, gradually building up to the final impressive result.

Create an Infinite Scrolling World (Starling/Nape)


Video of the live demo.

This is a short and simple tutorial, intended to show off the power of the Nape and Starling Flash libraries, but I really like the result! The actual logic behind the creation of the terrain is easy enough to understand that you could port it to most other gamedev platforms.

Simulate Water Surface in LibGdx


Video demo of the final effect.

This tutorial, by Rahul Srivastava of Rotating Canvas games, would perhaps go nicely with Michael Hoffman's Dynamic 2D Water Effects tutorial which we published earlier this year. Rahul explains how to use OpenGL shaders, a sine function, and random noise to create this neat water surface effect.

Understanding the Fisher-Yates Shuffle

Best Game Development Tutorials

Okay, this is really more of a straight CS tutorial than a gamedev-specific coding tutorial, but I couldn't resist including it here because I love the presentation. The shuffling animations help to illustrate what's already a clear tutorial.

Silhouette Detection

Best Game Development Tutorials

This article explores one question: how can we detect the silhouette of a 3D object? As is often the case, the first step is to clearly define the problem; once this is done, the tutorial walks through the specific problems and offers some sample code. By the end, you can take an arbitrary 3D model and generate its 2D outline.

Polygonal Map Generation for Games

Best Game Development Tutorials

This is one of my favourite tutorials of all time. It's comprehensive and very well explained, with plenty of diagrams and demos. Even if you have no plans to generate maps for your games, I think you'll find it a fascinating read.

Collision Detection and Response in N

Best Game Development Tutorials

Remember N? It's a classic Flash platformer, originally released in 2005 and eventually ported to Xbox, DS, and PSP. It really caught people's attention at the time for it's super-smooth motion and collision mechanics.

In this two-parter (part two is here), the developers of N explain the basics of their collision detection systems. If you want to take this further, Shiu wrote a tutorial for us about the same concepts.

Pixel-Perfect Collision Detection

Best Game Development Tutorials

The simple AABB (axis-aligned bounding box) method of collision detection is suitable for many games, but in my experience game developers often want to get to a pixel-perfect method as quickly as possible. This tutorial is fairly specific to XNA, but it explains the concepts clearly enough that you could implement them in your 2D development platform of choice.

2D Metaballs in XNA


Demo of the final effect.

This lava lamp-style effect is often used to render liquids, and is fairly straightforward to render with code - no custom shaders required! This tutorial is in XNA, but is easy enough to port to other platforms.

Higher-Order Fun: Implementing 2D Platformers

Best Game Development Tutorials

Rodrigo Monteiro breaks 2D platformers into four types - tile-based (pure), tile-based (smooth), bitmask, and vectorial - and succinctly explains how motion can be implemented in each case. This manages to be both an excellent introduction to the concepts and a great reference guide.

Lode's Computer Graphics Tutorial: Raycasting

Best Game Development Tutorials

It might not be strictly necessary to write your own raycasters these days, thanks to the likes of Stage3D, Unity, and OpenGL, but I think it's still interesting to learn the basic concepts behind rendering a room in 3D. This tutorial explains the rough idea, shows you how to build the solid-colour raycaster pictured above, and finishes by implementing a Wolfenstein 3D-style texture renderer.

Game Programming Primer

Best Game Development Tutorials

You probably shouldn't try to read this on your smartphone. This huge article by Randy Gaul is a wonderful primer, filled with great advice for programming games in C++.

Make Your Own RPG With the Source Engine

Best Game Development Tutorials

The Source Engine is best known for powering FPS games like Half-Life 2 and Team Fortress 2, but in this tutorial, Ben Evans shows you how to create a basic RPG prototype. He explains how to create quests, add dialogue, and set up an ending condition.

The Pure Advantage: Advanced Racing Game AI

Best Game Development Tutorials

AI for computer-controlled opponents shouldn't necessarily be designed to make them as competent as possible; racing against a set of perfect drivers would be no fun. Here, Eduardo Jiminez explains the "rubber band" AI in Pure, designed to keep the game feeling competitive, and therefore exciting, by preventing the player from falling too far behind (or getting too far in front!).

How to Program Independent Games

Best Game Development Tutorials

In this 80-minute talk (half presentation, half Q&A session), Jonathan Blow of Braid and The Witness gives the advice he would have given himself as an undergraduate game developer.

A* Pathfinding for Beginners

Best Game Development Tutorials

There are many A* pathfinding tutorials online, but I believe this is the best one to start with. Patrick Lester explains the method quickly and directly, with tips and clarifications, and even provides source code and some suggestions for what guides to read next.

Fix Your Timestep!

If you have a decent grasp of the maths of mechanics, coding a physics simulator seems like a simple task. On paper, it is. In practice, the discrete nature of any code simulation means you'll run into various problems - for instance, if your simulator's delta time doesn't match your game's display rate, you'll find that the simulation runs faster or slower than you intended.

In this brief but important article, Glenn Fielder explains why the problem occurs, and how to fix it.

Everyone's Platformer

Best Game Development Tutorials

Okay, this isn't technically a tutorial, but it certainly deserves a place here. Chris DeLeon has provided a three-level platformer game, complete with a level editor and full source code. As he puts it:

This is not so much an open source project as it is an unusually expansive pile of connected demonstration/example code, though intended to encapsulate as much or more about game design (user experience, tuning, system relationships) and game production (development tradeoffs, efficient authoring, content pipeline) as it is about the underlying programming.


Maths

Quaternions

Quaternions are a convenient way to represent rotations in 3 dimensional space. [...] The main advantage they have over Euler angles is that they can be interpolated without looking awful. You can compose rotations by multiplying quaternions, much like with rotation matrices, but a unit quaternion is always a rotation, while a 3×3 matrix could be a number of other types of (possibly undesirable) transformations.

This three-part tutorial from Twisted Oak Studios explains the maths of quaternions. This isn't a paint by numbers post; it assumes you have an interest in learning about these kind of concepts, rather than just putting them to use.

Fun With Convex Polygons

Best Game Development Tutorials

There's a wealth of great content on Paul Firth's site, but this is a post I keep referring back to: a couple of useful methods for working with convex polygons (that is, straight-sided shapes that don't double back on themselves).

Paul explains how to figure out the area inside a polygon, and how to detect whether a certain point is inside a polygon. Hardly exciting, but frequently handy.

Vector Maths - A Primer for Games Programmers

Best Game Development Tutorials

Another great guide from Paul Firth. This time, he tackles pretty much everything you need to know, as a game developer, to have a good grasp of vector mathematics. I use this as a reference (it's neatly organised!) but I believe it would serve as a decent introductory tutorial as well.

Linear Algebra for Game Developers

Best Game Development Tutorials

David Rosen of Wolfire Games goes through the basics of vectors and matrices in this four-part series, with plenty of game-related examples in both 2D and 3D.


Game Design

The No Twinkie Database

Best Game Development Tutorials

Like TVTropes for bad game design decisions. Ernest Adams has been keeping track of "game misfeatures" for over a decade (both from his own experiences and based on suggestions by readers), and has compiled them into a categorised list here.

Learning to Love Enemy Attack Patterns

Best Game Development Tutorials

Big bosses in RPGs should be tough, but it's no fun if they're impossible to beat. Here, Solitayre explains how to structure an enemy's attack patterns to make for memorable, rewarding battles.

Designing Around a Core Game Mechanic

Best Game Development Tutorials

In this article, Charmie of FunstormGames passes on Wil Mozell's deceptively simple game design methodology: the "Core Diagram" shown above. As the post shows, this applies surprisingly well to many different games, so it offers an interesting way to think about design.

11 Tips for Making a Fun Platformer

Best Game Development Tutorials

It's hard to categorise this post: it contains tips on coding, story writing, user interface, and teamwork, all centred around the topic of making platform games. If you are planning on making a platformer, do read this, whatever your role!

The Chemistry of Game Design

Best Game Development Tutorials

Can gameplay skills be broken down into a series of "atoms"? Danc says yes, and presents his method for doing so here. In this way, a game's mechanics can be given a clear structure, which can in turn be used to design the game to keep the player moving forward, always learning or improving.

If you enjoy this, check out Danc's presentation The Princess Rescuing Application, too.

I Have No Words and I Must Design

Note: See also the later revised version of this article (PDF).

As game designers, we need a way to analyze games, to try to understand them, and to understand what works and what makes them interesting. We need a critical language. And since this is basically a new form, despite its tremendous growth and staggering diversity, we need to invent one.

Principles of Virtual Sensation

Best Game Development Tutorials
The overlapping, interacting states of Super Mario's controls.

Steve Swink, author of Game Feel, discusses the concept of virtual sensation - "the thing that makes your mom lean left and right in her seat as she tries to play Rad Racer" - examining seven different ways of affecting it. To help demonstrate his point, he uses examples of popular games, and simple playable demos that focus on the controls.


Aesthetics and Presentation

Juice It or Lose It


Watch the presentation.

Martin Jonasson and Petri Purho demonstrate how a plain Breakout clone can be made much more fun by adding "juice" - little touches of polish. Be sure to check out the various links posted under the video on YouTube.

Legend of Dungeon - Dynamic Lighting on Sprites

Best Game Development Tutorials

Thanks to normal mapping, these simple 2D sprites can be shaded lit dynamically based on the light hitting them. Take a look at the skeleton in the pirate hat, in particular: one side is lit blue; the other is lit red. It's a great way to combine retro pixel art with the power of modern 3D gamedev environments.

Dynamic Lighting and Shadows


Demo of the effect.

Inspired by the above post, Matt Greer devised a method for adding dynamic lighting and shadows to 2D pixel art. This tutorial goes into more detail then the former, explaining the maths behind the effect with some sample code.

Incredipede's Ink-Bleed Fade


You can see the effect in the menu transitions in the first few seconds of this video.

Colin Northway explains how he created the ink-bleed fade effect for menu transitions in Incredipede. Aside from explaining the cool effect, this post also highlights the importance of trial and error.

A Layman's Guide to Projection in Videogames

Best Game Development Tutorials

I'll quote from the author, Radek Koncewicz:

Projection basically means taking a three dimensional object and displaying it on a 2D plane (i.e., a screen). There are various ways of accomplishing this, and each technique has a deep impact on a game’s look and mechanics.

Before reading this article, I had never really noticed projection in games - I could tell an isometric game from a true 3D game, sure - but as this article shows, "isometric" didn't really mean what I thought it did...

2D Game Art for Programmers

Best Game Development Tutorials

This is a collection of stellar step-by-step guides to drawing cartoon artwork suitable for games, without needing to actually draw anything. The guides are so simple that it feels more like assembling artwork than creating it - and I mean that as a compliment.

How to Choose Colours Procedurally

Best Game Development Tutorials

We've talked about palettes at Gamedevtuts+ before: both how to manually choose them and how to let players customise them. This article explains how to let a computer choose a suitable palette for your game - great for anything with procedurally-generated levels!

So You Want to Be a Pixel Artist?

Best Game Development Tutorials

Although this tutorial is over a decade old, it's still a great guide for programmers with no artistic ability whatsoever to make some decent-looking pixel art quickly.

If you're more artistically inclined, check out Derek Yu's Pixel Tutorial instead.


Being a Game Developer

How to Be an Indie Game Developer

This is my go-to article for aspiring indie game developers that want to know what they're getting in to. It's full of great little quotes like this:

Game design and level design are different skills: one is designing a system and the other is working out how to present that system in the most rewarding way.

Fun fact: we actually used this article as one of our reference guides when coming up with the plans for Gamedevtuts+.

Finishing a Game

Best Game Development Tutorials

In our recent poll, the most commonly selection for the hardest part of developing a game was "finishing it".

Here, Derek Yu lists practical advice for actually getting games done. (The post also doubles as a motivational kick up the rear!)

Visualizing the Creative Process

Best Game Development Tutorials
"Creativity is like a snake swallowing a series of tennis balls."

Danc explains his creative process for creating excellent games, including the all-important prototyping process (and the equally important getting-rid-of-bad-ideas process).

Lessons Learned From the Indie 'Meatgrinder'

I sat down with devs. We talked. I played their games. They told me about their relationships, their trials and their bright hopes. Honestly, it was heartbreaking. So many great games. And yet so many broken business models, broken production techniques and broken philosophies of what matters. Eighty percent of the games being shown will not make back their development budgets.

This is more a guide to what not to do; Danc shares the most common (and devastating) mistakes that indie game studios make. Learn from others.


Don't forget: besides publishing gamedev tutorials here, we also often share the best of the web on our Twitter, Facebook, and Google+ channels. I've also set up a Google+ community for sharing articles like these. If you know of a great tutorial that I've missed, let me know!

(And, naturally, if you've written one of the articles featured above, consider this an open invitation to write for us...)

Related Posts
  • Game Development
    Art
    Designing 3D Environments: Lights, Camera, Polygons? Action!Environment 3d 400
    The jump from 2D to 3D isn't just big—it's trans-dimensional! 3D can be daunting, but let's try to ease the painful transition with a solid game plan for getting your game ideas into a 3D space. We're not covering the specifics of creating 3D objects here, but we will be discussing tips for putting these into a game scene and getting the most out of them visually and in play.Read More…
  • Game Development
    Roundups
    15+ Analyses, Post Mortems, and Game Design DocsPost mortems analyses game design docs 400px
    You can't beat learning from personal experience... but learning from someone else's experience is often less painful. In this post, I've collated some of my favourite post mortems, game design documents, and design analyses for mainstream games, from Mario, Sonic, and Zelda to MGS2, The Sims Social, and Portal.Read More…
  • Game Development
    News
    Gamedevtuts+ Mission StatementGamedevtuts birthday mission statement 400px
    As part of the celebration of our one-year anniversary, we thought we'd take a look at the kinds of articles we plan to commission in the next 12 months. Internally, we've been debating the merits of one kind of article over another, who our readers are and who we should most often target, and what exactly is it about Gamedevtuts+ that we love so much.Read More…
  • Game Development
    News
    One Year of Gamedevtuts+!Gamedevtuts birthday celebration 400px
    We're proud to be celebrating the one year anniversary of Gamedevtuts+ today! Over the course of the last twelve months, we've published over two hundred gamedev tutorials, we've welcomed many new members to our team (including a new editor), and we've learned a lot about making games together. In this post, we'll take a look back at our first year...Read More…
  • Game Development
    Roundups
    30+ Gift Ideas for Game Developers and Game DesignersGift ideas for game developers and game designers
    Don't know what to put on your Christmas list? Got no idea what to get a game designer pal of yours? Let us help, with this bumper collection of gift ideas for gamedevs!Read More…
  • Code
    News
    Have You Checked out Gamedevtuts+ Recently?Letter
    We wanted to give you a quick update on the latest member of the Tuts+ family — Gamedevtuts+! Gamedevtuts+ is dedicated to teaching game development, with tutorials, tips, and articles about level layout, game design, coding, and working in the industry. We walk you through how to create games from scratch, go into the theory behind game development, level and character design, discuss working in the industry, and much more... Read on to find out more about the all-new Gamedevtuts+!Read More…