// ==UserScript== // @name 我的世界梦想之都自动签到 // @namespace https://itwxb.gitee.io/ // @version 0.1 // @description 我的世界自动签到回复 // @author qiaomu // @license GPL-3.0 // @match *://*/* // @icon https://www.google.com/s2/favicons?sz=64&domain=juejin.cn // @grant GM_registerMenuCommand // @grant GM_setValue // @grant GM_getValue // @run-at document-idle // @downloadURL none // ==/UserScript== (function () { "use strict"; // Your code here... // 签到网站 const H_zfw = "https://www.fansmc.com/server/731.html"; const H_bk = "https://play.mcmod.cn/sv20186914.html"; const H_klpqd = "https://klpbbs.com/k_misign-sign.html"; const H_klphf = "https://klpbbs.com/forum.php?mod=viewthread&tid=67975&extra=page%3D1&page=1"; // 菜单按钮 GM_registerMenuCommand("自动签到", auto, "h"); // 进入浏览器自动执行签到 window.onload = autoBtn(); function auto() { window.open(H_zfw); window.open(H_bk); window.open(H_klpqd); window.open(H_klphf); } function autoBtn() { const btns = document.querySelectorAll(".btn-group"); if (btns.length > 1) { const btna = btns[2].getElementsByTagName("a"); btna[0].click(); } const bkbtn = document.querySelector(".thumbup"); const masterup = document.querySelector(".masterup"); if (bkbtn) { bkbtn.click(); masterup.click(); } const text = document.getElementById("fastpostmessage"); const textBtn = document.getElementById("fastpostsubmit"); if (text) { text.value = "一起来玩吧,欢迎大家"; textBtn.click(); } const klpqd = document.querySelector(".lineB .qdleft .btn"); if (klpqd) { klpqd.click(); } } })();