NS IS ASSHOLE SCRIPT BY MONARCH HQ TORN CITY

Display Asshole on NS members profile for easy hospitalisation, to increase prosperity of MONARCH HQ.

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name         NS IS ASSHOLE SCRIPT BY MONARCH HQ TORN CITY
// @namespace    http://torn.com
// @version      1.1
// @description  Display Asshole on NS members profile for easy hospitalisation, to increase prosperity of MONARCH HQ. 
// @author       Theferret
// @match        https://www.torn.com/
// @grant        GM_addStyle
// ==/UserScript==
 
(function() {
    'use strict';
 
    GM_addStyle (`.-profile-mini-_userImageWrapper___2ZKEu{display: none !important;}`);
 
    var hideFactionBanner = true;
    var hideFactionPage = true;
 
    if(hideFactionBanner){
        //document.querySelector('.faction-info').style.display = 'none';
        GM_addStyle (`
                    .faction-info{display: none !important;}
    `);
    }
 
    if(hideFactionPage){
        //document.querySelector('.faction-description').style.display = 'none';
        GM_addStyle (`
                    .faction-description{display: none !important;}
    `);
    }
 
 
    hide()
 
    function hide(){
        //var memberList = document.querySelector('.member-list');
        var memberList = document.querySelector('.table-body');
 
        if(memberList){
            var factionMembers = memberList.childNodes
 
            if(factionMembers){
 
                //var inactives = memberList.querySelectorAll('div.member.icons ul#iconTray li[id^=icon2]');
 
                for(var member of factionMembers){
                    if(member.nodeType == 1){
                        if((!member.querySelector('.status').innerHTML.toLowerCase().includes('hospital')) || (!member.innerHTML.toLowerCase().includes('online-user'))) {
                        member.style.display = 'none';
                        }
                    }
                }
            }
            else{
                setTimeout(hide, 100);
            }
        }
        else{
            setTimeout(hide, 100);
        }
    }
})();