Arbybear

TagPro Wins Until Next Degree

Jul 15th, 2015
202
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. // ==UserScript==
  2. // @name TagPro Wins Until Next Degree
  3. // @namespace http://www.reddit.com/user/tpcarl/
  4. // @description Displays wins needed until next degree on score screen.
  5. // @include http://tagpro-*.koalabeast.com*
  6. // @include http://*.jukejuice.com:*
  7. // @license GPL version 3 or any later version; http://www.gnu.org/copyleft/gpl.html
  8. // @author ben, modified by ballparts
  9. // @version .1
  10. // ==/UserScript==
  11.  
  12. $('article > div.section.smaller').after( "<center><h3><div><p id='winsneeded'></p></div></h3></center>" );
  13.  
  14. url = $('a[href^="/profile"]').attr('href');
  15. if(url !== undefined) {
  16. var n = url.lastIndexOf('/');
  17. var profileNum = url.substring(n + 1);
  18. profilePage = String('/profile/'+profileNum);
  19. sessionStorage.setItem('profilePage',profilePage);
  20.  
  21. }
  22.  
  23.  
  24. if(document.URL.search('profile')<1) {
  25. $( "#winsneeded" ).load(sessionStorage.getItem('profilePage') + ' article > h3 > div', function(){
  26. $('#winsneeded > div:last-child').css({'font-size':'50%'});
  27. });
  28. }
Add Comment
Please, Sign In to add comment