Archive for May, 2008

AI in GTA IV: Nothing Spectacular

I’ve written about AI in video games and their real-life impact a while ago, with the conclusion that it is quite basic and does not really contain “intelligence”. Now with all the hype around the newest version of the Grand Theft Auto series, GTA IV, and a development budget of about $100 million, lets take a closer look if anything has changed.

GTA is basically a sandbox game with a good story tucked on. As a gangster in a virtual city, this iteration it is Liberty City, modelled after New York, you are free to roam around in all kinds of vehicles, from bikes, lots of cars up to military helicopters and do all kinds of things - most of them illegal, of course. Everything that is forbidden in the real world becomes not only possible, but a goal in GTA, from assassination tasks, drug trafficking, gang wars and - of course - car theft there’s everything there what the villain’s heart desires (I wont go into the psychological aspects here, but it is a real concern for parents and politics, especially the German government is pressing hard to ban Killerspiele).

Image Copyright IGN

There is a wide variety of actions in Liberty City, especially when it comes to driving and destroying things. Also, such a city simulation requires believable and complicated (artificial) agent behaviour, to allow the player to suspend his disbelief. And in fact, it is an interesting and often funny pastime to just watch non-player character (NPC) interactions, their discussions and police activity.

The general pedestrian behaviour and driving AI has improved considerably over GTA: San Andreas, but there are still the odd situations where agents don’t react properly. Some mention that the cover seeking behaviour of the police has some glitches, so that policemen in search for a new cover run around the side of the police car facing you instead of the back, or that they fall off buildings when you hide just behind the edge. However, these situations are rare and are often more funny than annoying. The AI, while not perfect, does it’s job alright. All the situations where you say “Wow, I didn’t think it would be that smart” are most likely scripted though, meaning that they have been predefined by the game designers and are not (fully) dynamically generated. Another indicator for the limitations of the AI system is the density of pedestrians, or rather, the lack of it. Similar to the previous incarnations, there are not nearly enough people or cars in the streets. Admittedly, this increase in crowd density is hard to implement correctly and is probably an effect of limited CPU power.

GTA4 is a good example of fake AI, artificial intelligence that only pretends to reason. This is very common in video games, as their primary goal is not to plan realistically and beat the player, but to provide enjoyment and make (smart) mistakes. This becomes apparent in how the game handles the appearance of police units. When your wanted-level increases, there are suddenly more police cars and cops around (especially for the higher levels), that come pouring out from behind street corners or are just there when you turn around. This behaviour, while perfectly legit for a game, would be useless in real life. All the steps which are most important for navigation and reasoning in robots and “proper” AI are cropped away in video games. Therefore there is -still- no possibility that non-player villain behaviour (would that be the police then, in GTA IV?) accidentally or even on purpose crosses over into the real world from a game AI.

Side note: As you may have noticed, I didn’t have a lot time to update AI Panic very often over the last weeks. At the moment I’m quite busy at the university, I have to hand in a kind-of-important internal report in about a month of what I’m planning to do in the next 2-3 years. Once this is out of the way, I’ll have more time for the blog again. Sorry about that!