Calculator Tools Calculator Tools
Create

TomRocksMaths Game Graphics Rating

Nov 16, 2023

About this app

Rate the graphics of the TomRocksMaths game across different gaming consoles.

TomRocksMaths Game Graphics Rating

Related apps

Put this on your site

Source

                    <html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1">

<title>TomRocksMaths Game Graphics Rating</title>
<meta name="description" content="Rate the graphics of the TomRocksMaths game across different gaming consoles.">
<meta name="keywords" content="TomRocksMaths, Game, Graphics Rating, Consoles">

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
<script src="https://www.youtube.com/iframe_api"></script>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet"
integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous">
<link href="https://fonts.googleapis.com/css2?family=Faster+One&family=Press+Start+2P&display=swap" rel="stylesheet">
<link href="https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css" rel="stylesheet">

<script type="text/javascript">
try {
// App Javascript Goes Here. Place your entire script content inside the try block for error handling.
const consoles = [
// Best consoles (1-500)
'RTX', /* ... other best consoles ... */
// Worst consoles (501-1000)
'Windows 95 3D Graphics', /* ... other worst consoles ... */
];

// This will run when the DOM is ready.
document.addEventListener("DOMContentLoaded", function() {
const mainContainer = document.getElementById('main-container');

for (let i = 1; i <= 1000; i++) {
const button = document.createElement('button');
button.className = 'btn btn-primary m-1';
button.innerText = `Rate Graphics for Game Copy #${i}`;
button.dataset.console = consoles[(i - 1) % consoles.length];
button.onclick = function() {
const rating = prompt(`Rate the graphics (0-10) for ${this.dataset.console}`);
if(rating !== null && rating >= 0 && rating <= 10) {
alert(`You rated the graphics for ${this.dataset.console} a ${rating}/10`);
}
};
mainContainer.appendChild(button);
}
});

// This function creates and loads the YouTube video player
function onYouTubeIframeAPIReady() {
const videoContainer = document.getElementById('video-container');
const player = new YT.Player('player', {
height: '360',
width: '640',
videoId: 'VIDEO_ID',
events: {
'onReady': onPlayerReady
}
});

function onPlayerReady(event) {
event.target.playVideo();
}
}

} catch (error) {
// This will throw the error to the parent window.
throw error;
}
</script>

<style>
/* App CSS Goes Here */
body {
font-family: 'Faster One', cursive;
background: linear-gradient(135deg, #6e8efb, #a777e3);
color: #fff;
}
.btn-primary {
background: #4e54c8;
background: -webkit-linear-gradient(to right, #8f94fb, #4e54c8);
background: linear-gradient(to right, #8f94fb, #4e54c8);
border: none;
}
.btn-primary:hover {
background: #8f94fb;
background: -webkit-linear-gradient(to right, #4e54c8, #8f94fb);
background: linear-gradient(to right, #4e54c8, #8f94fb);
}
#main-container {
text-align: center;
padding-top: 50px;
}
#video-container {
margin-top: 50px;
text-align: center;
}
</style>
</head>
<body>
<div id="main-container" class="container">
<!-- App HTML Goes Here -->
</div>

<div id="video-container">
<!-- YouTube Video Player -->
<div id="player"></div>
</div>

<script>
// Load the YouTube API
function loadYouTubeAPI() {
const tag = document.createElement('script');
tag.src = "https://www.youtube.com/iframe_api";
const firstScriptTag = document.getElementsByTagName('script')[0];
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag);
}

// When the DOM is ready, load the YouTube API
document.addEventListener("DOMContentLoaded", function() {
loadYouTubeAPI();
});
</script>
</body>
</html>