From 91e44ce19a0f343f8193eb38d11f925d64394029 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=F0=93=8D=BC?= <143974574+xojw@users.noreply.github.com> Date: Sun, 25 May 2025 14:43:27 -0500 Subject: [PATCH] Remove ads on 1v1.LOL --- public/assets/g/1v1lol/index.html | 104 +----------------------------- 1 file changed, 1 insertion(+), 103 deletions(-) diff --git a/public/assets/g/1v1lol/index.html b/public/assets/g/1v1lol/index.html index 0d7eb158..872353cb 100644 --- a/public/assets/g/1v1lol/index.html +++ b/public/assets/g/1v1lol/index.html @@ -13,7 +13,6 @@ - - -
-
-
-
-
- - -
-
-
- - -
-
-
-
@@ -222,55 +179,6 @@ var refreshNextTime = true; - function showAds() { - document.getElementsByClassName("ad-rectangle-bottom")[0].style.display = "block"; - document.getElementsByClassName("ad-leaderboard-bottom")[0].style.display = "block"; - document.getElementById("adRectangleUpper").style.display = "block"; - - if (typeof counter === "undefined") { - startCounter(); - resumeCounter(); - } else { - resumeCounter(); - refresh(); - } - } - - function hideAds() { - document.getElementsByClassName("ad-rectangle-bottom")[0].style.display = "none"; - document.getElementsByClassName("ad-leaderboard-bottom")[0].style.display = "none"; - document.getElementById("adRectangleUpper").style.display = "none"; - - pauseCounter(); - } - - // hide ads - hideAds(); - - function refresh() { - //console.log("time since ads refresh = " + timeSinceRefresh + " seconds"); - //console.log("time ads visible = " + timeAdsVisible + " seconds"); - - if (timeSinceRefresh <= 30 || timeAdsVisible <= 2) { - //console.log("don't refresh"); - return; - } - - if (document.getElementById("adRectangleBottom") != null && window.getComputedStyle(document.getElementsByClassName("ad-smallscreen")[0]).display != "none") { - cpmstarAPI({ kind: "adcmd", module: "POOL 83023", command: "refresh" }); - } - - if (document.getElementById("adLeaderboardBottom") != null && window.getComputedStyle(document.getElementsByClassName("ad-largescreen")[0]).display != "none") { - cpmstarAPI({ kind: "adcmd", module: "POOL 85420", command: "refresh" }); - } - - cpmstarAPI({ kind: "adcmd", module: "POOL 83025", command: "refresh" }); - - timeSinceRefresh = 0; - timeAdsVisible = 0; - //console.log("refresh ads"); - } - window.onfocus = function () { //console.log("onfocus"); resumeCounter(); @@ -283,26 +191,16 @@ }; var timeSinceRefresh = 0; - var timeAdsVisible = 0; var counter; - var adsVisible = false; function startCounter() { timeSinceRefresh++; - if (adsVisible) timeAdsVisible++; counter = setTimeout(function () { startCounter(); }, 1000); } - function resumeCounter() { - adsVisible = true; - } - - function pauseCounter() { - adsVisible = false; - } @@ -341,4 +239,4 @@ fixMacUserAgent(); - + \ No newline at end of file