Inspiration
Ever since I first learned about API, I was always interested in exploring it more. I took this hackathon's opportunity to look at one of the most popular games today, Riot Game's League of Legends. I've always wanted to explore some match result data of my own account and compare them with my friends who also play the game. I'm also striving to work for Riot Games, so I found this as a good opportunity to try to use their API.
What it does
This simple python script has a menu interface with several methods to choose from. The user will choose what kind of statistics they would like to view and provide their (or other's) summoner names. Most of the parameters have default values, but the user could choose to provide some of these parameters.
How I built it
I mainly used a public library called "Cassiopeia" that made handling the API requests and data easier to work with.
Challenges I ran into
It took me few hours to get used to Riot's API and the module, Cassiopeia, but once I got used to how they work, it became a lot easier to write additional methods. One particular challenge I ran across in one of the methods is accessing the timeline of the matches I got from Riot. Most of the methods work with the end game result data, but for two methods, I needed to look at some of the data during the game (gold difference at x minutes). It took me a bit to figure out how to work with timeline and timestamp for each frame in the match. The problem was that Riot's timestamp used datetime timedelta, so I needed to simply learn how to use timedelta.
Accomplishments that I'm proud of
I'm proud of this entire project that I worked on individually. I learned a lot about Riot's API, and also, I was able to write methods that would calculate some of the statistics I wanted to see in my own matches on League of Legends. It was satisfying to actually see what I've wanted to see.
What I learned
I mostly learned about working with API and the module, Cassiopeia.
What's next for LeagueOfLegends_Ranked_Stats
I'm planning on adding more methods for different statistics and also polishing up some of the existing methods. I'll personally use this script often (as it was made for personal interest), but I would also love to see others use it.
Log in or sign up for Devpost to join the conversation.