您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
instantly respawn with a press of a button
当前为
// ==UserScript== // @name respawn script for tricksplit.io // @namespace http://tampermonkey.net/ // @version 2.4 // @description instantly respawn with a press of a button // @author sos // @match https://tricksplit.io/ // @grant none // ==/UserScript== var socialKeys = document.getElementsByClassName('main')[0]; var menu = document.getElementsByClassName('menu'); var endPanel = document.getElementsByClassName('end'); var closePanel = document.getElementsByClassName('closePanel'); window.onload = function(){ closePanel[0].click(); // automaticlly closes the newSkins window at the start of the game window.addEventListener('keydown', keydown); window.addEventListener('keyup', keyup); window.game.animationDelay = 50; // Set this to any animation delay you want, !WARNING! if you set the animation delay below 1, your game is not gonna work setTimeout(startCollection, 5000); createKeys('Respawn', "respawn"); createKeys('Freeze', "freeze"); createKeys('FakeClip', "fake"); }; function startCollection() { var freeCoins = document.getElementById("freeCoins"); freeCoins.onclick = function() { console.log('auto coins collection started'); window.game.api.utils.claimFreeCoins(); setInterval(collectCoins, 7210000); } } function collectCoins() { window.game.api.utils.claimFreeCoins(); } function keydown(event) { if (event.keyCode == document.getElementById('respawn').value.charCodeAt(0) - 32 && window.game.chat.focused === false) { spawn(); } if (event.keyCode == document.getElementById('freeze').value.charCodeAt(0) - 32 && window.game.chat.focused === false) { var X = window.innerWidth/2; var Y = window.innerHeight/2; $("canvas").trigger($.Event("mousemove", {clientX: X, clientY: Y})); } if (event.keyCode == document.getElementById('fake').value.charCodeAt(0) - 32 && window.game.chat.focused === false) { window.game.socket.split(); setTimeout(function() { window.game.socket.send(new Uint8Array([0x33])) setTimeout(function() { window.game.socket.send(new Uint8Array([0x18])) }, 400) }, 500) } } function keyup(event) { if (event.keyCode == 68) { return; } } function spawn() { if (menu[0].style.display === "none") { window.game.socket.onClose("xd"); endPanel[0].style.display = "none"; document.getElementById('overlays').style.display = "none"; setTimeout(function() { window.game.spawn(); }, 1000); } } function createKeys(name, id) { var hotKey = document.createElement("div"); hotKey.setAttribute("class", "hotkey"); hotKey.setAttribute("style", "margin-bottom:5px") socialKeys.appendChild(hotKey); var hotKeyName = document.createElement("div"); hotKeyName.setAttribute("class", "hotkeyName"); hotKeyName.innerText = name; hotKey.appendChild(hotKeyName); var hotKeyCode = document.createElement("div"); hotKeyCode.setAttribute("class", "hotkeyCode"); hotKey.appendChild(hotKeyCode); var hotKeyInput = document.createElement("div"); hotKeyInput.setAttribute("class", "hotkeyInput"); hotKeyCode.appendChild(hotKeyInput); var keyInput = document.createElement("input"); //keyInput.setAttribute("class", "keyCode"); keyInput.setAttribute("type", "text"); keyInput.setAttribute("maxlength", "1"); keyInput.setAttribute("id", id); keyInput.setAttribute("style", "text-align:center;background-color:#adadae;text-transform:capitalize;font-size:24px;width:30px;position:absolute; right:250%"); hotKeyInput.appendChild(keyInput); } // https://docstore.mik.ua/orelly/webprog/DHTML_javascript/0596004672_jvdhtmlckbk-app-b.html \\ Link for key codes numbers