Derpthemeus / ChampionMastery.GG

League of Legends champion mastery highscores
https://championmastery.gg
MIT License
77 stars 28 forks source link

Display "Milestone" and "Mark of Mastery" progress as was introduced in the recent champion mastery update #53

Open AlexOliver98 opened 5 months ago

AlexOliver98 commented 5 months ago

Hi!

Before the recent champion mastery update, the service used to display how many champion mastery tokens were needed to progress to the next mastery level. It would be great if the service could display the new milestone and mark of mastery progress in the same way.

SariusGH commented 5 months ago

Hi, I think this is a good addition to the site! The required information should be provided by the champion mastery API.

{
    "puuid": "",
    "championId": 74,
    "championLevel": 2015,
    "championPoints": 22332350,
    "lastPlayTime": 1716898418000,
    "championPointsSinceLastLevel": 201750,
    "championPointsUntilNextLevel": -190750,
    "markRequiredForNextLevel": 2,
    "chestGranted": false,
    "tokensEarned": 1,
    "championSeasonMilestone": 7,
    "milestoneGrades": [
        "B",
        "...",
        "S+"
    ],
    "nextSeasonMilestone": {
        "requireGradeCounts": {
            "S-": 7
        },
        "rewardMarks": 1,
        "bonus": true
    }
},
{
    "puuid": "",
    "championId": 54,
    "championLevel": 27,
    "championPoints": 296843,
    "lastPlayTime": 1716859930000,
    "championPointsSinceLastLevel": 34243,
    "championPointsUntilNextLevel": -23243,
    "markRequiredForNextLevel": 2,
    "chestGranted": false,
    "tokensEarned": 0,
    "championSeasonMilestone": 0,
    "milestoneGrades": [
        "C+",
        "B-"
    ],
    "nextSeasonMilestone": {
        "requireGradeCounts": {
            "B-": 1,
            "C-": 4
        },
        "rewardMarks": 1,
        "bonus": false,
        "rewardConfig": {
            "rewardValue": "5f4333db-e90d-4705-903b-08dbf5e61006",
            "rewardType": "HEXTECH_CHEST",
            "maximumReward": 7
        }
    }
}

Comparing the "milestoneGrades" with the "requireGradeCounts" would allow tracking of which grades are required to reach the next Season Milestone.

Also looking at the "maximumReward" field, maybe a tracker of how many chests can still be earned this Season would also be possible alongside the Season Milestone tracker.