Hacker News new | past | comments | ask | show | jobs | submit login

Is it harder to make an AI that is mediocre at playing the game vs one that is good? That is the main issue with making good AIs for games now. We want AIs (if you can call them that) that play kinda like humans but worse then the player as the player wants to win.

Making an AI for game isn't about making a good AI. It is about making an AI that loses in a convincing manner. This is especially try for games like Starcraft (RTS and strategy games in general. For FPS games it really isn't so important as you can just increase or decrease the accuracy and hp of the enemies)




I think it's really important to realize is that a game AI isn't really there to try to win, or maybe even to "convincingly" beat you the same way a human is. Perhaps you could train an AI to make the game more "fun", but that's pretty hard to measure and people are so different. It's a really hard optimization process.

One commonality, it seems, is that players want to get better at the game. Perhaps, an AI that TEACHES the user to improve their play, and reduce errors would be an easier problem. So far we mostly do this using heuristics of gradually increasing difficulty, but it should really depend on what the player is weakest at... and what the user can improve at fastest! That is something nicely measurable, which you might use to train an AI.

Then, if/when people play against other human players they are as strong as they can be... often an FPS goal.


> So far we mostly do this using heuristics of gradually increasing difficulty, but it should really depend on what the player is weakest at.

That's how MOOCs should function, too.


> Perhaps you could train an AI to make the game more "fun"

This is actually a way more interesting problem to solve, for the gaming industry.

Beating games is cool for industries where gaming is not the final problem (autonomous cars, various decision making, etc). But if AIs are to be exploited by gaming industry, it needs to learn things like : "is the user bored?", "what usually triggers new interest?", "how should difficulty be adjusted given current way the user is playing?", etc.


>an AI that TEACHES the user to improve their play

Wouldn't you be able to do mutual training that way? By mutating the AI's "strategy" only after losses, the player would continuously need to figure out a weakness in the AI's game-plan. And the AI tries to evolve its strategy every time it loses.


You could use some kind of library of example "mistakes" made by very-high-level players to identify when lower-rank players are making similar errors; then point out to the user how everyone else who made that mistake 'updated' their behavior.


Well, starcraft AIs aren't particularly good. Any player who has completed the single player campaign could beat all the AIs that came with the game that didn't cheat.

And a player in the top 20 percent could beat any AI that has ever been created.

AIs are really in an abysmal state for RTSes.


What about APM? Doesn't the speed at which the AI can input commands give it a big advantage?


It's like saying that a Go AI would have a huge advantage because it can move instantly, giving the opponent no time to think. Perhaps it contributes, but strategy is far more important.

See "The Marginal Advantage," an essay from the famous Starcraft player Day9: http://www.teamliquid.net/forum/brood-war/64514-competitive-...


This essay reminds me very much of the "Playing to Win" series by David Sirlin: http://www.sirlin.net/ptw/

It's also worth noting that AlphaGo optimizes its perceived chance of winning the game, rather than its score. It "gets complacent" and mostly plays very conservatively the moment it's ahead on points, because it doesn't care about margins, only about win/loss.


Even if you add time control, Go is a turn based game. You have your own turn to think, unlike in a RTS game.


Sort of. Go players are limited to around ~2 hours per game and around ~1 minute per move: https://www.quora.com/What-are-the-standard-time-limits-in-G...

I meant to say that strategy trumps mechanics. Mechanical proficiency is necessary but not sufficient.


It does, but the AI has to do useful things first before doing them quickly is a benefit.

Additionally, humans can use economic reasoning (player built 3 barracks to they can't be building x, y and z). This can lead to AI being excessively safe (economically inefficient).


Definitely, but my guess is that Starcraft AI's are really good at Macro play (building the right units and tech trees), but at the upper levels of SC players win or lose in Micro play (specific positioning of units), which is much harder for an AI to accomplish well, since there are a lot of little tricks. Basically, Macro can be programmed easily, but Micro requires the player to respond creatively.

http://wiki.teamliquid.net/starcraft/Micro_and_Macro


It's actually the other way around, I'd say. Individual unit control follows very naturally when you have unlimited APM. And most of the time you can define simple and good criteria on how to position the units (e.g. concave, or exactly the right distance apart to avoid splash damage, or one unit a tiny bit more towards the enemy to be the first one targeted by incoming fire, ...). Build orders can be programmed, yes, but transitioning between strategies properly based on observations and guessing or judging the enemy's strategy is quite hard.


The ones I saw in the competitions lost against humans on such micro rules since the humans quickly intuited their blind spots. The ability to bluff and screw with AI's, a human strong point, is what made me predict Starcraft was going to be way harder than Go. I'm still betting on the human in this one.

And the last line you said is also true to make things even more difficult. :)


To some extent it depends on the game.

First person shooters can have super accurate AIs that are really frustrating to play against. Try beating the last "boss" in quake 3 on nightmare difficulty. A game like Starcraft relies much more on decision making that raw 3d math calculations and that makes making a decent AI pretty difficult without giving it advantages like extra resources or vision. That said, even though a game like Quake is easier to write an AI for, top players can still be top level AIs with superior reasoning about using the map and timing power up spawns and such.


> First person shooters can have super accurate AIs that are really frustrating to play against.

The Worms series is also notorious for this. Their AI targeting seems to flip between "clueless" and "godlike", with very little middle ground. E.g. https://youtu.be/gqPITW04vRQ?t=1m20s


Probably not, to be honest. For a game like chess, the challenge is that there are so few things you can actually do. Inefficiencies aren't really a thing, every single move has a semi-discrete value.

Starcraft however has all kinds of minor inefficiencies you can build in. You could inconsistently build workers, you could occasionally supply cap, your army comps can vary in sophistication level, etc.


I bet you could run an analysis of "move quality" for the human player, find out where the moves he is making would rank in a list of possible moves sorted by value of the AI's quality function, and select the same-percentile moves for the computer AI to make (from its available moves).


> Making an AI for game isn't about making a good AI. It is about making an AI that loses in a convincing manner. This is especially try for games like Starcraft (RTS and strategy games in general. For FPS games it really isn't so important as you can just increase or decrease the accuracy and hp of the enemies)

It is actually about making a good AI. Civ 6 or SC2, in both cases they simply "cheat" by providing multipliers to the AI in order to solve its limitations. The basic function is largely the same. Providing the AI with cheat codes is not "good" AI.

A good AI design would remove the need for such arbitrary advantages that are out of context for human players and leads to weird issues.


It depends. AIs can do some things much better than nearly all humans. Twiddly little micromanagement for example. Total Annihilation (and it's successors like Supreme Commander) do this. The AI will send out a constant stream of micromanaged harassers constantly order to annoy the human opponent to death.

Where the AIs tend to be very bad is in long term thinking and overall strategy.

Blizzard's AI in Starcraft generally plays like a slightly more aggressive but novice human. It's more fun than the TA AI, but not terribly strong once you understand the game mechanics.


Some AIs for the Spring RTS Engine had this too. The funny thing is though- harrassment doesent scale. In these Exponential Economy type of games, the harassment only works as long as the macro-strategy is unable to take off. After a certain treshold, you can micro all the funny dances in the world- but the wave of enemys is going to carry this surfer to the shores end.


I think it's about options for players, some are strong others fresh and both want to choose an AI to their likings. Sometimes they are in the mood to get beat maybe to learn new tactics and occasionally just a victim to fight frustration.

What wrong with a strength option? I'd include an unbeatable entry in any case.


I'm not sure that accuracy/HP are the right things to tweak. I've always wanted to be "surprised," in an unscripted way, by AI enemies in FPS and RTS games.


One game experimented with smart enemy units that could sneak up on a player and attack them from behind, or outflank them. The players hated it and assumed the computer was cheating and just spawning enemies behind them.

The same is sort of true in RTS games. The new rerelease of age of empires 2 has vastly improved AI that was developed by modders. Lots of players thought it was just cheating.

But in general it has been very well received. I think players can get used to good AI. They've just been trained to expect stupid AI that cheats.


For the vast majority of players it's probably irrelevant whether the AI cheats or not. The goal is not to play fair and beat the human usually, but to put up a good fight and make things challenging and, most importantly, fun for the human. Of course, competitive and professional players have different expectations or requirements in that regard.

Still, AI in games is mostly a trade-off. It usually can't take too much resources (because it usually has to run on the same machine the human is playing on), it has to be believable and fun to play against. This usually rules out too fancy algorithms and approaches with dubious returns.


I think the majority of players would prefer AIs that are challenging through better strategy and tactics, rather than just being bullet sponges or having better aim. People also get frustrated when the computer wins through cheating, rather than actually being better.


Having checkpoints along the way as you train your model could be a good way to allow fine-grained level selection. I guess :)


That would be funny. The difficulty slider changes to "How many hours of playtime" instead of easy, medium, hard. Actually it could even just scale it automatically based on a metric like steam hours played. that would be awesome.


I don't think so. Many of the fun things AIs do in games is attack at different stages of the game. They send a small force at the beginning, and then a little larger force a few minutes later, and then a big attack at the end. No AI trying to win would end up at this strategy. You would have to define the fun goals and have the AI train on that for it's success criteria.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: