Skip to content

Commit 5daddf0

Browse files
committed
Now.GG Fix
1 parent af33443 commit 5daddf0

File tree

6 files changed

+65
-6
lines changed

6 files changed

+65
-6
lines changed
15.7 KB
Loading
-1.83 KB
Binary file not shown.

static/assets/scripts/apps.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -245,14 +245,12 @@ document.addEventListener('DOMContentLoaded', () => {
245245
image: '/assets/media/icons/discord.jpg',
246246
categories: ['all', 'social'],
247247
blank: 'true',
248-
error: false,
249248
},
250249
{
251250
name: 'HD Today',
252251
link: 'https://hdtoday.tv',
253252
image: '/assets/media/icons/hd.png',
254253
categories: ['all', 'media', 'stream'],
255-
error: false,
256254
},
257255
{
258256
name: 'Roblox (Now.GG)',
@@ -269,13 +267,13 @@ document.addEventListener('DOMContentLoaded', () => {
269267
{
270268
name: 'Roblox (Now.GG Alternative)',
271269
link: 'https://nowgg.nl/play/roblox-corporation/5349/roblox',
272-
image: '/assets/media/icons/roblox.png',
270+
image: '/assets/media/icons/astroid.png',
273271
categories: ['all', 'emu'],
274272
},
275273
{
276274
name: 'Now.GG (Alternative)',
277275
link: 'https://nowgg.nl',
278-
image: '/assets/media/icons/now-gg.png',
276+
image: '/assets/media/icons/astroid.png',
279277
categories: ['all', 'emu'],
280278
},
281279
{

static/assets/scripts/g.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1507,13 +1507,13 @@ document.addEventListener('DOMContentLoaded', () => {
15071507
{
15081508
name: 'Roblox (Now.GG Alternative)',
15091509
link: 'https://nowgg.nl/play/roblox-corporation/5349/roblox',
1510-
image: '/assets/media/icons/roblox.png',
1510+
image: '/assets/media/icons/astroid.png',
15111511
categories: ['all', 'emu'],
15121512
},
15131513
{
15141514
name: 'Now.GG (Alternative)',
15151515
link: 'https://nowgg.nl',
1516-
image: '/assets/media/icons/now-gg.png',
1516+
image: '/assets/media/icons/astroid.png',
15171517
categories: ['all', 'emu'],
15181518
},
15191519
{

static/assets/scripts/now.js

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
function styledLog(message, style) {
2+
console.log(`%c${message}`, style);
3+
}
4+
5+
function runTopLogs() {
6+
console.log('%cdiscord.gg/interstellar', 'font-weight: bold; font-size: 39px; color: red; text-shadow: 3px 3px 0 rgb(217,31,38), 6px 6px 0 rgb(226,91,14), 9px 9px 0 rgb(245,221,8), 12px 12px 0 rgb(5,148,68), 15px 15px 0 rgb(2,135,206), 18px 18px 0 rgb(4,77,145), 21px 21px 0 rgb(42,21,113); margin-bottom: 12px; padding: 5%;');
7+
console.log('%cCredits to @xbubbo and @xderpman on Discord.', 'font-weight: bold; font-size: 20px; color: blue;');
8+
console.log('%cYou can use this code with proper credits.', 'font-weight: bold; font-size: 20px; color: purple;');
9+
}
10+
11+
var adjustmentCompleted = false;
12+
var attempts = 0;
13+
14+
function adjustElements() {
15+
if (adjustmentCompleted) {
16+
console.log('%cNow.GG Adjustment already completed. Stopping script.', 'font-size: 30px; color: green;');
17+
return true;
18+
}
19+
20+
var iframe = top.document.getElementById('iframeId');
21+
22+
if (iframe) {
23+
var innerDoc = iframe.contentWindow.document;
24+
25+
var roblox = innerDoc.getElementById('js-game-video');
26+
var controlBar = innerDoc.getElementById('ng-control-bar');
27+
28+
if (roblox && controlBar) {
29+
roblox.style.top = '295px';
30+
controlBar.style.top = '90%';
31+
console.log('%cSuccessfully adjusted Now.GG.', 'font-size: 30px; color: green;');
32+
33+
adjustmentCompleted = true;
34+
35+
return true;
36+
} else {
37+
console.log('%cFailed to find elements (roblox or controlBar).', 'font-size: 15px; color: red;');
38+
return false;
39+
}
40+
} else {
41+
console.log('%cFailed to find iframe with the specified ID.', 'font-size: 15px; color: red;');
42+
return false;
43+
}
44+
}
45+
46+
function checkAndAdjust() {
47+
var intervalId = setInterval(function () {
48+
runTopLogs();
49+
attempts++;
50+
if (adjustElements()) {
51+
clearInterval(intervalId);
52+
} else if (attempts >= 5) {
53+
console.log('%cNow.GG Script ran 5 times without finding elements. Stopping script.', 'font-size: 15px; color: red;');
54+
clearInterval(intervalId);
55+
}
56+
}, 7000);
57+
}
58+
59+
checkAndAdjust();
60+
console.log('%cNow.GG Adjustment script started. Checking every 7 seconds.', 'font-size: 15px; color: blue;');

static/go.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
<link rel="shortcut icon" id="dynamic-favicon" href="favicon.png" />
88
<title id="dynamic-title">Home</title>
99
<script src="https://kit.fontawesome.com/1237c86ba0.js" crossorigin="anonymous"></script>
10+
<script src="/assets/scripts/now.js"></script>
1011
<style>
1112
body {
1213
margin: 0;

0 commit comments

Comments
 (0)