Number 1 Highlighter

Highlights Number One Stuff

当前为 2015-04-13 提交的版本,查看 最新版本

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name          Number 1 Highlighter
// @namespace     FaxCelestis
// @description   Highlights Number One Stuff
// @include       *animecubed.com/billy/bvs/numberone*
// @grant         GM_addStyle
// @author        FaxCelestis
// @version       1.0g
// ==/UserScript==

var player = document.getElementsByName("player")[1].value;

function highlight()
{
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 1 Event/g, 'color:white\"><span style=\"background-color:red\">Tier 1 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 2 Event/g, 'color:black\"><span style=\"background-color:orange\">Tier 2 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 3 Event/g, 'color:black\"><span style=\"background-color:yellow\">Tier 3 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 4 Event/g, 'color:black\"><span style=\"background-color:green\">Tier 4 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 5 Event/g, 'color:white\"><span style=\"background-color:blue\">Tier 5 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/color:red\">Tier 11 Event/g, 'color:white\"><span style=\"background-color:purple\">Tier 11 Event<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 10/g, '<b><span style=\"color:white;background-color:red\">Round 10<\/span><br><sup>\(-1 HP per turn!\)<\/sup>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 11/g, '<b><span style=\"color:white;background-color:red\">Round 11<\/span><br><font size=\"1\"><sup>\(-1 HP per turn!\)<\/sup><\/font>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 12/g, '<b><span style=\"color:white;background-color:red\">Round 12<\/span><br><font size=\"1\"><sup>\(-1 HP per turn!\)<\/sup><\/font>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 13/g, '<b><span style=\"color:white;background-color:red\">Round 13<\/span><br><font size=\"1\"><sup>\(-1 HP per turn!\)<\/sup><\/font>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 14/g, '<b><span style=\"color:white;background-color:red\">Round 14<\/span><br><font size=\"1\"><sup>\(-1 HP per turn!\)<\/sup><\/font>');
document.body.innerHTML = document.body.innerHTML.replace(/<b>Round 15/g, '<b><span style=\"color:white;background-color:red\">Round 15<\/span><br><font size=\"1\"><sup>\(-1 HP per turn!\)<\/sup><\/font>');
document.body.innerHTML = document.body.innerHTML.replace(/Battle 1/g, '<span style=\"font-variant:small-caps;color:red\">Battle 1<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/Battle 2/g, '<span style=\"font-variant:small-caps;color:red\">Battle 2<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/Battle 3/g, '<span style=\"font-variant:small-caps;color:red\">Battle 3<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/Battle 4/g, '<span style=\"font-variant:small-caps;color:red\">Battle 4<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/Final Battle!/g, '<span style=\"font-variant:small-caps;color:red\">Final Battle!<\/span>');
document.body.innerHTML = document.body.innerHTML.replace(/Final Battle!/g, '<span style=\"font-variant:small-caps;color:red\">Final Battle!<\/span>');
document.body.innerHTML = document.body.innerHTML.split('<td>'+player+'<\/td>').join('<td><span style=\"color:black;background-color:yellow\">'+player+'<\/span><\/td>')
document.body.innerHTML = document.body.innerHTML.split('<strike>'+player+'<\/strike>').join('<strike><span style=\"color:white;background-color:red\">'+player+'<\/span><\/strike>')
document.body.innerHTML = document.body.innerHTML.split('<b>'+player+'<\/b>').join('<b><span style=\"color:white;background-color:green\">'+player+'<\/span><\/b>')
}

highlight();