1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Best PC Game AI Ever - Maybe Firaxis Can Hire Their Coders as Consultants?

Discussion in 'Civ5 - General Discussions' started by Mark the Bold, Oct 27, 2010.

  1. Mark the Bold

    Mark the Bold Warlord

    Joined:
    Oct 4, 2010
    Messages:
    149
    First off, let me say that I love Civ5. Already logged 100+ hours and still not bored.

    There are well over 50 "Civ5 / Firaxis / Shafer is worse than Hitler" threads currently on this forum. Kindly ask you post your hate on those threads. This is a constructive thread. Please and thank you.

    As the title suggests, since AI criticism is a big part of the Civ5 hate threads, what PC game do think had the best AI ever.

    My choices:

    (1) GalCiv II - Finally a game with AI that would anticipate your invasion by noticing (duh) your large buildup of forces on their border. Also, there actually were EVIL civs who would behave *gasp* evilly. Diplomacy mattered in this game. If you declared war against everybody all the time, you would die. Picking your battles was important.

    (2) Homeworld II - Before they defanged the AI to appease those lame people who suck at video games, the pre-patch 1.1 AI was devious and simply awesome. It would bait and retreat, send raiding fleets to your resource extraction efforts while you were away, and send their main battle groups on full scale attacks when they had significantly weakened you. They actually counter-attacked. No joke.

    (3) Warcraft III - Let's face it, the Insane settings of the AI is a challenge to even the most battle hardened Warcraft III players. Blizzard has always been great at this.

    (4) X-Com: UFO Defense. For all you old timers out there, this game was awesome for turn based strategy. You actually hated the AI in this game. It hated you too.

    (5) Perfect Dark (N64- Not PC I know). Not a strategy game, but a game with awesome AI nonetheless. The 'PerfectSims' were tough as nails, and possessed herding and hunting tactics.

    Personally, I think AI is the most interesting and challenging part of computer programming and I like to give props to game companies that do it right. Lets hear your thoughts folks.
     
  2. sleepingbear

    sleepingbear Warlord

    Joined:
    Aug 18, 2008
    Messages:
    104
    As I recall Gal Civ II has a feature were you could upload completed games to the developers to help "teach" the AI. Its been a while since I played it.
     
  3. BobDole

    BobDole American Leader in Civ VI

    Joined:
    Mar 1, 2010
    Messages:
    811
    Eh, Warcraft III's AI was pretty bad IMO, a step down from their AI in Starcraft. I remember using the reveal map cheat once to see what it was up to and watching it lose its hero while creeping. It overall wasn't that great and was quite beatable. Probably better off pointing out SCII's AI (yeah, the Insane AI cheats somewhat and it has godlike micro, but they are pretty decent overall tactically).
    A FPS is a pretty different type of game, and the AI really wasn't smart or anything, it typically grabbed a shield if it could and then came right after you. They were pretty easily outsmarted, and you could usually just camp in a room if you wanted and mow them down when they walked in. They were primarily good because they always knew where you were no matter what. Same with Dark AIs, which were primarily good because of how ridiculously cheap they were, not because of tactical genius.

    Can't really comment on the other games. I still think the AI will continue to get better, this patch brought some improvements so there's some hope yet.
     
  4. Jharii

    Jharii King

    Joined:
    Sep 3, 2007
    Messages:
    696
    Location:
    Walled Lake, MI
    Aye. And this is one of the most compelling reasons why I believe that Elemental will ultimately succeed.
     
  5. Jharii

    Jharii King

    Joined:
    Sep 3, 2007
    Messages:
    696
    Location:
    Walled Lake, MI
    Mark, are you familiar with memetic AI?
     
  6. LDiCesare

    LDiCesare Deity

    Joined:
    Dec 22, 2005
    Messages:
    2,612
    Location:
    France
    Galciv (I and II) AI was good but the game was designed around it to be honest.
    Also, Elemental by the same coder has an ai worse than that of Civ V by miles, but the game is much more complex than either Galciv or Civ (tactical battles, spells..).

    Considering Galciv AI coder is also the CEO of Stardock, and he'll be busy coding an ai for Elemental during the foreseeable future, it's unlikely he'll touch anything about Civ 5 for quite a while. However, in case Elemental ai was somehow fixed within 6 months time, it's probably not unreasonable to believe he might actually code an ai for Civ 5, but as a mod. I doubt it, and I also doubt that he could do much since he'd need C++ access and the ability to spawn threads to do it his way, and the current restrictions on modding Civ 5 make me believe all of this is quite unlikely to be available for some time.
     
  7. sleepingbear

    sleepingbear Warlord

    Joined:
    Aug 18, 2008
    Messages:
    104
    It would be great if more companies used an upload feature to fine tune AI performance. Until the day that AI becomes self-aware and starts hunting down Sarah Connor. :scan:
     
  8. Thormodr

    Thormodr Servant of Civ Supporter

    Joined:
    Feb 15, 2005
    Messages:
    4,807
    Location:
    Vancouver, Canada
    Agreed on GalCiv II. Very good AI. It bodes well for Elemental in the future. :)
     
  9. tokala

    tokala Emperor

    Joined:
    Jan 14, 2006
    Messages:
    1,739
    Location:
    Klein Texas, Germany
    Brad Wardell (Stardock CEO) actually announced some time before the Civ5 release that he intended to take a sabbatical and mod Civ5 for a while. This got canned when he realized that Civ5 would be Steam-only, so he would have effectively supported a direct competitor to their own Impulse distribution system.
    And with the current situation on his hands, he has cancelled that sabbatical anyway.

    Re: "the game was designed around the AI": That's how things should be done for any single-player focussed strategy game. Most of the time it isn't, unfortunately.
     
  10. Mark the Bold

    Mark the Bold Warlord

    Joined:
    Oct 4, 2010
    Messages:
    149
    Well, I kinda suck at RTS games so I found it quite formidable. But I have not played Starcraft II so I am not qualified to compare the two.

    Couldn't agree with you more that its a different type of game. However, I have to give it huge kudos in that it was created for a very primitive gaming system, was installed on a cartridge, created in 2000 (!) and most people who owned the game didnt even know you could enable bots in Multiplayer. I play a lot of FPS, and I still found a deathmatch with 4-6 of these things running around was quite difficult.
     
  11. andrewlt

    andrewlt Prince

    Joined:
    Jul 27, 2004
    Messages:
    473

    In FPS games, though, they could always code the AI to be more accurate at higher levels. It doesn't mean they're smart.

    It's the same thing with Blizzard's RTS games. My APM is around 30-40. Top players, especially SC:BW ones, can have 400-500+. The computer can easily exceed that, even on difficulty settings I don't find particularly difficult.
     
  12. Soro

    Soro Warlord

    Joined:
    May 22, 2003
    Messages:
    193
    I'd suggest two other titles for consideration:

    1) Distant Worlds.

    2) Europa Univeralis III.

    Both have excellent AI.
     
  13. Mark the Bold

    Mark the Bold Warlord

    Joined:
    Oct 4, 2010
    Messages:
    149
    I am somewhat familiar with it. Let me clear my throat by saying that I am in no way a AI programmer. I'm an engineer by trade and most of my coding is simple, and used by people with high amounts of technical knowledge already. However, my wife works at a college with an outstanding graduate studies program in gaming AI and I always audit classes whenever I can. Exposed to great essays on this subject by Ray Kurzweil and Douglas Hofstadter. Most interesting was the Hofstadter concepts of "strange loops" and how we will never develop AI through logic and code, but rather by creating infinite and somtimes regressive (!) loops of logic TRYING to make sense of itself. Fascinating and mind blowing stuff. I also like the Asimov test of true AI: We will know we will have invented it for sure when it resists us turning it off. ;)

    Sorry to go off topic. I read a lot about it when Neverwinter Nights was supposedly going to implement it but abandoned it because the guy behind it got poached off the project by Apple. Any interesting links on the subject? Would be much appreciated.
     
  14. Snapp

    Snapp Chieftain

    Joined:
    Oct 27, 2010
    Messages:
    90
    I don't want to make this about SC2, but IMO the AI is actually horrible in SC2. Insane AI and even very hard AI are hard because they have perfect macro mechanics.

    Strategy wise they are horrible, they always go the same build, they don't really build counter units and if you attack their base with a single air unit they send their whole army back to deal with it.
     
  15. Lanstro

    Lanstro Warlord

    Joined:
    Sep 20, 2004
    Messages:
    253
    Battle for Wesnoth has solid AI, and a combat system quite similar to Civ5's.
     
  16. BobDole

    BobDole American Leader in Civ VI

    Joined:
    Mar 1, 2010
    Messages:
    811
    Yeah, I never said the AIs were brilliant, because they definitely aren't (they're atrocious on maps where you can turtle on an island and build your base there, for example) but they're OK. I've played a lot of games with worse AI.

    Definitely difficult (and a lot of fun, I spent waaay too much time on PD) but the difficulty was mostly from the AI simply being really good at aiming, not because it was good at any sort of strategy. Civ sort of faces the same problem, the AI used to be able to get by with brute force by stacking crap and charging at you, not because the AI was brilliant tactically (IV's AI was susceptible to things like pillaging or attacks from multiple directions) and now the challenge is to make an AI that can survive without being able to play that way.
     
  17. Jharii

    Jharii King

    Joined:
    Sep 3, 2007
    Messages:
    696
    Location:
    Walled Lake, MI
    I had some... at work. :) Let me do those searches again. :)
     
  18. Jharii

    Jharii King

    Joined:
    Sep 3, 2007
    Messages:
    696
    Location:
    Walled Lake, MI
    Memetic AI, as posted by WheelMud:

    This guy took the concept from William Bull and is implementing it in his MUD engine.

    Let me start by saying that I used this in my persistent world for NWN, and it was AMAZING! I am also not an AI programmer, but it intrigues me greatly, particularly this type of system.

    At it's core, the AI has basic needs and wants. Its ultimate goal is to fulfill the needs primarily and its wants secondarily. It has little snippets of code, called memes, that set out to try to do this task. The memes get organized and reorganized until it can perform those tasks, then repeats to try to do it more efficiently.

    Now, the great thing about this is that one AI unit could have a set of memes to, for instance, fish for food. It knows how to walk to the river (which is also used in the meme to gather water). It has a spear it uses to attack the fish to gather the food. This AI unit (let's call him Bob) is at the river and encounters another AI unit (Fred). Fred uses a pole and bait to fish. Bob sees that he is more efficient at gathering fish and learns how to fish using a pole when Fred teaches him (he copies the memes to Bob). Joila! Bob now knows how to fish.

    This is a VERY generic example. Other questions are posed just from that simple scenario, such as how does Bob know that there are fish in the river and how did Bob find the river to begin with? Or does Bob know how to cook the food?

    Finding the river is an interesting one. Basically, the river sends out a signal that says "I'm water! I'm water!" and if Bob is within the radius of that signal, he would be drawn to it. Bob finds the water and drinks, fulfilling that need. He stores the location of the water source for future reference.

    And so on...

    The beauty of this system is that you provide these basic code snippets and the ability for the AI to use them, organize them, store them, and learn them. Of course, there are plenty other methods that are used, but I think you get the idea.

    Now... imagine this in Civilization where each AI has its own needs and wants. The memes (snippets of code, functions) are already in the game, they just need to be told how to use them, organize them, store them, and learn them. The beauty of this would be that the AI could learn from both other AI opponents and from human opponents alike. Heck, this information could even be easily shared on the internet, obviously.

    Interestingly, imagine this scenario... My Elizabeth AI learns how to more efficiently build Stonehenge from me. I play you in a multiplayer game. Our shared Napoleon AI encounters my AI Elizabeth and learns how to build Stonehenge from her. You start a new game a week later and Napoleon rushes Stonehenge two turns before yours is complete. "What the?!?!'

    Anyhow, these are highly generic examples. But I think you can see how this would be an amazing system. I have been infatuated with it for the better part of 8 years now. It is big brain stuff and at the moment is really just outside of my grasp as far as implementation. But man, the concept is just nightmarishly full of potential.

    FYI, when he created this, I saw some examples where he had two communities of AI interacting amongst themselves and each other. One community loved to dance for entertainment while the other community loved to drink and party for entertainment. Both shared the same lake for water and fish, so they encountered each other regularly, yet their "entertainment" wants were so efficient from learning them in their own communities that they didn't share each others' methods of entertainment, although on occasion, they would try each others' methods.
     
  19. DaveGold

    DaveGold Emperor

    Joined:
    Dec 1, 2009
    Messages:
    1,058
    I'll give a mention to the Puerto Rico evolver by Tony Mitton. He created an excel spreadsheet that could execute the mechanics of the Puerto Rico boardgame and then created a number of AI players with 'genes' that directed some behaviours. You could iterate a big number of games with those players, record the results, and then mutate/crossbreed the most successful AI players to form a new generation with inherited genes. With each generation the AI did get a bit smarter and the better AIs would beat casual players. It wasn't perfect of course but it was a very interesting experiment.

    Some advantages of the evolving AI came from it remembering your games. The next generation of AIs might remember your winning strategies and begin to follow them. They would also remember which strategies won and lost to you and then eliminate some of the losing strategies from their genes, making them a bigger challenge against your personal play style. It's a bit optimistic to see that sort of evolving AI in a CIV game any time soon. An evolving AI would certainly stop embarking units quite so often.
     
  20. UknowsI

    UknowsI Nybygger

    Joined:
    Dec 8, 2002
    Messages:
    146
    Location:
    Korea
    I found the EU3 AI to be horrible, maybe worse than Civ 5. There is a while since I played it, but I remember at first I really liked the concept of the game, but that I got bored because the AI was too predictable. After a while you learn the how the AI works and it feels like a set of triggers mechanisms with a small RNG attached to it.

    XCom:UFO Enemy Unknown, I am not quite sure how the AI worked because you could hardly see their moves, but it often felt like they just move around randomly and then shoot when they see you. Because there is so many hidden areas in the game this will often seem smart since they will occasionally jump out and ambush you. The Alien's did however never cooperate (except through luck). Set up a position, lure one out, kill him, repeat, would always work.

    Personally I think the tactical combat AI in Civ needs help from chess programmers. The tactical AI in Civ would be greatly increased if a unit could do what was smartest thinking no steps a head and only considering tiles 3 steps away. If they made it able to think 1 or 2 turns into the future and 4 tiles in each direction the game would be changer completely.

    For most games the level of the AI depends more on how easy it is to make an AI to it than on how well they did it. As mentioned earlier it's not hard to make an AI which plays FPS at a very high level because you can simply increase their accuracy. Games that are formulated as an optimization problem can often be optimized more efficiently by a computer than it can by us, and combinatorial problems can be crunched more efficiently, but with a more complex game like Civ 5 which requires a lot of judgement it becomes harder.
     

Share This Page