MoxxiMod

one click at a time

目前為 2022-05-27 提交的版本,檢視 最新版本

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

You will need to install an extension such as Tampermonkey to install this script.

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name         MoxxiMod
// @namespace    https://studiomoxxi.com/
// @description  one click at a time
// @author       Ben
// @match        *.outwar.com/*
// @version      3.1
// @grant        GM_xmlhttpRequest
// @license MIT
// @grant        GM_getResourceText
// @grant        GM_addStyle
// @require      http://code.jquery.com/jquery-3.6.0.min.js
// ==/UserScript==


// rankings on homepage

if ( document.URL.indexOf("home") != -1 ) {
var theImage7;
theImage7 = document.querySelector("#content-header-row > div.col-lg-4.col-md-4.col-sm-12.col-12.layout-spacing.layout-spacing > div > div.widget-heading > h6")
theImage7.innerHTML =
'<div id="rankings_home">' +
'<table><tr><td>' +
'<iframe src="/newrankings?type=char_power" style="border:0px #ffffff none;" scrolling="yes" frameborder="0" height="250px" width="270px"></iframe>' +
'</td><td>' +
'<iframe src="/newrankings?type=char_elepower" style="border:0px #ffffff none;" scrolling="yes" frameborder="0" height="250px" width="270px"></iframe>' +
'</td></tr></table>' +

'<table><tr><td>' +
'<iframe src="/newrankings?type=crew_power" style="border:0px #ffffff none;" scrolling="yes" frameborder="0" height="250px" width="270px"></iframe>' +
'</td><td>' +
'<iframe src="/newrankings?type=crew_elepower" style="border:0px #ffffff none;" scrolling="yes" frameborder="0" height=250px" width="270px"></iframe>' +
'</td></tr></table></div><p><hr><img src=https://studiomoxxi.com/ow_themes/custom_jobs/minimal_01/shoutbox.png>'}

// world

function doc_keyUp(e) {
    if (e.key === '1') {
            document.querySelector("#roomDetails > ul > li:nth-child(1) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '2') {
            document.querySelector("#roomDetails > ul > li:nth-child(2) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '3') {
            document.querySelector("#roomDetails > ul > li:nth-child(3) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '4') {
            document.querySelector("#roomDetails > ul > li:nth-child(4) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '5') {
            document.querySelector("#roomDetails > ul > li:nth-child(5) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '6') {
            document.querySelector("#roomDetails > ul > li:nth-child(6) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '7') {
            document.querySelector("#roomDetails > ul > li:nth-child(7) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '8') {
            document.querySelector("#roomDetails > ul > li:nth-child(8) > div > div.ml-3.d-block.align-self-center > a > img").click();}
    if (e.key === '9') {
            document.querySelector("#roomDetails > ul > li:nth-child(9) > div > div.ml-3.d-block.align-self-center > a > img").click();}}

document.addEventListener('keyup', doc_keyUp, false);

if ( document.URL.indexOf("world") != -1 ) {
let observer = new MutationObserver(mutationRecords => {
  console.log(mutationRecords); // console.log(the changes)
  attackframe()
});
observer.observe(roomid_display, {
  childList: true, // observe direct children
  subtree: true, // and lower descendants too
  characterDataOldValue: true // pass old data to callback
});

function attackframe(){
$('a[target="_blank"]').prop("target", "attack");
};}

if (document.URL.indexOf("plrattack") != -1 ) {
$("#sidebar").hide()
$("body > center > div.sub-header-container").hide()
$("body > center > div.header-container.fixed-top").hide()
$("#ranks-filters > form > div").hide()
GM_addStyle ( `
#container{background:#0B0B0B !important;}
#content > div.layout-px-spacing{margin-top: -50px !important;background:#0B0B0B !important;}
.mr-3, .mx-3 {margin-right: 0rem!important;}
#content-header-row > center{zoom: 90% !important;}
` );}

if ( document.URL.indexOf("world") != -1 ) {
var theImage8;
theImage8 = document.querySelector("#content-header-row > div.col-xl-5.col-lg-12.col-md-6.col-sm-12.col-12.layout-spacing.px-1 > div > div.widget-content > div.room-top")
theImage8.innerHTML =
'<iframe src="https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/dc_box.png" name="attack" style="border:0px #ffffff none;" scrolling="no" frameborder="0" height="450px" width="750px"></iframe>'}

if ( document.URL.indexOf("world") != -1 ) {
GM_addStyle ( `
#roomDetails > ul > li > div > div.mr-3 > img {display:none !important;}
#ranks > li > div > div.mr-3 > div > div.rank-row-image > a{width: 0px !important;}
#ranks > li > div > div.media-body{text-align: left !important;}
#content > div.layout-px-spacing{margin-left: -100px !important;}
.mr-3, .mx-3 {margin-right: 0rem!important;}
#content-header-row > div.col-xl-5.col-lg-12.col-md-6.col-sm-12.col-12.layout-spacing.px-1 > div > div.widget-content > div.room-middle{display:none !important;}
.spawnRow{padding-top:0px !important;padding-bottom:0px !important;}
#roomDetails > ul > li {
display: block !important;
list-style-type: disc !important;
margin-block-start: 0em !important;
margin-block-end: 0em !important;
margin-inline-start: 0px !important;
margin-inline-end: 0px !important;
padding-inline-start: 0px !important;
}
` );}


// shift page content left

if (document.URL.indexOf("home") != -1 ) {
GM_addStyle ( `
    #content{left: -100px !important;}
    #content-header-row > div.bio.col-lg-8.col-md-8.col-sm-12.col-12.layout-spacing.layout-spacing > div.widget.widget-chart-one.mb-3 > div.widget-content.text-left > img[src*="circumspect"]{zoom:150% !important;box-shadow: 0px 0px 1px 1px #e9d100 !important;}
    #content-header-row > div.bio.col-lg-8.col-md-8.col-sm-12.col-12.layout-spacing.layout-spacing > div.widget.widget-chart-one.mb-3 > div.widget-content.text-left > img[src*="markdown"]{zoom:150% !important;box-shadow: 0px 0px 1px 1px #00fcff !important;}
    ` );}

if (document.URL.indexOf("profile") != -1 ) {
GM_addStyle ( `
    #content{left: -100px !important;}
    ` );}

// redefined

if ( document.URL.indexOf("scratch_ticket") != -1 ) {
var theImage2;
theImage2 = document.querySelector("#content > div.layout-px-spacing")
theImage2.innerHTML = '<div id="contentframe" style="position:fixed; top: 100px; left: -65px;">' +
'<iframe src="https://www.redefined.ro/?Quests" style="border:0px #ffffff none;" name="redefined" scrolling="yes" frameborder="0" marginheight="0px" marginwidth="0px" height="800px" width="1600px" allowfullscreen></iframe>' +
'</div>'}

// itemdb

if ( document.URL.indexOf("raffle") != -1 ) {
var theImage3;
theImage3 = document.querySelector("#content > div.layout-px-spacing")
theImage3.innerHTML = '<div id="contentframe" style="position:fixed; top: 120px; left: 210px;">' +
'<iframe src="https://ow-raiding.com/items.php" style="border:0px #ffffff none;" name="redefined" scrolling="yes" frameborder="0" marginheight="0px" marginwidth="0px" height="800px" width="1300px" allowfullscreen></iframe>' +
'</div>'}

// new rankings page

if ( document.URL.indexOf("raidtools") != -1 ) {
var theImage5;
theImage5 = document.querySelector("#content > div.layout-px-spacing")
theImage5.innerHTML = '<table><tr><td style="vertical-align:top" width="500px">' +
'<iframe src="https://torax.outwar.com/newrankings" style="border:0px #ffffff none;" name="rankings" scrolling="yes" frameborder="0" marginheight="0px" marginwidth="0px" height="5250px" width="100%" allowfullscreen ></iframe>' +
'</td>' +
'<td style="vertical-align:top" bgcolor=#171717 width="300px">' +
'<a href=/newrankings?type=char_power target="rankings">Character Power</a><br>' +
'<a href=/newrankings?type=char_exp target="rankings">Character Experience</a><br>' +
'<a href=/newrankings?type=char_maxRage target="rankings">Character Max Rage</a><br>' +
'<a href=/newrankings?type=char_elepower target="rankings">Character Ele Power</a><br>' +
'<a href=/newrankings?type=char_chaos target="rankings">Character Chaos Damage</a><br>' +
'<a href=/newrankings?type=char_wilderness target="rankings">Wilderness Level</a><br>' +
'<a href=/newrankings?type=char_tower target="rankings">Tower Level</a><br>' +
'<a href=/newrankings?type=char_yesterdaygrowth target="rankings">Growth Yesterday</a><br>' +
'<a href=/newrankings?type=char_yesterdayquests target="rankings">Quests Yesterday</a><br>' +
'<a href=/newrankings?type=char_yesterdayraids target="rankings">Raids Yesterday</a><br>' +
'<a href=/newrankings?type=mastery_attack target="rankings">Char Mastery: Attack</a><br>' +
'<a href=/newrankings?type=mastery_strip target="rankings">Char Mastery: Strip</a><br>' +
'<a href=/newrankings?type=mastery_defend target="rankings">Char Mastery: Defend</a><br>' +
'<a href=/newrankings?type=mastery_crewhit target="rankings">Char Mastery: Crew Hits</a><br>' +
'<a href=/newrankings?type=crew_power target="rankings">Crew Power</a><br>' +
'<a href=/newrankings?type=crew_avgpower target="rankings">Crew Avg Power</a><br>' +
'<a href=/newrankings?type=crew_exp target="rankings">Crew Experience</a><br>' +
'<a href=/newrankings?type=crew_maxRage target="rankings">Crew Max Rage</a><br>' +
'<a href=/newrankings?type=crew_avgMaxRage target="rankings">Crew Avg Max Rage</a><br>' +
'<a href=/newrankings?type=crew_elepower target="rankings">Crew Ele Power</a><br>' +
'<a href=/newrankings?type=crew_avgelepower target="rankings">Crew Avg Ele Power</a><br>' +
'<a href=/newrankings?type=crew_chaos target="rankings">Crew Chaos Damage</a><br>' +
'<a href=/newrankings?type=crew_avgchaos target="rankings">Crew Avg Chaos Damage</a><br>' +
'<a href=/newrankings?type=crew_mastery_strip target="rankings">Crew Mastery: Strip</a><br>' +
'<a href=/newrankings?type=crew_mastery_crewhit target="rankings">Crew Mastery: Hits</a><br>' +
'<a href=/newrankings?type=crew_kills target="rankings">Crew Total Kills</a><br>' +
'<a href=/newrankings?type=crew_yesterdaykills target="rankings">Crew Yesterday God Kills</a><br>' +
'<a href=/newrankings?type=crew_todayraids target="rankings">Crew 24h Raids</a><br>' +
'<a href=/newrankings?type=crew_bossdamage target="rankings">Crew Total Boss Damage</a><br>' +
'<a href=/newrankings?type=crew_bossdamage_max target="rankings">Crew Max Boss Damage</a>' +
'</td></tr></table>'}

// old rankingspage

if (document.URL.indexOf("newrankings") != -1 ) {
$(document).on('click', 'a', function(e){
    e.preventDefault();
    var url = $(this).attr('href');
    window.open(url, '_parent');})}

if (document.URL.indexOf("newrankings") != -1 ) {
$("#sidebar").hide()
$("body > center > div.sub-header-container").hide()
$("body > center > div.header-container.fixed-top").hide()
$("#ranks-filters > form > div").hide()
GM_addStyle ( `
    #container {background: #0F0F0F !important;}
    #ranks > li > div > div.mr-3 > div > div.rank-row-image > a > img {display:none !important;}
    #ranks > li > div > div.mr-3 > div > div.rank-row-image > a{width: 0px !important;}
    #ranks > li > div > div.media-body{text-align: left !important;}
    #content > div.layout-px-spacing{margin-top: -50px !important;}
    .mr-3, .mx-3 {margin-right: 0rem!important;}
    #content{left: 20px !important;top:-10px !important;}` );}

if ( document.URL.indexOf("newrankings?type=crew") != -1 ) {
    $(document).ready(function() { //When document has loaded

setTimeout(function() {

var links = document.getElementsByTagName("a"); //array
var regex = '(characters/)([0-9]+)';
for (var i=0,imax=links.length; i<imax; i++) {
    if (links[i].href.includes("characters")) {

   links[i].href = links[i].href.replace("characters/","crew_profile.php?id=");
    }
}
}, 1000);

});
}


// raid joining

if ( document.URL.indexOf("world") != -1 ) {
let observer = new MutationObserver(mutationRecords => {
  console.log(mutationRecords); // console.log(the changes)
  raidframe()
});
observer.observe(roomid_display, {
  childList: true, // observe direct children
  subtree: true, // and lower descendants too
  characterDataOldValue: true // pass old data to callback
});

function raidframe(){

if ( document.URL.indexOf("world") != -1 ) {
    $(document).ready(function() {
setTimeout(function() {
    var links = document.getElementsByTagName("a");
for (var i=0,imax=links.length; i<imax; i++) {
    if (links[i].href.includes("formraid")) {
   links[i].target = "attack";
    }}}, 10);});}

if ( document.URL.indexOf("world") != -1 ) {
    $(document).ready(function() {
setTimeout(function() {
    var links = document.getElementsByTagName("a");
for (var i=0,imax=links.length; i<imax; i++) {
    if (links[i].href.includes("joinraid")) {
   links[i].target = "attack";
    }}}, 10);});}

setTimeout(function() {
if(window.location.href.indexOf("world?") > -1 ||
    window.location.href.indexOf("world.php?rg_sess_id=") > -1) {
document.querySelector("#roomDetails > ul > li.list-group-item.list-group-item-action.spawnRow.raidMob > div > div.ml-3.d-block.align-self-center > a > img").click();}
}, 1000);}

}

setTimeout(function() {
if(window.location.href.indexOf("joinraid") > -1) {
document.querySelector("#content-header-row > div.skinborder.w-100.ml-0.mr-0.ml-lg-3.mr-lg-3 > div > div:nth-child(1) > div:nth-child(4) > form > div > input.btn.btn-primary").click();}
}, 1000);

setTimeout(function() {
if(window.location.href.indexOf("joinraid") > -1) {
document.querySelector("#content-header-row > div.skinborder.w-100.ml-0.mr-0.ml-lg-3.mr-lg-3 > div > div:nth-child(1) > form > input.btn.btn-primary").click();}
}, 1000);

if (document.URL.indexOf("formraid") > -1 ||
    document.URL.indexOf("joinraid") > -1 ) {
$("#sidebar").hide()
$("body > center > div.sub-header-container").hide()
$("body > center > div.header-container.fixed-top").hide()
$("#ranks-filters > form > div").hide()
GM_addStyle ( `
    #content-header-row{position:fixed !important;top:0px !important;}` );}

// backpack and equipment pop up

if (document.URL.indexOf("world") > -1 ||
   document.URL.indexOf("home") > -1 ||
   document.URL.indexOf("profile") > -1 ||
   document.URL.indexOf("scratch_ticket") > -1 ||
   document.URL.indexOf("ow_messagecenter") > -1 ||
   document.URL.indexOf("attack_search") > -1 ) {
document.querySelector('body img[src*="images/toolbar/Equipment.png"]').click();
document.querySelector('body img[src*="images/toolbar/Backpack.png"]').click();}

setTimeout(function() {
document.querySelector("#potion-tab").innerHTML = 'Pots'
document.querySelector("#regular-tab").innerHTML = 'Items'
    }, 200);

// wilderness attacking

if ( document.URL.indexOf("wilderness") != -1 ) {
var theImage12;
theImage12 = document.querySelector("#divWildernessContainer > div.row.mx-3.mt-3 > div.col-12.col-lg-6.statbox.widget.box.box-shadow.text-left")
theImage12.innerHTML = '<div id="contentframe" style="">' +
'<iframe src="https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/raid_results_box.png" style="border:0px #ffffff none;" name="wildernessatk" scrolling="no" frameborder="0" marginheight="0px" marginwidth="0px" height="500px" width="800px" allowfullscreen></iframe>' +
'</div>'}

if ( document.URL.indexOf("wilderness") != -1 ) {
$(document).ready(function(){
    $('a[href*="somethingelse"]').prop("target", "wildernessatk");
});
}

if ( document.URL.indexOf("showattack") != -1 ) {
setTimeout("parent.location.href = 'wilderness.php';",(newtimeout + 1));}

if ( document.URL.indexOf("wilderness") != -1 ) {
function doc_keyUp(e) {
    if (e.key === 'Enter') {
            document.querySelector("#wildernessLink > img").click();}}
document.addEventListener('keyup', doc_keyUp, false);
}

if (document.URL.indexOf("showattack") != -1 ) {
$("#sidebar").hide()
$("body > center > div.sub-header-container").hide()
$("body > center > div.header-container.fixed-top").hide()
$("#ranks-filters > form > div").hide()
GM_addStyle ( `
    .main-content{background: transparent !important;top:-50px !important;left:-50px !important;transform: scale(0.75) !important;transform-origin: top center !important;}
    #content-header-row > div:nth-child(2) > div:nth-child(1) > div{display:none !important;}
    body img[src*="Bar_separator_little"]{display:none !important;}
    #container{background:#0F0F0F !important;}
    #content-header-row > div:nth-child(6) > div:nth-child(1),#content-header-row > div:nth-child(2) > div:nth-child(3),#content-header-row > div:nth-child(2) > div:nth-child(1),#content-header-row > div > div.col-12.col-lg-6.text-left.pl-5.mt-5.mt-md-0{background: transparent !important;}` );
}



// explorer nav bar

document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav > li.nav-item.more-dropdown.little-space.hide-on-mob.progress-top").innerHTML = '<table><tr><td>' +
'<div class="dropdown">' +
'  <button class="dropbtn">FAST TRAVEL</button></a>' +
'  <div class="dropdown-content">' +
    '    <a href="/world.php?room=26137">ASTRAL RIFT</a>' +
    '    <a href="/world.php?room=25989">CHALLENGES</a>' +
    '    <a href="/world.php?room=24284">DEATHBAT GRAVEYARD</a>' +
    '    <a href="/world.php?room=4249">EOB SANDS</a>' +
    '    <a href="/world.php?room=42550">MADNESS VAULT</a>' +
    '    <a href="/world.php?room=23311">MOUNTAIN CAVE</a>' +
    '    <a href="/world.php?room=23471">PRISTINE DEPTHS</a>' +
    '    <a href="/world.php?room=11">ROOM 11</a>' +
    '    <a href="/world.php?room=6640">SCIENTIFIC DISTRICT</a>' +
    '    <a href="/world.php?room=17321">UNDERGROUND Q SEC BASE</a>' +
    '    <a href="/world.php?room=10697">VALLEY OF DEATH</a>' +
    '    <a href="/world.php?room=25994">WARDENS SANCTUARY</a>' +
    '    <a href="/wilderness">WILDERNESS</a>' +
'  </div>' +
'</div>' +
'</td><td>' +

'<table><tr><td>' +
'<a href=world><button class="dropbtn">EXPLORE</button></a>' +

'</td></tr></table>'



// sess id

var byptlink = document.querySelector("#accordionExample > a");
var sessid = byptlink.href.replace(/https:\/\/rampidgaming.outwar.com\/stripe_buy\?game=ow&outwar=0&wsrv=\$subDomain&lvl=\$user\[level]&rg_sess_id=/, ' ');

function copySess() {
            /* Copy text into clipboard */
            navigator.clipboard.writeText
                (sessid);
    alert("session id has been copied to clipboard");
        }

document.querySelector("#userProfileDropdown").addEventListener("click", copySess);

document.querySelector("#userProfileDropdown").setAttribute("onmouseover", "statspopup(event,'Click to copy SESS ID to clipboard')");

var bypplink = document.querySelector("#components > li:nth-child(11) > a")

// custom side menu

var theImage;
theImage = document.querySelector("#sidebar");
theImage.innerHTML = '<div class="sidebar-wrapper sidebar-theme">'+
'<nav id="sidebar">'+
'<div class="shadow-bottom"></div>'+
'<ul class="list-unstyled menu-categories ps" id="accordionExample">'+

'<li class="menu">'+
'<a href="/home" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fa fa-home"></i>'+
'<span> HOME</span>'+
'</div>'+
'</a>'+
'</li>'+

'<li class="menu">'+
'<a href="#components" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-user fa-fw"></i>'+
'<span> CHARACTER</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="components" data-parent="#accordionExample">'+

'<li><a href="/profile"> PROFILE</a></li>'+
'<li><a href="/ow_messagecenter"> MESSAGE CENTER</a></li>'+
'<li><a href="/cast_skills"> SKILLS</a></li>'+
'<li><a href="/allies"> MY ALLIES</a></li>'+
'<li><a href="/underlings"> UNDERLINGS</a></li>'+
'<li><a href="/user_preferences"> PREFERENCES</a></li>'+
'<li><div id=updates24><a href="/crew_apply"> MOXXIMOD</a></font></div></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#server" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-server fa-fw"></i>'+
'<span> SERVER</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="server" data-parent="#accordionExample">'+
'<li><a href="/attack_search"> SEARCH</a></li>'+
'<li><a href="/raidtools"> RANKINGS</a></li>'+
'<li><a href="/gladiator"> GLADIATORS</a></li>'+
'<li><a href="/event?eventid=woz"> WAR OF ZHUL</a></li>'+
'<li><a href="/event?eventid=top"> TRIAL OF POWER</a></li>'+
'<li><a href="/kotw"> KOTW</a></li>'+
'<li><a href="/news"> NEWS</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#elements" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fa fa-shopping-cart fa-fw"></i>'+
'<span> ECONOMY</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="elements" data-parent="#accordionExample">'+
'<li><a href="/treasury?type=-1"> BUY ITEMS</a></li>'+
'<li><a href="/mytreasury"> SELL ITEMS</a></li>'+
'<li><a href="/treasury?type=192"> AMULET SHOP</a></li>'+
'<li><a href="/supplies"> SUPPLIES</a></li>'+
'<li><a href="/pointtransfer"> TRANSFER PNTS</a></li>'+
'<li><a href="' + byptlink.href +'">BUY POINTS</a></li>'+
'<li><a href="' + bypplink.href +'">BUY PP</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#forms" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-shield fa-fw"></i>'+
'<span> CREW</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="forms" data-parent="#accordionExample">'+
'<li><a href="/crew_home"> CREW HOME</a></li>'+
'<li><a href="/crew_profile"> CREW PROFILE</a></li>'+
'<li><a href="/crew_bossspawns"> RAID BOSSES</a></li>'+
'<li><a href="/crew_vault"> CREW VAULT</a></li>'+
'<li><a href="/godstatus"> GOD STATUS</a></li>'+
'<li><a href="/crewinvites"> CREW INVITES</a></li>'+
'<li><a href="/crew_leavecrew"> LEAVE CREW</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#pvp" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-shield-alt fa-fw"></i>'+
'<span> PVP</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="pvp" data-parent="#accordionExample">'+
'<li><a href="/attacklog"> ATTACK LOG</a></li>'+
'<li><a href="/pvptourney"> OPEN TOURNEY</a></li>'+
'<li><a href="/closedpvp"> PVP BRAWL</a></li>'+
'<li><a href="/crew_hitlist"> HITLIST</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#datatables" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-shopping-bag fa-fw"></i>'+
'<span> ITEMS</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="datatables" data-parent="#accordionExample">'+
'<li><a href="/vault"> VAULT</a></li>'+
'<li><a href="/blacksmith"> BLACKSMITH</a></li>'+
'<li><a href="/augmentequip"> ADD AUGMENTS</a></li>'+
'<li><a href="/itemtransfer"> ITEM TRANSFER</a></li>'+
'<li><a href="/cauldron"> CAULDRON</a></li>'+
'<li><a href="/raffle"> ITEM DATABASE</a></li>'+
'<li><a href="/challenge"> CHALLENGE SETS</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#resources" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fas fa-book fa-fw"></i>'+
'<span> QUESTS</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="resources" data-parent="#accordionExample">'+
'<li><a href="/world"> EXPLORE</a></li>'+
'<li><a href="/scratch_ticket"> REDEFINED</a></li>'+
'<li><a href="/weeklyquests"> BOOSTERS</a></li>'+
'<li><a href="/questlog"> QUEST LOG</a></li>'+
'<li><a href="/dungeons"> DUNGEONS</a></li>'+
'<li><a href="/collections"> COLLECTIONS</a></li>'+
'<li><a href="/challenge"> CHALLENGES</a></li>'+
'</ul>'+
'</li>'+

'<li class="menu">'+
'<a href="#rga" data-toggle="collapse" aria-expanded="false" class="dropdown-toggle">'+
'<div class="">'+
'<i class="fa fa-address-card"></i>'+
'<span> RGA</span>'+
'</div>'+
'<div>'+
'<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-right"><polyline points="9 18 15 12 9 6"></polyline></svg>'+
'</div>'+
'</a>'+
'<ul class="collapse submenu list-unstyled" id="rga" data-parent="#accordionExample">'+
'<li><a href="/myaccount.php?ac_serverid=2"> TORAX CHARS</a></li>'+
'<li><a href="/myaccount.php?ac_serverid=1"> SIGIL CHARS</a></li>'+
'<li><a href="/accountinfo.php"> ACCOUNT</a></li>'+
'<li><a href="/support.php"> OW SUPPORT</a></li>'+
'<li><a href="?cmd=logout"> LOGOUT</a></li>'+
'</ul>'+
'</li>'+

'<p><br>' +

'<div class=search>' +
'<form method="post" action="playersearch.php" target="_parent">' +
'<div class="col-12 px-2">' +
'<input id="t-text" type="text" name="search" placeholder="player search" class="form-control" required="">' +
'</div>' +
'</form>' +
'</div>' +
'<div class="row mt-4">' +
'</div>'+
'<form method="post" action="crewsearch.php" target="_parent">' +
'<div class="col-12 px-2">' +
'<input id="t-text" type="text" name="search" placeholder="crew search" class="form-control" required="">' +
'</div>' +
'</form>' +
'<p><a href=https://studiomoxxi.com/ target="_blank"><img src=https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/mm_logo.png width=130px style="margin-top: 30px"></a>' +
'</div>' +
'<div class="row mt-4">' +
'</div></div>' +
'</p></div>'

var servername = window.location.hostname.split(".")[0];
setTimeout(function() {
$("span:contains('SERVER')").text(servername);
}, 10);

// skills in toolbar

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        'https://torax.outwar.com/profile',
    onload:     function (responseDetails) {

        const skill0 = /<img align="absmiddle" border="0" src="\/images\/skills\/skill_2952\.gif" hspace="2" width="25" height="25" alt="Underlings" onmouseover="popup\(event,'<b>Level 1 Underlings<\/b><br \/><br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const lingloy = skill0.exec(responseDetails.responseText);
        const skill1 = /<img align="absmiddle" border="0" src="\/images\/skills\/circumspect\.png" hspace="2" width="25" height="25" alt="Circumspect" onmouseover="popup\(event,'<b>Level [0-9]+ Circumspect<\/b><br \/>Your heart beat steadies\. You become careful, and alert when attacking your targets\.<br \/> Rage costs of mobs in DC are lowered by [0-9]+%<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const circ = skill1.exec(responseDetails.responseText);
        const skill2 = /<img align="absmiddle" border="0" src="\/images\/skills\/markdown\.png" hspace="2" width="25" height="25" alt="Markdown" onmouseover="popup\(event,'<b>Level [0-9]+ Markdown<\/b><br \/>You become more focused and alert for battle\. Decreases cost by [0-9]+% to form\/join raids\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const markdown = skill2.exec(responseDetails.responseText);
        const skill3 = /<img align="absmiddle" border="0" src="\/images\/skills\/hitman\.png" hspace="2" width="25" height="25" alt="Hitman" onmouseover="popup\(event,'<b>Level [0-9]+ Hitman<\/b><br \/>You put extra effort into your kills when there is money on the line\. Double strip and gain XP from players\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const hitman = skill3.exec(responseDetails.responseText);
        const skill4 = /<img align="absmiddle" border="0" src="\/images\/skills\/haste\.png" hspace="2" width="25" height="25" alt="Haste" onmouseover="popup\(event,'<b>Level [0-9]+ Haste<\/b><br \/>Your actions become lightning fast, time speeds up with your every move\.<br \/> Respawn times on DC mobs are reduced by [0-9]+%\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const haste = skill4.exec(responseDetails.responseText);
        const skill5 = /<img align="absmiddle" border="0" src="\/images\/skills\/streetsmarts\.png" hspace="2" width="25" height="25" alt="Street Smarts" onmouseover="popup\(event,'<b>Level [0-9]+ Street Smarts<\/b><br \/>Your experience can not be stripped\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const street = skill5.exec(responseDetails.responseText);
        const skill6 = /<img align="absmiddle" border="0" src="\/images\/skills\/onguard\.png" hspace="2" width="25" height="25" alt="On Guard" onmouseover="popup\(event,'<b>Level [0-9]+ On Guard<\/b><br \/>You never tire\. Your strength cannot be stolen in battle\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const onguard = skill6.exec(responseDetails.responseText);
        const skill7 = /<img align="absmiddle" border="0" src="\/images\/skills\/\.\.\/items\/itemz80\.gif" hspace="2" width="25" height="25" alt="Quest Experience Potion" onmouseover="popup\(event,'<b>Level 1 Quest Experience Potion<\/b><br \/>Increases quest EXP rewards by 50% for characters lvl 84 and below\.<br \/>[0-9]+ [a-zA-Z]+ .*/i;
        const questexp = skill7.exec(responseDetails.responseText);

        var skills = '';
        if (lingloy != null)
        skills += lingloy;
        if (circ != null)
        skills += circ;
        if (markdown != null)
        skills += markdown;
        if (hitman != null)
        skills += hitman;
        if (haste != null)
        skills += haste;
        if (street != null)
        skills += street;
        if (onguard != null)
        skills += onguard;
        if (questexp != null)
        skills += questexp;


let menu = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav");

let li = document.createElement('li');
li.innerHTML =
    '<div id=skillsbar>' +
    skills +
    '</div>'

insertAfter(li, menu.lastElementChild);

                }
} );

function insertAfter(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

// ammys toolbar icon

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        'https://torax.outwar.com/ajax/backpackcontents.php?tab=quest',
    onload:     function (responseDetails) {
const myRe = /Amulet of Achievement" data-itemqty="([0-9]*)"/g;
const myArray = myRe.exec(responseDetails.responseText);

var ammy ='';
if (myArray[1] != null)
ammy += myArray[1];

const theImage = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav > li:nth-child(4)");
theImage.innerHTML = `<a href="#" onmouseover="statspopup(event,'<tr><td><b>Amulets:</b></td><td>`+ammy+`</td></tr>')" onmouseout="kill()"><img border="0" src="https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/ammy.png" align="middle"></a>`
                }
} );

function insertAfter2(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let menu = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav");

let li = document.createElement('li');
li.textContent = '';
insertAfter2(li, menu.children[2]);


// moxximod raid results

if (document.URL.indexOf("crew_raidresults") != -1 ) {
document.querySelector("#content-header-row > table > tbody > tr > td > form > p > input:nth-child(3)").setAttribute("value", "MoxxiMod raid results");
};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {
GM_addStyle ( `
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(1){width:10% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(2){width:15% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(3){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(4){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(5){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(6){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(7){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(8){width:5% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(1) > td:nth-child(9){width:45% !important;}
    #content-header-row > table > tbody > tr > td > div > center > div > table{background:#0B0B0B !important;}
    ` );

var mmraids = document.querySelector("#content-header-row > table > tbody > tr > td > form > p > input:nth-child(3)");

function insertAfter2(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let rrHead = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr");
let tdHead = document.createElement('td');
tdHead.textContent = 'Damage';
insertAfter2(tdHead, rrHead.lastElementChild);

let rrHead2 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr");
let tdHead2 = document.createElement('td');
tdHead2.textContent = 'Average';
insertAfter2(tdHead2, rrHead2.lastElementChild);

let rrHead4 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr");
let tdHead4 = document.createElement('td');
tdHead4.textContent = 'Drops';
insertAfter2(tdHead4, rrHead4.lastElementChild);

let raidLink1 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(2) > td:nth-child(5) > a");
console.log(raidLink1);
GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink1,
    onload:     function (responseDetails) {

var raidDmg1 = /Damage: ([0-9,]*)/;
var printDmg1 = raidDmg1.exec(responseDetails.responseText);

var raidDrops1 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops1 = raidDrops1.exec(responseDetails.responseText);

let row1 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(2)")

let td1 = document.createElement('td');
td1.textContent = printDmg1[1].replace(/,/g, '');
insertAfter2(td1, row1.lastElementChild);

var Cells = row1.getElementsByTagName("td");

let td2 = document.createElement('td');
td2.textContent = Math.floor(printDmg1[1].replace(/,/g, '')/Cells[2].innerText);
insertAfter2(td2, row1.lastElementChild);

let td4 = document.createElement('td');
td4.innerHTML = printDrops1[1];
insertAfter2(td4, row1.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter3(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink12 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(3) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink12,
    onload:     function (responseDetails) {

var raidDmg12 = /Damage: ([0-9,]*)/;
var printDmg12 = raidDmg12.exec(responseDetails.responseText);

var raidDrops12 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops12 = raidDrops12.exec(responseDetails.responseText);
let row12 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(3)");
let td12 = document.createElement('td');
td12.textContent = printDmg12[1].replace(/,/g, '');
insertAfter3(td12, row12.lastElementChild);

var Cells2 = row12.getElementsByTagName("td");

let td22 = document.createElement('td');
td22.textContent = Math.floor(printDmg12[1].replace(/,/g, '')/Cells2[2].innerText);
insertAfter3(td22, row12.lastElementChild);

let td42 = document.createElement('td');
td42.innerHTML = printDrops12[1];
insertAfter3(td42, row12.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter4(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink13 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(4) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink13,
    onload:     function (responseDetails) {

var raidDmg13 = /Damage: ([0-9,]*)/;
var printDmg13 = raidDmg13.exec(responseDetails.responseText);
var raidDrops13 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops13 = raidDrops13.exec(responseDetails.responseText);
let row13 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(4)");

let td13 = document.createElement('td');
td13.textContent = printDmg13[1].replace(/,/g, '');
insertAfter4(td13, row13.lastElementChild);

var Cells3 = row13.getElementsByTagName("td");

let td23 = document.createElement('td');
td23.textContent = Math.floor(printDmg13[1].replace(/,/g, '')/Cells3[2].innerText);
insertAfter4(td23, row13.lastElementChild);

let td43 = document.createElement('td');
td43.innerHTML = printDrops13[1];
insertAfter4(td43, row13.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter5(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink14 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(5) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink14,
    onload:     function (responseDetails) {

var raidDmg14 = /Damage: ([0-9,]*)/;
var printDmg14 = raidDmg14.exec(responseDetails.responseText);
var raidDrops14 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops14 = raidDrops14.exec(responseDetails.responseText);
let row14 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(5)");

let td14 = document.createElement('td');
td14.textContent = printDmg14[1].replace(/,/g, '');
insertAfter5(td14, row14.lastElementChild);

var Cells4 = row14.getElementsByTagName("td");

let td24 = document.createElement('td');
td24.textContent = Math.floor(printDmg14[1].replace(/,/g, '')/Cells4[2].innerText);
insertAfter5(td24, row14.lastElementChild);

let td44 = document.createElement('td');
td44.innerHTML = printDrops14[1];
insertAfter5(td44, row14.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter6(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink15 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(6) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink15,
    onload:     function (responseDetails) {

var raidDmg15 = /Damage: ([0-9,]*)/;
var printDmg15 = raidDmg15.exec(responseDetails.responseText);
var raidDrops15 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops15 = raidDrops15.exec(responseDetails.responseText);
let row15 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(6)");

let td15 = document.createElement('td');
td15.textContent = printDmg15[1].replace(/,/g, '');
insertAfter6(td15, row15.lastElementChild);

var Cells5 = row15.getElementsByTagName("td");

let td25 = document.createElement('td');
td25.textContent = Math.floor(printDmg15[1].replace(/,/g, '')/Cells5[2].innerText);
insertAfter6(td25, row15.lastElementChild);

let td45 = document.createElement('td');
td45.innerHTML = printDrops15[1];
insertAfter6(td45, row15.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter7(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink16 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(7) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink16,
    onload:     function (responseDetails) {

var raidDmg16 = /Damage: ([0-9,]*)/;
var printDmg16 = raidDmg16.exec(responseDetails.responseText);
var raidDrops16 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops16 = raidDrops16.exec(responseDetails.responseText);
let row16 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(7)");

let td16 = document.createElement('td');
td16.textContent = printDmg16[1].replace(/,/g, '');
insertAfter7(td16, row16.lastElementChild);

var Cells6 = row16.getElementsByTagName("td");

let td26 = document.createElement('td');
td26.textContent = Math.floor(printDmg16[1].replace(/,/g, '')/Cells6[2].innerText);
insertAfter7(td26, row16.lastElementChild);

let td46 = document.createElement('td');
td46.innerHTML = printDrops16[1];
insertAfter7(td46, row16.lastElementChild);

    }})};

if (document.URL.indexOf("https://torax.outwar.com/crew_raidresults.php?most_recent=MoxxiMod") != -1 ) {

function insertAfter8(newNode, existingNode) {
existingNode.parentNode.insertBefore(newNode, existingNode.nextSibling);
}

let raidLink17 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(8) > td:nth-child(5) > a");

GM_xmlhttpRequest ( {
    method:     'GET',
    url:        raidLink17,
    onload:     function (responseDetails) {

var raidDmg17 = /Damage: ([0-9,]*)/;
var printDmg17 = raidDmg17.exec(responseDetails.responseText);
var raidDrops17 = /<a href="#" onmouseover="popup\(event,'([^']*)'\)" onmouseout="kill\(\)">[0-9]+ items<\/a>/i;
var printDrops17 = raidDrops17.exec(responseDetails.responseText);
let row17 = document.querySelector("#content-header-row > table > tbody > tr > td > div > center > div > table > tbody > tr:nth-child(8)");

let td17 = document.createElement('td');
td17.textContent = printDmg17[1].replace(/,/g, '');
insertAfter8(td17, row17.lastElementChild);

var Cells7 = row17.getElementsByTagName("td");

let td27 = document.createElement('td');
td27.textContent = Math.floor(printDmg17[1].replace(/,/g, '')/Cells7[2].innerText);
insertAfter8(td27, row17.lastElementChild);

let td47 = document.createElement('td');
td47.innerHTML = printDrops17[1];
insertAfter8(td47, row17.lastElementChild);

    }})};


// custom side menu

if ( document.URL.indexOf("crew_apply") != -1 ) {
var theImage11;
theImage11 = document.querySelector("#content")
theImage11.innerHTML =
'<div id=moxxi_mod_page>' +
'<img src=https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/mm_logo.png width=50% padding=20px><p>' +
'<a href=https://discord.com/invite/f35cccbWU8?utm_source=Discord%20Widget&utm_medium=Connect target=_blank><img src=https://studiomoxxi.com/moxximod/discord.png width=30%></a><p>' +
'MoxxiMod is a userscript written to improve the gaming user interface and player experience<p>' +
'The code is a combination of CSS (cascading style sheets) and JS (javascript)<p>' +
'<b>MoxxiMod is 100% free</b><p>' +
'If you want to support, please send points to <font color=A30020>Moxxi</font><p>' +
'For help with setup or to report a bug, join our Discord server<p>' +
'<a href=https://studiomoxxi.com/moxximod/ target=_blank>Click Here</a> for the latest scripts</div>' +
'<div id=moxxi_mod_tys>' +
'<p>BIG THANK YOU FOR THE TECHNICAL DEV SUPPORT<p>Beast666007, Bello, CarminT' +
'<p>AND THANK YOU TO THE BETA TESTERS<p>Rhino, Andreas, Brillo, Dkgoon<br>StarFox, Kevin, Kriminal, Shawn<br>Tyler, Xafloc, Jalek, Rodeo<br>StarPower, TeddyPain, TheStud'+
'</div>'
}

// extra

if (document.URL.indexOf("726169") != -1 ) {
GM_addStyle ( `
   #divProfile > div:nth-child(2) > div > div > div.col-xl-4.col-md-5 > div > div:nth-child(2) > div > div > div:nth-child(2) > img{content: url("https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/disa_head.png") !important;}` );
}