Basic question re AI: RTS versus TBS

In a case it wasn't linked before, Soren Johnson's (Civ 4 creator) lecture on game AI

One of the most important facts to take away is Civilization is a lot about immersion so "gamey" AI is not fun for many players. We like AI to behave in a reasonable manner as a leader of a foreign country, not as another player who tries to win using everything in their disposal up to and including abuse of game mechanics. Unlike the Starcraft AI or chess AI.
 
We like AI to behave in a reasonable manner as a leader of a foreign country, not as another player who tries to win using everything in their disposal up to and including abuse of game mechanics.

Which is where the Ai in Civ 6 falls flat for me, as it doesn't play the role of foil very well. There's almost no apparent differentiation to the way they behave, their "personality" is exclusively based on their leader animation rather than in game behaviour (that animation is great, though!), they don't adopt a strategy that could lead to victory and stick to it, and they'll almost completely ignore you in the mid to late game regardless of whether you're their friend or their enemy. Takes all the interest out of playing the game, for me. Others feel differently, of course.

As a side note, I read "abuse of game mechanics" as short hand for "the game design suffers from play balance issues that haven't been addressed". I believe a good part of the AI's challenge in Civ 6 is that many options offered to the players are significantly worse than others in 95%+ situations. A solid balance pass on Civ 6's ruleset would do wonders for the AI, as every choice it could make would be closer to equal in impact. It still won't be able to situationally evaluate which is best in the current circumstances as well as an experienced player, but at least it won't be saddled with the consequences of clearly sub-optimal decisions. Unfortunately, we need to wait until the dev team finalizes the rules for Civ 6 before that balance pass can get started. Since a third expansion is in the works, we're likely at least a year away from that.
 
haven't read through all the replies yet, but my opinion would be: put a "win" AI that actively tries to win on Emperor+ difficulties, programmed with optimal decisions. It won't guarantee them a win, but they'd be better competitors.
Role-Players probably won't step up too far beyond Emp anyway. Base AI only need simple, totally-immersion-breaking fixes.
I'd also like leaders to act more uniquely between each of them (even for RP AI only), agendas alone aren't enough to make them different (Civ5 flavor system really strikes me and i liked it).
 
In RTS players and machine have the same time to do things. If the players would have the same time as the machine to do things in civ (seconds each turn) the machine would win each time.
And this is only one of the reasons
 
In RTS players and machine have the same time to do things. If the players would have the same time as the machine to do things in civ (seconds each turn) the machine would win each time.

If that's an actual reason for poor AI decision making, why not add an option to allow the AI longer to finish it's turns? I'd happily let the AI have as much time to think as it needs, if that would result in a better game experience.
 
In a case it wasn't linked before, Soren Johnson's (Civ 4 creator) lecture on game AI

One of the most important facts to take away is Civilization is a lot about immersion so "gamey" AI is not fun for many players. We like AI to behave in a reasonable manner as a leader of a foreign country, not as another player who tries to win using everything in their disposal up to and including abuse of game mechanics. Unlike the Starcraft AI or chess AI.

I've already called this out as a cop-out and have given my reasons why. I'd be interested to see a refutation of them, especially from strategy developers in general (this problem is not limited to Civ, though it's perhaps more glaring) but really by anybody.

"Reasonable" rulers in history acted on incentives. The game's incentives are different. They are different because of both practical limitations and developer's choices to make them different.

Creating "gamey" incentives and then pretending they're not there/instructing the AI to ignore them because they're not fun is at least somewhat dishonest.
 
This AI you are talking about is not actually the AI that's in the SC2 game. This was an experiment.
 
If that's an actual reason for poor AI decision making, why not add an option to allow the AI longer to finish it's turns? I'd happily let the AI have as much time to think as it needs, if that would result in a better game experience.
I'd make it the opposite and put the player on a clock. 30 seconds (or whatever) and your turn is done. Let's see how "dumb" that AI really is . . .
 
I just saw this article about an AI crushing it on Starcraft: https://www.vox.com/future-perfect/...l-intelligence-google-deepmind-starcraft-game . As you know, Starcraft involves infinite amount of possible decisions every microsecond, and this AI was able to beat proplayers.

I am confused about how an AI exists that is able to beat programmers in an RTS game involving an infinite number of possibilities and choices that have to be made every nanosecond, when the same AI is unable to play a TBS involving a smaller number of choices (granted, still a lot), on less of a compressed timetable.

I also remember someone saying that the AI programmer in Civ 6 was brought over from Starcraft. To me starcraft is infinitely more complicated (and hard as hell, which is why i stopped playing). Why is it so hard to make a good Civ 6 AI?
This is a vast overestimation of the complexity of StarCraft II. There's no "infinite number of possibilities and choices that have to be made every nanosecond". SC2, like many RTS games, is all about build orders and maintaining a very basic economy running, purely to produce the precise amount and combination of units required to attack. While you can theoretically do an infinite number of things at any given moment, the amount conducive to optimal gameplay is far, far more finite.

There's far less layers than in a Civ game, there's no roleplaying and hell, there's not even turtling in a pro, win-at-all-costs-in-5-minutes context. And there's also the fact that in RTS, the AI has the luxury of time to continuously process and ponder what to do; in TBS, the majority of calculations (and more complex ones at that) have to be carried out in a fraction of the time.

Not saying it's a piece of cake to build an AI for such a game, but people keep underestimating the complexity of multi-victory 4X strategy.
 
While you can theoretically do an infinite number of things at any given moment, the amount conducive to optimal gameplay is far, far more finite.

And that's why it's hard for an AI. You think like a human, "well chess is easy there are clearly only 4-5 moves you need to think about in any position" but that's because you rely on intuition to find those moves, which an AI doesn't have. Finding the small number of good moves in a giant pool of possible moves is the core of what makes it hard to build a good AI.
 
Some people claim that the AI trying would break immersion, but I assert the opposite. The fact that my supposed opposition is playing for a different objective often only tangentially related to actual victory conditions is off-putting and dishonest.

The AI may be "trying", it just might not be trying to do what you envision it should do. There has always been a spectrum of players who play this game differently and thus envision its perfection in different ways.

Many see it like you do. The AI should play a game, a puzzle, and put that puzzle together in the shortest amount of time without making stupid mistakes.

Many expect the game to be more of a simulation of human activities, responses and perceptions. Flawed, in other words. These folks would expect the AI to go about its business and make decisions in the moment without knowledge of how to end the game in the future. That is not to say they don't have ambitions, just that an ambition may be to be the best in the world at something, not to build x of this and arrange the pieces so the 4th wall puzzle is solved.

I don't profess to know how good or bad the AI is, but in this game, the devs have to straddle the different play style expectations and that isn't easy.
 
And that's why it's hard for an AI. You think like a human, "well chess is easy there are clearly only 4-5 moves you need to think about in any position" but that's because you rely on intuition to find those moves, which an AI doesn't have. Finding the small number of good moves in a giant pool of possible moves is the core of what makes it hard to build a good AI.
Sure, proper artificial intelligence would play millions of games figuring out the optimal orders and such on its own. But in a standard context, you program the AI with predefined strategies: the human designer cuts through the meaningless choices to provide the computer opponent an array of viable ones. This in an average RTS context; in a 4X context, it's much harder to program the AI with preset courses of action since the number of variables involved is much greater.

Then there's the matter of adaptability in the face of the strategy the adversary employs. That's the real challenge. But still, it's not like the SC2 AI has to deal with diplomacy, faith, culture, or anything that's not destroying the enemy bases. There's research and expansion, but compared to Civ it's very basic and short term: the techs to research are very limited in a blitz win-at-all-costs context, as are the expansion bases (little more than mining outposts to increase resource income).
 
Sure, proper artificial intelligence would play millions of games figuring out the optimal orders and such on its own. But in a standard context, you program the AI with predefined strategies: the human designer cuts through the meaningless choices to provide the computer opponent an array of viable ones. This in an average RTS context; in a 4X context, it's much harder to program the AI with preset courses of action since the number of variables involved is much greater.

I'm not sure what you are talking about, AlphaStar doesn't use human designed policies. Blizzard's AI does but I don't think anyone in this thread said it was any good.
 
I'm not sure what you are talking about, AlphaStar doesn't use human designed policies. Blizzard's AI does but I don't think anyone in this thread said it was any good.
My original post was in response to the original post of this thread, which boiled down to "Hey, AI can kill it in SC2 and that's a super complex game, infinitely more complex than Civ! Why is it so hard to come up with good AI for Civ?"

I sought to disprove both that SC2 is a particularly complex game, and that Civ isn't. It is, essentially, the other way round.
 
My original post was in response to the original post of this thread, which boiled down to "Hey, AI can kill it in SC2 and that's a super complex game, infinitely more complex than Civ! Why is it so hard to come up with good AI for Civ?"

I sought to disprove both that SC2 is a particularly complex game, and that Civ isn't. It is, essentially, the other way round.

The OP is about AlphaStar which doesn't have human designed policies.

The OP is also based on a false premise. The reason it sucks is that nobody really tried to build one that doesn't, they got like 1 guy working there making some if statements, we pretty far from the machine learning experts who tried their hand at starcraft 2. The in-game AI for Starcraft is actually terrible as well.

The reason there are great AIs for Starcraft 2 and Dota 2 (not in-game AI, mind you, AIs developed by third parties) is that they have an API for machine learning so we can programmatically interact with the game allowing anyone to try. So you have college students competing in AI tournaments for who can make the best SC AI and you get big names like Deepmind trying it out as well. Of course, you will end up with amazing AIs with so many people working on it.
 
Last edited:
Civilization may seem complex as a human but from an AI perspective it is pretty simple. AlphaStar spent 1 week learning how to beat humans without knowing where the human is (fog of war on) and while using slower APM's in a game where decisions are not binary but constantly changing. A lot of Civ decisions are simple binary choices. Build a campus or not. Trade coal or not. Found a city or not. As the AI plays itself millions of times over and over it will learn the most optimal build orders and expansion tactics to win.

The issue isn't if AI can beat a human in Civ. The problem is it would suck to play against. You would see things like ICS and tons of units and a bunch of chopping/pillaging.

Can you make an AI that is competent at playing to certain victory conditions without min/max style play. That seems pretty hard. Not sure what parameters you can use to let an AI learn to play like a human who isn't just trying to win but embrace some element of role play where we build amazing empires.

Firaxis knows its audience and most of them aren't struggling with an AI that is ruining their game because it lacks depth. I wish they had a huge AI and design team that was able to work on this game but it isn't like they have 10 devs working on AI and a 20 man team working on game design. They have a hard enough time just release the game without bugs like Canada getting nuked during peace, or ships using tunnels.

Someday in the future DeepMind or something like Azure/AWS will have a service you can upload your code to that will come with an API you program with some win conditions and it will develop AI for you.
 
The AI may be "trying", it just might not be trying to do what you envision it should do. There has always been a spectrum of players who play this game differently and thus envision its perfection in different ways.

"Trying" implies attempting to attain one of the victory conditions as defined by the game. In addition to its usual tactical failures, the AI is *intentionally* designed not try at the strategic level. This is not a respectable choice and players should not respect it.

People can open up Civ 6 then not play Civ 6 (up to and including literally, such as going to do laundry while the game is open). If they're not in MP that's their sole prerogative. If they are in MP and their opponents didn't agree to them doing that they should be kicked. This choice has no bearing on the AI regardless.

Many expect the game to be more of a simulation of human activities, responses and perceptions. Flawed, in other words.

What's flawed is the reasoning used to make such a case. An arbitrary amount of "simulation is okay", but not other times. Simulation is okay, until it isn't okay.

Incoherent logic should not inform game design, or most decisions for that matter. And incoherent logic is what is being used to "expect the game to be more of a simulation of human activities".

What do actual human activities in Civ 6 look like? I bet they're different from the AI's activities, even among the players purporting they want to role play. People will "role play" then complain if they lose to the AI attacking them. That's not credible rationale and it shouldn't be treated with any meaningful weight in the game's design. Players making that case are necessarily irrational in that context.

These folks would expect the AI to go about its business and make decisions in the moment without knowledge of how to end the game in the future.

Those are expectations of active dishonesty and self-inconsistency. The game has clear incentives. Historical leaders acted on historical incentives. In a scenario where "historical" AI are ignoring their incentives, the assertion that it is a "historical simulation" is objectively false.

I don't profess to know how good or bad the AI is, but in this game, the devs have to straddle the different play style expectations and that isn't easy.

They get no such pass for this. Design the game first, then make the AI play the game. If they think the game would suck if the AI actually plays it, maybe they should rethink their design.

The issue isn't if AI can beat a human in Civ. The problem is it would suck to play against. You would see things like ICS and tons of units and a bunch of chopping/pillaging.

Can you make an AI that is competent at playing to certain victory conditions without min/max style play.

If the AI playing the game optimally isn't fun, the AI isn't what's at fault with the game. The game's design/rules/victory conditions are what's broken in that case, not the AI.
 
Last edited:
I'd make it the opposite and put the player on a clock. 30 seconds (or whatever) and your turn is done. Let's see how "dumb" that AI really is . . .

If the AI had to navigate the UI to make it's inputs, maybe that would be a level playing field.

Anyway, not sure what the objection was to an option to allow the AI to take as much time per turn as I do on average. Not as a default setting, obviously, but as an optional setting for those who would like to see the AI be a more challenging. I'm not convinced that would help the current AI, but if processing time is indeed a factor, that's presumably one that players could be allowed to choose for themselves whether they value shorter turns or better AI decisions.
 
If the AI had to navigate the UI to make it's inputs, maybe that would be a level playing field.

Anyway, not sure what the objection was to an option to allow the AI to take as much time per turn as I do on average. Not as a default setting, obviously, but as an optional setting for those who would like to see the AI be a more challenging. I'm not convinced that would help the current AI, but if processing time is indeed a factor, that's presumably one that players could be allowed to choose for themselves whether they value shorter turns or better AI decisions.

With the current implementation it wouldn't change anything. As far as I know, the AI doesn't actually search the solution space for a good move. It wouldn't be hard to implement one that does, at least if you restrain the problem to unit movements as some have suggested. Would still be a huge improvement if the AI would use it's units properly. But they probably don't see it as good investment of resources for them as a company.
 
I've already called this out as a cop-out and have given my reasons why. I'd be interested to see a refutation of them, especially from strategy developers in general (this problem is not limited to Civ, though it's perhaps more glaring) but really by anybody.

"Reasonable" rulers in history acted on incentives. The game's incentives are different. They are different because of both practical limitations and developer's choices to make them different.

Creating "gamey" incentives and then pretending they're not there/instructing the AI to ignore them because they're not fun is at least somewhat dishonest.

Maybe reasonable was wrong choice of words on my part. Strictly speaking not every ruler acted what I'd call reasonably. What I meant was believably. Believably as leaders of a country and not as gamers in a game.

It's very hard to create all the right initiatives for the Civ leaders to make them act believably as real life rulers. In Civ we have immortal leaders not accountable to people, nobility, sponsors, businesses. You may have some trouble due to unhappiness but nothing even close to real life consequences (civil wars, revolutions, coup d'état, assassinations....). The game would be extremely complicated and probably not that fun. The art is to make the game gamey (for the player) while also keeping immersion and a semblance, or a feeling of "realism". Example: while in real life we too had a space race, USA and USSR didn't even consider to go to war to prevent each other from being the first. The rest of the world also didn't consider ganging up on both of them to prevent from winning space victory right. But in civ the game, not doing that likely results in you losing, so a gamey AI should definitely do it. I get where you come from but I think what you want is not reasonably possible. Even if technology is already there, the amount of work needed would make the price of the game ridiculous.

And yes different people draw the line in different place. For me personally, Civ4 AI was not gamey enough, and generally terrible like Civ AI always is, but I'd still pick it over Civ 5 and Civ 6.

If the AI playing the game optimally isn't fun, the AI isn't what's at fault with the game. The game's design/rules/victory conditions are what's broken in that case, not the AI.
Yes they are, on a fundamental level: In real history you don't achieve "victory". So we can either drop the victory conditions altogether, or have a purely gamey AI, or something in between. I choose something in between and I dont see anything wrong with it. AI is here for my pleasure, it should behave however I damn want. If I want some challenge but also some immersion, that's how AI should act.
 
Last edited:
Back
Top Bottom