// ==UserScript== // @id scanner-link@xMAXIMx // @name IITC plugin: Scanner link // @version 0.1 // @description Adds scanner link to IITC // @author xMAXIMx // @category Info // @include *://*.ingress.com/* // @match *://*.ingress.com/* // ==/UserScript== function wrapper(plugin_info) { if(typeof window.plugin !== 'function') window.plugin = function(){}; window.plugin.scannerLink = function () {}; window.plugin.scannerLink.portalInfo = function () {$('.linkdetails').append('');}; function setup() {window.addHook('portalDetailsUpdated', window.plugin.scannerLink.portalInfo);} setup.info = plugin_info; if (!window.bootPlugins) window.bootPlugins = []; window.bootPlugins.push(setup); if (window.iitcLoaded && typeof setup === 'function')setup(); } var script = document.createElement('script'); var info = {}; if (typeof GM_info !== 'undefined' && GM_info && GM_info.script) {info.script = {version: GM_info.script.version,name: GM_info.script.name,description: GM_info.script.description};} var textContent = document.createTextNode('('+ wrapper +')('+ JSON.stringify(info) +')'); script.appendChild(textContent); (document.body || document.head || document.documentElement).appendChild(script);