Gpop note counter

h

  1. // ==UserScript==
  2. // @name Gpop note counter
  3. // @namespace http://tampermonkey.net/
  4. // @version 0.1
  5. // @description h
  6. // @author osugamer983
  7. // @match https://gpop.io/play/*
  8. // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==
  9. // @grant none
  10. // ==/UserScript==
  11. (function() {
  12. 'use strict';
  13. window._$3q.prototype._$77 = function(a) {
  14. var b = a.key.toLowerCase();
  15. if (a.keyCode == 32) {
  16. if (this._$85 == true) {
  17. this._$bc();
  18. }
  19. a.preventDefault();
  20. } else if (b == "u") {
  21. if (this._$85 == true) {
  22. this._$4S();
  23. }
  24. a.preventDefault();
  25. } else if (b == "r") {
  26. if (this._$85 == true) {
  27. this._$39u();
  28. this._$40u()
  29. this._$7L();
  30. }
  31. a.preventDefault();
  32. }
  33. };
  34. window._$3q.prototype._$40u = function() {
  35. document.querySelector(".perfs").textContent = this.noteshitPerf;
  36. document.querySelector(".greats").textContent = this.noteshitGreat;
  37. document.querySelector(".goods").textContent = this.noteshitGood;
  38. document.querySelector(".oks").textContent = this.noteshitOk;
  39. document.querySelector(".totalhits").textContent = this.noteshitPerf+this.noteshitOk+this.noteshitGreat+this.noteshitGood
  40. document.querySelector(".misses").textContent = this.noteshitMiss;
  41. }
  42. window._$3q.prototype._$39u = function() {
  43. this.noteshitMiss = 0;
  44. this.noteshitOk = 0;
  45. this.noteshitGood = 0;
  46. this.noteshitGreat = 0;
  47. this.noteshitPerf = 0;
  48. };
  49. window._$3q.prototype._$bj = function(a) {
  50. this._$39u()
  51. this._$8V(a);
  52. this._$8E();
  53. this._$aj();
  54. this._$5g();
  55. this._$aB();
  56. this.mode = -1;
  57. this._$8C = 0.3;
  58. this._$6D = 15;
  59. this._$86 = 100 / this._$6D;
  60. this._$7n = 4;
  61. this._$z(false);
  62. this._$9z = false;
  63. this._$3E("load");
  64. this.gamespeed = 5;
  65. this._$5V = 50;
  66. this._$3Y = 10;
  67. this._$8i = false;
  68. this._$7t = 2;
  69. this._$8f = this._$7t / this._$6D;
  70. this._$V = 1.25;
  71. this._$5w = this._$V / this._$6D;
  72. this._$b7 = -1;
  73. this._$b8 = 500;
  74. this._$68 = 0;
  75. this._$bq = 0;
  76. this.lesslag = false;
  77. this._$8c();
  78. this.gm = "o";
  79. window.addEventListener("resize", this._$1y.bind(this));
  80. this._$1y();
  81. };
  82. window._$3q.prototype._$4k = function(a) {
  83. this._$5k(a);
  84. this._$3y[a] = _$7B.epoch() + 0.6 * 1000;
  85. this._$6N[a] = _$7B.epoch() + 0.08 * 1000;
  86. this.noteshitMiss += 1;
  87. this._$40u()
  88. this._$3o[a]["0"].style.opacity = 1;
  89. this._$3o[a]["0"].style.top = _$7B._$4K(-15, 15) + "px";
  90. this._$3o[a]["0"].style.left = _$7B._$4K(-5, 5) + "px";
  91. this._$3o[a]["0"].style.transform = "translateX(-50%) scale(1.2)";
  92. };
  93. window._$3q.prototype._$5n = function(a, c) {
  94. this._$5k(a);
  95. this._$3y[a] = _$7B.epoch() + 0.6 * 1000;
  96. this._$6N[a] = _$7B.epoch() + 0.08 * 1000;
  97. var b = "1";
  98. if (c < 0.5) {
  99. this.noteshitOk += 1;
  100. }
  101. else if (c < 0.75) {
  102. this.noteshitGood += 1;
  103. b = "2";
  104. } else if (c < 0.9) {
  105. this.noteshitGreat += 1;
  106. b = "3";
  107. } else {
  108. this.noteshitPerf += 1;
  109. b = "4";
  110. }
  111. this._$40u()
  112. this._$3o[a][b].style.opacity = 1;
  113. this._$3o[a][b].style.top = _$7B._$4K(-15, 15) + "px";
  114. this._$3o[a][b].style.left = _$7B._$4K(-5, 5) + "px";
  115. this._$3o[a][b].style.transform = "translateX(-50%) scale(1.2)";
  116. };
  117. })();