A Look At Modern Game AI
IEEE Spectrum is running a feature about the progress of game AI, and how it's helping to drive AI development in general. They explore several of the current avenues of research and look at potential solutions to some of the common problems.
"The trade-off between blind searching and employing specialized knowledge is a central topic in AI research. In video games, searching can be problematic because there are often vast sets of possible game states to consider and not much time and memory available to make the required calculations. One way to get around these hurdles is to work not on the actual game at hand but on a much-simplified version. Abstractions of this kind often make it practical to search far ahead through the many possible game states while assessing each of them according to some straightforward formula. If that can be done, a computer-operated character will appear as intelligent as a chess-playing program--although the bot's seemingly deft actions will, in fact, be guided by simple brute-force calculations."
The problem is that internally the game "knows" where you are- after all, it has to track your location.
Every play against someone in counterstrike who was hacking? Wallhacks, aimbots, the whole nine yards? There's really nothing at all stopping the developers from doing that; and in fact some older games basically did do that, just with arbitrary delays before the AI snapped on you, deliberate fudge factors on accuracy, whatever it took to make the difficulty level sane for a human player.
It's possible to compartmentalize it, of course, so it doesn't know that; but you as a player have no idea which approach they took. If the AI is incredibly good in a game, it's possible it's "cheating" and doesn't really have to deal with hidden information.
Care about privacy? Read this!
That is true. The computer is simply very different, so modeling our strengths is just as hard as our weaknesses.
It's trivial for an AI-controlled enemy to get headshots all the time. It's trivial for the AI to have complete knowledge of the battlefield and state of all items and characters on it. Humans can't do that.
It's a lot -less- than trivial for an AI to notice patterns in the enemy and exploit them. Thus the same approach tends to work 100 times against the same AI. It can't learn from its mistakes.
But then you end up with an AI that wins all the time
And we don't want that. We want an AI that wins some of the time, and that is beatable. That is, it should present us with a challenge, but the challenge can't be too great because then the game will be no fun.
So, we only want a smart-enough AI, not a god AI.
"Total destruction the only solution" - Bob Marley
Additionally, a multilevel AI helps to even out the use of CPU. You don't want to take high-level command decisions every quarter second, because that would not leave enough time for any of the lower tiers to do anything useful, and would require too much CPU. With a multi-tiered AI, you can dedicate small and frequent AI slots to low-level decisions, and hold high-level decisions for less frequent and more CPU-intensive thinking.
The problem with game AI isn't that we can't make better AI, it is that we don't make it a priority. Todays machines are powerful enough to give us good visuals but not powerful or memory spacious enough to really devote resources to too much beyond that. In Mass Effect I want to say we devoted something like 75% of the memory budget to textures, and we still had to downgrade the textures before the final ship. I don't know what the final stats were, but I wouldn't be surprised if about 90% of the budget was allocated to textures and polygons.
That's not to say if you were to quadruple the memory on today's machines that AI would suddenly improve drastically, though. Many teams don't have the resources to devote to programming, so they need to take whatever is in the package. There's room for some entrepenureal spirits to create snap in AI programs, like what Havoc does for physics. Get started now, and you may have a refined product ready for the next generation of consoles.
As an animator, I just want to point out that most anything smart you see in a game is a scripted sequence. An AI marine flipping a table and taking cover is mostly animation work. The only real code there is is a simple set of conditions that determine if the animation should be played and then some state changes to coincide with the animation. The measure of an AI isn't what kind of cool things it can do, because that's animator work, it's how quickly it figures out what it should do, and how well it figures out the quickest way to do it. When you see AI running out in the open, taking the long route to cover, getting hung up on corners or doing circles, that's bad AI.
To give credit (and blame) where credit (and blame) is due, designers choose what kind of behaviors that are possible, so they too are highly responsible for the final appearance of the AI. If a designer neglects a cover system, then it can make even an intelligent AI look stupid by just having enemies stand in harms way. If a designer includes a visceral chainsaw attack, even a poor AI that gets a kill can still seem impressive.
It neve ceases to amaze me that that while science is fiercly opposed to God or Theology infiltrating science as a process, in AI development they almost "assume" that intelligence was crafted by a God.
COMPLEX BEHAVIOR IS EMERGENT, NOT DESIGNED.
In AI development they seem to assume that the proper development of AI to to be a God and design a system or method of AI that accomplished a specfic set of goals or objectives.
Day after day evolution is a truth in science, and thats fine; but when it comes to AI development I swear they have never heard of evolution.
Your behavior is a result from a wide and largely independent array of inputs.
Your eyes don't make any decisions and aren't designed for decision making, they're input.
Your feet, lungs, and regions of your brain operate as a COMPLEX INTEGRATED SYSTEMS OF INDEPENDENT FACULTIES.
This is a much larger problem then the specifics of the task at hand. We are talking an organic development model for AI rather then a deterministic method. That is the largest flaw of Computer Science. Computers are largely deterministic devices, intelligence, isn't deterministic. A determinstic method of AI development is doomed.
You have to evolve the AI. The AI needs to know the limitations of it's organism for proper development.
Light, Dark ...
Up, Down
Here, There
Friend, Foe
Move from A to B
Find A Weapon
Assess Threat
Attack or Flee
etc...
The very process of evolving the AI api in an organic model give the model itself the ability to ignore irrelevant data by feeding abstract and generalized data up the cognitive food chain with irrelevant data dying off early in the process. If the general data is insufficent then the AI simply asks it faculties for more specific input.
OUT - I WANT TO READ HAMLET
IN - BOOK SHELF NEAR, OBJECTS FOUND ON BOOKSHELF, ASSUME RECTAGLE OBJECTS ARE BOOKS
IN - BOOKS OVER THERE ON THE BOOK SHELF (RECTANGLE OBJECTS CONFIRMED AS BOOK)
IN - BOOK ON TOP SHELF IS ABEL (Binary Search fo the book shelf)
IN - BOOK ON BOTTOM SHELF IS ZEUS
OUT - LOOK IN THE MIDDLE OF THE BOOK SHELF
IN - FIRST BOOK IS HOUSE OF M
OUT - GO BACK A FEW BOOKS TO THE LEFT
IN - FOUND BOOK HAMLET
OUT - GET BOOK
IN - TOO FAR AWAY
OUT - MOVE CLOSER
IN - I AM NEAR THE BOOK
OUT - GRAB BOOK
IN - LEFT ARM WON'T MOVE
OUT - USE RIGHT ARM
IN - I HAVE THE BOOK IN HAND
Additionally AI evolves with the organism itself (physical charactersitics influence mental development).
The reality of an AI is they need to be compiled or GROWN to fit the organism (say a terrorist or counter-terrorist in Counter-Strike)
BASE FACULTIES + ORGANISM DEFINITION + CIRCUMSTANTIAL OVERIDES + GAME PLAY OVERIDES = Source Code for AI
AI Complier then builds out an organic, almost B-Tree like info passing\storing pipelines based on the limitations.
A creature with no eyes would never have to process visual data. In that case distant objects are irrelivant except for memory storage.
My Prediction: AI isn't something that is developed, it's something that is Grown.
You define it then compile it.
-=[ Who Is John Galt? ]=-