// ==UserScript== // @name MoxxiMod 8 // @namespace https://studiomoxxi.com/ // @description one click at a time // @author Ben // @match *.outwar.com/* // @version 8.15 // @grant GM_xmlhttpRequest // @license MIT // @run-at document-start // @grant GM_getResourceText // @grant GM_addStyle // @grant GM_setValue // @grant GM_getValue // @grant GM_deleteValue // @grant GM_listValues // @grant GM_xmlhttpRequest // @grant GM_addValueChangeListener // @grant unsafeWindow // @require http://code.jquery.com/jquery-3.6.0.min.js // @require https://cdnjs.cloudflare.com/ajax/libs/html2canvas/0.4.1/html2canvas.min.js // @require https://greasyfork.org/scripts/460904-canvas2image/code/Canvas2Image.js?version=1155383 // @downloadURL none // ==/UserScript== /* globals jQuery, $, waitForKeyElements */ const url = document.URL; if ( url.match("mob.php") || url.match("mob_talk") || url.match("rampidgaming.outwar") || url.match(/attack\/[0-9]+/i) ){ return }; if (window.self !== window.top) { return; } loadCustomTheme(); if (url.match("outwar")) { GM_addStyle (` body > center > div.sub-header-container{display:none;z-index:9999;} body > center > div.header-container.fixed-top{display:none;} body > center > div.sub-header-container2{display:none;} body > center > div.sub-header-container > header{height:46px;box-shadow:0 5px 5px 0 rgba(0,0,0,1) !important;} #accordionExample{display:none;} body > center > div.sub-header-container{top:0px} #container{position:relative;top:-70px} #sidebar ul.menu-categories.ps{border-right:0px !important;top:-90px;z-index:100;} body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav > li:nth-child(1) > div > span{width:150px !important;} span.toolbarSpan{margin-left:7px;vertical-align:middle;} .form-control-new{display:inline-block;border: 1px solid #1b2e4b;color:#e6e6e6;letter-spacing:1px;padding-left:10px;padding-right:10px;background:#1b2e4b;font-size:18px;box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);border-radius:5px;transition: .5s ease-out;} .form-control-new:hover{opacity:0.5;} .navbar{min-height: 0px !important;} @keyframes gradientScroll { 0% {background-position: 0% 50%;} 50% {background-position: 100% 50%;} 100% {background-position: 0% 50%;} } .sub-header-container .navbar { -webkit-box-shadow: 0 6px 10px 0 rgba(0,0,0,.14),0 1px 18px 0 rgba(0,0,0,.12),0 3px 5px -1px rgba(0,0,0,.2); -moz-box-shadow: 0 6px 10px 0 rgba(0,0,0,.14),0 1px 18px 0 rgba(0,0,0,.12),0 3px 5px -1px rgba(0,0,0,.2); box-shadow: 0 6px 10px 0 rgba(0,0,0,.14),0 1px 18px 0 rgba(0,0,0,.12),0 3px 5px -1px rgba(0,0,0,.2); background: linear-gradient(270deg, #1B2E4B, #1a1c2d, #1B2E4B); /* Define the gradient colors */ background-size: 300% 300%; /* Set the size larger than 100% to create the scrolling effect */ background-position: 0% 50%; /* Start position of the gradient */ animation: gradientScroll 5s linear infinite; /* 5 seconds animation duration, moves left to right infinitely */ border-radius: 0; padding: 0; justify-content: flex-start; min-height: 53px; width: 100%; } .pop td {text-align:left;padding:2px;font-size:11px;color:#FFFFFF;} #language-dropdown > div > p.top-exp.mr-1.menu_mid_size{display:none !important;} #language-dropdown > div > p.top-rage{display:none;} body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav > li:nth-child(1) > div > span{display:none;} li.toolbarButtons{margin-right:13px;} #dropdownCharacters{width:230px !important;margin-left:1rem;font-weight:700;visibility:visible !important;} #dropdownRgas{visibility:visible !important;} .btn-mm{background-color:#060818;margin-left:3px;margin-right:3px;color:#FFFFFF;padding:.4375rem 1.25rem;font-size:14px;font-weight:400;transition: .5s ease-out;cursor:pointer;border-radius:10px;box-shadow: 0 5px 20px 0 rgba(0,0,0,.1);letter-spacing:2px;} .btn-mm:hover{filter: saturate(250%);opacity:0.75;} .pointer{cursor:pointer;} #content > div.footer-wrapper{display:none;} #container > div.footer-wrapper{display:none;} body img[src*="items/skillitem.jpg"] {content: url("https://studiomoxxi.com/moxximod/aneuro.webp") !important;} body img[src*="items/questshard.jpg"] {content: url("https://studiomoxxi.com/moxximod/newqshard.gif") !important;} table.table{margin-bottom: 0rem;} .little-space{margin-top:0px;} .table td, .table th{padding:8px !important;} .bio .widget-content-area h3:after{display:none;} img[src*="images/toolbar/Attacked.png"] {display: none;} `); GM_addStyle (` #toolbarTiles img{width:30px;height:30px;border-radius:5px;margin-right:4px;margin-left:4px;} img.tile-still:hover{filter: saturate(250%);opacity:0.5;} img.tile-animate{cursor:pointer;transition: .5s ease-out;animation: fadeIn 1s ease-in-out forwards, tileanimate 1s infinite;box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);} img.tile-still{cursor:pointer;transition: .5s ease-out;animation: fadeIn 1s ease-in-out forwards;box-shadow: 0 0 3px rgba(0, 0, 0, 1);} @keyframes fadeIn {from {opacity: 0;} to {opacity: 1;}} @keyframes tileanimate{0% {filter: saturate(100%);} 50% {filter: saturate(250%); } 100% {filter: saturate(100%);}} `); GM_addStyle (` #travelDiv{z-index:0;height:0px;box-shadow: 0 0 10px rgba(0, 0, 0, 1);overflow:auto;text-align:center;display:inline-block;} .travel-destination{width:300px;margin-bottom:7px;height:40px;padding:5px;text-align:left;} img.travel-img{height:25px;width:25px;border-radius:5px;margin-right:15px;margin-left:5px;box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);} `); GM_addStyle (` #appsDiv{z-index:0;height:0px;box-shadow: 0 0 10px rgba(0, 0, 0, 1);overflow:hidden;text-align:left;} div.appDiv{display:inline-block;font-size:9px;text-align:center;font-family:monospace,monospace;width:95px;} img.app-img{background: linear-gradient(to bottom, #898989, #262626);height:60px;width:60px;margin:7px;border-radius:10px;padding:10px;box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);box-shadow: inset 0.4em 0.4em 0.4em 0 rgba(255,255,255,0.8), inset -0.4em -0.4em 0.4em 0 rgba(0,0,0,0.8);cursor:pointer} img.app-img:hover{filter: saturate(250%);opacity:0.75;transition: .5s ease-out;} `); GM_addStyle (` #casterDiv{z-index:0;height:0px;box-shadow: 0 0 10px rgba(0, 0, 0, 1);overflow:hidden;text-align:center;} img.castable{height:35px;width:35px;margin:4px;border-radius:10px;box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);background:#000000;cursor:pointer;transition: 0.25s ease-out;} img.castable:hover{filter: saturate(250%);opacity:0.5;} img.caster-selected{border:2px #00CC00 SOLID !important;width:35px !important;height:35px !important;padding:3px !important;} `); GM_addStyle (` #searchDiv{z-index:0;height:0px;box-shadow: 0 0 10px rgba(0, 0, 0, 1);overflow:hidden;text-align:center;} #searchDiv > form > input,#searchDiv > input{font-size:18px;} `); GM_addStyle (` #itemtable > tbody > tr:nth-child(2) > td:nth-child(2) > img:nth-child(1){min-width:58px;} body img[src*="gem_green1"] {content: url("https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/gem_green.webp") !important;width: 25px !important;margin:2px;border:0px solid #666666;margin-top:5px;} body img[src*="gem_blue2"] {content: url("https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/gem_blue.webp") !important;width: 25px !important;margin:2px;border:0px solid #666666;margin-top:5px;} body img[src*="gem_red2"] {content: url("https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/gem_red.webp") !important;width: 25px !important;margin:2px;border:0px solid #666666;margin-top:5px;} body img[src*="gem_white2"] {content: url("https://studiomoxxi.com/ow_themes/custom_jobs/classic_01/gem_white.webp") !important;width: 25px !important;margin:2px;border:0px solid #666666;margin-top:5px;} body img[src*="gemslot2"] {width: 30px !important;margin-bottom:5px;border:1px solid #666666;} #itemtable>tbody>tr:nth-child(2)>td:nth-child(2)>img:nth-child(8) {width: 25px !important;margin:4px !important;} #itemtable>tbody>tr:nth-child(2)>td:nth-child(2)>img:nth-child(9) {width: 25px !important;margin:4px !important;} #itemtable>tbody>tr:nth-child(2)>td:nth-child(2)>img:nth-child(10) {width: 25px !important;margin:4px !important;} #itemtable>tbody>tr:nth-child(2)>td:nth-child(2)>img:nth-child(11) {width: 25px !important;margin:4px !important;} #itemtable>tbody>tr:nth-child(2)>td:nth-child(2)>img:nth-child(12) {width: 25px !important;margin:4px !important;} `); GM_addStyle (` #authSlider{z-index:9999;height:0px;box-shadow: 0 0 10px rgba(0, 0, 0, 1);overflow:hidden;width:100%;text-align:center;color:#FFFFFF;position:fixed;font-weight:700 !important;font-size:20px;opacity:0;botom:0px;} `) GM_addStyle (` .mm-cell{background-color:#060818;} `) GM_addStyle (` #blankOverlay{height:100%;width:100%;z-index:1000;position:fixed;top:0px;border-radius:0px;opacity:0.99;} `) GM_addStyle (` #loadingOverlay{height:100%;width:100%;z-index:9999;position:fixed;top:0px;border-radius:0px;opacity:0.50;} #loadingOverlay > img{position:absolute;top:50%;left:50%;transform: translate(-50%,-50%);} `) GM_addStyle (` .dropdown-menu{box-shadow: 0px 0px 10px rgba(0, 0, 0, 1);} `) GM_addStyle(` img[src="images/store_head.jpg"]{display:none;} img[src="images/page/gladiator/Gladiator.png"]{display:none;} `) }; let travelMenuCreated = false; let appsMenuCreated = false; let casterMenuCreated = false; let searchMenuCreated = false; let authSliderCreated = false; let superfetchCache = {} if (window.location.href.toString().match(/outwar\.com\/characters\/[0-9]+/i)){window.location = window.location.href.replace("characters/","profile?id=")}; $('head').append(''); let didPageLoadedRun = false; var observer = new MutationObserver(function(mutationsList, observer) { if (document.querySelector("#container")) { didPageLoadedRun = true; pageLoaded(); observer.disconnect(); }; }); observer.observe(document, { childList: true, subtree: true }); setTimeout(function() { if (!didPageLoadedRun){ didPageLoadedRun = true; pageLoaded(); console.log('MOXXIMOD: Triggered 2 second lag timer'); }; }, 2000); async function pageLoaded() { let serverNo; let server; if (window.location.toString().match('sigil')){ serverNo = 1 server = 'sigil' } else { serverNo = 2 server = 'torax' }; let rgaName; if (document.body.innerHTML.match(/rg_sess_id=[A-Za-z0-9]+"/i)){ rgaName = document.body.innerHTML.match(/rg_sess_id=([A-Za-z0-9]+)"/i)[1]; } else { rgaName = "null" }; async function moxximod(){ const charId = (document.body.innerHTML.match(/outwar\.com\/page\?x=([0-9]+)/i) || [0,0])[1] const toolbarData = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav").innerHTML.replace(/[\n\r]/g,''); const dataTime = toolbarData.match(/

(.*?)<\/p>/i)[1] const dataLevel = toolbarData.match(/(.*?)<\/span>/i)[1] const dataRage = parseInt(toolbarData.replace(/,/g,'').match(/(.*?)<\/span>/i)[1]) const dataExp = parseInt(toolbarData.replace(/,/g,'').match(/(.*?)<\/span>/i)[1]) const dataEnhancementExp = parseInt(toolbarData.replace(/,/g,'').match(/Enhancement Exp:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataToLevel = toolbarData.match(/Needed to Level:<\/b><\/td>(.*?)<\/td><\/tr>/i)[1] const dataGrowth = parseInt(toolbarData.replace(/,/g,'').match(/Growth Today:<\/b><\/td>(.*?)<\/td><\/tr>/i)[1]) const dataMinimum = parseInt(toolbarData.replace(/,/g,'').match(/Minimum:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataExpPerTurn = parseInt(toolbarData.replace(/,/g,'').match(/Growth Today:<\/b><\/td>.*?<\/td><\/tr>Per Turn:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataRagePerTurn = parseInt(toolbarData.replace(/,/g,'').match(/Per Turn:<\/b><\/td>([0-9]+)<\/td><\/tr>Maximum:/i)[1]) const dataMaximum = parseInt(toolbarData.replace(/,/g,'').match(/Maximum:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataGold = parseFloat(toolbarData.replace(/,/g, '').match(/Gold:<\/b><\/td>(.*)<\/td><\/tr>/i)[1]); const dataPoints = parseFloat(toolbarData.replace(/,/g, '').match(/Points:<\/b><\/td>(.*)<\/font><\/td><\/tr>/i)[1]); const dataPremium = parseFloat(toolbarData.replace(/,/g, '').match(/Premium:<\/b><\/td>.*?\.<\/font>[0-9]+<\/font>/i).toString().replace("","").replace("Premium:","").replace("","")); const dataSkillPoints = parseFloat(toolbarData.replace(/,/g, '').match(/Skill:<\/b><\/td>(.*)<\/td><\/tr>/i)[1]); const dataAttack = parseInt(toolbarData.replace(/,/g,'').match(/Attack:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataHp = parseInt(toolbarData.replace(/,/g,'').match(/Hit Points:<\/b><\/td>([0-9]+)<\/td><\/tr>/i)[1]) const dataCritical = parseInt(toolbarData.replace(/,/g,'').match(/Critical:<\/b><\/td>([0-9]+)%<\/td><\/tr>/i)[1]) const dataRampage = parseInt(toolbarData.replace(/,/g,'').match(/Rampage:<\/b><\/td>([0-9]+)%<\/td><\/tr>/i)[1]) const dataBlock = parseInt(toolbarData.replace(/,/g,'').match(/Block:<\/b><\/td>([0-9]+)%<\/td><\/tr>/i)[1]) const fetchTokens = await challengeStatus(server); const dataFreeTokens = fetchTokens.match('error') ? "NA" : parseInt(fetchTokens.match(/"tokens":"(.*?)"/i)[1]); const dataPremiumTokens = fetchTokens.match('error') ? "NA" : parseInt(fetchTokens.match(/"p_tokens":"(.*?)"/i)[1]); const profile = await superfetch('profile'); await menu(rgaName,charId,serverNo,profile); await toolbar(charId,toolbarData,dataTime,dataLevel,dataRage,dataExp,dataEnhancementExp,dataToLevel,dataGrowth,dataMinimum,dataExpPerTurn,dataRagePerTurn,dataMaximum,dataGold,dataPoints,dataPremium,dataSkillPoints,dataFreeTokens,dataPremiumTokens,dataAttack,dataHp,dataCritical,dataRampage,dataBlock) if (document.body.innerHTML.match('images/ErrorImg.jpg') || document.body.innerHTML.match('img/error.png')){ return; }; await updateRga(rgaName); if (url.match("profile") && !url.match("crew_profile")) { await onOff("profilePage"); if (GM_getValue("onOff(profilePage)") != "false"){ await profilePage(server) }; } else if (url.match("home") && !url.match("crew_home") && !url.match("homepost")) { if (GM_getValue("onOff(home)") != "false"){ await home(profile) }; await onOff("home"); } else if (url.match("world")){ if (GM_getValue("onOff(world)") != "false"){ await world(profile,server) }; await onOff("world"); } else if (url.match("cast_skills")){ if (GM_getValue("onOff(cast_skills)") != "false"){ await castSkills() }; await onOff("cast_skills"); } else if (url.match("crew_profile")){ if (GM_getValue("onOff(crew_profile)") != "false"){ await crewProfile(server) }; await onOff("crew_profile"); } else if (url.match("primegods")){ if (GM_getValue("onOff(primegods)") != "false"){ await primegods(profile) }; await onOff("primegods"); } else if (url.match("crew_vault")){ if (GM_getValue("onOff(crew_vault)") != "false"){ await crewVault() }; await onOff("crew_vault"); } else if (url.match("trade")){ if (GM_getValue("onOff(trade)") != "false"){ await trade() }; await onOff("trade"); } else if (url.match("godstatus")){ if (GM_getValue("onOff(godstatus)") != "false"){ await godstatus() }; await onOff("godstatus"); } else if (url.match("crew_raidresults")){ if (GM_getValue("onOff(crew_raidresults)") != "false"){ await raidResults() }; await onOff("crew_raidresults"); } else if (url.match("itemtransfer")){ if (GM_getValue("onOff(itemtransfer)") != "false"){ await itemTransfer() }; await onOff("itemtransfer"); } else if (url.match("crew_bossspawns")){ if (GM_getValue("onOff(crew_bossspawns)") != "false"){ await bossSpawns() } await onOff("crew_bossspawns"); } else if (url.match("boss_stats")){ if (GM_getValue("onOff(boss_stats)") != "false"){ await bossStats() }; await onOff("boss_stats"); } else if (url.match("changefaction")){ if (GM_getValue("onOff(changeFaction)") != "false"){ await changeFaction(profile) }; await onOff("changefaction"); } else if (url.match("augmentequip")){ if (GM_getValue("onOff(augmentequip)") != "false"){ await augmentEquip(server) }; await onOff("augmentequip"); } else if (url.match("closedpvp")){ if (GM_getValue("onOff(closedpvp)") != "false"){ await closedpvp(profile,server,charId) }; await onOff("closedpvp"); } else if (url.match("pointtransfer")){ if (GM_getValue("onOff(pointtransfer)") != "false"){ await pointTransfer(dataPremium) }; await onOff("pointtransfer"); } else if (url.match(/gladiator\?mobid=[0-9]+/i)){ if (GM_getValue("onOff(gladiator)") != "false"){ await gladiator(charId,profile) }; await onOff("gladiator"); } else if (url.match("type=vision")){ await moxxivision(server,serverNo,rgaName,charId); } else if (url.match("type=questreport")){ await blankOverlay(server,serverNo,rgaName,charId); await appQuestReport(server,serverNo,rgaName,charId); } else if (url.match("blacksmith")){ if (GM_getValue("onOff(blacksmith)") != "false"){ await blacksmith(server,serverNo,rgaName,charId) }; await onOff("blacksmith"); } else if (url.match(/raidattack\.php\?raidid=[0-9]+/i)){ await raidattack(); } else if (url.match("spawntimeview")){ await oracle(); } else if (url.match("crew_permissions")){ await crewpermissions(); }; return profile; }; await itemOnHover(); await itemDropMenu(server,serverNo,rgaName); await openPotionBp(); const profile = await moxximod(); $('#content').show(); if (!url.match("blacksmith") && !url.match("augmentequip") && !url.match("trade") && !url.match("security_prompt") && !url.match("augmentremove")){ await tiles(profile); } else { document.querySelector("#toolbarTiles").remove(); }; }; async function profilePage(server){ GM_addStyle (` #allAugs > img {height:30px;width:30px;margin:1px;border-radius:5px;border:2px #475254 SOLID;} #missingRobot, #skills > img {height:40px;width:40px;margin:3px;border-radius:5px;border:2px #475254 SOLID;} div.card-body{padding:0px;} #divHeaderName > font{text-transform: uppercase;font-size: 1.5em;font-weight: bold;margin-bottom: 1rem;} #pbuttons{margin:1rem !important;} #content > div > div:nth-child(1){max-width:350px !important;} #content > div > div:nth-child(2){max-width:800px !important;} .widget{padding:10px !important;} .progress{margin-bottom:0rem;} #UnderlingTable > thead > tr > th{padding:10px;margin:5px;margin-top:10px} #UnderlingTable > tbody > tr > td{padding:10px;margin:5px} #UnderlingTable > thead > tr > th,#UnderlingTable > tbody > tr > td{padding:3px;margin:0px;} #profileSlayerDiv > div > div > img {height:20px !important;} div.smallSlayerDiv {height:20px;width:20px;overflow:hidden;display:inline-block;} #UnderlingTable > thead > tr > th:nth-child(4){display:none;} #UnderlingTable > tbody > tr > td:nth-child(4){display:none;} div.profile-comments{text-align: left !important;} div.crestDiv > img{height:32px;width:32px;} `); let profileHeader = document.querySelector("#divHeader").innerHTML.replace(/[0-9]+ Profile Hits/i,'') const profileInfo = document.querySelectorAll('div.card')[0].innerHTML.replace(`

PLAYER INFO
`,"").replace(``,`
`) const profileEq = document.querySelectorAll('div.card')[1].innerHTML.replace(`
EQUIPMENT
`,"").replace(`/images/thedude.png`,'https://studiomoxxi.com/moxximod/thedudeplus.png').replace('left:214px; top:346px;','left:10px; top:300px;').replace('left:258px; top:346px;','left:54px; top:300px;').replace('','') const profileCrests = document.querySelectorAll('div.card')[2].innerHTML.replace(`
SKILL CRESTS
`,"") const profileMastery = document.querySelectorAll('div.card')[3].innerHTML.replace(`
MASTERIES
`,"") const profilePic = document.querySelectorAll('div.card')[5].innerHTML.match(/src="([^"]*)"/i)[1] const profileSlayer = document.querySelectorAll('div.card')[9].innerHTML.replace(``,`

`).replace(/

<\/div>/g,` onmouseout="kill();">
`) const profileLings = document.querySelector("#UnderlingTable").outerHTML.replace('table table-striped-dark mt-1','') const profileSkills = document.querySelector('#divSkillsCast').innerHTML.replace(//i,""); const charId = document.body.innerHTML.match(/trade\?tradeWith=([0-9]+)/i)[1]; let uploadPicLink = ''; if (document.querySelector("#divProfile > div:nth-child(2) > div > div > div.col-xl-8.col-md-7 > div > div:nth-child(1) > div > a") != null){ GM_addStyle (`#uploadPicLinkDiv{margin-bottom:-25px;}`) uploadPicLink = document.querySelector("#divProfile > div:nth-child(2) > div > div > div.col-xl-8.col-md-7 > div > div:nth-child(1) > div > a").outerHTML; }; if (document.querySelector("#divActions > a:nth-child(1)")){ var playerAttack = document.querySelector("#divActions > a:nth-child(1)").outerHTML.replace(`ATTACK`,"").replace(`ATTACK`,"").replace(``,"") var playerName = playerAttack.match(//i)[1] var playerId = playerAttack.match(//i)[2] } if (window.location.href.match("id") == null){ GM_addStyle (`#pbuttons{display:none !important;}`) } if (playerAttack == undefined){GM_addStyle (`#atk_button{display:none !important;}`)} var isplayerpp = "no" if (profileHeader.match(//i) != null){ profileHeader = profileHeader.replace(//i,"") isplayerpp = "yes" } if (isplayerpp == "yes"){ profileHeader = profileHeader.replace(``,``) } else { profileHeader = profileHeader.replace(``,``) }; document.querySelector("#content").innerHTML = `

`+profileInfo+`

UNDERLINGS

`+profileLings+`
`+profileEq+`
ALL AUGMENTS

`+uploadPicLink+`
`+profileMastery+`
`+profileSlayer+`
` if (isplayerpp == "yes"){ document.querySelector("#isppspan").innerHTML = `
` }; const classCrest = profileCrests.match(/left:9px.*\n(.*)/i) const ferocityCrest = profileCrests.match(/left:83px.*\n(.*)/i) const preservationCrest = profileCrests.match(/left:157px.*\n(.*)/i) const afflictionCrest = profileCrests.match(/left:231px.*\n(.*)/i) if (classCrest){ document.querySelector("#classCrestDiv").innerHTML = classCrest[1] } if (ferocityCrest){ document.querySelector("#ferocityCrestDiv").innerHTML = ferocityCrest[1] } if (preservationCrest){ document.querySelector("#preservationCrestDiv").innerHTML = preservationCrest[1] } if (afflictionCrest){ document.querySelector("#afflictionCrestDiv").innerHTML = afflictionCrest[1] } const allPotionsInfo = await info("All Potions"); const allPotions = allPotionsInfo.map(([item]) => item); const activePotions = (profileSkills.match(/alt="([^"]*)"/g) || []).map(match => match.slice(5, -1).replace(/'/g,'')); const missingPotions = allPotions.filter(item => !activePotions.includes(item)); const missingString = missingPotions.map((item, index) => (index > 0 && index % 2 === 0) ? `
${item}` : item).join(', ').replace(/'/g,''); document.querySelector("#missing").innerHTML = `` if (GM_getValue("auth").match("Full")){ document.querySelector("#missingPotions").setAttribute("onmouseover", `statspopup(event,'Missing ${missingPotions.length} Potions

${missingString}')`); } else { document.querySelector("#missingPotions").setAttribute("onmouseover", `statspopup(event,'Missing ${missingPotions.length} Potions

MoxxiMod+ subscribers can see a complete list of uncast potions here')`); }; if (isplayerpp == "yes"){ GM_addStyle (` #divHeaderName{color:#E79A31 !important;} .bg-danger,.bg-primary,.bg-secondary,.bg-success,.bg-warning{background-color:#E79A31 !important;} -moz-box-shadow: 0px 0px 3px 3px rgba(209,156,32,0.5); box-shadow: 0px 0px 3px 3px rgba(209,156,32,0.5);} #content > div > div:nth-child(1) > div:nth-child(1) > div:nth-child(2) > table > tbody > tr:nth-child(4) > td:nth-child(2) > b > font{color:#E79A31 !important;} #content > div > div:nth-child(1) > div:nth-child(1) > div:nth-child(2) > table > tbody > tr:nth-child(5) > td:nth-child(2) > b > font{color:#E79A31 !important;} #content > div > div:nth-child(1) > div:nth-child(1) > div:nth-child(2) > table > tbody > tr:nth-child(6) > td:nth-child(2) > b > font{color:#E79A31 !important;} #content > div > div:nth-child(1) > div:nth-child(1) > div:nth-child(2) > table > tbody > tr:nth-child(8) > td:nth-child(2) > b > font{color:#E79A31 !important;} `) }; const faction = document.querySelector("body").innerHTML.match(/FACTION<\/font><\/b><\/td>[\n\r].*>(.*?) \((.*?)\)/i) const factionLvl = parseInt(faction[2]) let factionImg; let profileFactionImg = [] if (faction[1] == "Vordyn"){ GM_addStyle (`.profile-widget{-webkit-box-shadow:0px 0px 3px 3px rgba(252,41,205,0.3);`) factionImg = 'https://studiomoxxi.com/moxxibots/factions/v.png' } else if (faction[1] == "Delruk"){ GM_addStyle (`.profile-widget{-webkit-box-shadow:0px 0px 3px 3px rgba(255,120,39,0.3);`) factionImg = 'https://studiomoxxi.com/moxxibots/factions/d.png' } else if (faction[1] == "Alvar"){ GM_addStyle (`.profile-widget{-webkit-box-shadow:0px 0px 3px 3px rgba(0,159,255,0.3);`) factionImg = 'https://studiomoxxi.com/moxxibots/factions/a.png' } else { GM_addStyle (`.profile-widget{-webkit-box-shadow:0px 0px 3px 3px rgba(26,26,26,1);`) }; for (let i = 0; i < factionLvl; i++) { profileFactionImg.push(``) }; if (factionLvl >= 1){ document.querySelector("#classLogo").setAttribute("onmouseover", `statspopup(event,'${faction[1]}
Loyalty Level ${factionLvl}')`); document.querySelector("#classLogo").setAttribute("onmouseout", `kill()`); }; document.querySelector("#classLogo").innerHTML = profileFactionImg.join('') const arrayOfItems = profileEq.match(/itempopup\(event,'[0-9]+'\)/g); getAugs(arrayOfItems); async function getAugs(arrayOfItems){ let augs = [] const itemLoop = async (item) => { const items = await superfetch(`item_rollover.php?id=${item.match(/[0-9]+/i)}`) const allAugs = items.match(/src="[^"]*" ONMOUSEOVER="itempopup\(event,'[0-9]+_[0-9]+'\)"/g) if (allAugs){ for (let i = 0; i < allAugs.length; i++) { augs.push(allAugs[i]) }; }; }; if (arrayOfItems){ await Promise.all(arrayOfItems.map(itemLoop)); document.querySelector("#allAugs").innerHTML = augs.sort().join('').replace(/src=/g,'`) } }; notes(profileHeader,charId,server); }; async function menu(rgaName,charId,serverNo,profile){ GM_addStyle (`#accordionExample{display:revert !important;background:#060818;}`) if (document.querySelector("#accordionExample > a")){ const buyPointsLink = document.querySelector("#accordionExample > a").outerHTML.match(/href="([^"]*)">/i)[1]; const crewId = (profile.toString().match(//i) || [false,false])[1] const level = parseInt(document.querySelector('.toolbar_level').innerHTML) document.querySelector("#accordionExample").innerHTML = `

` var ulElement = document.getElementById("menuCrew"); if (crewId){ const liHome = document.createElement("li"); const liProfile = document.createElement("li"); const liPrime = document.createElement("li"); const liRaids = document.createElement("li"); const liBosses = document.createElement("li"); const liVault = document.createElement("li"); const liCap = document.createElement("li"); const liGods = document.createElement("li"); const liLeave = document.createElement("li"); liHome.innerHTML = `CREW HOME` liProfile.innerHTML = `CREW PROFILE` liPrime.innerHTML = `PRIME GODS` liRaids.innerHTML = `RAID RESULTS` liBosses.innerHTML = `RAID BOSSES` liVault.innerHTML = `CREW VAULT` liCap.innerHTML = `CAP STATUS` liGods.innerHTML = `GOD STATUS` liLeave.innerHTML = `LEAVE CREW` ulElement.appendChild(liHome); ulElement.appendChild(liProfile); ulElement.appendChild(liPrime); ulElement.appendChild(liRaids); ulElement.appendChild(liBosses); ulElement.appendChild(liVault); ulElement.appendChild(liCap); ulElement.appendChild(liGods); ulElement.appendChild(liLeave); } else { var liInvites = document.createElement("li"); liInvites.innerHTML = `CREW INVITES` ulElement.appendChild(liInvites); }; if (level >= 91){ const ulElement = document.querySelector("#components"); const newLiElement = document.createElement("li"); newLiElement.innerHTML = `FACTIONS`; ulElement.appendChild(newLiElement); }; if (GM_getValue('globalSecurityWord')){ const savedSecWord = GM_getValue('globalSecurityWord'); document.querySelector("#global_sec_word").value = savedSecWord; }; document.querySelector("#secWordButton").addEventListener('click', async function(){ const inputText = document.querySelector("#global_sec_word").value GM_setValue('globalSecurityWord',inputText); await secword(); alert(`Successfully saved ${inputText} to your browser`) }); }; }; async function challengeStatus(server){ const data = await superfetch(`https://${server}.outwar.com/ajax/challenge_status`); if (data.match('Trustees do not have access to this page')){ data = `{"result":true,"tokens":"NA","p_tokens":"NA","timeleft":59210}` } return data; } async function toolbar(charId,toolbarData,dataTime,dataLevel,dataRage,dataExp,dataEnhancementExp,dataToLevel,dataGrowth,dataMinimum,dataExpPerTurn,dataRagePerTurn,dataMaximum,dataGold,dataPoints,dataPremium,dataSkillPoints,dataFreeTokens,dataPremiumTokens,dataAttack,dataHp,dataCritical,dataRampage,dataBlock){ GM_addStyle (`body > center > div.sub-header-container{display:revert !important;}`) document.querySelector("body > center > div.sub-header-container > header > a").remove() const toolbarDivcount = document.querySelectorAll("li.nav-item.more-dropdown.little-space.hide-on-mob").length for (let i = 3; i < toolbarDivcount+3; i++) { document.querySelector("li.nav-item.more-dropdown.little-space.hide-on-mob:nth-child("+i+")").setAttribute("style","display:none") }; const toolbarNewLi = document.createElement('li'); toolbarNewLi.innerHTML = ` `; toolbarNewLi.setAttribute('class','nav-item more-dropdown little-space hide-on-mob') const toolbarUl = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav"); toolbarUl.appendChild(toolbarNewLi); const utcDate = new Date(); const estOffset = 5 * 60; const estDate = new Date(utcDate.getTime() - estOffset * 60000); const estFormatter = new Intl.DateTimeFormat('en-US', { timeZone: 'UTC', weekday: 'long' }); const dayOfTheWeek = estFormatter.format(estDate); const untilMax = Math.ceil((dataMaximum - dataRage) / dataRagePerTurn); const maxTime = (parseInt(dataTime.match(/([0-9]+):/i)[1]) + untilMax) % 12; const maxHour = (untilMax > 0) ? `${maxTime}:00` : "NOW"; if (GM_getValue('charId') != charId && parseInt(dataLevel) >= 80){ const qbp = await superfetch('ajax/backpackcontents.php?tab=quest'); const reps = qbp.match(/data-name="Badge Reputation"/i) ? parseInt(qbp.match(/data-name="Badge Reputation" data-itemqty="([0-9]+)"/i)[1]) : 0; GM_setValue('charId', charId); GM_setValue('badgeReps', reps); }; const dataReps = GM_getValue('badgeReps') ? GM_getValue('badgeReps') : 0 const pointsTable = `
PREFERRED PLAYER
PB POINTS:${dataPoints.toLocaleString()}
PREM POINTS:${dataPremium.toLocaleString()}
FREE TOKENS:${dataFreeTokens.toLocaleString()}
PREM TOKENS:${dataPremiumTokens.toLocaleString()}
GOLD:${dataGold.toLocaleString()}
SKILL POINTS:${dataSkillPoints.toLocaleString()}
BADGE REPS:${dataReps}
` const expTable = `
EXPERIENCE:${dataExp.toLocaleString()}
ENHANCEMENT EXP:${dataEnhancementExp.toLocaleString()}
NEEDED TO LEVEL:${dataToLevel}
GROWTH TODAY:${dataGrowth.toLocaleString()}
MINIMUM EXP:${dataMinimum.toLocaleString()}
PER TURN:${dataExpPerTurn.toLocaleString()}
` const rageTable = `
MAXIMUM:${dataMaximum.toLocaleString()}
WILL MAX:${maxHour}
PER TURN:${dataRagePerTurn.toLocaleString()}
ATTACK:${dataAttack.toLocaleString()}
HIT POINTS:${dataHp.toLocaleString()}
CRITICAL:${dataCritical.toLocaleString()}%
RAMPAGE:${dataRampage.toLocaleString()}%
BLOCK:${dataBlock.toLocaleString()}%
` if (GM_getValue("savedRgas") == undefined) {GM_setValue("savedRgas","no sessions saved")} if (GM_getValue("savedRgas") == "no sessions saved"){ document.querySelector("#toolbarRgas").remove() } else { const options = GM_getValue("savedRgas") document.querySelector("#toolbarRgas").innerHTML = ` ` document.getElementById("dropdownRgas").addEventListener("change", function() { var selectedValue = this.value; if (selectedValue !== "") { window.location.href = selectedValue; }; }); }; document.querySelector("#toolbarPoints").innerHTML = `$` document.querySelector("#toolbarClock").innerHTML = `${dataTime}` document.querySelector("#toolbarLvl").innerHTML = `LEVEL: ${dataLevel}` document.querySelector("#toolbarRage").innerHTML = `RAGE: ${dataRage.toLocaleString()}` if (toolbarData.match(``)){ document.querySelector("#toolbarRageText").setAttribute("style","border: 2px SOLID #FF0000 !important") }; if (dataFreeTokens == 30){ document.querySelector("#toolbarPoints a").setAttribute("style","border: 2px SOLID #F9E400 !important") }; if (dataReps >= 15){ document.querySelector("#toolbarPoints a").setAttribute("style","border: 2px SOLID #00FF00 !important") }; if (dataToLevel.match(/LEVEL!/)){ document.querySelector("#toolbarLvl a").setAttribute("style","border: 2px SOLID #00FF00 !important") }; document.querySelector("#language-dropdown > svg").outerHTML = `` const dropdownNative = document.querySelector("body > center > div.sub-header-container > header > ul.navbar-nav.flex-row.mr-auto.toolbar-nav > li:nth-child(1)").innerHTML const dropdownModified = dropdownNative.replace(`