adiphy script


SUBMITTED BY: deadman44

DATE: Feb. 13, 2017, 4:39 p.m.

FORMAT: Text only

SIZE: 1.4 kB

HITS: 881

  1. // ==UserScript==
  2. // @name ADIPHY Bot
  3. // @namespace http://adiphy.com/
  4. // @version 1.0
  5. // @description Start and Stop button to bot on Adiphy
  6. // @author Mariechan
  7. // @match http://adiphy.com/
  8. // @grant none
  9. // ==/UserScript==
  10. (function() {
  11. 'use strict';
  12. $(document).ready(function(){
  13. var flag=0;
  14. var token;
  15. var site;
  16. var alias;
  17. $('.infostop:first').prepend('<li><button id="stop" type="button" class="btn btn-danger" style="height:50px;width:80px;">Stop</button></li>');
  18. $('.infostop:first').prepend('<li><button id="start" type="button" class="btn btn-primary" style="height:50px;width:80px;">Start</button></li>');
  19. $('#start').click(function(){
  20. flag=1;
  21. run();
  22. });
  23. $('#stop').click(function(){
  24. flag=0;
  25. });
  26. function run(){
  27. var interval_obj = setInterval(function(){
  28. token=$("#user-token").text();
  29. site=$('.item-site:first').text();
  30. alias=$('.item-site:first').parent().find(".item-alias").text();
  31. e=window.open(site+"/"+alias+"/"+token,"botvn","width=50,height=50,top=20000,left=100000,status=0,toolbar=no");
  32. if(flag===0)
  33. clearInterval(interval_obj);
  34. }, 4000);
  35. }
  36. });
  37. })();

comments powered by Disqus