logo change, style change, games json file; almost whole revamp is in this commit

This commit is contained in:
MonkeyGG2
2023-09-08 21:05:46 -04:00
parent 999b1858ac
commit a2f0a93a75
200 changed files with 172568 additions and 57 deletions
+19 -1
View File
@@ -6,12 +6,30 @@ function changeLoadingTip() {
}
changeLoadingTip();
$("#everything-else").hide();
$("#everything-else, #page-loader, .games, .proxy, .settings").hide();
let changeTip = setInterval(() => {
changeLoadingTip();
}, 3000);
fetch("./game-info.jsonc").then((e) => e.text()).then((jsonc) => {
// removing all the comments from the jsonc file
let json = JSON.parse(jsonc.replace(/\\"|"(?:\\"|[^"])*"|(\/\/.*|\/\*[\s\S]*?\*\/)/g, (m, g) => g ? "" : m));
let gamesList = $("#gamesList");
for (game in json) {
gamesList.append(`<li url="games/${json[game]}">${game}</li>`);
}
$("#gamesList li").on("click", function() {
let url = $(this).attr("url");
$("#everything-else").fadeOut();
$("#page-loader").fadeIn();
$("#page-loader iframe")[0].src = url;
$("#page-loader iframe")[0].focus();
});
});
$(window).on("load", () => {
$(".track").attr("stroke", "url(#grad2)");
$(".worm1").hide();