您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Drag with right-click, upgrade with left click.
当前为
- // ==UserScript==
- // @namespace -
- // @grant none
- // @version 1.2.0
- // @author Stew#4055
- // @run-at document-start
- // @match *://moomoo.io/*
- // @match *://dev.moomoo.io/*
- // @match *://sandbox.moomoo.io/*
- // @supportURL https://discord.gg/G2gJFbx7GD
- // @name Make Upgradebar draggable.
- // @description Drag with right-click, upgrade with left click.
- // @require http://code.jquery.com/jquery-latest.min.js
- // ==/UserScript==
- document.addEventListener("DOMContentLoaded", () => {
- class a {
- constructor() {
- $("body").on("contextmenu", function (e) {
- return false;
- });
- let e = document.getElementById("upgradeHolder");
- e.addEventListener("mousedown", function (t) {
- if (3 === t.which) {
- let o = t.clientX,
- i = t.clientY;
- function n(t) {
- let n = o - t.clientX,
- l = i - t.clientY;
- const c = e.getBoundingClientRect();
- e.style.left = c.left - n + "px", e.style.top = c.top - l + "px", o = t.clientX, i = t.clientY
- }
- window.addEventListener("mousemove", n), window.addEventListener("mouseup", function e() {
- window.removeEventListener("mousemove", n), window.removeEventListener("mouseup", e)
- })
- }
- })
- }
- }
- new a;
- })