Jump to content

Anyone good at AI ?

zindan

What is required to make a AI for a game? Lets say a game like Brawlhalla, which math and which programming languagaes would be required to make a really good AI bot in Brawlhalla that nobody can beat?
I found one guy stating a few, can someone with knowledge tell me if he is correct? 
https://www.quora.com/What-math-is-used-in-machine-learning-artificial-intelligence-research

Link to comment
Share on other sites

Link to post
Share on other sites

Making AI that nobody can beat is stupid easy: you just have it react to everything the player inputs the moment the application gets around to processing it. Making an AI with believable flaws is the challenging part. For example, I made a Tic-Tac-Toe game that had a vs. computer mode. Since Tic-Tac-Toe is easy to solve, it was easy to develop an "AI" that can't be beaten, at best you can only tie against it. I haven't gotten any further than that because I can't begin to think how to make a dumber "AI" without it being obvious.

 

If we're talking about AI that is external to the game and has to go on what the output is, then that's a different story. Though it would only require pattern matching to figure out what the other character is likely doing.

Link to comment
Share on other sites

Link to post
Share on other sites

40 minutes ago, M.Yurizaki said:

Making AI that nobody can beat is stupid easy: you just have it react to everything the player inputs the moment the application gets around to processing it. Making an AI with believable flaws is the challenging part. For example, I made a Tic-Tac-Toe game that had a vs. computer mode. Since Tic-Tac-Toe is easy to solve, it was easy to develop an "AI" that can't be beaten, at best you can only tie against it. I haven't gotten any further than that because I can't begin to think how to make a dumber "AI" without it being obvious.

 

If we're talking about AI that is external to the game and has to go on what the output is, then that's a different story. Though it would only require pattern matching to figure out what the other character is likely doing.

Is it really that easy? Do you think you could make an AI on Brawlhalla that could beat me ? I highly doubt it. The game is pretty simple and you use about 8 buttons in total.   This should be interesting.   The reason that I doubt you could is because there are so many possibilities and the requirement of creativity is essential.

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, zindan said:

Is it really that easy? Do you think you could make an AI on Brawlhalla that could beat me ? I highly doubt it. The game is pretty simple and you use about 8 buttons in total.   This should be interesting.   The reason that I doubt you could is because there are so many possibilities and the requirement of creativity is essential.

Could I? No, because implementing game AI isn't really my field of expertise.

 

But again, it depends on if the AI is internal or external. If it's internal, that makes the job much easier and all the AI has to do is react to your inputs the moment the application gets around to servicing it. You're only hope at that point is to exploit limitations imposed by the rules.

Link to comment
Share on other sites

Link to post
Share on other sites

Well... There's "traditional" game AI where it follows a script and then there's machine learning/deep learning AI. There's a lot of ways you could do it with machine learning but for more complex AIs it's mostly reinforcement learning (Q-learning).

 

1 hour ago, zindan said:

which math and which programming languagaes

Math: Multi-variable Calculus, Linear Algebra

As for the programming language, there is no specific one but most machine/deep learning projects use python b/c of its libraries such as Numpy and Tensorflow. 

Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, M.Yurizaki said:

Could I? No, because implementing game AI isn't really my field of expertise.

 

But again, it depends on if the AI is internal or external. If it's internal, that makes the job much easier and all the AI has to do is react to your inputs the moment the application gets around to servicing it. You're only hope at that point is to exploit limitations imposed by the rules.

Internal is fine.  But no it's not just reacting to the opponents moves. The opponent will react in one way to trick you in to reacting in one way and then the opponent will do something else. You have to predict your opponents moves, it is very difficult for a machine to do this I think.  I don't think the technology exists to beat the best brawlhalla player in the world. No machine could probably do that. 

Link to comment
Share on other sites

Link to post
Share on other sites

10 minutes ago, zindan said:

Internal is fine.  But no it's not just reacting to the opponents moves. The opponent will react in one way to trick you in to reacting in one way and then the opponent will do something else. You have to predict your opponents moves, it is very difficult for a machine to do this I think.  I don't think the technology exists to beat the best brawlhalla player in the world. No machine could probably do that. 

If there are any limitations in the system that could be exploited, then the AI could simply exploit those to get around any sort of clever tricks you can come up with.

 

This doesn't sound like anything different than any other fighting game.

Link to comment
Share on other sites

Link to post
Share on other sites

45 minutes ago, M.Yurizaki said:

If there are any limitations in the system that could be exploited, then the AI could simply exploit those to get around any sort of clever tricks you can come up with.

 

This doesn't sound like anything different than any other fighting game.

I don't believe it can be done. 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, zindan said:

I don't believe it can be done. 

People thought that a computer capable of beating the world's best Go player couldn't be done (at least, not within the near future back in 2010 or so).

 

But it was done, and Go is one of the most mathematically complicated games with perfect information.

Link to comment
Share on other sites

Link to post
Share on other sites

41 minutes ago, M.Yurizaki said:

People thought that a computer capable of beating the world's best Go player couldn't be done (at least, not within the near future back in 2010 or so).

 

But it was done, and Go is one of the most mathematically complicated games with perfect information.

Brawlhalla isn't something that is even close to Alpha go.  A set of rules don't and a computer behind them running the game isn't enough.  Also why are you even saying that ? I said and I quote "I believe it cannot be done"   I never assumed that it would never be possible. So I don't see the point of your comparison with what people believed some time ago. 

Link to comment
Share on other sites

Link to post
Share on other sites

5 minutes ago, zindan said:

Brawlhalla isn't something that is even close to Alpha go.  A set of rules don't and a computer behind them running the game isn't enough.  Also why are you even saying that ? I said and I quote "I believe it cannot be done"   I never assumed that it would never be possible. So I don't see the point of your comparison with what people believed some time ago. 

Those two phrases are awfully close to being synonymous so...

 

In any case, again, anything you can do, the computer can also do. If you can react against a combination of actions, so can the computer, and with perfect precision. If it's just "who comes up with the combination of inputs that wins," then it's a game of chance and you may as well claim that no AI can beat you in RPS. At least not without blatant cheating.

 

Then again, it's not really cheating if the computer is reacting to the input you just pressed.

Link to comment
Share on other sites

Link to post
Share on other sites

Not yet mate but I want to get into it. I am just not sure if I am smart enough

Link to comment
Share on other sites

Link to post
Share on other sites

52 minutes ago, zindan said:

Internal is fine.  But no it's not just reacting to the opponents moves. The opponent will react in one way to trick you in to reacting in one way and then the opponent will do something else. You have to predict your opponents moves, it is very difficult for a machine to do this I think.  I don't think the technology exists to beat the best brawlhalla player in the world. No machine could probably do that. 

Initially it will probably fail to beat you, but as it learns it will see the patterns in your movements and learn to counter/react to those. Then it could probably learn your tricks pretty fast. These are interesting I guess:

 

29 minutes ago, zindan said:

Brawlhalla isn't something that is even close to Alpha go.  A set of rules don't and a computer behind them running the game isn't enough.  Also why are you even saying that ? I said and I quote "I believe it cannot be done"   I never assumed that it would never be possible. So I don't see the point of your comparison with what people believed some time ago. 

And that is exactly the point :) people used to say that about a lot of things and here we are now doing most of that.

Crystal: CPU: i7 7700K | Motherboard: Asus ROG Strix Z270F | RAM: GSkill 16 GB@3200MHz | GPU: Nvidia GTX 1080 Ti FE | Case: Corsair Crystal 570X (black) | PSU: EVGA Supernova G2 1000W | Monitor: Asus VG248QE 24"

Laptop: Dell XPS 13 9370 | CPU: i5 10510U | RAM: 16 GB

Server: CPU: i5 4690k | RAM: 16 GB | Case: Corsair Graphite 760T White | Storage: 19 TB

Link to comment
Share on other sites

Link to post
Share on other sites

10 minutes ago, tikker said:

Initially it will probably fail to beat you, but as it learns it will see the patterns in your movements and learn to counter/react to those. Then it could probably learn your tricks pretty fast. These are interesting I guess:

 

And that is exactly the point :) people used to say that about a lot of things and here we are now doing most of that.

The first video is pretty cool but damn in brawlhalla imagine blocking whilst someone is jumping, fast falling, dashing, throwing something at you at close distance..... naaah it's to much.  Fast forward to 1:30 or watch the entire clip.   At 1:30, the predicted down hits. I can't imagine an AI being able to predict something like that, it's just insane.

 

 

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, zindan said:

The first video is pretty cool but damn in brawlhalla imagine blocking whilst someone is jumping, fast falling, dashing, throwing something at you at close distance..... naaah it's to much.  Fast forward to 1:30 or watch the entire clip.   At 1:30, the predicted down hits. I can't imagine an AI being able to predict something like that, it's just insane

 

 

There's certainly a lot more freedom in this game that complicate things, but keep in mind that we are talking about computers here. Give it time and it will learn. I'm positive we'll have an AI capable of it someday.

Crystal: CPU: i7 7700K | Motherboard: Asus ROG Strix Z270F | RAM: GSkill 16 GB@3200MHz | GPU: Nvidia GTX 1080 Ti FE | Case: Corsair Crystal 570X (black) | PSU: EVGA Supernova G2 1000W | Monitor: Asus VG248QE 24"

Laptop: Dell XPS 13 9370 | CPU: i5 10510U | RAM: 16 GB

Server: CPU: i5 4690k | RAM: 16 GB | Case: Corsair Graphite 760T White | Storage: 19 TB

Link to comment
Share on other sites

Link to post
Share on other sites

2 minutes ago, tikker said:

There's certainly a lot more freedom in this game that complicate things, but keep in mind that we are talking about computers here. Give it time and it will learn. I'm positive we'll have an AI capable of it someday.

Do you think that someone could programm a bot that is able to beat the best player in the world on brawlhalla ?  Like not an AI that "learns" But a software with a set of rules like "if player does this" Then you do this.    Say a pro player instructs the programmer on the best outcomes in different situations and you include a lot of situations in to the programm.  Perhaps there are to many possibilities for this to be functional ?

Link to comment
Share on other sites

Link to post
Share on other sites

10 minutes ago, zindan said:

Do you think that someone could programm a bot that is able to beat the best player in the world on brawlhalla ?  Like not an AI that "learns" But a software with a set of rules like "if player does this" Then you do this.    Say a pro player instructs the programmer on the best outcomes in different situations and you include a lot of situations in to the programm.  Perhaps there are to many possibilities for this to be functional ?

I don't think that's feasible. The "if player does this" part is best taken care of by machine learning, as programming explicitely for every possible combo, move etc. is impossible. As you say, there are too many possibilities for this to explicitely be programmed for by a human. What you could do is train the AI by letting it analyze recorded fights or sparring with it, for example. Eventually it can learn, for example, that if it falls off people can come after it still or that it can still save itself or something else.

This is similar to the Go example @M.Yurizaki gave. You teach it the basic rules of the game how pieces can move, maybe some basic strategies (I don't know the exact details) and then let it learn for itself by playing against other people and other AI.

Crystal: CPU: i7 7700K | Motherboard: Asus ROG Strix Z270F | RAM: GSkill 16 GB@3200MHz | GPU: Nvidia GTX 1080 Ti FE | Case: Corsair Crystal 570X (black) | PSU: EVGA Supernova G2 1000W | Monitor: Asus VG248QE 24"

Laptop: Dell XPS 13 9370 | CPU: i5 10510U | RAM: 16 GB

Server: CPU: i5 4690k | RAM: 16 GB | Case: Corsair Graphite 760T White | Storage: 19 TB

Link to comment
Share on other sites

Link to post
Share on other sites

8 minutes ago, tikker said:

I don't think that's feasible. The "if player does this" part is best taken care of by machine learning, as programming explicitely for every possible combo, move etc. is impossible. As you say, there are too many possibilities for this to explicitely be programmed for by a human. What you could do is train the AI by letting it analyze recorded fights or sparring with it, for example. Eventually it can learn, for example, that if it falls off people can come after it still or that it can still save itself or something else.

This is similar to the Go example @M.Yurizaki gave. You teach it the basic rules of the game how pieces can move, maybe some basic strategies (I don't know the exact details) and then let it learn for itself by playing against other people and other AI.

Who can do this?!!? I wanna see this shit happen.  

Link to comment
Share on other sites

Link to post
Share on other sites

7 minutes ago, zindan said:

Who can do this?!!? I wanna see this shit happen.  

That's out of my league unfortunately. I can't imagine it being easy though and it will take a lot of time as well for the training I guess.

 

[Edit] If it can be done for SSB, it can be done for Brawlhalla:

https://www.engadget.com/2017/02/26/super-smash-bros-ai-competes-with-top-players/

Crystal: CPU: i7 7700K | Motherboard: Asus ROG Strix Z270F | RAM: GSkill 16 GB@3200MHz | GPU: Nvidia GTX 1080 Ti FE | Case: Corsair Crystal 570X (black) | PSU: EVGA Supernova G2 1000W | Monitor: Asus VG248QE 24"

Laptop: Dell XPS 13 9370 | CPU: i5 10510U | RAM: 16 GB

Server: CPU: i5 4690k | RAM: 16 GB | Case: Corsair Graphite 760T White | Storage: 19 TB

Link to comment
Share on other sites

Link to post
Share on other sites

58 minutes ago, tikker said:

That's out of my league unfortunately. I can't imagine it being easy though and it will take a lot of time as well for the training I guess.

 

[Edit] If it can be done for SSB, it can be done for Brawlhalla:

https://www.engadget.com/2017/02/26/super-smash-bros-ai-competes-with-top-players/

I will be able to try in like 5-6 years after I'm done with my software engineering

Link to comment
Share on other sites

Link to post
Share on other sites

1 hour ago, zindan said:

Do you think that someone could programm a bot that is able to beat the best player in the world on brawlhalla ?  Like not an AI that "learns" But a software with a set of rules like "if player does this" Then you do this.    Say a pro player instructs the programmer on the best outcomes in different situations and you include a lot of situations in to the programm.  Perhaps there are to many possibilities for this to be functional ?

If you want an absolutely perfect playing AI, then yes, the possibilities are too great for any current existing technology to process. But brute force methods like this are rarely ever useful, especially in a competitive game against a human. The computer doesn't have to play perfectly. It just has to play beyond the limitations of what humans can do.

 

This greatly reduces the problem the program has to solve. Instead of trying to evaluate every possible combination based on the state of the game at that time, evaluate what actions produces the most favorable outcome. You can do this without machine learning if you're willing to crunch through the scenarios. Depending on what actions it comes up with, humans, who are creatures of habit and pattern recognition, may be thrown out of whack and lose their edge. This caught one of the players who went up against AlphaGo off guard because the computer was playing moves that are rarely played by other humans, yet provided the best outcome. A game like Go is way too complex for a human to ever resolve with reasonable precision. So all a computer has to do is resolve it to a precision outside of what humans are capable of.

 

I mean if you want a whack at it, program a perfect playing Tic-Tac-Toe application. That's really easy for a human to solve.

Link to comment
Share on other sites

Link to post
Share on other sites

3 minutes ago, M.Yurizaki said:

If you want an absolutely perfect playing AI, then yes, the possibilities are too great for any current existing technology to process. But brute force methods like this are rarely ever useful, especially in a competitive game against a human. The computer doesn't have to play perfectly. It just has to play beyond the limitations of what humans can do.

 

This greatly reduces the problem the program has to solve. Instead of trying to evaluate every possible combination based on the state of the game at that time, evaluate what actions produces the most favorable outcome. You can do this without machine learning if you're willing to crunch through the scenarios. Depending on what actions it comes up with, humans, who are creatures of habit and pattern recognition, may be thrown out of whack and lose their edge. This caught one of the players who went up against AlphaGo off guard because the computer was playing moves that are rarely played by other humans, yet provided the best outcome. A game like Go is way too complex for a human to ever resolve with reasonable precision. So all a computer has to do is resolve it to a precision outside of what humans are capable of.

 

I mean if you want a whack at it, program a perfect playing Tic-Tac-Toe application. That's really easy for a human to solve.

The actions that produce the most favorable outcome are always different. Machines can't predict brawlhalla moves. This is not chess where the player is like forced to do a certain something in order to win etc etc. Brawlhalla gameplay can't be calculated in the same way. It's like your opponent might back dodge if you do sidesig  but the next time you do sidesig he might jump up, the third time he might back dash and then hit you, the fourth time he throws his weapon to interrupt your attack. Its just insane.    Play it against me once you will think like " WHAT THE HECK" How does he predict my every move ?  I would love to see an AI beat the best player in the world, that would mean... wow, incredible.

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, zindan said:

The actions that produce the most favorable outcome are always different. Machines can't predict brawlhalla moves. This is not chess where the player is like forced to do a certain something in order to win etc etc. Brawlhalla gameplay can't be calculated in the same way. It's like your opponent might back dodge if you do sidesig  but the next time you do sidesig he might jump up, the third time he might back dash and then hit you, the fourth time he throws his weapon to interrupt your attack. Its just insane.    Play it against me once you will think like " WHAT THE HECK" How does he predict my every move ?  I would love to see an AI beat the best player in the world, that would mean... wow, incredible.

But how do you predict other people's moves? Unless you're some kind of clairvoyant, if you are using tells or other signs within the game itself so can the AI. When you have an imperfect information game like this, any information can be used to create a probable outcome with high degrees of confidence.

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, M.Yurizaki said:

But how do you predict other people's moves? Unless you're some kind of clairvoyant, if you are using tells or other signs within the game itself so can the AI. When you have an imperfect information game like this, any information can be used to create a probable outcome with high degrees of confidence.

I don't know how to answer that question. "How do I read the player".   Remember that it is incredible hard even for real players to predict another player at all times.  It's not a 100% always hit game. 

If someone is out of map he must get back to the ledge so this leaves him with not a lot of options but a simple turn left when your opponent thinks you will go right can save you.    You sort of just get a feeling. Previous moves, the players habbits etc. But the opponent can change his way of playing all of a sudden and surprise you. There is somewhat guessing involved in gameplay, predicting is essential. 

Link to comment
Share on other sites

Link to post
Share on other sites

Why would you ask a question just to say it couldn't be done? That's a big middlefinger to everyone answering your question. 

Use the quote function when answering! Mark people directly if you want an answer from them!

Link to comment
Share on other sites

Link to post
Share on other sites

Guest
This topic is now closed to further replies.

×