LeagueSets is an easy to use chrome extension that allows users to quickly download in-game item sets from popular guide sites such as Mobafire, ProBuilds, ChampionGG and U.GG
LeagueSets is the winner of Riot Games API Challenge 2.0, Item Sets Category. A Chrome extension allows the benefit of convenience, and allows player to use the vast resources of information already available on various sites.
Go to the Chrome App Store for LeagueSets and install normally.
Install LeagueSets, then...
Open up the manifest and add your script with a url to the guides section of the site.
{
"matches": ["URL_OF_GUIDES_SECTION"],
"js": ["./scripts/your_script"]
},
Your script will follow the same structure as outlined below, where it will return a BLOCKS object when called.
var BLOCKS;
chrome.runtime.sendMessage({
from: 'content',
subject: 'showPageAction'
});
chrome.runtime.onMessage.addListener(function(msg, sender, response) {
if ((msg.from === 'popup') && (msg.subject === 'guide')) {
//code here
response(BLOCK);
}
});
The BLOCKS object must contain a title, and multiple item blocks for your set. The item sets require a title, and a list of item ids.
var BLOCKS = {
title: "title_of_guide",
items: [
{
header: "title_of_block",
items: ["2003","2004, ..."]
},
{
..
},
]
};
Some sites may use there own custom item id's. In which case you will have to provide a JSON table of values to convert
(Remeber to include this file in the manifest). There is a template, /scripts/templates/table_template.js that may be helpful. The mobafire script is an example of this.
LeagueSets isn't endorsed by Riot Games and doesn't reflect the views or opinions of Riot Games or anyone officially involved in producing or managing League of Legends. League of Legends and Riot Games are trademarks or registered trademarks of Riot Games, Inc. League of Legends © Riot Games, Inc.