Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for 6.8.1 mastery changes #46

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

michaellavoie
Copy link

Hey I've enjoyed this app but noticed it stopped working since LOL 6.8.1 moved a few masteries around and changed their static data mastery.json file format a bit.

Code Changes
I saw the format for how the Mastery.Tree variable provided changed in the new mastery.json file so i updated the ChampionGG.vb to parse it from the new location.

Data/Json Changes
I also updated the masteries.json (called mastery.json now on the lol static data page) to the latest version and also updated coordinates.json file for the new mastery button locations.

Internal Utilities
Updating coordinates is a pain in the butt so i also added a "Json Utilities" folder with 3 linqpad scripts (linqpad is a free lightweight version of visual studio and is nice for small utility scripts). The big one "CoordinatesGenerator.linq" will automatically generate the coordinates.json file based off 2 bmp screenshot files (mastery page and champ select mastery page) as long as they are 1280x800 and you use a single pixel green dot to mark the upper left of each mastery icon (i've included example bmp that i used). My hope is if Riot keeps tweaking the mastery layout this will make it easier to keep up.

I'd be happy to go back and forth on the changes if there's anything you want to discuss further.

Best wishes,

-platy

…d the format of the mastery.json file. "Tree" field must now be parsed from a new location.

Also updated masteries.json to latest version adn updated coordinates.json for new/moved masteries
…on file in the future. Download the free tool https://www.linqpad.net/ to run these 3 scripts.

1) DownloadMasteryJson.linq - this will download the latest version of the masteries.json file. Usefule if the mastery file is updated by riot
2) CoordinatesGenerator.linq - this file will re-build the coordinates.json file for you based on the 2 bmp images you provide.  Take 2 screenshots of the lol app, one on the mastery editing page and one in the champ select mastery editing page.  Trim them down to 1280x800 file size (the default size of the app), then use a single pixel pencil tool with the color Green (red:0 green:255 blue:0, 00FF00) and mark a dot in the upper left corner of every mastery (they don't have to be perfectly on the corner, just close).  Save as a bmp and then run this script to re-generate the coordinates.json file.
3) ValidateCoordinatesJson.linq - Utility for validating the current mastery.json file and coordinates file look correct. Only needed if you need debugging help
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant