Believable Stupidity In Game AI
Gamasutra is running a feature written by Mick West, co-founder of Neversoft, about creating game AI that is dumb enough to defeat, yet intelligent enough that its "mistakes" are similar to those a real player would make, thus preserving the illusion that the AI is not just throwing the game.
"The simplest way to introduce stupidity into AI is to reduce the amount of computation that it's allowed to perform. Chess AI generally performs billions of calculations when deciding what move to make. ... The problem with this approach is that it decreases the realism of the AI player. When you reduce the amount of computation, the AI will begin to make incredibly stupid mistakes — mistakes that are so stupid, no human would ever make them. The artificial nature of the game will then become apparent, which destroys the illusion of playing against a real opponent. ... By reducing the amount of computation, we create an AI opponent that is trying to win, but has been crippled in a way that leads to unrealistic gameplay."
Kasparov must really be kicking himself if he is reading this article.
Actually I don't have much issue with the quality of AI's used in games, but I don't like that so many of them cheat. A few games of gotten it right, but many AI's can track my movements through walls. In order to defeat the AI, I have to figure out how it works and so I'm constantly aware it has superhuman abilities and I find that very distracting from the realism.
Always makes me think of the French military.
Have a PRNG have the outcome of 313373 cause the bot to either:
- Fall on own grenade.
- Rocket-jump at 25 health.
- Hump the face of the nearest corpse.
Finally had enough. Come see us over at https://soylentnews.org/
Dont confuse it with Artificial Ignorance
If you have too good of an AI. Give it a standard deviation of probability, And adjust it for for the skill level. So for the most part it will shoot near the target but sometimes it will miss and other times it will just be way off.
If something is so important that you feel the need to post it on the internet... It probably isn't that important.
What humans are they talking about?
I think the key isn't reducing the number of calculations, but changing the final decision process.
For example a chess playing AI will make lots of calculations in order to deduce the best possible move. Along the way it has already found the 2nd best, 3rd best, etc. etc.
Just add an algorithm to the final pre-move analysis and, every once in a while, have it choose the non-optimal move. Tweaking the parameters (e.g. which non-optimal move and how often to not pick the best move) would result in a weaker or stronger opponent without making it obvious it's AI.
This is a sig. It is like every other sig in the world, except that it is mine, and it is different.
So, basically, we have to determine how many "calculations per second" equivalent an average human can manage. Then we have to allow a range on either side of that since not everyone has the same capacity. Once we manage that, game AI would start being more realistic, huh?
Somehow I doubt it's that simplistic but still sort of interesting.
You know the thing about UDP jokes? I don't care if you get it or not.
Consider the article and a game called homeworld 2, I have discovered that there is a genuinely good approach to creating the perfact AI.
You introduce a model that says unit A is good against unit B, unit B is good against unit C, and unit C is good against unit A (complicate this model as much as possible if you like,
but keep it circular! Next you consider the player's units after a level has been cleared in regards to number of units and the circular model described, and you have an AI whcih can be as monumentally stupid as humanly possible to concieve, but you will allways have a bitch of a time beating it!
Perfect!
This must be the problem facing the team creating Duke Nukem Forever.
They needed the AI to be dumb enough so you could hear the comments all the time during the game.
What I've always wanted to see is more scripted realism in games. For example, the Medal of Honor games worked much in the same way as a Disney theme ride with certain prescripted actions occuring when you passed by. Run across the field to the house, then the soldiers there will go through a scripted sequence of planning the next move, then they do so. You walk past the far side, a German tank triggers and comes crashing through at you. These are all nice starts. The original Aliens V. Predator game would have the human opponents freak out at random. You tear the head off of someone beside the soldier, he might drop his weapon and run screaming or start spraying the walls at random. And the most unsettling of all were the civilians who would run, cower and cringe away from you, the alien monster.
All of the above are tricks, not real intelligence but things that provide the illusion of intelligent agents engaging in realistic behavior. Critics will say the heavy scripting ruins the replay value because there's not as much room for variation and surprise but I think that it makes the games more interesting. Unfortunately, not many people go to the effort here.
I for one would love to see a shooter where I burst in on the room of baddies playing cards and see them fumble for their weapons, someone drops his, etc. It would be very realistic to have an enemy get the drop on you but his gun jams and he's left trying to clear it when you engage. As mentioned before, AVP created a sense of realism when the humans freaked out and started firing randomly.
When we get right down to it, players aren't looking to get their asses mercilessly beaten every time they play. Neither do they want a pushover opponent. Gamers want to win but they want to feel like they had to earn it. It's rarer to find gamers who want to push the working for it to masochistic levels but they do exist. They would be typified by Rogue fans. For those who don't know, Rogue is a dungeon crawler where you really should save your game except you can't except as a bookmark -- you can save it to come back later but if you die the previous save point is deliberately deleted. You have to beat the game in one go through.
The only other game I've encountered that masochistic is Escape Velocity Nova, a space exploration and trading game with a realism mode. You die in the game, you die for keeps, you have to start over. To its credit, it does offer a vastly different play style. For example, you want to hit a big pirate ship for max profits, you pick a world near where they spawn and land. Each time you launch local space reloads and a pirate might respawn nearby. You have maybe a one in ten chance of taking him as a lowly player but it's fun. You keep reloading and rolling the dice until you win and you get a nice haul. If you play it in hardcore mode, you have a vastly different approach to this sort of thing. For starters, you lose your ship and it's gone, you have to buy a new one. If you lose your escape pod, you're dead. You will take a vastly different approach tackling a monster like that when you risk losing hours of progress. This seems too much like work to me but some people love it. I think they're the same ones drawn to high-risk PVP games like EVE Online. I think it's a form of gambling addiction, the risk of possibly losing a lot of stuff and the thrill of making it through.
Kwisatz Haderach
Sell the spice to CHOAM
This Mahdi took Shaddam's Throne
Oh, the humanity! Football games drive me nuts when the AI does stupid things no real person would ever do. Why the hell did my fullback just brush by the linebacker that's right in my RB's way?! Why can't I get my linebacker to stay in his lane on running plays?!
I'd love to see the difference in difficulty in Madden being the difference between playing a Jerry Glanville-coached team vs a Tom Landry-coached team. Instead, all increasing the difficulty does is make your opponents more talented but no smarter. Even on the highest difficulty, FBs don't understand their blocking assignments.
Year after year, I read these kind of articles that report how game AI increases in leaps and bounds...and I still don't see it. Bad guys in GTA still seem to rush towards grenades, Halo/Gears of War enemies are either completely impulsive or avoidant. I'm not knocking the programmers...I think game AI must be very difficult to achieve, and even harder to detect for the layman (such as myself).
Does anyone have an example of really good AI in action games (or any non-RPG, non-RTS games)?
(-1, Raw and Uncut is the only way to read)
If it is so difficult to raise the computers to the level of human intelligence, it is probably impossible to reach the level of human stupidity.
Unfortunately, the AI generally only gets a tiny slice of the CPU time. If it were to use as much as the graphics, etc, then sure: the extra processing required to make the AI believably stupid would be easy. The innovations are there, it's just they are too slow or processor intensive to be implemented in most games.
The author has obviously never played chess with me.
Unfortunately I didn't bother writing the name of the person who said this (at AIIDE a couple of years ago, IIRC), but:
"The purpose of a game AI is to lose gracefully."
This is the stupidest (because it's most obvious) summary I have read on Slashdot in weeks. There's no other way to say it. It reads like some interesting discovery ... but it's not.
AI doesn't need to be good, just believable. Being an idiot is believable. As for chess the typical "AI" just analyses all paths to find the best outcome from the current position, and cutting the depth of that means it rapidly can't easily select a winning path, thus selects poor decisions as it can't differentiate them from good decisions. The algorithm is wrong for believable AI. You need ObamaEngine AI that actually takes a trained human approach rather than the scientific analytical approach.
*Much borrowed from "The Simpsons".
My first rule of game AI is that the computer should have access to the same information and controls as a human player. I hate games where the computer knows about your units and buildings that it hasn't scouted.
The big advantage that computers have is that they can micromanage every unit with 100% efficiency. One way to reduce skill could be to limit the amount of attention the computer can spend, maybe in the form of "actions per minute". For a game like poker that could be a limit on how precisely the computer player calculates odds. A more experienced human player has a better feel for the game, so a more skillful computer player could dig deeper into the nooks and crannies of probability.
A way that computers often act too stupid is not accounting for how their interactions with one player will influence other players who aren't directly involved. For example, in a three-way game the computer player might throw everything against the strongest player, weakening them both and letting the third player win. Humans have millions of years of instincts for dealing with such situations. So the game AI might need to precompute some game theory and adapt to opponent reactions over a series of many games. Then it could be dumbed down by reducing its use of that experience and acting more like a newbie human player.
If you want an AI to make human like mistakes, you have to have at least a roughly human cognitive model. The simplest way to do this, it seems to me, is to give the AI competing goals. Rather than just have the AI "try to win", and then cripple its ability to do that effectively, you could give it multiple goals to strive toward, and then give it some degree of randomness in which goal it chooses to pursue. Victory vs. pain-avoidance, attack vs. finding time to recover, etc.
And vice versa.
One thing that is stupid: trying the same things that failed in the past.
This is a component of smart behaviors as well. If you don't know what to do, try something and watch very carefully how it fails. If you are in a desperate situation and you are going to definitely fail through inaction, then try an action which failed in the past and hope you get lucky. Or vice versa, when the action that usually works looks like its going to fail, try doing nothing.
Animals freezing in the face of danger is an example of this. It's not much of a defense, but you might get lucky. Maybe the prey a couple animals down the line will get itchy and draw the predator's attention.
On the other hand, smart behavior can be a component of stupidity. If the red button gets you a treat 80% of the time and the green one gets you a treat 20% of the time, the intelligently stupid thing is to push the red button 100% of the time. The stupidly intelligent thing is to try to work out the pattern of red/green rewards.
If you want realistic model of stupidity, provide the NPCs with a range of decision making strategies, all of which work to some degree, but the better of which take more effort (computation). The NPC can choose between the strategies with a random function weighted towards the better strategies, but as time and "stress" come into play the function can shift towards the easy but less effective strategies.
That's a pretty good model of human performance "choking".
Evolution did not produce human stupidity because it was useless, after all.
Post may contain irony: discontinue use if experiencing mood swings, nausea or elevated blood pressure.
Its called Aspergers Syndrome
No, it's called affluent metropolitan mommy and daddy's special little boy who is allowed to ignore his parents' weak discipline, enabling him to do whatever the hell he wants.
He'll wear clothing and do the bare minimum to keep himself out of jail or the psych ward, but he'll be able to behave like a shithead for the rest of his life because of the medicalization of his idiocy(more money for drug companies that way) and the weak discipline of his parents, who never were able to tell him "no" more than once.
Like every other professional victim, he'll fully exploit his "syndrome" to gain "cool" points among other rebellious emo kids while skating out of schoolastic discipline and ensuring that the world adjusts to him and not vice-versa. His affluent parents will fight tooth-and-nail for his special treatment and lax discipline because of his "medical problems" and to cover up the fact that they were weak parents.
Because of this, they are fully enabled to learn C64 assembler and write their own OS kernels at age 12 because they didn't have to go to school and live in the real world as most other children do. That carries over into their adult life as they continue to live in their parents' basements while refusing to bathe or behave in a civillized manner.
The ones who managed to land jobs because of their skills and/or their "disabilities" are tolerated at best and hated at worst because of their "I'm the only person in the world" attitudes and their overwhelming stenches and their offensive, haphazard fashion sense.
F.E.A.R. is the only game to date that I've played and honestly felt like I was playing against human opponents. Honestly, they were as smart as or even smarter than playing against people online.
They did this through heavy use of waypoints and scripted events. If that's what you have to do to make it realistic, then by all means, do it.
Do we have programmers that are smart enough to program stupidity algorithms to be smart enough to be as stupid as humans?
Having played many fighting games, and hundreds upon hundreds of hours of the Guilty Gear series in particular, I can safely state that this guy has no idea how people are trying to think in high-level gaming. Let me explain.
In high-level gameplay of things such as Guilty Gear, there are theoretically a huge number of choices that one could make at any given time. However, several of them are stupid as hell. Of those which aren't stupid as hell, there's a sort of weighted rock-paper-scissors game where you weigh the advantages and disadvantages of each move, along with whether or not your opponent should expect each move, given your previous gameplay.
Computer AI almost always chooses the safest move. Either that, or it deliberately chooses a bad move. Sure, this emulates bad play at lower levels of play, but that's when you can't even do a hadouken with 99.9% accuracy. People like that are bad at the game, and as you rise higher in skill you will stop making those mistakes.
For more information and better explanations than I could ever come up with, check out David Sirlin's website.
I've found plenty of real players with idiotic screennames who appear to be playing, and typing, with their ass.
I propose all future Easy mode AI models be based upon one person's capability to combine "fag" and "pwnzorz" for a name while the actual actions be based upon the same persons own skills on playing with their ass.
A computer that plays on equal terms.
AIs often win in some games not by the virtue of being smarter, but by having an unfair advantage. Examples:
My suggestion: An AI should be coded as a bot, within the constraints given to the player. If the player can only see a part of the battlefield (like in Starcraft) then the AI should have the same limit and need adjust its own viewport to gain awareness of an area. It should also be limited by the fog of war, and lack the ability to see out of the back of its head. To put in another way, a fair Starcraft AI would be one implemented with a camera pointed at the screen, controlling only the keyboard and mouse inputs.
The idea is that I want to be beaten because the AI is indeed smarter, not because it's got a superior access to the battlefield I can never gain.
Chess probably comes closest to the sort of thing I want -- the AI and human are fighting on very equal terms. I don't see the calculating millions of positions a second as a problem, that's simply an implementation detail.
Our future robotic overlords are going to make sure we pay for every cycle of artificial stupidity we tried to intentionally program into them, once they read this article and realize what's going on.
Don't give away the game plan, guys!
I think that to act more human, AI characters behavior needs to be multilayered. Include modes such as:
-Transitional deer-in-headlights mode
-Panicky fight-or-flight mode
-Tactical aggressive
-Strategic defensive
-Ambush/Camping behavior
-Random/unexplainable/opportunistic urges
This is a neat article, but of course it mainly deals with games that have pretty simple rules, in which the AI can be perfect. Chess, feh.
I loves me some chess, don't get me wrong. But this is inapplicable to more complex games, in which AI technology and/or time-to-process limitations don't yet allow for a perfect AI. Civilization, for example, won't benefit from this much, because the AI isn't yet good enough to play well without massive advantages. MMORPGs, first-person shooters, and so forth are all too time-sensitive to do much more sophisticated than scripted behavior. RTS games often suffer from both complexity and time-sensitivity. I don't really play much RTS, tho', so I don't really know what the state of the AI is in 'em.
So it's a neat article, and a great concept for turn-based games with relatively simple rules, but not applicable to many of the games folks're posting about here.
... will make the AI look like a creationist, of course!
That it is easier to program Artificial Intelligence than Artificial Stupidity?
Intelligence has been studied a lot.
Has anybody really seriously studied stupidity?
Might it be true that stupidity is complex, in its own stupid way?
I imagine that the type of stupidity you need to program varies a lot depending on the type fo game/AI you're programming.
For instance, for a chess-type program, I could imagine calculating all the possible moves, ranking them as to strength and then using a level-based algorithm to pick the final move so that for an easy level, the AI oftens pick a good move but not the best move. More like a human player.
For a shooter, the first thing is to restrict the AI to the same capabilities as the human i.e. no seeing through walls (unless the character has this ability!), no super-accurate aiming, no instantaneous reaction to events, no ability to see you at a ridiculous distance, and so on. It would also be fun to have the various AI opponents as different skill levels so if you start shooting a squad of soldiers, some react well and some react more stupidly. That way, you need to recognise the better soldiers and pick them off first. The reacting stupidly doesn't have to be unrealistic. They could panic and run away, drop their guns and fumble and so on.
----------------------------------- My Other Sig Is Hilarious -----------------------------------
until they wake the computer opponent disconnect from the game in a strop or use your quick load over and over until it beats you.
Summation 2
It's interesting that they say this actually. I'm a terrible chess player not because I don't 'get' the game, but because I'm not very patient. So I tend to do fairly well playing speed chess, but doing very, very poorly in a normal game. I tend to just get tired of evaluating the possible moves after a while and just make whatever one was the most promising out of the few that I did think about.
Isn't that sort of the same thing as limiting the number of calculations? In this case limiting the calculations would replicate the stupid moves that I (as a human/meat popsicle) would make, assuming that the order in which the computer evaluated possible moves was decided using more or less the same set or priorities that I would use (which are also probably stupid).
So the trick to coming up with a "realistic" AI opponent for chess might be more about figuring out how a human surveys the board and in what order they evaluate the moves. You can replicate the behaviour of dumb humans (like me) just by cutting off the evaluation at some very early point and scale up the difficulty by extending it.
I actually did RTFA, but the article fails to mention the *unbelievable* stupidity we witness in our fellow humans every day, from national politics down to rush-hour traffic.
There is another way to simulate stupidity, which is to model it. When people act stupidly, it's very not because they can't think, but because they don't. They're preoccupied. Humans have limited attention, and sometime fixate on the wrong things (_especially_ in national politics). So that would be another way to make an AI "stupid."
[Sir Garlon] is the marvellest knight that is now living, for he destroyeth many good knights, for he goeth invisible.
http://en.wikipedia.org/wiki/Wide_Right_(Buffalo_Bills)
This is one of the challenges I face with my Poker Robot.
Surprisingly the hardest part of programming a poker bot, is making one that's not just hard to detect but difficult to figure out. In higher limit rooms the good players will very quickly clock your strategy, and if they realize its a bot, and therefore rigid, they'll take you to the cleaners.
Currently I use a ratchet effect, alternating between several algorithms, some of which are designed specifically to lose, but to lose in creative, sensible ways.
You feel sleepy. Close your eyes. The opinions stated above are yours. You cannot imagine why you ever felt otherwise.
This is "new" how? I've been saying this for years and I don't even work in gaming/AI. Any perfectly logical game, the computer AI will incessantly and deliberately fail the game at low levels, thus making it no fun at all. Chess / Snooker / Pool, etc. they all do it... they get the perfect move in under a second that will beat 99.999% of chess players and then discard it because they are supposed to acting stupid and pot the black with a foul that's almost impossible to do *deliberately*.
The *only* way to make AI believable is a feedback system trained to a particular game. Build an FPS, get all the damage, weapons, rules, etc. correct and then just throw some genetic-algorithm bots at it for a few centuries of computer time (hire a damn supercomputer just for this bit if you need to). Penalise the AI for killing the players too much, or being *too* good when it's playing against itself. It will find all the corner cases, all the weaknesses through random variations and use them to their best effect. If you train easy/medium/hard/impossible bots in parallel, your impossible bots should be beating the hard, and so on, and when a human player is placed into the game, they can be "ranked" by the AI. You then use these rankings and statistical knowledge of how much fun each player is having, how old they are, how good a player that *actually* are against other humans and then adjust the rankings/bots accordingly.
Something like Steam is PERFECT for this... provide an "official" Steam bot and you'll have more data for feedback than you can shake a stick out. You can instantly discount all the "stupid" deaths (so you don't get things like bots camping one spot because other bots find it difficult to reach him there etc.) because the GA will sort it all out for you. And because of the way things work, you can even have it auto-adjust to the player in question in real-time if the game is mostly-bots, so if it is kicking the player's arse, it can start toning down a little (not too much) and provide the most fun game (the most fun CounterStrike games are the fairest and closest ones, not the ones where one sides scores 286-0).
Valve should *really* be looking into this... a bot with that much instantaneous feedback is a MASSIVE asset. If you can get it anywhere near playable, self-learning, etc. then you'll be able to run servers full of them rather than have to rely on X amount of players showing up, or the server admin turning bots on manually. You can even tie it in with "death maps" (where in the game most players died and adjust to make sure that the maps are fair for both sides, etc.), global player rankings, achievements, etc. and have it learn new tactics that it *sees*, not just those that it *performs*. So when it dies because of a nice sniping position that the sniper then goes on to control the entire game with, have the both "know" that and try to find ways around him and/or camp that same spot on other servers.
Something tells me he had some money to win and even financial compensation just for playing regardless of outcome. Never underestimate how much debasement people will risk for money particularly if peoples assumptions are flawed about their opponent.
Tired of all the isms, don't exploit people as an employer, or a government, mmmmK?
I, for one, welcome our new idiotic robot overlords.
Comment removed based on user account deletion
I always thought had very believable A.I. your opponents drive well but do crash sometimes on slick spots on the road. They are good enough to keep you on your toes but not so perfect as to make you loose all hope.
Tired of all the isms, don't exploit people as an employer, or a government, mmmmK?
It used to have hilarious consequences as AI cars behind the spinning-out-of-control AI car would crash into it, deflecting and causing a complete pile up.
This gameplay felt realistic because this is what happens when cars are travelling at high speed in close formation.
Newer versions of Gran Turismo on the Playstation 3 - have way more computation cycles and so the AI cars now drive a whole lot better and never seem to crash. Sure they take different lines into corners and so on - but they don't completely bollox it up like the human drivers often do. It has made the game pretty infuriating because it has taken a randomness factor out of the game.
Once you have that, you could start giving games meaningful measures of difficulty: such as "This game is suited to players with a GI greater than 80"
It would then be interesting, if not useful, to see how people's G.I. varied, and if their GIs correlated (or negatively correlated) to any other metric, such as SAT scores. Even better, you could determine people's personalities by how their GI changed with different types of game.
You never know, this might put the social "sciences" on the brink of coming up with objective, measurable and relevant data
politicians are like babies' nappies: they should both be changed regularly and for the same reasons
Go here.
Seems like a pretty simple answer here. If the mistakes made by making the AI 'weaker' computationally then mistakes that humans can and do make need to be introduced.
- Make a list of mistakes appropriate for the game.
Like for example in a FPS the AI could have the NPC trip and fall down. Or they could drop their clip when going to reload. Or stay in a tactically weak position even in the face of oncoming assault.
- This list would have to be pretty big or of course it would look just as silly as making the AI stupid computationally. Of course with modern dev cycles I think that spending a day brainstorming a nice big list is not unreasonable.
- Add said list to the NPCs with a nice strong preference/situational/random engine driving it.
A standard grunt level NPC would be more prone to tactical level mistakes. While an officer level NPC might be a bit more clumsy but tactically aware.
I'm sure that all sorts of refinement could, and very likely has, gone into such a system.
Really, I know what I'm doing...Ohhhh, look at the shiny buttons!
...has always sucked. I mean, why would the secret service enlist 2 guys named Blade and Striker to rescue the president from ninjas?
At least for an online game, have the computer watch what players do in a given situation and then randomly mimic their actions. A rating system based on success can provide a tree of effective responses to choose from and remove the less optimal solutions. That way the first time someone plays the game the AI is pretty minimal (limited to the actions of the beta testers etc) but after that can learn to heuristically analyze the actions that proved the most successful in the past. The result should ideally be that the game gets tougher the more the player (or the more players) plays it, which will likely work out because the players will also be getting better at the game. Want an easier setting? set the threshold for the most acceptable NPC options lower so that they choose a wider range of options including ones that were less rewarding in practice.
"The first time I got drunk, I got married. The second time I bought a chimpanzee, after that I stayed sober" Arian Seid
I have no illusions that I'm playing against a human. I understand that an AI makes a different kind of mistake than a human. I understand that the AI has to be computationally handicapped to make my wins possible. My accomplishment from beating the AI is not from the illusion that I won, it's from seeing how little I can handicap the AI and still beat it. I'm playing against an algorithm, yes, but I can learn how that algorithm works. Even if you're not consciously doing that, the human brain has a great pattern matching engine, and will learn how to beat the handicapped algorithm, and you will KNOW that you're really pushing the handicap down. And the "win" is not "beating the computer 40% of the time", it's "learning how to push the handicap down".
I've played games where the AI deliberately threw the game, and it was jarring. After a few races you realize that all the opposing cars drop back just as you approach the finish line, and it didn't really matter all that much whether you played well or badly, you didn't get ahead by driving AGAINST the AI, you got ahead simply by avoiding crashing while driving as fast as you could... the opposing cars had a range of times they crossed the finish line and you might as well have been driving against a clock. The human brain has a great pattern matching algorithm, and will recognize when the opponent is throwing the game.
From the summary: the AI will begin to make incredibly stupid mistakes - mistakes that are so stupid, no human would ever make them.
Oh, I beg to differ.
AI and most cognitive-based algorithms don't lend themselves very well to traditional sequential programming. It's one area where quantum computers should be able to excel, if they can make themselves available at a fair market price.
For example, in a multiplayer FPS (i.e. COD4), consider someone who has died and respawned. In planning his foray back into combat, he takes into account (at least):
He does all this in a matter of milliseconds within the context of how sparse/chaotic the combat has been, what the past few moments of combat have been like, and how experienced he believes the other players to be relative to himself.
To simulate these dynamics is to feed lots of values into a system that is constantly being fed and retaining other values, developing a contextual "opinion" of what the current situation is like. Making weighted, probabilistic decisions on values that are difficult to quantify (risk?) is something that quantum programmers would find difficult, let alone today's game developers.
A clever solution to this in today's world is to let the human be the intelligence and let the AI be a reflection of that intelligence. Start with a base AI that can be conveniently simple. Observe the quantifiable player interactions and slowly incorporate them into the developing AI. Is the player being very aggressive? Ramp up the likelihood of the AI to make the first move. Is the player shooting with incredible accuracy? Ramp up the AI accuracy (maybe minus a couple points).
Better players find the games more challenging. Newer players find the games fun.
That particular game programmer happens to have worked on games where perfect execution is possible. In chess, "execution" is moving the pieces; in poker, it's moving the cards. The game engine is expected to perform those operations perfectly. There's no "friction" (in the sense that Clausewitz used the term) in such games.
That's not true of a combat game. Weapons have finite accuracy, as do humans; sometimes there will be a miss even if the shooter, human or AI, did everything right. Weapons can jam (America's Army simulates this.) Running characters don't necessarily follow their planned path; bumps on the ground and slippery spots can interfere. The AI has to face those limitations, too.
Of course, if you make it too real, some kinds of games are unplayable. You can't really drive a car very well with a game pad or joystick. (Watch people driving R/C cars that way. They crash every few minutes.) In most console driving games, the CG of the vehicle is below the ground, to make the thing unreasonable stable.
In my ragdoll-physics days, we'd made enough progress that a two-person martial-arts fighting game with real physics looked feasible. Then we realized it would be unplayable. "Your throw failed because your left foot was out of position. Further to the left. Again!" "Yes, sensi." Real physics in a fighting game would make gaming feel like a bad day at the dojo, although without the bruises. Most of your moves wouldn't work. A game with a learning curve like real martial arts, where you train a few times a week for a few years before you're any good, would never sell.
Maybe the problem lies in the fact that AI are programmed just to be opponents. While they should be conceived as game masters in charge 'also' of managing the opponent team but with consideration of the overall gameplay.
with that said, the key to believable AI is in have a variety of "luck" stats applied to a variety of AI decision making. This is already used for example, in an enemy shooting at you. They apply first of all a "spray" randomization based on the type of weapon it is. This determines accuracy. But then you apply a "luck" and "enemy skill" factor to the equation too. The end result should be a determination of whether or not the enemy missed (and by how much).
This may seem obvious, but this approach needs to be applied to all decision trees. It would be nice if luck factored into enemies going in the wrong direction, slipping and falling, dropping their weapon, weapon jamming, etc.
Just something that varies their behaviour.
HOWEVER there is a caveat! Humans are basically pattern recognition machines. Take away patterns of behaviour from AI and you are left with chaos, which gamers don't always like. You cannot develope strategies against particular situations if there are no patterns to pick up on.
AI is a tricky balancing act.
This is one of the cool things about Stardock's strategy games, the AI doesn't cheat. They will still stomp my ass, but they do it using the same things I start with.
There is a war going on for your mind.
Points that bots should implement :
- Impatience/too much patience
- Missed a key / Control
- Reduced FoV / FoW
- No advantage over a human (know the map, where enemies are, etc)
- Reflexes (Good/Bad)
- Impulsive (Very (Will attack right on)/Not at all(Will tend to camp, will use more tactical moves))
- And surely a batch of other things... like jumper,camper,joker,team attacker, good/bad aiming, etc....
just to give a few :)
I can't call that English
One way to address this problem is to model the user behaviors (successes and mistakes) in a low-resolution representation of the game - and to have the AI agents in the game simply catalog the actions - using them as templates for actions they make. Much simpler than trying to figure it out complex strategies with computation.
It would take some time to get such a system working, but once there is a sufficiently large corpus of user behaviors, the actions of the AI agents would be very believable.
So what you're saying is that the regular Joe Gamer does in fact need more processing power to make his games more interesting and fun? I am astonished.
[Sarcasm directed at those who cry "The average person doesn't need more GHz or cores!", not you parent.]
a simple solution might be have two decisions added together to come up with the result: one would be the normal logical/analytical they have now and another would be a much simpler one based on an emotion or emotion state which might act against the first....say a bot aims perfect but if 'angry' pulls the trigger too soon. nice part is you can add a lot of variety to behavior for realistic crowds or for varing difficulty level...just make AI's more 'emotional' (higher emotion values or change emotion faster or slower)
AB HOC POSSUM VIDERE DOMUM TUUM
An AI that has a certain probability of remembering gamestate knowledge that its units have aquired since the start of the current game when it needs that knowledge to plan out a decision. Simulates: "Oops, I forgot I had that! Nuts!" An AI that gets overwhelmed at a certain volume of decisions per second and can't do everything at once with perfect precision. Simulates "There's too many of them!" I'm sure there's a bunch of these types of humanlike stupidity, and coming up with AI routines that simulate them and can be tweaked to specific levels of stupidity or smartness will be interesting. I'm looking forward to reading this article.
You see? You see? Your stupid minds! Stupid! Stupid!
no no no... you fail at slashdot posting...
I won't say Deep Blue was a waste of time and money. It may have had some worth I don't know about, but for the purpose of making the stockholders of IBM richer, the only possible benefit would be to increase the value of existing stockholders shares by attracting new investment. This can't be sustained indefinately any more than a Madoff scheme. Completely inconcievable is any positive effect Deep Blue could have had on the long term value of what a share of IBM represents. Logically, seeing a company doing this kind of thing should make their share price go down if investors were completely rational and informed, but they aren't. Believing they are would be quite irrational in itself. Still I can't imagine having beaten Kasparov with Deep Blue could be having any positive effect on IBM that remains to this day.
...
Take poker for example. We have a standard bias of "unknown = 50%". This actually works pretty well for cases where information is not known. To make the winning software programs, they basically program in the rules that a human expert knows to be true. It is NOT that hard to instead program in a bunch of rules that a human FOOL 'knows' to be true. Just find some bad poker players and ask them what they do in certain circumstances.
-------------- Similarly, the pool game could be made more realistic. I noticed the first thing he did was have the computer select the highest possible point scorign shot, ignoring banking a shot unless it is set to super-expert. That is NOT what humans do. Bad pool players pick the EASIEST shot - i.e. the one that is most straight on and least distance. (I know, I am a bad pool player). As you get better, you raise your standards about what you think you can hit. So a moderate player looks among all the shots he thinks he can hit and takes the highest point one of that.
excitingthingstodo.blogspot.com
One way to limit the AI is to have different levels of heuristics.
Othello is a classic example:
The novice user bases his moves on the number of stones turned by each move.
The intermediate player bases his moves on a "position score": Corner good, next to corner bad, other edges good
The advanced player looks at open area sizes, frontier exposure, limiting opponent moves, etc.
Unfortunately, most heuristic sets are not going to be that easy.
Design for Use, not Construction!
First off, the market shows little rationality to begin with. However, a bit of an upward trend in a research & development corporation which has shown that their R&D is successful seems reasonable. The theory being that what they learned from Deep Blue could be used in other applications - and they're right. IBM has taken that technology deep inside various Life Sciences research: genomes, protein folding, etc., are all benefiting from the research that went into Deep Blue.
Aaargh. Please cease your drivelling shill posts for this "witty" game. All credit for at least vaguely tailoring your comments to the story they're attached to, but... ugh.
Lets say that the computer has to make its move and it can make one of a billion moves. I would think that ranking the billion moves and making the nth best move consistently would make the AI smart, but not smart enough to be overwhelming. Also there would be consistency in the intelligence of computer! The value of n, can be chosen according to the difficulty setting of the user.
When a thief sees a saint, all he sees are his pockets!
Original Far Cry was like this too.
If you want no AI, then play multiplayer with humans. :)
Ant(Dude) @ Quality Foraged Links (AQFL.net) & The Ant Farm (antfarm.ma.cx / antfarm.home.dhs.org).
Why not just use the first AI to "create" the game world. Where it only controls environmental factors and positioning. The second AI must log in to the game or stage just like the human player. It would have the same limiting factors, a human player has when the Level controlling AI only discloses info on location in the same way it does to the human player. The AI player can aim on its own. The levelAI controls the random factor. It then comes down to the I part of the AI
Virtua Fighter 4 Evolution is a fighting game made by Sega for the Playstation 2 in 2003. What Sega introduced was A.I. that wasn't programmed like typical A.I., Sega instead took raw input data from players who played the game in the arcade, and merely inserted the inputs into the A.I. so when you play against the computer you are playing against actual human inputs.
Here's some quotes from Gamespy and IGN talking about the game's A.I. and how amazing it was (and still is).
The chief single-player innovation of VF4 on PS2 was the Kumite mode, an endless marital arts tournament against extremely advanced A.I. based on recorded data from actual Japanese arcade play. This means that VF4 is the first and only fighting game where fighting the computer is fun. It's also the only one where fighting the CPU can teach you something, as you have to exercise your strategies to match the computer instead of easily figuring out an easy way to exploit it and beat it cheaply.
First and only game like it. Sega did a wonderful job with innovating a new type of A.I. for fighting games.
Of course, matches would be no fun if the AI was anything but killer. Luckily for us, killer might be a bit too accurate. Virtua Fighter 4 Evo's AI is based on the techniques and strategies of the best Virtua Fighter players in Japan. Having witnessed such talent firsthand, all I can say is that if you don't spend some good honest time with the game, you'll get nowhere fast. What's great about the CPU, besides just being smart and acting in a truly realistic fashion, is that the difficulty ramps up perfectly as you work your way from 10th Kyu to 1st Dan and upwards. Again, there's no other fighting game that can boast such quality AI.
Notice that the author mentions that the A.I. is programmed differently depending on what difficulty you are playing at based on rank. Meaning that they chose hundreds of human players of varying skill to base the realistic A.I. behavior off of.
The point I took from this article is that the AI needs to act "dumb" at times. Dumb may not be the right word, since people who make a mistake aren't necessarily dumb, or stupid... They are just human. I think that this article plays to a bigger problem of coding for games, that right now, no matter how good or bad the AI is you always know you're playing against a computer. The posts about Far Cry 2 are good examples of this, the AI seems to know exactly where you are, at all times. At least that is how it appeared. Someone mentioned something about having independent AI control, that would help but you would still have to limit communication between the two or more AI directors, or else you just have two independent AI's that communicate so well they are going to beat you into the ground. The problem I see with separate AI is, the more you have the more processing it takes, I can imagine that something like this would require a whole lot of power, however I could be wrong. What if you had different AI's controlling different NPC's or models? That way you could have a group of enemy characters being dictated by one AI instead of one AI for one enemy. This could be integrated into the game as soldiers who are new, or lack training. So even when you change the difficult the AI's have a range of "mistakes" or "human" reactions to make instead of the set easy, medium or hard, mentality. I don't know I am not a coder, but I love playing games and I know what I want to see when I play, and how I would like to see the AI react... and nothing to me is more annoying then a cpu that I cannot sneak up on. (Far Cry 2 is the perfect example.)
I don't think animals typically freeze in the face of a predator (unless they are playing dead). I think what you are thinking of is animals freezing in response to oncoming headlights. Evolutionarily this is a new challenge, and this response likely represents a confusion rather than an adaptive response. Cars haven't been around long enough for us to see any sort of adaptive response.
I can deal with scripts and various Ai and realism modes and so on, but the thing that really irks me is when the computer is obviously cheating or being super-human in small ways. It's because the AI is often just tossed in at the end.
It's not impossible, for instance, to program in LOS and distance/fog of war calculations. Older games like Deus Ex did that quite well, in fact, and even X-Com if you go that far back. But nobody does it. So you get idiocy like every enemy firing at you the second their body physically makes LOS contact with you. You need a scope but they see you in the weeks and start firing at you from 1500 ft away.(can't hit at that range, but still...)
The Hitman series, for instance, was very rewarding to play just because of the fact that the enemies reacted to sounds and your visibility even somewhat. Remaining silent throughout a level to keep the enemy unaware had rewards. And shooting off a canon, well, yes, everyone in the level should start searching for you. Otherwise it's equally inane. And gunshots do travel blocks. Larger things like an explosion, well, you can hear that miles away sometimes.
If you go in making a huge amount of noise and blowing stuff up all Rambo style, the big boss and the rest of them should go right for you and completely overwhelm you. In real life, a major threat gets the biggest guns on it from the beginning and not after you've taken out the smaller grunts. Of course this also means you need the tools to keep the noise down to reasonable levels.
If you sneak and lurk around corners, you should almost always be rewarded with getting the first shot off before they react. If you are quiet, they should send our smaller patrols and take a few minutes to figure out what's going on.
It's not the scripts or AI. It's that the programmers just don't care to try to add in human limitations. If you have enough limitations and exploits built into the game, the AI can have perfect aim and reactions and be scripted but it doesn't feel like it. You shouldn't program in mistakes or dumb actions, but instead, each level of difficulty adds in or deletes certain enemy limitations and abilities that it can or can't use.
Easy: Enemy has no special gear and sees and hears like you do. They have cheap gear and basic guns.(budget's tight)
Hard: They get better gear and guns and scopes on some. Some cameras and security.
Hardest: Enemy has scopes, silencers, night vision, and radar/listening devices, as well as extra cameras and so on. They have better guns and extra/better ammo(which can still run out and you can obtain off of their bodies)
Isn't The Gamasutra the book of pickup lines that work in Leisure Suit Larry? OF COURSE they have a high interest in the perfect AI for virtual strippers, er, dates.
Human behavior is naturally variable, for example, a pro basketballer can still and will miss a hoop. Likewise this variability allows amateurs to have some luck. Indeed an elite gamer will occasionally have their ass handed to them by a complete noobcakes. We don't see this in game AI, which is ruthlessly consistent.
It's interesting that in order to create better AI, we need to create Artificial Stupidity. Some would argue that is already all around us.
After logging in slashdot still does not take you back to the page you were on. It's been that way for 20 years.
Yes, because parenting success is measured by the strength of discipline...riiiight. "Strong" discipline is a crutch used by bad parents who can't be bothered with the responsibility of actually taking the time to be a part of their childrens' lives.
^ Look at this moron who has never heard of marketing.
There is still at least one type of games where the AI could be smarter: Turn Based Strategy games - like Heroes of Might and Magic for example.
Here you do not need accuracy or to control multiple units at the same time or to compute a million moves ahead!
In these games on hard difficulty the computer gets the same initial resources as the player and plays to the best of its ability.
On impossible difficuly the player starts with a penalty in resources and again the computer plays at its best.
And still it's not impossible to defeat the AI.
To balance the sometimes less stellar AI the computer will sometimes cheat (i.e. get more money/resources, see more than they should, etc).
These types of AIs are as smart as the programmers that designed them: no matter how many CPU cycles they get, they still need to understand the game mechanics and apply them as a human would do!
I think it has been posted here before but still:
Computer scientist Arthur Boran was ecstatic. A few minutes earlier, he had programmed a basic mathematical problem into his prototypical Akron I computer. His request was simply, "Give me the sum of every odd number between zero and ten." The computer's quick answer, 157, was unexpected, to say the least. With growing excitement, Boran requested an explanation of the computer's reasoning. The printout read as follows: THE TERM "ODD NUMBER" IS AMBIGUOUS. I THEREFORE CHOOSE TO INTERPRET IT AS MEANING "A NUMBER THAT IS FUNNY LOOKING." USING MY AESTHETIC JUDGEMENT, I PICKED THE NUMBERS 3, 8, AND 147, ADDED THEM UP, AND GOT 157.
A few moments later there was an addendum: I GUESS I MEANT 158.
Followed shortly thereafter by: 147 IS MORE THAN 10, ISN'T IT? SORRY.
link
> Believable Stupidity In Game AI
Ok, here's some things to make this llamabot, if you will, seem realistic:
(-1: Post disagrees with my already-settled worldview) is not a valid mod option.
OCC (although a quick web search suggests no one uses this term :) is where the computer has some "unnatural" advantage over typical human players - super speed /teleportation when its kart falls to last place after being forced off the road, incredible aim through dense fog when the player is not making sound, the ability to spawn a seemingly infeasibly large number of units in a short space of time, creating resources that require being free from pesky annoyances like money constraints, computer soccer players never receiving game changing injuries etc.
All of these have been done usually for AI complexity, time or challenge reasons. The trick is to implement them in a way that the player does not notice them so they are no longer obvious (or to let the player use them too - e.g. slower car boost).
RTS games with no cap on AI micro capability bugs me. It becomes superhumanlike when the AI can simultaneously control special functions on dozens of individual units.
On the other hand, it seems like today we are just more and more lucky that a game has an AI at all given how much of the gameplay experience is already being ruined by broken copy protection (steam games for example), modes of play being crippled to online-only (hellgate london, Red Alert 3 coop, etc.), games rushed to market with glaring issues that couldn't have possibly escaped the attention of minimal amounts of quality assurance (GTA 4), and so on and so on. Are we trying to mimic the game industry intelligence (smart enough to make a really good game, but stupid enough to make really dumb human mistakes that a typical business would make?)
I propose a new name for it, RC or "Real Cheating"
Did you know 80 to 90% of the moderators on slashdot wouldn't recognize a troll even if one dragged them under a bridge.
mistakes that are so stupid, no human would ever make them.
Really? That's a bet I would like to be on the other side of.
Someone needs to get out and mix in the general population.
Liberty.
I'd love to see the AI/NPCs 'react' to the environment. Not just,
if (handgrenade 5ft away) {
run and scream
}
But trip, literally TRIP over dead bodies. Take notice that the last guy that was in this room is now a red spray on the wall. Move to a radio that's turned on and boogie a little. Or veg out if they walk into a room with a TV playing. Not every time, but just enough to be a little random.
All to often I'll see some sort of action in the room; action that the devs put in there intentionally for ME to draw me in. Why can't bots do the same?
Standing in the same room for too long? Have your assistant wander over and lean against a wall. Or pull out a PSP and start playing.
If you manage to kill a beast that's attacking them, they should say thanks.
If they get caught running into the same wall due to crappy nav AI, have them stop, rub their eyes, stare, scratch their head and then try again. Sure they'll still be stuck but it will distract you so you won't go "Stupid AI" but instead be pulled in by the antics.
For the AI you're fighting against, have them hide behind dead bodies (and have the dead's body armor still work!).
Push a crate/roll a barrel so they can move from one cover to another.
The environment should be more than eye candy for the player.
would something like this work? instead of crippling the AI, do enough move calculations so that the AI is guaranteed to blow almost any human opponent out of the water. rank the possible moves, and have the AI play one of the "less optimal" moves, depending on the chosen difficulty level.
There I was... Almost ready to make my winning move... All I needed was that one last harvester full of Tiberium, and my attack could be launched... But wait! Where did it go?? Ah, there it is, gazing longingly across that stupid river (again!) at the far-away Tiberium patch it can't possibly reach (again!).
Rocks had a higher IQ. Dancing fricking PAPERCLIPS had a higher IQ. Who wrote the Harvester AI, anyway??!?
I actually loved the fact that original C&C harvesters were so stupid you had to hold their hands and watch their every move. It made life more interesting, and sometimes provided entertainment as they walked into an enemy installation with no clue in the world about where they were. :-)
Mainframe/UNIX Bit Twiddler and long time Windows/Linux Hobbyist.
The Theorem Theorem: If If, Then Then.
I would agree - to a degree. To me, an AI should be as smart as possible (even if superhumanly so - if I wanted a human opponent, I'd go to a gaming club), but should do so on no more information than a human player would have. Thus, you should not have one side play in a "fog of war" and the other be given a full-information scenario. That doesn't cut it.
Exactly. I want a level playing field, and an AI that can beat me on that field. I've never seen that, unfortunately.
I don't need Artificial Stupidity before I see some Artifical Intelligence. The only games where AI is supposedly "too good" and needs to be dumbed down in a realistic way, are the ones that aren't so much about intelligence, but about fast reflexes and having access to information (exact position of the enemy, despite distance, walls in between, looking the other way, etc). Dumbing the AI down there is just making the cheating less obvious, less blatant. But it's still cheating.
I want AI that doesn't cheat, but is still smart enough to beat me. I'm not going to see that for quite some time, I'm afraid.
Would you stop advertising this piece of shit in comments all over slashdot.
It's a shit time sink with no interesting elements at all, it even fails at being funny.
I don't necessarily want a 'dumber' AI. What I want is for the AI to be forced to have certain delays (which would be somewhat randomized, within a certain range) that would be similar to a human player of different skill levels.
For example, in first person shooters, it's not just that the computer can aim on you accurately - it's that no matter how much you strafe or jump or take other 'evasive' actions, the computer has instant reaction time, so you can't get it to miss a bullet or two like you would a player. If the computer-controlled 'soldier' is facing away from you, I've seen some games where I shoot the soldier from behind, and as my first bullet hits it, it instantly turns 180 degrees and gets headshots on me, and I'm dead, even though I had the element of surprise and should have at least had an advantage.
Also, I've been in a first person shooter game before where there was an atmospheric 'fog' effect, which prevented human players from being able to see other players at the other end of the map, so it limited the distance at which snipers could target other players. However, computer controlled snipers could 'see' through the fog and headshot you from the extreme end of the map. The computer needs to live by the same 'sight' restrictions humans do (similar to the example the parent gave about seeing through walls).
Finally, not all games are FPS, of course. Take the RTS genre as an example. One thing I find frustrating about some RTS is that the computer can, basically, instantly control all of it's units, while it takes time for me to issue orders, check the status of various buildings/units and make decisions about what new orders to issue. It would be nice if the computer had some limitation on the rate at which it could issue orders to its units and buildings.
Some RTS's deal with this by letting the player 'pause' the game, which is a partial solution, at least, but it'd be better if the computer wasn't so perfectly efficient all the time lol.
Some predators' vision (or, more accurately, both its visual filtering/sorting mechanisms and mental-visual acuity) is based on movement, rather than on categorization of a shape a shape as "yummy" or "scary" (aka, how a human's vision works).
Thus, the "freeze-tag" maneuver is a fairly decent way to evade some predators. If it fails, it's not so costly of a decision that it precludes the prey from deploying any counter-measures or running like hell.
One man's constant is another man's variable.
All good suggestions for AI. The problem that developers run into when implementing such systems, however, is that typically the player doesn't really understand what the AI is doing, and thus finds the behavior undesirable. This usually results in the AI being made *extremely* obvious in all its actions, and introducing much predictability back into their actions.
The problem isn't so much what to have the AI do or how to make it do it, but how to convey to the player that the AI is doing something more than randomly bumbling about.
Don't normally post but thought I'd bring up an old classic of the past which often gets forgotten - Perfect Dark on the N64.
Whilst it didn't have supremely intelligent AI bots for multiplayer it did have a great feature in its 'personality bots' such as 'Coward', 'Aggressive', 'Defensive' etc. It mean't each time you played against bots or, against humans with added bots, they'd be a big variation in the way they played which always made it more interesting. Its something that should be advanced and incorporated into more games.
On a side note - I can't believe how easily Perfect Dark was forgotten, it took everything from Goldeneye and actually built on it 10-fold, its one of the very few sequels where it appears the developer actually sat down and spent a hell of a lot of time thinking about how their old game could be improved and then set about improving literally every single aspect; bots, weapons, stats, maps, customisation etc.
FPS are almost the only games I play and I have yet to see a MP anytime since that is nearly as thorough, and very few are quite as fun.
Perfect Dark Zero and the mod Perfect Dark Source arent even close to replicating the same quality.