// ==UserScript== // @description 快速下注,自动签到,查积分,地图通过率 // @icon https://apic.douyucdn.cn/upload/avatar/002/86/30/15_avatar_big.jpg // @name 斗鱼超级小桀房间工具 // @version 1.0 // @match https://www.douyu.com/74751 // @match https://www.douyu.com/cave // @grant none // @namespace https://greasyfork.org/users/142968 // @require https://greasyfork.org/scripts/31852-zjyong/code/zjyong.js?version=208667 // @downloadURL none // ==/UserScript== var dragFlag = false; var x,y; var URL var yiqian = true var lastText = "" var acf_did = getCookie('acf_did') var nickname = getCookie('acf_nickname') var acf_uid = getCookie('acf_uid') var acf_ltkid = getCookie('acf_ltkid') var acf_stk = getCookie('acf_stk') var ver = "1.0" var div = document.createElement('div'); div.setAttribute('id', 'newDiv'); div.addEventListener('mousedown', down, false); document.addEventListener('mousemove', move, false); document.addEventListener('mouseup', up, false); div.innerHTML = "自动签到"; //显示积分 div.style.setProperty('position', 'absolute'); div.style.setProperty('width', '201px'); div.style.setProperty('height', '275px'); div.style.setProperty('background', '#eff7ff'); div.style.setProperty('left', '960px'); div.style.setProperty('top', '10px'); div.style.setProperty('border', '1px solid #96c2f1'); div.style.setProperty('z-index', '999'); div.style.setProperty('box-shadow', '0 1px 5px 4px #888888'); document.body.appendChild(div); var arr=new Array("bnt_qyl1","bnt_qyl2","bnt_yyb1","bnt_yyb2","bnt_xxlb","bnt_qd","#1 老子全压了","#2 老子全压了","#1 老子压一半","#2 老子压一半","#谢谢老板","#入团"); for (var i=0;i<6;i++) { addevent(arr[i],arr[i+6]) } //document.getElementById('viewjf').addEventListener('click', function (event) { view_jf(); }, false); document.getElementById('bnt_cf').addEventListener('click', function (event) { cd(); }, false); var swfobj = document.getElementById("douyu_room_flash_proxy"); var k = crc64(ver + nickname).toString(16); chajifen(); chaditu(); setInterval( function(){ //if(document.getElementById("viewjf").checked) { //chajifen(); chaditu(); //} if(document.getElementById("autoqd").checked) { qd(); } },7000); function addevent(id,str) { document.getElementById(id).addEventListener('click', function (event) { danmu(str); }, false); } function cd() { $("#bnt_cf").attr("disabled", true); chajifen(); window.setTimeout(cd_done,10000); } function cd_done() { $("#bnt_cf").attr("disabled", false); } function chajifen() { URL = 'https://www.zyz2000.ml:9987/info?target=jf&name=' + nickname + '&k=' + k fetch(URL).then(function(response) { return response.text(); }).then(function(json) { $(".jifenxianshi").val(json); }); } function chaditu() { URL = 'https://www.zyz2000.ml:9987/info?target=dt&name=' + nickname + '&k=' + k fetch(URL).then(function(response) { return response.text(); }).then(function(json) { $(".dituxianshi").val(json); }); } function down(e) { e = e || window.event; x = e.clientX - div.offsetLeft; y = e.clientY - div.offsetTop; div.style.cursor="move" dragFlag = true; } function move(e) { if (dragFlag) { e = e || window.event; div.style.left = e.clientX - x + 'px'; div.style.top = e.clientY - y + 'px'; } } function up(e) { dragFlag = false; div.style.cursor="auto" } function qd(){ var date=new Date(); var m=date.getMinutes(); if(m==0||m==30){ if (yiqian) { danmu("#签到"); yiqian = false } } else {yiqian = true} } function danmu(str){ if (!swfobj) {swfobj = document.getElementById("douyu_room_flash_proxy")} if (str == lastText){ for (var i=0;i