Live data from Hacker News

Game AI vs Traditional AI

altdevblogaday.com

41–50 of 52 posts

Re: Game AI vs Traditional AI

#41

In single player games you have NPCs (non-player characters) and in multiplayer games you have bots (again, computer controlled characters). For instance, Team Fortress 2 has bots and Half-Life 2 has NPCs. The difference is, bots behave and mimic actual human beings. They are bound by the same rules, and have the same controls and range of motion as human players. It's hard to distinguish the difference at times, gra…

> Why is it that we aren't seeing the bot approach to AI implanted into single player games? Why aren't we facing opponents who have their own missions/agendas in single player games, who are bound to the same controls/restrictions/exploits as yourself?

It is hard to put difficulty curves on those kind of AI, and they often are implemented to use full scale path searching to find objectives, so in games with larger maps they would either need to blind to things in the distance or consume excessive processing power.

I remember the Skarr in the original Unreal would be hunting the Nali until you came around and they would attack you. Their behaviors were amazing at the time (and honestly, they still are better than 99% of game AI) in that they would dodge, feign death, hide in cover, and act as packs when in groups to fight you.

They were also distinctly harder at the time than almost any other AI opponent. So much so that I remember a tremendous amount of complaining that their AI was too good.

> I want AI that wants to do something, like another player would, that isn't concerned with me in particular, that has it's own goals/rewards instead of just fighting me or spouting dialogue at me.

The problem with this is that not enough people would pay for the complex AI. Game are about profit motive, and sadly making sophisticated artificial worlds of intelligent bots doesn't bring home the bacon. It is absolutely possible, especially in an MMO kind of setting, since you can just throw more CPU cores to do all the complex logic for whatever fancy AI your NPCs are using, but nobody seems interested.

Re: Game AI vs Traditional AI

#42

Good article. Voltaire wrote something about this: "The perfect is the enemy of the good." It's hard to keep in mind, especially when inexperienced.

My boss always tells me "Perfect is the enemy of good enough", I didn't know it came from Voltaire, but it's useful to remember a lot of the time.

Re: Game AI vs Traditional AI

#43
post #33
post #2

I have an academic and professional background in traditional AI, and I've programmed an AI for a 3D video game I made in college. My traditional AI background is mostly in applying a wide variety of mainstream machine learning algorithms, including neural networks, SVMs, and regression, to real world problems like fraud and image detection. I was somewhat frustrated when building the game AI because the best solutio…

>...which is basically applied statistics. Well, one could also say that human intelligence is applied statistics, subject to biases. When you look at how we make decisions you'll see that we either refer to past data on the subject, or on a subject related to the issue at hand. Our past data can contain incorrect information and we'd still use it, since we don't know it's incorrect. Right up until someone comes up t…

There's very little logic evidenced in human intelligence. What's there is a tangled web of heuristics that gets us to a good enough approximation of a reasonable action to keep us from killing ourselves (usually), but also brings calculation time way down compared to if we had to explicitly determine the rational action.

Irrational behavior is the norm. It's explicitly rational behavior that is artificial, and we choose when to mentally crunch the numbers of rationality based on our good-enough old heuristics.

Re: Game AI vs Traditional AI

#44

Earlier quoted context omitted.

To be fair, that designer is almost certainly correct. What benefit would your machine learning AI bring to a RTS game? Things like the AI Director in Left4Dead are the more interesting applications, but even then it doesn't apply to every type of game.

> What benefit would your machine learning AI bring to a RTS game? Currently if I understand correctly, the traditional approach is to define a bunch of actions and figure out a realistic way to choose what action to perform, tuning a state machine carefully to make sure the character is realistic as well as beatable. I can imagine this takes a lot of work. I think a huge benefit of machine learning could be to chang…

> Currently if I understand correctly, the traditional approach is to define a bunch of actions and figure out a realistic way to choose what action to perform, tuning a state machine carefully to make sure the character is realistic as well as beatable. I can imagine this takes a lot of work.

The aim is not to produce a realistic response, but fun. It's much, much easier to produce a response that isn't fun than to produce one that is, and this is the problem. Often a complex, systemic AI needs much more tuning to be fun than a simpler, more authored AI. Fun is an emotional response so it's hard to define systemically.

> In other words, the designer can now treat the character states as a black-box model, and instead worry directly about its input-output behavioural relationship, something I think an artist might have better intuition for compared to dealing with explicit state machines.

Game designers are not the same as graphic designers or artists, they work exclusively in logic. Flow charts, decision trees and giant spreadsheets are standard tools of the trade.

However, there's certainly scope for being able to take the game designer's logic to a higher, more abstract level. Being able to remove some of the micro-management would be useful. I'm not sure that machine learning helps there though, it seems more of a planning problem.

Re: Game AI vs Traditional AI

#45
post #4

It's a lot more important for AI for game characters to look real than to be real. It's easy to forget that the characters are there to support the fun of the game, and not to be fun to write or support the ego of the author. Incidentally, I thought the article was worth it for the mention of Infinite Mario and Galactic Arms Race alone-- I had not heard of those projects before.

Granted.... However, a game character getting stuck in a corner or jumping to water without a reason is not much fun. The following article illustrate the point: http://aigamedev.com/open/article/bugs-caught-on-tape/

It depends on your definition of fun. It can be hilarious!

I would guess that all of these bugs were known by the developer at the time of ship and not seen to be important enough to 'fix'. Bug #4 may even have been an authored response. As a player, that's exactly what I want to see happen when I throw in a flaming barrel.

Re: Game AI vs Traditional AI

#46
post #2

I have an academic and professional background in traditional AI, and I've programmed an AI for a 3D video game I made in college. My traditional AI background is mostly in applying a wide variety of mainstream machine learning algorithms, including neural networks, SVMs, and regression, to real world problems like fraud and image detection. I was somewhat frustrated when building the game AI because the best solutio…

It seems to me that 3D game AI is like low-latency trading: it's not about sophistication in approach, so much as fast execution and knowing how the system (e.g. the exchange or the game world) and tools work on a microscopic level.

I think one of the issues in game AI is that "good enough" is the target for commercial work, and it's not finding platonic solutions to the underlying problem. I'm working on AI for Ambition (using vanilla neural nets and backprop, to start). I'm not actually creating an "intelligence". I'm creating something good enough to pose a challenge (e.g. not make obvious stupid plays that ruin the feel). Eventually, I'd like to have agents that give me more understanding of the underlying structure of the game... but for now, something shippable is the target. With games we don't want a real human intelligence (humans get bored and leave, a few cheat) but rather a reliable player at a customizable skill level.

Re: Game AI vs Traditional AI

#47
post #2

I have an academic and professional background in traditional AI, and I've programmed an AI for a 3D video game I made in college. My traditional AI background is mostly in applying a wide variety of mainstream machine learning algorithms, including neural networks, SVMs, and regression, to real world problems like fraud and image detection. I was somewhat frustrated when building the game AI because the best solutio…

> When people want AI in video games they want the AI to be truly smart.

Yes! This statement made me think immediately of Team Fortress 2 and how impressive talented spy-players are. They're so impressive that I can be in awe of a good player whether he's my ally or my opponent. Of course, the latter also comes with some frustration.

For those unfamiliar, the spy in TF2 has the ability to cloak (turn invisible) for a few seconds as well as indefinitely disguise himself as a member of the enemy team. Subtle cues give away a disguised spy--he can't run 'through' team members of the same color like true allies can; he un-disguises if he attacks. His deadliest attack is the backstab--knife someone in the back to instantly kill.

What makes good spy players so impressive is that they've anticipated how other people behave and have thought of effective countermeasures.

A troll-ish, albeit intelligent, example of such intelligence involves a spy spraying a provocative out-of-game image on a wall at a corner. He cloaks when an enemy approaches and waits near the corner. Most new players will pause when running past the image to have a closer look. The spy then uncloaks and backstabs the player.

Example: http://youtu.be/zOR3snVKW0E?t=18s

Pre-programming this sort of behavior makes it quickly predictable, unless the AI has enough variety in its 'bag of tricks' that it would take a long time to learn it all...just like playing against a skilled opponent for a long time. I'd love to see the day when game AI could discover such behaviors on its own, searching for new ones when old techniques become too common.

Re: Game AI vs Traditional AI

#48
post #3

I've just had my first course in AI, and being interested in games, I was curious to see how the reasonably specific, theoretical techniques we were taught could fit into game design. This was a reasonably interesting example, but I think I'd be more interested in some specific applications, although I appreciate these might be jealously guarded secrets...

http://web.media.mit.edu/~jorkin/gdc2006_orkin_jeff_fear.pdf Here's a (pdf) paper presented by Jeff Orkin, lead AI programmer on F.E.A.R, at the 2006 GDC. He talks about how he made the enemies behave in a human-like manner using a technique called Goal Oriented Action Planning. http://web.media.mit.edu/~jorkin/ This is his MIT student page.

Re: Game AI vs Traditional AI

#49
post #21
post #2

I have an academic and professional background in traditional AI, and I've programmed an AI for a 3D video game I made in college. My traditional AI background is mostly in applying a wide variety of mainstream machine learning algorithms, including neural networks, SVMs, and regression, to real world problems like fraud and image detection. I was somewhat frustrated when building the game AI because the best solutio…

One approach that has been more successful and easier to integrate than machine learning is Monte Carlo based systems. That's what the latest Go AIs use and they are making big strides. It's powers various card game AIs, here's the developer talking about it: http://hfog.blogspot.com/2010_01_01_archive.html Though this absolutely brutal Race for the Galaxy AI was generated using machine learning: http://www.keldon.ne…

A hat-tip for mentioning Keldon's RFTG AI.

It's surprisingly brutal and even against good players it wins a good proportion of games. It does though show the downside of the machine learning and neural net approach (it uses a trained neural net) in that it can take a very long time to train the network and when it exhibits unexpected behavior it's almost impossible to tell why.

For those interested, all the source for the AI is on Keldon's website (linked above) - the only thing missing is the art for the cards at the publisher's request.

Re: Game AI vs Traditional AI

#50

Earlier quoted context omitted.

I hear you. I have a similar background like yours and I had a huge disappointment when I broke into the game industry 2 years ago. But I am not agree with you in the sense that an statistic approach is not possible. There are so many opportunities but the reality is that game designers don't want that to happen. The main problem I have found in this regard is the fact that designers love to have control over the beh…

a veteran RTS game designer and his response was very heart breaking, he just told me that Game AI was good enough and that "people" wouldn't care about a better AI This makes me sad.. most RTS games have such terrible AI it often pains me to play them (and I love RTS games). Yeah yeah everything is moving towards online multiplayer, but I can't be the only person who would pay extra for a good single player experien…

[deleted]
Post reply on HN