Calculator Tools Calculator Tools
Create

Arrow Clicker Game

Nov 25, 2023

About this app

A fun arrow clicking game where you score points by clicking the up arrow. When the timer ends, it rains Roblox logos for bonus points!

Arrow Clicker Game Score: 0 Time Left: 15s ⬆️

Related apps

Put this on your site

Source

                    <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Arrow Clicker Game</title>
<meta name="description" content="A fun arrow clicking game where you score points by clicking the up arrow. When the timer ends, it rains Roblox logos for bonus points!">
<meta name="keywords" content="Arrow Clicker, Game, Fun, Roblox, Points, Timer">
<link href="https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap" rel="stylesheet">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></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">
<style>
body {
font-family: 'Press Start 2P', cursive;
background-color: #f0f0f0;
}

#main-container {
text-align: center;
padding-top: 50px;
}

#scoreboard {
font-size: 2em;
margin-bottom: 20px;
}

#arrow-btn {
font-size: 3em;
cursor: pointer;
user-select: none;
}

.roblox-logo {
position: absolute;
width: 50px;
opacity: 0.7;
pointer-events: none;
animation: fall 3s linear infinite;
}

@keyframes fall {
0% {
top: -50px;
}
100% {
top: 100%;
}
}
</style>
</head>
<body>
<div id="main-container" class="container">
<div id="scoreboard">Score: <span id="score">0</span></div>
<div id="timer">Time Left: <span id="time-left">15</span>s</div>
<div id="arrow-btn">⬆️</div>
</div>

<script>
let score = 0;
let gameTime = 15;
let gameInterval;
let robloxInterval;

document.addEventListener("DOMContentLoaded", function() {
$('#arrow-btn').click(function() {
score++;
$('#score').text(score);
});

gameInterval = setInterval(function() {
gameTime--;
$('#time-left').text(gameTime);

if (gameTime <= 0) {
clearInterval(gameInterval);
startRobloxRain();
}
}, 1000);
});

function startRobloxRain() {
robloxInterval = setInterval(function() {
const robloxLogo = $('<div class="roblox-logo">🟥</div>');
const startPosition = Math.random() * $(window).width();
robloxLogo.css({
left: startPosition,
color: '#ff0000',
filter: 'drop-shadow(0 0 6px #ff0000)',
animationDuration: (Math.random() * 3 + 2) + 's', // Randomize fall speed
});

$('body').append(robloxLogo);

robloxLogo.click(function() {
score += 10; // Graham points
$('#score').text(score);
$(this).remove();
});

setTimeout(function() {
robloxLogo.remove();
}, 3000);
}, 500);
}
</script>
</body>
</html>