Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // ==UserScript==
- // @name slashers Helper
- // @namespace edited ls
- // @include http://ladderslasher.d2jsp.org/v1.30/
- // @version 2.0
- // @grant none
- // ==/UserScript==
- function addGlobalStyle(css) {var head;var style;
- head = document.getElementsByTagName('head') [0];
- if (!head) {return;}
- style = document.createElement('style');
- style.type = 'text/css';
- style.innerHTML = css;
- head.appendChild(style);}
- addGlobalStyle('.itemBoxRight { display:none; border:1px solid red}');
- addGlobalStyle('.cataArrowControls svg {width:0px; height:0px; position:absolute; opacity:.2; cursor:pointer }');
- unsafeWindow.setInvTab = (function(fCache){return function(e){fCache.apply(this, [0]);}}(unsafeWindow.setInvTab));
- unsafeWindow.showLake = function () {new CSkill(Skill.FISHING);};
- unsafeWindow.dTDmg = function (e, t, s, a, o, r, i)
- {var n = CEd("div", e, "pa targetDmgBox", {left: (r && r.x < t ? r.x : t) + "px",top: (r && r.y < s ? r.y : s) + "px"}),l = SVG(n, 0, 0, 1, 1);
- n.label = CTD(n, a, "pa targetDmg" + (o ? " " + o : ""), {left: (r && r.x < t ? t - r.x : 0) + 4 + "px",top: (r && r.y < s ? s - r.y : 0) + 2 + "px"});
- var c = n.label.offsetHeight + 4,u = n.label.offsetWidth + 8,p = u,d = c;
- if (r) { p += Math.abs(t - r.x), d += Math.abs(s - r.y), l.setAttribute("viewBox", (r.x < t ? r.x - t : 0) + " " + (r.y < s ? r.y - s : 0) + " " + p + " " + d)}
- l.style.width = p + "px", l.style.height = d + "px", i && (n.icon = CI(n, "svg/" + i + ".svg", (r && r.x > t ? r.x - t : 0) - 8, (r && r.y > s ? r.y - s : 0) - 8, 16, 16));var m = 1;
- return n.alp = new njTween(n, "opacity", null, 1.5, 0, m, function(e) {e.parentNode && e.parentNode.removeChild(e)}), n};
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement