I am The First Son of the Hurricane and the Grand Master of the Storm Order.
This article desires to remind people the importance of scraping and collecting data the hard way. If you can manage to pull off such feats, you can perform wonders that rival OpenAi and Deepmind.
Video demonstration is here and at the bottom of the article.
Hopefully after watching the video and reading the article, you understand why I am the Emperor of Pokémon Ai.
Ai bots for games are held back due to the difficulty of collecting the necessary data to give a neural network. Games are not designed for this in mind. Fortunately, there are ways around this limitation. Either the data is given to you, or it is taken.
Game data exists in the Ether. It exists, and nothing prevents you from taking it aside from your skill and will.
We’re all familiar with Alpha Go tackling Go and OepnAi Five tackling Dota 2. Those feats are both nice, but they have limits.
In the game of Go, the environment was create by Deepmind and thus all information of interest is readily available for them to train on.
In the event of OpenAi Five, they are provided with tools that are not available to the public. So that is data being handed to them from the creators.
For this Article, Pokémon Sword and Shield will be used, but you can easily replace with other games.
To make Ai bots for Pokémon of the simplest form, you might need to enter all the information for your team and who you are fighting.
When playing the game, all this information is readily available to you, even during a match. You just have to collect the data.
You could write down by hand all this information and have it represented your observation space, or you can have software collect this information.
On the screen below, you can see some stats information of a Pokémon. Using common computer vision tools such as OCR, you can easily extract the numbers to construct the team yourself.
On the following two screens, you can information related to your opponent. You can use this to deduce who you are fighting and add this to your observation space.
On this screen you can look at your available/legal attacks. These can represent the different actions you want to take: action1, action2, action3, action4 respectively.
By scanning all these screens you can construct an observation space that contains your Team’s stats and attacks, their status (Poisoned, Fainted, Frozen, etc), and your current opponent. Your actions will be the available attacks.
From there you can use any behavior cloning techniques you know to make Ai bots that can play similar to a human.
It is important to note that in Pokémon, not all actions are legal at a given time. One example would be if a Pokémon is taunted, a good portion of attacks are not legal. How to handle that logic is beyond the scope of this article.
I must warn you, this style of programming is no walk in the park. If you dare to try something like this, I STRONGLY recommend games simpler than Pokémon Battles. Or if you insist on Pokémon, then either automate everything or automate nothing. You have no idea the horrors that await you.
In the video at the bottom, you can see all of this automated. But starting out, you do not need to automate. You could manually navigate to the screens of interest, and run your script to collect the data.
Korean Voice Over English Closed Captions.
English Voice Over Version
I am a Digidestined who is a Pokémon Ai specialist. I have been studying Pokémon Ai in secret for a long time. That is why I can do these things.
I have many tools related to Pokémon Ai. This is just one of them.