What Would You Like to See from Game AI?
jtogel asks: "As someone working in new (bio-inspired) AI research with an eye to applications in games, but within an academic setting, I often hear that game developers are not incorporating cutting-edge academic AI into their projects because it's too "risky" (they can't really predict how gamers would react), and because they don't see the point in it. As a gamer, and as someone who cares what gamers think, I am often surprised by the sorry state of current commercial game AI - it has hardly moved since the 1980s. However, maybe the problem is that no-one really knows what we want from game AI. Academics keep coming up with innovative AI technologies, but what we should we use it for? What do you think? What sort of intelligent behavior would you like to see in games, but don't at present? Which are the most obvious intelligence deficiencies of current NPCs that need to be fixed?"
Let us take the simple game of tic-tac-toe (three by three) as our game space. Not too hard. Tic-tac-toe, checkers, cognac, are popular games that fall in this category. And when you use AI to its full advantage, the computer rarely loses.
As we move towards type II games, we see games like chess or go where the game space is too large to search but still 'algorithms' (or heuristics) can be defined that prune the tree space or match/strive patterns out of raw moves. Look up tables are also useful but not really "AI" in the strictest of sense.
A full fledged type II game would be something like Warcraft or a complex computer game in which the internal engine of the playing board (server in this case) has an innumerable amount of states that it can exist in.
The NPCs and AI in games like Doom or even Halo are still fairly simple. They rely on heuristics and Euclidean distances (conceptually within the game) to overcome their opponents. If they are faced with obstacles, they deviate from their path.
Now you ask me what I would like to see. I have very finite desires and I will list them here:
- AI that learns. I am so sick of AI not keeping a log of encounters. There are many learning algorithms out there and none of them apply to full emersion games (like SWG or WoW) and its because there are too many variables--too many parameters to build the small dimensional vector fields of the Win or Learn Fast (WoLF) algorithm. This isn't the only kind of learning though, what about statistical analysis of prior opponents? "I'm a level 54 mage encountering a level 52 warrior, my odds of survival are x% based on past encounters with warriors two levels below me..." Yes, it's pre-canned statistical analysis but things like this could seriously act as a good heuristic for many games.
- If you reduce the game space or find some really good heuristic (as in the above), dumb it down. Meet the user's pleasure level. It should be a challenge but not such a challenge that victory is unattainable.
- Use your imagination. That's all I'm going to say about that one. There is no cookbook for heuristics
... learn to throw things at the user.
- Introduce long term "bounty hunter" style AI. I would enjoy an AI that sleeps and is constrained like I am. Introduce simple work parsers to our enemies. The closer you can come to interacting with me on the level of a real human, the more I'm going to like it. I know there are robots out there that understand basic human speech, why can't there be games where we receive phone calls or e-mails from assassins in real life? I know this sounds ridiculous, but make me afraid of my foe outside the game. Get in my head.
- Introduce random variables. I don't care if you have to build in mechanisms to your game that are illogical so that the AI sometimes goofs up. All humans are fallible at a certain point and if you have differing levels of predictability in your AI, the user will love it.
In the end, my opinion is that the largest deficiency for game AI is that it fails the Turing Test.Horribly.
I can easily tell that I'm not playing another human.
My work here is dung.
I'd like to see game AI that adapts to the ability of the player(s). That way, someone with little patience could start playing and see a reasonable rate of success immediately, but still enjoy things later as they become more skilled.
SIGSEGV caught, terminating
wait... not that kind of sig.
Why can't the game AI learn routes, etc. from the player? One of my biggest gripes with bots is that they either only follow a (few) set pattern, as opposed to a player displaying (to the game) many other diverse routes and locations.
Don't blame me, I voted for Kodos
The developers of Red Steel for the new nintendo wii said that they upped the AI players combat skills, because the new controller allowed faster and more accurate aiming than a traditional controller. They're point was that game AI is usually braindead to make it reasonable to the players who are slightly hindered by an unnatural interface. It's common in video games for a character to stand without any cover at the end of a long hallway. This isn't because the programmers couldn't program the AI to look for cover. Game characters aren't often built to be tactical, because they'd creme the gamer. That's my take.
FramSticks
Here is a great example of Artificial Life that generates truly unexpected behavior during runs. Perhaps this type of Alife simulation could be an inspiration for a new generation of game AI. Do not program a location and series of behavior patterns, instead make a population of AIs based on a variety of physical forms. Each form will have a limited set of possible movements within a the simulated world. It will need inputs in order to determine friend and foe, perhaps something similar to limited vision and hearing. It will need survival as a baseline goal. They will also need "food" of some sort. Perhaps the player or other, different, AIs can represent a food source. Give it some form of sex in order to reproduce its learned behavior through some genetic mechanism.
I suspect a hardware physics chip would help tremendously. But what I've seen of FramSticks was pretty damn cool. I have no idea how well it could be incorporated into AI gaming though. So this is just one of those: *shrug* hey, what about this? type of posts from someone ignorant and totally out of the field.
But I'll tell you what I don't want to see: Dynamic AI. Or at least the kind of dynamic AI we see now-a-days. I'm talking about those racing games where you're beating the hell out of the computer driver but in the last lap or so he ends up becoming completely inhuman (perhaps even "cheating") and beating you or coming close to it. Stop that shit, it's not any fun.
Rob
AI isn't currently fun. It's used mostly as a difficulty slider. And when it's doing its most impressive things, I don't see it happening, so I don't care. So I want two things from AI: I want to know what it's doing, and I want to be the cause of what it's doing.
1) If I've got a bunch of bots on my team, and I rush out like a madman, I want them to be completely suicidal as well, or maybe cover me. And I want them to say "covering you" as they do it, so I don't go sit behind a rock as soon as I hear gunfire.
2) If I'm sneaking up on some AI enemy, I want the AI to recognize that I'm sneaking up on it, and then LET ME SNEAK UP ON IT. Maybe it notices that I'm right next to something I can duck behind, so it shuffles its feet and slowly looks around back towards me, giving me just enough time to respond.
3) If I'm in a deathmatch, I want clever, flawed, fair bots. Bots that know good spots to fight from, but get up and move after a kill or two. Bots that aim poorly when I get the jump on them they just picked up their mouse in panic.
4) If I'm fighting a squad of enemies, I want to overhear their communication somehow so that I don't think they're looking through walls waiting for me. And I want them to react slowly to what I'm doing, not instantaneously.
I want my AI to be fun, and I want it to be pretty obvious it's being fun.
What if Ragnaros changed his strategy (not so that he constantly targeted the healers--because there are rules of aggro in effect in WoW) but what if he followed a markov model built off of spell/counterspell? What if Ragnaros had a little bit of unpredictability built into him?
What if he slowly remembers which characters (yes, by name) are spec'ed and drinks resistance potions according to their specialty class of magic? This would stop people from camping and grind-looting him (I know camping isn't possible in instances but guilds do the same instance run over and over with the difficulty the same everytime).
I don't know who Ragnaros is but if he has the ability to move around, why don't they have him become more frantic or hostile if he's seen the same people and remembers them?
You'll noticed that I said you will find heuristics that make it too hard (like targeting healers first or not emerging) and you have to purposely dumb it down to meet your user's needs.
I said use your imagination and make things interesting--not figure out how to make NPCs afraid of conflict
That would be my idea of fun.
My work here is dung.
But real AI has to involve some sort of learning, which is to say, letting game events "write" your behavior script. When would this be useful? The best example I can think of: Entirely stable environments that are "alive". Current games give you staged non-equilibrium situations that get triggered when your PC enters the scene. This sort of thing is just very obvious and unsatisfying if the goal is immersion. What good AI might do is this: before the game is released, the various separate settings might be populated with a bunch of artificial-life characters with specific motivations, needs, preferences, etc. (Maybe like the Sims, except more complex psychologically.) Then the game authors would let this initial system reach an equilibrium their big server. If they don't like the equilibrium that was produced, they tweak the initial AI and try again. Eventually, this will produce in a "natural" way something like a small, functioning village. When a PC enters the village, it will have been in an equilibrium which the actions of the PC will disrupt, almost certainly in unpredictable ways. That is how you give the player a true sense of freedom, like their actions really matter. Somebody like me might wonder: What would happen if I steathily killed the village miller, or gave him a gigantic horde of treasure, etc? That sort of scenario is impossible to play out in current games. And that sucks.
Now granted, writing Artificial Life that reaches an equilibrium similar to a real village, and still manages to react believably when a PC shows up may be a tall order, but I absolutely think it's a goal worth shooting for. For one thing, since many of the A-life interactions will happen in mutual isolation, the processing could be easily broken up into separate threads. Also, it's worth mentioning that this is not an all-or-nothing affair. If the equilibrium state produced at the end of several A-life generations is not exactly what you wanted, it's OK to slightly tweak the end result. The effect will still be much more convincing than the "village/dungeon/colony/factory eternally frozen in a moment until a PC triggers it."
One last bit: If you want to make AI characters seem realistic, maybe a good place to start is with Maslow's hierarchy of needs. Start there and build on that foundation. Everybody puts self-preservation ahead of other priorities, and so should AI. Ditto for all the other stuff on the hierarchy. So for example, if a fire I started destroys your hut, you will interrupt your routine to seek shelter, because this is your highest priority. For this, you may need to interact with other A-life, who might offer you a place to stay, financial help, or help with constructing a new hut - all for their own reasons, that depend on how much they like you, how likely they think you are to reciprocate, etc. If you saw me kill the miller, you will tell the other villagers, who may decide to ambush and capture you. How does a game produce that sort of behavior? Well, for one thing, planning requires some sort of awareness of expected consequences. But this should not be hard for a computer to do. It would guess that the PC would resist any attempt at capture, and it can (in the background) play out several "what if" scenarios compare their outcome to the goals of the villagers. This should show that a haphazard attack is a bad idea. Now it may look like I'm asking for a crazy amount of processing power. Maybe, but remember, we'll all have many CPU's to work with in the near future, so the ones that aren't running the game can be computing these "what if" scenarios. Also
Let's travel back to the heady first days of Ultima Online, when they had a spawn system that approximated real world birth-life-reproduction-death cycles. Unfortunately the player population couldn't FIND any mobs to fight, the spawn was too realistic and couldn't cope with the artificial nature of players screwing up their routines. Old spawn system trashed, new spawn system based on timers goes into place, problem solved.
The way things work in the real world is not nessesarily a good basis for a game.
Jonah HEX
Horror & SciFi Erotic Nudes
Um, have you played Oblivion yet? You can walk through towns, listen to people's converesations with each other, and start quests based on them...
The fact is, a mouse allows perfectly good aiming to snipe a player circle strafing and ducking behind cover, and some of them have damn good reflexes. In my CS and UT days I had no problems turning and accurately headshotting a player crouched behind some crates in a split second, and I'm nowhere near the best player out there. Or I haven't heard of anyone having problems with the bots in Noone Lives Forever, which _do_ take cover. At any rate, the mouse was perfectly fast and accurate for that.
So I'm supposed to believe that only against bots is a mouse so slow that the bot has to stand still in the open to be hittable at all? Heh.
Want a more natural controller? How about a lightgun? Those existed for ages, and some of them (e.g., Namco's) had nearly pixel accuracy. They can be moved around with a flick of the wrist, just like the Wii controller. And if holding it like that had any kind of advantage, noone's keeping you from holding some lightguns by the barrel and using the button on the side to shoot.
So, please. The Wii controller may have its advantages, but (like anything else even vaguely computer- or console-related) it also has a bunch of shameless marketroids behind it. Tho'll cheerfully claim any absurdity if it helps sell their snake oil. Use your own brains when reading such patently absurd statements.
The limit was _never_ how fast or accurate the mouse is, but how fast and accurate the player is. And if the AI was dumbed down in a lot of games, I can also tell you why:
1. Because of player skill constraints. It's not that the mouse isn't fast enough, it's that the average gamer in your target market segment _isn't_ Thresh or Fatality. You can't throw 20 perfectly skilled opponents at them and expect the average player to track them all and handily dispatch them all. More importantly, the gameplay isn't a deathmatch where you just respawn when shot either: in most single-player FPS, if you got killed, it's game over and you need to reload. You don't want the casual gamer to _need_ to save before each corner, and reload 5 times before he manages to shoot before the bot headshots him. Because that's just no fun.
So even if you do program the bot to take cover, you still must make it easy enough to kill by a casual gamer. You have to just give the impression that the bot is playing well, not actually have it play well.
Contrary to uneducated belief, making a bot unpredictable and have 100% accurate aim takes no skill at all. The first is just a matter of using a random number generator, and the second is elementary maths: take the bot's position, take the target position, set the gun to point exactly along that vector. There you go: a deadly aim that never misses. That's not what's hard to program. But what you really want it to stand out of cover at regular intervals that the player can learn, and spend several seconds missing, so Joe Average has the time to aim and dispatch him.
2. Even more importantly, because of budget constraints. _The_ reason FPS exploded in the '90 wasn't because everyone wanted to play only that, it was because they were _cheap_ to produce. You could make a profit even if you sold less copies. You could license a 3D graphics engine, hack together a few levels and a couple of skins, and call it a game. Unlike RPGs and adventures which needed lots of scripting, animations, and occasionally AI, a FPS was cheap to produce precisely _because_ it didn't bother with those.
So noone was going to spend more money on one. Definitely not on ellaborate AI and character interactions, and not on the myriad of animations needed for the bots to take cover behind corners, crates, pillars, or upturn tables when nothing else is available.
3. Because of CPU power constraints. Let me tell you how those "minimum requirements" on a game box are born: the marketting guy, yours or the publisher's, comes and tells you: "studies say that 10% of people still have a 286, so our game must be 16 bit and run on a 12 MHz 286." That's an actual q
A polar bear is a cartesian bear after a coordinate transform.