Article
NetworkFlow

Game Design 2.0: Learning from Social Networks

Alex J. Champandard on June 15, 2007

Cast your thoughts back a few years… Picture the Yahoo! Directory, with many categories but all submissions get pigeonholed, clumsy browsing and no search, let alone a way to subscribe. This structure didn’t work so well in the end did it? Still, that’s what most game developers use every day to organize their character behaviors.

A finite state machine

Game Design 1.0: Behaviors as States

Most game engines have their own big directory to manage the behavior of actors. It’s typically a hierarchical finite state machine (HFSM) or scripts of nested Lua functions. So instead of web-page categories, you end up with large trees of states.

This approach of creating behaviors has certainly worked for many generations of games:

Advantages
It’s easy to build simple decision making and control systems. The designers have ways to specify the next “state” or “script” to be executed.
Disadvantages
The whole tree gets complicated very quickly — and it’s particularly a problem dealing with multiple concurrent states and behaviors.

States are a useful concept for describing behaviors; this actor is acting afraid or happy, running or walking. But as soon as you decide to use states to organize behaviors in a tree-like structure, things get tricky…

  • Where do you put behaviors that fit into multiple states?

  • How do you categorize states in relation to each other?

  • Can you handle the logic for multiple concurrent behaviors?

Some of you may be resigned to the fact that building behavior logic is hard, and would no doubt claim that’s the nature of game development. But in this era of Web 2.0, social content and emergent complexity, there’s no doubt a better way. Here’s an idea:

A scheduler running behaviors

Game Design 2.0: Behaviors Networking with Tags

  1. Build your engine for concurrent behaviors, as blog posts around the web.

  2. Don’t try to sort them into categories/states, just label them with tags!

  3. Provide a central feed for tags and list current popular tags — like Technorati.

  4. Use the feeds and popular tags to make new blog posts, if you want.

It may well sound easier than it is, but it’s something to think about! The majority of the articles here at AiGameDev.com are geared towards this goal, and make a lot of sense from this new perspective. For example, one possible solution to implement this in games today involves using a central scheduler in the role of Technorati, making observers for RSS feeds, and having many modular behaviors instead of bloggers that can decide when to make a new post.

Discussion 0 Comments

If you'd like to add a comment or question on this page, simply log-in to the site. You can create an account from the sign-up page if necessary... It takes less than a minute!