Make Upgradebar draggable.

Drag with right-click, upgrade with left click.

  1. // ==UserScript==
  2. // @namespace -
  3. // @grant none
  4. // @version 1.2.0.1
  5. // @author Stew#4055
  6. // @run-at document-start
  7. // @match *://moomoo.io/*
  8. // @match *://dev.moomoo.io/*
  9. // @match *://sandbox.moomoo.io/*
  10. // @supportURL https://discord.com/invite/G2gJFbx7GD
  11. // @name Make Upgradebar draggable.
  12. // @description Drag with right-click, upgrade with left click.
  13. // @require http://code.jquery.com/jquery-latest.min.js
  14. // ==/UserScript==
  15. document.addEventListener("DOMContentLoaded", () => {
  16. class a {
  17. constructor() {
  18. $("body").on("contextmenu", function (e) {
  19. return false;
  20. });
  21. let e = document.getElementById("upgradeHolder");
  22. e.addEventListener("mousedown", function (t) {
  23. if (3 === t.which) {
  24. let o = t.clientX,
  25. i = t.clientY;
  26.  
  27. function n(t) {
  28. let n = o - t.clientX,
  29. l = i - t.clientY;
  30. const c = e.getBoundingClientRect();
  31. e.style.left = c.left - n + "px", e.style.top = c.top - l + "px", o = t.clientX, i = t.clientY
  32. }
  33. window.addEventListener("mousemove", n), window.addEventListener("mouseup", function e() {
  34. window.removeEventListener("mousemove", n), window.removeEventListener("mouseup", e)
  35. })
  36. }
  37. })
  38. }
  39. }
  40. new a;
  41. })

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址