A few years ago, I wrote a quick function to download all the pokemon pictures from www.pokemon.com/us/pokedex for my kids to create the equivalent of the pokedex:
Beyond that, I don’t know anything about Pokemon, so don’t ask me anything about them 😛
Due to the recent success of Pokémon Go, I thought that I should extend the function, make it more friendly, accessible,… and share it, of course 😀
If you like Pokemon and PowerShell, this page is for you. You’ll discover, get to know Pokemon and have them all at your finger tips in your favorite console:
The first thing to do is to capture all the pictures from the main site:
The function aims to download all the files. You can launch it, interrupt it, relaunch it. It’ll restart where it left till the end. You’ve got to have at least 720 (the current total of pokemon) jpeg files in the Pokedex folder so that the other functions work.
The Build-Pokedex function will always end by displaying how many Pokemon exist.
Now, to use the Find-Pokemon and Show-Pokemon, it’s pretty straightforward
If you just pipe the two cmdlets together, the picture will be shown:
Find-Pokemon -Name Kyurem | Show-Pokemon
If you use the -Online switch, the default browser should open the web page corresponding to the pokemon you looked for
Find-Pokemon -Name Kyurem | Show-Pokemon -Online
To discover a new Pokemon more randomly, you can do
0..720 | Get-Random | Find-Pokemon | Show-Pokemon -Online
Enjoy and have fun 😎