dlrocker / pikamon-py

Python native Pokemon bot for Discord
MIT License
0 stars 0 forks source link

Use the pokemon API to spawn a pokemon #5

Closed dlrocker closed 3 years ago

dlrocker commented 3 years ago

As part of #3 we created the logic and framework for spawning a pokemon. Now we need the actual code to spawn the pokemon. We also need to keep track of the pokemon's information so that we can use it later in the catch logic.

Can use the following to get information on the pokemon itself

https://pokeapi.co/api/v2/pokemon/<pokemon_id>

Can use the following to get pokemon images:

https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/other/official-artwork/<pokemon_id>.png

Currently the maximum pokemon ID that is supported through the API is 807, so we should not look for pokemon ID's past this number

dlrocker commented 3 years ago

In order to send the message we only need the pokemon's ID. This means that this is also all we currently need to store for the cache as well.