xivanalysis Button

Jump from FFlogs fight to respective xivanalysis page with a button. Redirects to selected player and pull (if any), or to the report page per default.

  1. // ==UserScript==
  2. // @name xivanalysis Button
  3. // @namespace dansa#5509
  4. // @version 1.1
  5. // @description Jump from FFlogs fight to respective xivanalysis page with a button. Redirects to selected player and pull (if any), or to the report page per default.
  6. // @author dansa
  7. // @match https://*.fflogs.com/reports/*
  8. // @match https://fflogs.com/reports/*
  9. // @run-at document-idle
  10. // @grant GM_addStyle
  11. // ==/UserScript==
  12.  
  13. GM_addStyle(".xivabtn { position: fixed; z-index: 2000; bottom:0; right:0; background-color: #202020;}");
  14. GM_addStyle(".xivaimg { height:33px;width:33px;margin:5px;background-image: url(https://xivanalysis.com/logo.png);background-size: contain;}");
  15.  
  16. (function () {
  17. $("body").append("<div class='report-overview-boss-box xivabtn'><a id='xivabtn' href='"+ "https://xivanalysis.com/report-redirect/" + location.href +"'><div class='xivaimg'></div></a></div>");
  18. })();
  19.  
  20. window.onhashchange = function() {
  21. $("#xivabtn").attr("href", "https://xivanalysis.com/report-redirect/" + location.href);
  22. };