Sunday, June 3, 2007

Crowding Behavior in Games

A few weeks ago I posted about a new game we created for MTV called Crowd Magnet. The goal of that game is to drive around and allow people to crowd around your car, and then to lead them to a dance club. To make this behavior at least somewhat realistic and interesting you need to try do the following things:
  • Attract people to the rear of the car
  • Repel people from the front of the car (to avoid being run over) if close enough
  • Allow people to stand close but not to collide with each other
  • Make a person flee from the car if they get annoyed (i.e. they are no longer attracted)
I've come up with a simple demo that shows most of this behavior at the link below. This demo is not interactive - just let it play.
http://www.electrotank.com/junk/jobe/Crowd/Crowd.html

This is my final post (for a while at least) on emergent behavior. I have some more ideas to explore on the subject when the time comes.

Next to come is a series of posts on search algorithms. As applied to games of course. This means pathfding, maze solving, etc.

2 comments:

Jeff Fulton said...

Jobe, I love this stuff! I have found AI for games the most interesting and ultimately frustrating topic.

I have a couple good books (besides the chapter in yours) - One by O'Reilly, and one by Wordware. They are both substantial, but are difficult to translate to AS 2/3.0. Your Flash examples are great treat!

Thanks

MD said...

Awesome! I'm looking forward to seeing more. Keep up the good work.