Gota Script

T - 16 Split -|- Y - Triple Split -|- U - Double Split -|- Tab - Cursor Center

目前為 2016-10-29 提交的版本,檢視 最新版本

  1. // ==UserScript==
  2. // @name Gota Script
  3. // @namespace Pretty Good Gota Script
  4. // @description T - 16 Split -|- Y - Triple Split -|- U - Double Split -|- Tab - Cursor Center
  5. // @version 7.5
  6. // @author FFEC & Freebie - Editted By Silf
  7. // @match http://gota.io/web/*
  8. // @grant GM_addStyle
  9. // ==/UserScript==
  10.  
  11. function addStyleSheet(style){
  12. var getHead = document.getElementsByTagName("HEAD")[0];
  13. var cssNode = window.document.createElement( 'style' );
  14. var elementStyle= getHead.appendChild(cssNode);
  15. elementStyle.innerHTML = style;
  16. return elementStyle;
  17. }
  18.  
  19. //Custom Font, Logo, Minimap
  20. addStyleSheet('@import url(https://fonts.googleapis.com/css?family=Ubuntu);');
  21. GM_addStyle('* #logo {background-image: url("http://i.imgur.com/l0QnU0E.png");}');
  22. GM_addStyle('* #minimap-canvas {background-image: url("http://i.imgur.com/QMBgZaC.png");}');
  23. GM_addStyle('*{font-family: Ubuntu;}');
  24. GM_addStyle('* .coordinates {font-family: Ubuntu;}');
  25. GM_addStyle('* #leaderboard-panel {font-size: 24px;}');
  26.  
  27. var fillTextz = CanvasRenderingContext2D.prototype.fillText;
  28. CanvasRenderingContext2D.prototype.fillText = function(){
  29. var argumentz = arguments;
  30. if(this.canvas.id == 'leaderboard-canvas'){
  31. this.font = 'bold 15px Ubuntu';
  32. }
  33. if(this.canvas.id == 'minimap-canvas'){
  34. this.font = 'bold 15px Ubuntu';
  35. }
  36. if(this.canvas.id == 'party-canvas'){
  37. this.font = 'bold 15px Ubuntu';
  38. }
  39. fillTextz.apply(this, arguments);
  40. };
  41.  
  42. //Border Removal
  43. document.getElementById("leaderboard-panel").style.borderRadius = "0";
  44. document.getElementById("leaderboard-panel").style.borderWidth = "0px";
  45. document.getElementById("leaderboard-panel").style.boxShadow = "0px 0px 0px black";
  46. document.getElementById("score-panel").style.borderRadius = "0";
  47. document.getElementById("score-panel").style.borderWidth = "0px";
  48. document.getElementById("score-panel").style.boxShadow = "0px 0px 0px black";
  49. document.getElementById("minimap-panel").style.borderRadius = "0";
  50. document.getElementById("minimap-panel").style.borderWidth = "0px";
  51. document.getElementById("minimap-panel").style.boxShadow = "0px 0px 0px black";
  52. document.getElementById("minimap-panel").style.marginBottom = "3px";
  53. document.getElementById("party-panel").style.borderRadius = "0";
  54. document.getElementById("party-panel").style.borderWidth = "0px";
  55. document.getElementById("party-panel").style.boxShadow = "0px 0px 0px black";
  56.  
  57. //Panel Borders
  58. GM_addStyle('* .main-panel {border: solid 3px rgba(99, 97, 95, 0.5)}');
  59. GM_addStyle('* .main-panel {border-radius: 0px}');
  60. GM_addStyle('* .main-panel {box-shadow: 0px 0px 0px 0px rgba(0,0,0,0.52)}');
  61. GM_addStyle('* .gota-btn {border-radius: 15px}');
  62. GM_addStyle('* .main-bottom-stats {border-radius: 5px}');
  63. GM_addStyle('* #popup-party {border-radius: 0px}');
  64. GM_addStyle('* #popup-party {box-shadow: 0px 0px 0px 0px rgba(0,0,0,0.25)}');
  65. GM_addStyle('* #popup-login {border-radius: 0px}');
  66. GM_addStyle('* #popup-login {box-shadow: 0px 0px 0px 0px rgba(0,0,0,0.25)}');
  67. GM_addStyle('* .login-input {border-radius: 0px}');
  68. GM_addStyle('* #chat-input {border-radius: 0 0 0px 0px}');
  69. GM_addStyle('* .ui-pane {box-shadow: 0px 0px 0px 0px rgba(0,0,0,0.52)}');
  70.  
  71. //Chat Size
  72. GM_addStyle('* #chat-panel {width: 300px}');
  73. GM_addStyle('* #chat-panel {height: 195px}');
  74.  
  75. //Social Media Buttons Removal
  76. $(".main-bottom-links").replaceWith("");
  77.  
  78. //Instructions
  79. var maincontent = document.getElementById("main-content");
  80. var version = document.createElement("div");
  81. version.innerHTML = 'T - Tricksplit -|- Y - Triplesplit -|- U - Double split -|- Tab - Linesplit';
  82. version.id = 'instructions';
  83. maincontent.appendChild(version);
  84. document.getElementById("instructions").style.textAlign = "center";
  85. document.getElementById("instructions").style.fontSize = "12px";
  86. document.getElementById("instructions").style.color = "white";
  87.  
  88. //LeaderBoard
  89. var fz = "   ᒪᗴᗩᗪᗴᖇ ᗷᗝᗩᖇᗪ";
  90.  
  91. $(".lh").replaceWith(fz);
  92.  
  93. $("#main-rb").replaceWith("");
  94. GM_addStyle ('* #main {left: 350px;}');
  95.  
  96. $("#btnforums").replaceWith("");
  97. GM_addStyle ('* #main {left: 350px;}');
  98.  
  99. //Custom Cursor
  100. GM_addStyle ('* body {cursor: crosshair;}');
  101.  
  102. //Line Split Macro
  103. document.onkeydown = checkKey;
  104. function checkKey(e) {
  105. e = e || window.event;
  106. if (e.keyCode == '9') {
  107. player.mouseRawX = canvas.width / 2;
  108. player.mouseRawY = canvas.height / 2;
  109. }
  110. }
  111.  
  112. //Double Split
  113. (function() {
  114. var amount = 2;
  115. var duration = 5;
  116.  
  117. var overwriting = function(evt) {
  118. if (evt.keyCode === 85) {
  119. for (var i = 0; i < amount; ++i) {
  120. setTimeout(function() {
  121. window.onkeydown({keyCode: 32});
  122. window.onkeyup({keyCode: 32});
  123. }, i * duration);
  124. }
  125. }
  126. };
  127.  
  128. window.addEventListener('keydown', overwriting);
  129. })();
  130.  
  131. //Triple Split Macro
  132. (function() {
  133. var amount = 3;
  134. var duration = 5;
  135.  
  136. var overwriting = function(evt) {
  137. if (evt.keyCode === 89) {
  138. for (var i = 0; i < amount; ++i) {
  139. setTimeout(function() {
  140. window.onkeydown({keyCode: 32});
  141. window.onkeyup({keyCode: 32});
  142. }, i * duration);
  143. }
  144. }
  145. };
  146.  
  147. window.addEventListener('keydown', overwriting);
  148. })();
  149.  
  150. //16 Split Macro
  151. (function() {
  152. var amount = 4;
  153. var duration = 5;
  154.  
  155. var overwriting = function(evt) {
  156. if (evt.keyCode === 84) {
  157. for (var i = 0; i < amount; ++i) {
  158. setTimeout(function() {
  159. window.onkeydown({keyCode: 32});
  160. window.onkeyup({keyCode: 32});
  161. }, i * duration);
  162. }
  163. }
  164. };
  165.  
  166. window.addEventListener('keydown', overwriting);
  167. })();
  168. //Remove some of the code sections if you dislike them