您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Hotkeys for BvS Crane
// ==UserScript== // @name BvS crane hotkeys // @namespace [email protected] // @description Hotkeys for BvS Crane // @include http://*animecubed.com/billy/bvs/partyhouse.html // @version 1.2 // @grant GM_getValue // @grant GM_setValue // ==/UserScript== var setDiff = function(diff) { var diffElem = document.querySelector('input[name="cranepick"][value="' + diff + '"]'); if (diffElem) { diffElem.checked = true; } }; var submitted = false; var play = function() { var selectedDiff = document.querySelector('[name="cranepick"]:checked'); if (!selectedDiff) { return; } GM_setValue('diff', selectedDiff.value); if (submitted) return; submitted = true; document.cgame.submit(); }; var warned = false; var kick = function() { if (/: Crane/.test(document.cgame.textContent)) { alert('Crane potion detected; are you sure you want to kick?'); warned = true; return; } if (submitted) return; submitted = true; document.cgamek.submit(); }; var main = function() { if (!document.cgame) return; var lastDiff = GM_getValue('diff'); if (lastDiff) { setDiff(lastDiff); } document.addEventListener('keyup', function(e) { switch (e.code) { case 'KeyD': play(); break; case 'KeyK': kick(); break; case 'KeyE': setDiff(1); break; case 'KeyM': setDiff(2); break; case 'KeyH': setDiff(3); break; case 'KeyS': setDiff(4); break; } }); }; main();
QingJ © 2025
镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址