Macro para agariopvt

Dê massa rapidamente e splite rapidamente também! Use as teclas W e T.

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください。
  1. // ==UserScript==
  2. // @name Macro para agariopvt
  3. // @author ThousZ
  4. // @description Dê massa rapidamente e splite rapidamente também! Use as teclas W e T.
  5. // @match http://agar.io/*
  6. // @match http://agariopvt.com/play*
  7. // @match http://es.agareoz.com/*
  8. // @grant none
  9. // @version 0.0.1.20170301012747
  10. // @namespace https://greasyfork.org/users/106355
  11. // ==/UserScript==
  12.  
  13. window.settings = {
  14. start: function(){
  15. this.macros();
  16. },
  17.  
  18. macros: function(){
  19. window.addEventListener('keydown', keydown);
  20. window.addEventListener('keyup', keyup);
  21.  
  22. var ejecting = false;
  23. var splitSpeed = 26;
  24. var ejectSpeed = 28;
  25.  
  26. function keydown(event) {
  27. if (event.keyCode == 87 && ejecting === false) {
  28. ejecting = true;
  29. setTimeout(eject, ejectSpeed);
  30. }
  31. if (event.keyCode == 84) {
  32. split();
  33. setTimeout(split, splitSpeed);
  34. setTimeout(split, splitSpeed*2);
  35. setTimeout(split, splitSpeed*3);
  36. }
  37. }
  38.  
  39. function keyup(event) {
  40. if (event.keyCode == 87) {
  41. ejecting = false;
  42. }
  43. }
  44.  
  45. function eject() {
  46. if (ejecting) {
  47. window.onkeydown({keyCode: 87});
  48. window.onkeyup({keyCode: 87});
  49. setTimeout(eject, ejectSpeed);
  50. }
  51. }
  52.  
  53. function split() {
  54. $("body").trigger($.Event("keydown", { keyCode: 32}));
  55. $("body").trigger($.Event("keyup", { keyCode: 32}));
  56. }
  57. }
  58. };
  59. settings.start();