Logs Check

try to take over the world!

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey, Greasemonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey किंवा Violentmonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

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

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला Tampermonkey यासारखे एक्स्टेंशन इंस्टॉल करावे लागेल..

ही स्क्रिप्ट इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्क्रिप्ट व्यवस्थापक एक्स्टेंशन इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्क्रिप्ट व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला Stylus सारखे एक्स्टेंशन इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

ही स्टाईल इंस्टॉल करण्यासाठी तुम्हाला एक युझर स्टाईल व्यवस्थापक इंस्टॉल करावे लागेल.

(माझ्याकडे आधीच युझर स्टाईल व्यवस्थापक आहे, मला इंस्टॉल करू द्या!)

// ==UserScript==
// @name         Logs Check
// @namespace    http://tampermonkey.net/
// @version      2024-02-06
// @description  try to take over the world!
// @author       Artem_Tankov
// @match        https://logs.blackrussia.online/gslogs/*
// @icon         https://icons.iconarchive.com/icons/hopstarter/adobe-cs4/256/File-Adobe-Dreamweaver-XML-01-icon.png
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

        const LoadingDocument = document.getElementById("loading-overlay")
        const LoadTable = document.getElementById("loading-overlay-container")
        const a = document.getElementById("next-page-btn")
        const ButtonNextPage = window.getComputedStyle(a);
        const LoadDocOff = window.getComputedStyle(LoadingDocument)
        const i = document.querySelector(".collapse.navbar-collapse")
        const AllLogsButton = document.createElement("button")
        const OffAllLogsButton = document.createElement("button")
        var lol = 1;

        AllLogsButton.style.marginRight = "70px"
        AllLogsButton.style.borderRadius = "10px"

        OffAllLogsButton.style.position = "fixed"
        OffAllLogsButton.style.top = "550px"
        OffAllLogsButton.style.borderRadius = "10px"

        AllLogsButton.textContent = "Все логи";
        OffAllLogsButton.textContent = "Остановить";

        i.prepend(AllLogsButton);
        LoadTable.prepend(OffAllLogsButton);

        function AllLogs() {
            if (ButtonNextPage.display == "block" && lol == 1) {
                setTimeout(function() {
                    console.log("Нажал");
                    a.click();
                    AllLogs();
                }, 3000);
            }
        }

        function OffAllLogs() {
            lol = 0
            setTimeout(function() {
                lol = 1
         }, 4000);
            console.log("Остановись")
      }

        AllLogsButton.addEventListener('click', () => {
            AllLogs()
            AllLogsButton.style.background = "#d0db02"
                                                      })
        OffAllLogsButton.addEventListener("click", () => {
            AllLogsButton.style.background = "#fff"
            OffAllLogs()
                                                      })
})();