I’ve been coding AI for a long time, nav systems, state systems, behaviour trees, hybrid systems. Generally working in 3rd person action games, ocassionally more strat based games.
I can tell you right now there is no I in A.I., and nor should there be.
You see the Intelligence is the easy bit, its avoiding super human intelligence that’s the problem. AI programmers should really be working in A.S artificial stupidity. For me there’s nothing worse than sniping an enemy 400 meters away, and as soon as you fire the gun, every member of the enemy squad turns in unison knowing exactly where I am and returns fire with near perfect aim (even though I’m hiding behind a bush 400 meters away)- I’m looking at you borderlands, The enemies achieve this amazing feet in under 30 ms, despite the sound of the gun firing taking at least a second to reach them from my location.
In the original syndicate for the Amiga, due to lack of processing power the AI processing had to be done across multiple game turns with enemy agents processed every 4 to 8 game turns, this actually made an improvement over the PC version which had AI’s reacting simultaneoulsy and instantaneously to every player action.
In later games events would be stored in a queue and be delivered with a delay suitable for the type of event.
Another example of annoying omnipotent AI are the cops in GTA, once the cops are after you they are all universally aware of your exact location, there’s no obvious communication between them other than instantaneous and telepathic kind, hiding is of no use cops can see through walls, your only hope is to leave the cop danger circle. At least in GTA they made this a clear part of the gameplay, but I always wanted to hide, to snipe one cop and have the act remain a secret, I guess really I wanted to play thief, lurking in shadows.
Here is a final example where enemy AI’s know too much, thanks to A* all AI’s know exactly the most efficient route to get to you, there might be a complex maze of paths between you and them, but miraculously the moment you fired the bullet from the roof top, every enemy in a 100 meters knew the exact path to get to you . Has anyone ever seen an enemy turn wrongly up a dead end go wtf and run back the other way. No because we have too much “I” and not enough “S”.
In Syndicate Wars we actually experimented with worst path, instead of taking the best path to the target, take the worst, I had AI’s do this about half the time. This resulted in most excellent flanking maneuvers on behalf of the AI as some took the long way round to get to you and came in the back way while other agents came in the front.
At Krome for a WIP shooter I experimented in a system that maintained incomplete knowledge for each AI about possible locations for the player based of last seen location, approx player speed, areas that can be seen, and connectivity of occluded areas from the AI’s perspective. This takes a lot of CPU with a lot of raycasting but shows that if the rendering guys gives us a few more cpu cycles we can achieve interesting realistic AI.
The red areas show where the AI (the T pose dark character in the distance) can’t see, the spreading green shows where the player might be, creeping away from the last known location of the player.
Notice the green cant spread to adjacent pockets of red (hidden) areas because theres no connectivity, essentially the AI can see that the player is trapped behind the current bit of cover. Allthough not obvious in the video, moving ai’s work as well because the info in the grid is continuously aged and updated by 50 raycasts per game turn from the current AI’s location to each cell of the grid.
So to wrap up, to help me enjoy your game more please make your AI enemies dumber!