Add index.html
Browse files- index.html +388 -132
index.html
CHANGED
|
@@ -3,7 +3,7 @@
|
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
-
<title>
|
| 7 |
<style>
|
| 8 |
@import url('https://fonts.googleapis.com/css2?family=Comic+Neue:wght@700&display=swap');
|
| 9 |
|
|
@@ -29,7 +29,7 @@
|
|
| 29 |
color: #8B4513;
|
| 30 |
margin-bottom: 30px;
|
| 31 |
text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
|
| 32 |
-
font-size:
|
| 33 |
text-align: center;
|
| 34 |
}
|
| 35 |
|
|
@@ -37,27 +37,30 @@
|
|
| 37 |
display: flex;
|
| 38 |
flex-direction: column;
|
| 39 |
align-items: center;
|
|
|
|
| 40 |
}
|
| 41 |
|
| 42 |
.poo-button {
|
| 43 |
-
width:
|
| 44 |
-
height:
|
| 45 |
background-color: #d4a017;
|
| 46 |
border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
|
| 47 |
display: flex;
|
| 48 |
justify-content: center;
|
| 49 |
align-items: center;
|
| 50 |
-
font-size:
|
| 51 |
cursor: pointer;
|
| 52 |
user-select: none;
|
| 53 |
position: relative;
|
| 54 |
-
box-shadow: 0
|
| 55 |
-
inset 0 -
|
| 56 |
-
inset 0
|
| 57 |
transition: transform 0.1s;
|
| 58 |
-
margin-bottom:
|
| 59 |
-
filter: drop-shadow(0 0
|
| 60 |
overflow: hidden;
|
|
|
|
|
|
|
| 61 |
}
|
| 62 |
|
| 63 |
.poo-button:hover {
|
|
@@ -65,109 +68,198 @@
|
|
| 65 |
}
|
| 66 |
|
| 67 |
.poo-button:active {
|
| 68 |
-
transform: scale(0.
|
| 69 |
}
|
| 70 |
|
| 71 |
.poo-button::after {
|
| 72 |
content: '';
|
| 73 |
position: absolute;
|
| 74 |
-
width:
|
| 75 |
-
height:
|
| 76 |
background-color: #8B4513;
|
| 77 |
border-radius: 50%;
|
| 78 |
-
top:
|
| 79 |
-
filter: blur(
|
| 80 |
opacity: 0.3;
|
| 81 |
}
|
| 82 |
|
| 83 |
.counter {
|
| 84 |
-
font-size:
|
| 85 |
color: #8B4513;
|
| 86 |
-
margin-top:
|
| 87 |
background-color: rgba(255,255,255,0.7);
|
| 88 |
-
padding:
|
| 89 |
-
border-radius:
|
| 90 |
-
box-shadow: 0
|
| 91 |
}
|
| 92 |
|
| 93 |
.floating-poo {
|
| 94 |
position: absolute;
|
| 95 |
-
font-size:
|
| 96 |
pointer-events: none;
|
| 97 |
opacity: 0;
|
| 98 |
-
animation: float-up
|
| 99 |
-
filter: drop-shadow(0 0
|
|
|
|
| 100 |
}
|
| 101 |
|
| 102 |
@keyframes float-up {
|
| 103 |
0% {
|
| 104 |
-
transform: translateY(0);
|
| 105 |
opacity: 1;
|
| 106 |
}
|
| 107 |
100% {
|
| 108 |
-
transform: translateY(-
|
| 109 |
opacity: 0;
|
| 110 |
}
|
| 111 |
}
|
| 112 |
|
| 113 |
.controls {
|
| 114 |
-
margin-top:
|
| 115 |
display: flex;
|
| 116 |
-
gap:
|
| 117 |
}
|
| 118 |
|
| 119 |
.volume-control {
|
| 120 |
display: flex;
|
| 121 |
align-items: center;
|
| 122 |
background-color: rgba(255,255,255,0.7);
|
| 123 |
-
padding:
|
| 124 |
-
border-radius:
|
| 125 |
-
box-shadow: 0
|
| 126 |
}
|
| 127 |
|
| 128 |
.volume-control label {
|
| 129 |
-
margin-right:
|
| 130 |
color: #8B4513;
|
|
|
|
| 131 |
}
|
| 132 |
|
| 133 |
input[type="range"] {
|
|
|
|
|
|
|
| 134 |
accent-color: #d4a017;
|
| 135 |
}
|
| 136 |
|
| 137 |
.instructions {
|
| 138 |
-
margin-top:
|
| 139 |
background-color: rgba(255,255,255,0.7);
|
| 140 |
-
padding:
|
| 141 |
-
border-radius:
|
| 142 |
-
max-width:
|
| 143 |
text-align: center;
|
| 144 |
color: #8B4513;
|
| 145 |
-
box-shadow: 0
|
| 146 |
-
line-height: 1.
|
|
|
|
| 147 |
}
|
| 148 |
|
| 149 |
.streak {
|
| 150 |
-
font-size:
|
| 151 |
-
margin-top:
|
| 152 |
color: #d4a017;
|
| 153 |
-
text-shadow:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 154 |
}
|
| 155 |
|
| 156 |
-
@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 157 |
.poo-button {
|
| 158 |
-
width:
|
| 159 |
-
height:
|
| 160 |
-
font-size:
|
| 161 |
}
|
| 162 |
|
| 163 |
h1 {
|
|
|
|
|
|
|
|
|
|
|
|
|
| 164 |
font-size: 1.8rem;
|
| 165 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
| 166 |
}
|
| 167 |
</style>
|
| 168 |
</head>
|
| 169 |
<body>
|
| 170 |
-
<
|
|
|
|
|
|
|
| 171 |
|
| 172 |
<div class="poo-container">
|
| 173 |
<div class="poo-button" id="pooButton">💩</div>
|
|
@@ -175,16 +267,23 @@
|
|
| 175 |
<div class="streak" id="streak">Current streak: 0 clicks per second</div>
|
| 176 |
</div>
|
| 177 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 178 |
<div class="controls">
|
| 179 |
<div class="volume-control">
|
| 180 |
-
<label for="volume">
|
| 181 |
<input type="range" id="volume" name="volume" min="0" max="1" step="0.1" value="0.5">
|
| 182 |
</div>
|
| 183 |
</div>
|
| 184 |
|
| 185 |
<div class="instructions">
|
| 186 |
-
<p>Click the poo button as
|
| 187 |
-
|
|
|
|
| 188 |
</div>
|
| 189 |
|
| 190 |
<script>
|
|
@@ -192,71 +291,87 @@
|
|
| 192 |
const counterElement = document.getElementById('counter');
|
| 193 |
const volumeControl = document.getElementById('volume');
|
| 194 |
const streakElement = document.getElementById('streak');
|
|
|
|
|
|
|
|
|
|
|
|
|
| 195 |
|
| 196 |
let counter = 0;
|
| 197 |
let lastClickTime = 0;
|
| 198 |
let streakCount = 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 199 |
|
| 200 |
-
//
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 201 |
const fartSounds = [
|
| 202 |
new Audio('https://assets.mixkit.co/active_storage/sfx/153/153-preview.mp3'),
|
| 203 |
new Audio('https://assets.mixkit.co/active_storage/sfx/154/154-preview.mp3'),
|
| 204 |
new Audio('https://assets.mixkit.co/active_storage/sfx/155/155-preview.mp3')
|
| 205 |
];
|
| 206 |
|
| 207 |
-
//
|
| 208 |
-
|
| 209 |
-
|
| 210 |
-
});
|
| 211 |
|
| 212 |
-
//
|
| 213 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 214 |
const volume = volumeControl.value;
|
| 215 |
fartSounds.forEach(sound => {
|
| 216 |
sound.volume = volume;
|
| 217 |
});
|
| 218 |
-
|
|
|
|
|
|
|
| 219 |
|
| 220 |
pooButton.addEventListener('click', () => {
|
| 221 |
-
// Increment counter
|
| 222 |
-
|
|
|
|
| 223 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 224 |
|
| 225 |
// Play random fart sound
|
| 226 |
-
|
| 227 |
-
fartSounds[randomSound].currentTime = 0;
|
| 228 |
-
fartSounds[randomSound].play();
|
| 229 |
-
|
| 230 |
-
// Create floating poo
|
| 231 |
-
createFloatingPoo();
|
| 232 |
|
| 233 |
-
//
|
| 234 |
-
|
| 235 |
-
|
| 236 |
-
|
| 237 |
-
if (timeDiff < 500) { // If clicked within 0.5 seconds
|
| 238 |
-
streakCount++;
|
| 239 |
} else {
|
| 240 |
-
|
| 241 |
}
|
| 242 |
|
| 243 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 244 |
|
| 245 |
-
//
|
| 246 |
-
|
| 247 |
|
| 248 |
// Special effects every 10 clicks
|
| 249 |
if (counter % 10 === 0) {
|
| 250 |
-
|
| 251 |
-
void pooButton.offsetWidth; // Trigger reflow
|
| 252 |
-
pooButton.style.animation = 'jiggle 0.5s';
|
| 253 |
-
|
| 254 |
-
// Create multiple poos
|
| 255 |
-
setTimeout(() => {
|
| 256 |
-
for (let i = 0; i < 5; i++) {
|
| 257 |
-
createFloatingPoo();
|
| 258 |
-
}
|
| 259 |
-
}, 200);
|
| 260 |
}
|
| 261 |
});
|
| 262 |
|
|
@@ -266,20 +381,181 @@
|
|
| 266 |
poo.textContent = '💩';
|
| 267 |
|
| 268 |
// Random position around the button
|
| 269 |
-
const left = Math.random() *
|
| 270 |
poo.style.left = `${left}px`;
|
| 271 |
poo.style.top = `${pooButton.offsetTop + pooButton.offsetHeight / 2}px`;
|
| 272 |
|
| 273 |
-
// Random animation
|
| 274 |
-
poo.style.animationDuration = `${0.
|
| 275 |
-
poo.style.animationDelay = `${Math.random() * 0.
|
| 276 |
|
| 277 |
document.body.appendChild(poo);
|
| 278 |
|
| 279 |
-
// Remove after animation
|
| 280 |
setTimeout(() => {
|
| 281 |
poo.remove();
|
| 282 |
-
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 283 |
}
|
| 284 |
|
| 285 |
// Easter egg - long press
|
|
@@ -287,66 +563,46 @@
|
|
| 287 |
|
| 288 |
pooButton.addEventListener('mousedown', () => {
|
| 289 |
pressTimer = setTimeout(() => {
|
| 290 |
-
|
| 291 |
-
for (let i = 0; i < 20; i++) {
|
| 292 |
-
setTimeout(() => {
|
| 293 |
-
createFloatingPoo();
|
| 294 |
-
}, i * 50);
|
| 295 |
-
}
|
| 296 |
-
|
| 297 |
-
// Play all fart sounds at once
|
| 298 |
-
fartSounds.forEach(sound => {
|
| 299 |
-
sound.currentTime = 0;
|
| 300 |
-
sound.play();
|
| 301 |
-
});
|
| 302 |
|
| 303 |
// Counter bonus
|
| 304 |
-
counter +=
|
| 305 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 306 |
|
| 307 |
// Visual feedback
|
| 308 |
-
pooButton.style.transform = 'scale(1.
|
| 309 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 310 |
});
|
| 311 |
|
| 312 |
-
pooButton.addEventListener('mouseup',
|
| 313 |
-
|
| 314 |
-
});
|
| 315 |
|
| 316 |
-
|
| 317 |
clearTimeout(pressTimer);
|
| 318 |
-
}
|
| 319 |
|
| 320 |
// Mobile touch support
|
| 321 |
pooButton.addEventListener('touchstart', (e) => {
|
| 322 |
e.preventDefault();
|
| 323 |
pressTimer = setTimeout(() => {
|
| 324 |
-
|
| 325 |
-
|
| 326 |
-
setTimeout(() => {
|
| 327 |
-
createFloatingPoo();
|
| 328 |
-
}, i * 50);
|
| 329 |
-
}
|
| 330 |
-
|
| 331 |
-
// Play all fart sounds at once
|
| 332 |
-
fartSounds.forEach(sound => {
|
| 333 |
-
sound.currentTime = 0;
|
| 334 |
-
sound.play();
|
| 335 |
-
});
|
| 336 |
-
|
| 337 |
-
// Counter bonus
|
| 338 |
-
counter += 5;
|
| 339 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 340 |
-
|
| 341 |
-
|
| 342 |
-
|
| 343 |
-
}, 1000);
|
| 344 |
-
});
|
| 345 |
|
| 346 |
pooButton.addEventListener('touchend', (e) => {
|
| 347 |
e.preventDefault();
|
| 348 |
clearTimeout(pressTimer);
|
| 349 |
-
});
|
| 350 |
</script>
|
| 351 |
-
|
| 352 |
</html>
|
|
|
|
| 3 |
<head>
|
| 4 |
<meta charset="UTF-8">
|
| 5 |
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
| 6 |
+
<title>MEGA Poo Button</title>
|
| 7 |
<style>
|
| 8 |
@import url('https://fonts.googleapis.com/css2?family=Comic+Neue:wght@700&display=swap');
|
| 9 |
|
|
|
|
| 29 |
color: #8B4513;
|
| 30 |
margin-bottom: 30px;
|
| 31 |
text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
|
| 32 |
+
font-size: 4rem;
|
| 33 |
text-align: center;
|
| 34 |
}
|
| 35 |
|
|
|
|
| 37 |
display: flex;
|
| 38 |
flex-direction: column;
|
| 39 |
align-items: center;
|
| 40 |
+
position: relative;
|
| 41 |
}
|
| 42 |
|
| 43 |
.poo-button {
|
| 44 |
+
width: 300px;
|
| 45 |
+
height: 300px;
|
| 46 |
background-color: #d4a017;
|
| 47 |
border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
|
| 48 |
display: flex;
|
| 49 |
justify-content: center;
|
| 50 |
align-items: center;
|
| 51 |
+
font-size: 150px;
|
| 52 |
cursor: pointer;
|
| 53 |
user-select: none;
|
| 54 |
position: relative;
|
| 55 |
+
box-shadow: 0 20px 40px rgba(0,0,0,0.3),
|
| 56 |
+
inset 0 -20px 40px rgba(0,0,0,0.2),
|
| 57 |
+
inset 0 10px 20px rgba(255,255,255,0.4);
|
| 58 |
transition: transform 0.1s;
|
| 59 |
+
margin-bottom: 40px;
|
| 60 |
+
filter: drop-shadow(0 0 10px rgba(139, 69, 19, 0.5));
|
| 61 |
overflow: hidden;
|
| 62 |
+
z-index: 10;
|
| 63 |
+
border: 10px solid #8B4513;
|
| 64 |
}
|
| 65 |
|
| 66 |
.poo-button:hover {
|
|
|
|
| 68 |
}
|
| 69 |
|
| 70 |
.poo-button:active {
|
| 71 |
+
transform: scale(0.97) rotate(5deg);
|
| 72 |
}
|
| 73 |
|
| 74 |
.poo-button::after {
|
| 75 |
content: '';
|
| 76 |
position: absolute;
|
| 77 |
+
width: 240px;
|
| 78 |
+
height: 120px;
|
| 79 |
background-color: #8B4513;
|
| 80 |
border-radius: 50%;
|
| 81 |
+
top: 60px;
|
| 82 |
+
filter: blur(20px);
|
| 83 |
opacity: 0.3;
|
| 84 |
}
|
| 85 |
|
| 86 |
.counter {
|
| 87 |
+
font-size: 2.5rem;
|
| 88 |
color: #8B4513;
|
| 89 |
+
margin-top: 30px;
|
| 90 |
background-color: rgba(255,255,255,0.7);
|
| 91 |
+
padding: 15px 30px;
|
| 92 |
+
border-radius: 30px;
|
| 93 |
+
box-shadow: 0 8px 16px rgba(0,0,0,0.15);
|
| 94 |
}
|
| 95 |
|
| 96 |
.floating-poo {
|
| 97 |
position: absolute;
|
| 98 |
+
font-size: 50px;
|
| 99 |
pointer-events: none;
|
| 100 |
opacity: 0;
|
| 101 |
+
animation: float-up 2s forwards;
|
| 102 |
+
filter: drop-shadow(0 0 4px rgba(0,0,0,0.4));
|
| 103 |
+
z-index: 5;
|
| 104 |
}
|
| 105 |
|
| 106 |
@keyframes float-up {
|
| 107 |
0% {
|
| 108 |
+
transform: translateY(0) scale(1);
|
| 109 |
opacity: 1;
|
| 110 |
}
|
| 111 |
100% {
|
| 112 |
+
transform: translateY(-250px) rotate(360deg) scale(1.5);
|
| 113 |
opacity: 0;
|
| 114 |
}
|
| 115 |
}
|
| 116 |
|
| 117 |
.controls {
|
| 118 |
+
margin-top: 40px;
|
| 119 |
display: flex;
|
| 120 |
+
gap: 20px;
|
| 121 |
}
|
| 122 |
|
| 123 |
.volume-control {
|
| 124 |
display: flex;
|
| 125 |
align-items: center;
|
| 126 |
background-color: rgba(255,255,255,0.7);
|
| 127 |
+
padding: 15px 20px;
|
| 128 |
+
border-radius: 40px;
|
| 129 |
+
box-shadow: 0 8px 16px rgba(0,0,0,0.15);
|
| 130 |
}
|
| 131 |
|
| 132 |
.volume-control label {
|
| 133 |
+
margin-right: 15px;
|
| 134 |
color: #8B4513;
|
| 135 |
+
font-size: 1.5rem;
|
| 136 |
}
|
| 137 |
|
| 138 |
input[type="range"] {
|
| 139 |
+
width: 200px;
|
| 140 |
+
height: 20px;
|
| 141 |
accent-color: #d4a017;
|
| 142 |
}
|
| 143 |
|
| 144 |
.instructions {
|
| 145 |
+
margin-top: 30px;
|
| 146 |
background-color: rgba(255,255,255,0.7);
|
| 147 |
+
padding: 20px;
|
| 148 |
+
border-radius: 15px;
|
| 149 |
+
max-width: 700px;
|
| 150 |
text-align: center;
|
| 151 |
color: #8B4513;
|
| 152 |
+
box-shadow: 0 8px 16px rgba(0,0,0,0.15);
|
| 153 |
+
line-height: 1.6;
|
| 154 |
+
font-size: 1.3rem;
|
| 155 |
}
|
| 156 |
|
| 157 |
.streak {
|
| 158 |
+
font-size: 2rem;
|
| 159 |
+
margin-top: 25px;
|
| 160 |
color: #d4a017;
|
| 161 |
+
text-shadow: 2px 2px 3px rgba(0,0,0,0.2);
|
| 162 |
+
background-color: rgba(255,255,255,0.7);
|
| 163 |
+
padding: 15px 25px;
|
| 164 |
+
border-radius: 25px;
|
| 165 |
+
}
|
| 166 |
+
|
| 167 |
+
.poo-splat {
|
| 168 |
+
position: absolute;
|
| 169 |
+
font-size: 30px;
|
| 170 |
+
pointer-events: none;
|
| 171 |
+
opacity: 0;
|
| 172 |
+
animation: splat 1s forwards;
|
| 173 |
+
transform-origin: center;
|
| 174 |
+
}
|
| 175 |
+
|
| 176 |
+
@keyframes splat {
|
| 177 |
+
0% {
|
| 178 |
+
transform: scale(1);
|
| 179 |
+
opacity: 1;
|
| 180 |
+
}
|
| 181 |
+
100% {
|
| 182 |
+
transform: scale(5);
|
| 183 |
+
opacity: 0;
|
| 184 |
+
}
|
| 185 |
+
}
|
| 186 |
+
|
| 187 |
+
.background-poos {
|
| 188 |
+
position: fixed;
|
| 189 |
+
top: 0;
|
| 190 |
+
left: 0;
|
| 191 |
+
width: 100%;
|
| 192 |
+
height: 100%;
|
| 193 |
+
pointer-events: none;
|
| 194 |
+
z-index: -1;
|
| 195 |
+
}
|
| 196 |
+
|
| 197 |
+
.background-poo {
|
| 198 |
+
position: absolute;
|
| 199 |
+
font-size: 30px;
|
| 200 |
+
opacity: 0.2;
|
| 201 |
+
animation: floating 15s infinite linear;
|
| 202 |
}
|
| 203 |
|
| 204 |
+
@keyframes floating {
|
| 205 |
+
0% {
|
| 206 |
+
transform: translateY(0) rotate(0deg);
|
| 207 |
+
}
|
| 208 |
+
100% {
|
| 209 |
+
transform: translateY(-100vh) rotate(360deg);
|
| 210 |
+
}
|
| 211 |
+
}
|
| 212 |
+
|
| 213 |
+
.power-ups {
|
| 214 |
+
display: flex;
|
| 215 |
+
gap: 20px;
|
| 216 |
+
margin-top: 30px;
|
| 217 |
+
}
|
| 218 |
+
|
| 219 |
+
.power-up {
|
| 220 |
+
width: 80px;
|
| 221 |
+
height: 80px;
|
| 222 |
+
background-color: #d4a017;
|
| 223 |
+
border-radius: 50%;
|
| 224 |
+
display: flex;
|
| 225 |
+
justify-content: center;
|
| 226 |
+
align-items: center;
|
| 227 |
+
font-size: 40px;
|
| 228 |
+
cursor: pointer;
|
| 229 |
+
box-shadow: 0 5px 15px rgba(0,0,0,0.2);
|
| 230 |
+
transition: transform 0.3s;
|
| 231 |
+
border: 5px solid #8B4513;
|
| 232 |
+
}
|
| 233 |
+
|
| 234 |
+
.power-up:hover {
|
| 235 |
+
transform: scale(1.1);
|
| 236 |
+
}
|
| 237 |
+
|
| 238 |
+
@media (max-width: 768px) {
|
| 239 |
.poo-button {
|
| 240 |
+
width: 200px;
|
| 241 |
+
height: 200px;
|
| 242 |
+
font-size: 100px;
|
| 243 |
}
|
| 244 |
|
| 245 |
h1 {
|
| 246 |
+
font-size: 2.5rem;
|
| 247 |
+
}
|
| 248 |
+
|
| 249 |
+
.counter {
|
| 250 |
font-size: 1.8rem;
|
| 251 |
}
|
| 252 |
+
|
| 253 |
+
.streak {
|
| 254 |
+
font-size: 1.5rem;
|
| 255 |
+
}
|
| 256 |
}
|
| 257 |
</style>
|
| 258 |
</head>
|
| 259 |
<body>
|
| 260 |
+
<div class="background-poos" id="backgroundPoos"></div>
|
| 261 |
+
|
| 262 |
+
<h1>MEGA POO BUTTON 💩💩💩</h1>
|
| 263 |
|
| 264 |
<div class="poo-container">
|
| 265 |
<div class="poo-button" id="pooButton">💩</div>
|
|
|
|
| 267 |
<div class="streak" id="streak">Current streak: 0 clicks per second</div>
|
| 268 |
</div>
|
| 269 |
|
| 270 |
+
<div class="power-ups">
|
| 271 |
+
<div class="power-up" id="powerUp1" title="Turbo Mode (10x power)">🚀</div>
|
| 272 |
+
<div class="power-up" id="powerUp2" title="Poo Explosion">💥</div>
|
| 273 |
+
<div class="power-up" id="powerUp3" title="Golden Poos">🌟</div>
|
| 274 |
+
</div>
|
| 275 |
+
|
| 276 |
<div class="controls">
|
| 277 |
<div class="volume-control">
|
| 278 |
+
<label for="volume">VOLUME:</label>
|
| 279 |
<input type="range" id="volume" name="volume" min="0" max="1" step="0.1" value="0.5">
|
| 280 |
</div>
|
| 281 |
</div>
|
| 282 |
|
| 283 |
<div class="instructions">
|
| 284 |
+
<p>Click the HUGE poo button as much as you can!<br>
|
| 285 |
+
Try beating your high score and unlock special effects with the power-ups.<br>
|
| 286 |
+
The longer you press, the bigger the surprise!</p>
|
| 287 |
</div>
|
| 288 |
|
| 289 |
<script>
|
|
|
|
| 291 |
const counterElement = document.getElementById('counter');
|
| 292 |
const volumeControl = document.getElementById('volume');
|
| 293 |
const streakElement = document.getElementById('streak');
|
| 294 |
+
const powerUp1 = document.getElementById('powerUp1');
|
| 295 |
+
const powerUp2 = document.getElementById('powerUp2');
|
| 296 |
+
const powerUp3 = document.getElementById('powerUp3');
|
| 297 |
+
const backgroundPoos = document.getElementById('backgroundPoos');
|
| 298 |
|
| 299 |
let counter = 0;
|
| 300 |
let lastClickTime = 0;
|
| 301 |
let streakCount = 0;
|
| 302 |
+
let turboMode = false;
|
| 303 |
+
let goldenPoos = false;
|
| 304 |
+
let activatedPowerUps = {
|
| 305 |
+
turbo: 0,
|
| 306 |
+
explosion: 0,
|
| 307 |
+
golden: 0
|
| 308 |
+
};
|
| 309 |
|
| 310 |
+
// Create background poos
|
| 311 |
+
for (let i = 0; i < 30; i++) {
|
| 312 |
+
createBackgroundPoo();
|
| 313 |
+
}
|
| 314 |
+
|
| 315 |
+
// Preload sounds
|
| 316 |
const fartSounds = [
|
| 317 |
new Audio('https://assets.mixkit.co/active_storage/sfx/153/153-preview.mp3'),
|
| 318 |
new Audio('https://assets.mixkit.co/active_storage/sfx/154/154-preview.mp3'),
|
| 319 |
new Audio('https://assets.mixkit.co/active_storage/sfx/155/155-preview.mp3')
|
| 320 |
];
|
| 321 |
|
| 322 |
+
// Additional power-up sounds
|
| 323 |
+
const powerUpSound = new Audio('https://assets.mixkit.co/active_storage/sfx/264/264-preview.mp3');
|
| 324 |
+
const explosionSound = new Audio('https://assets.mixkit.co/active_storage/sfx/2439/2439-preview.mp3');
|
|
|
|
| 325 |
|
| 326 |
+
// Set initial volume
|
| 327 |
+
updateAllVolumes();
|
| 328 |
+
|
| 329 |
+
volumeControl.addEventListener('input', updateAllVolumes);
|
| 330 |
+
|
| 331 |
+
function updateAllVolumes() {
|
| 332 |
const volume = volumeControl.value;
|
| 333 |
fartSounds.forEach(sound => {
|
| 334 |
sound.volume = volume;
|
| 335 |
});
|
| 336 |
+
powerUpSound.volume = volume;
|
| 337 |
+
explosionSound.volume = volume;
|
| 338 |
+
}
|
| 339 |
|
| 340 |
pooButton.addEventListener('click', () => {
|
| 341 |
+
// Increment counter (more if turbo mode)
|
| 342 |
+
const increment = turboMode ? 10 : 1;
|
| 343 |
+
counter += increment;
|
| 344 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 345 |
|
| 346 |
// Play random fart sound
|
| 347 |
+
playRandomSound();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 348 |
|
| 349 |
+
// Create floating poos
|
| 350 |
+
if (goldenPoos) {
|
| 351 |
+
createGoldenPoo();
|
|
|
|
|
|
|
|
|
|
| 352 |
} else {
|
| 353 |
+
createFloatingPoo();
|
| 354 |
}
|
| 355 |
|
| 356 |
+
// Additional poos if in turbo mode
|
| 357 |
+
if (turboMode) {
|
| 358 |
+
for (let i = 0; i < 3; i++) {
|
| 359 |
+
setTimeout(() => {
|
| 360 |
+
if (goldenPoos) {
|
| 361 |
+
createGoldenPoo();
|
| 362 |
+
} else {
|
| 363 |
+
createFloatingPoo();
|
| 364 |
+
}
|
| 365 |
+
}, i * 200);
|
| 366 |
+
}
|
| 367 |
+
}
|
| 368 |
|
| 369 |
+
// Streak calculation
|
| 370 |
+
updateStreak();
|
| 371 |
|
| 372 |
// Special effects every 10 clicks
|
| 373 |
if (counter % 10 === 0) {
|
| 374 |
+
triggerSpecialEffect();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 375 |
}
|
| 376 |
});
|
| 377 |
|
|
|
|
| 381 |
poo.textContent = '💩';
|
| 382 |
|
| 383 |
// Random position around the button
|
| 384 |
+
const left = Math.random() * 200 - 100 + pooButton.offsetLeft + pooButton.offsetWidth / 2;
|
| 385 |
poo.style.left = `${left}px`;
|
| 386 |
poo.style.top = `${pooButton.offsetTop + pooButton.offsetHeight / 2}px`;
|
| 387 |
|
| 388 |
+
// Random animation properties
|
| 389 |
+
poo.style.animationDuration = `${0.8 + Math.random() * 2}s`;
|
| 390 |
+
poo.style.animationDelay = `${Math.random() * 0.5}s`;
|
| 391 |
|
| 392 |
document.body.appendChild(poo);
|
| 393 |
|
|
|
|
| 394 |
setTimeout(() => {
|
| 395 |
poo.remove();
|
| 396 |
+
}, 2000);
|
| 397 |
+
}
|
| 398 |
+
|
| 399 |
+
function createGoldenPoo() {
|
| 400 |
+
const poo = document.createElement('div');
|
| 401 |
+
poo.className = 'floating-poo';
|
| 402 |
+
poo.textContent = '🌟';
|
| 403 |
+
poo.style.color = 'gold';
|
| 404 |
+
poo.style.textShadow = '0 0 10px gold';
|
| 405 |
+
|
| 406 |
+
const left = Math.random() * 200 - 100 + pooButton.offsetLeft + pooButton.offsetWidth / 2;
|
| 407 |
+
poo.style.left = `${left}px`;
|
| 408 |
+
poo.style.top = `${pooButton.offsetTop + pooButton.offsetHeight / 2}px`;
|
| 409 |
+
poo.style.animationDuration = `${1 + Math.random() * 2}s`;
|
| 410 |
+
poo.style.animationDelay = `${Math.random() * 0.5}s`;
|
| 411 |
+
|
| 412 |
+
document.body.appendChild(poo);
|
| 413 |
+
|
| 414 |
+
setTimeout(() => {
|
| 415 |
+
poo.remove();
|
| 416 |
+
}, 2000);
|
| 417 |
+
}
|
| 418 |
+
|
| 419 |
+
function createSplat() {
|
| 420 |
+
const splat = document.createElement('div');
|
| 421 |
+
splat.className = 'poo-splat';
|
| 422 |
+
splat.textContent = '💩';
|
| 423 |
+
|
| 424 |
+
const left = Math.random() * 300 - 150 + pooButton.offsetLeft + pooButton.offsetWidth / 2;
|
| 425 |
+
splat.style.left = `${left}px`;
|
| 426 |
+
splat.style.top = `${pooButton.offsetTop + pooButton.offsetHeight / 2}px`;
|
| 427 |
+
|
| 428 |
+
document.body.appendChild(splat);
|
| 429 |
+
|
| 430 |
+
setTimeout(() => {
|
| 431 |
+
splat.remove();
|
| 432 |
+
}, 1000);
|
| 433 |
+
}
|
| 434 |
+
|
| 435 |
+
function createBackgroundPoo() {
|
| 436 |
+
const poo = document.createElement('div');
|
| 437 |
+
poo.className = 'background-poo';
|
| 438 |
+
poo.textContent = '💩';
|
| 439 |
+
|
| 440 |
+
poo.style.left = `${Math.random() * 100}vw`;
|
| 441 |
+
poo.style.top = `${100 + Math.random() * 20}vh`;
|
| 442 |
+
poo.style.animationDuration = `${10 + Math.random() * 20}s`;
|
| 443 |
+
poo.style.animationDelay = `${Math.random() * 10}s`;
|
| 444 |
+
|
| 445 |
+
backgroundPoos.appendChild(poo);
|
| 446 |
+
}
|
| 447 |
+
|
| 448 |
+
function playRandomSound() {
|
| 449 |
+
const randomSound = Math.floor(Math.random() * fartSounds.length);
|
| 450 |
+
fartSounds[randomSound].currentTime = 0;
|
| 451 |
+
fartSounds[randomSound].play();
|
| 452 |
+
}
|
| 453 |
+
|
| 454 |
+
function updateStreak() {
|
| 455 |
+
const currentTime = Date.now();
|
| 456 |
+
const timeDiff = currentTime - lastClickTime;
|
| 457 |
+
|
| 458 |
+
if (timeDiff < 500) {
|
| 459 |
+
streakCount++;
|
| 460 |
+
} else {
|
| 461 |
+
streakCount = 1;
|
| 462 |
+
}
|
| 463 |
+
|
| 464 |
+
streakElement.textContent = `Current streak: ${streakCount} clicks per second`;
|
| 465 |
+
lastClickTime = currentTime;
|
| 466 |
+
|
| 467 |
+
// Visual effect for high streaks
|
| 468 |
+
if (streakCount > 5) {
|
| 469 |
+
streakElement.style.color = '#ff5555';
|
| 470 |
+
streakElement.style.fontWeight = 'bold';
|
| 471 |
+
} else {
|
| 472 |
+
streakElement.style.color = '#d4a017';
|
| 473 |
+
streakElement.style.fontWeight = 'normal';
|
| 474 |
+
}
|
| 475 |
+
}
|
| 476 |
+
|
| 477 |
+
function triggerSpecialEffect() {
|
| 478 |
+
// Button animation
|
| 479 |
+
pooButton.style.transform = 'scale(1.1) rotate(10deg)';
|
| 480 |
+
setTimeout(() => {
|
| 481 |
+
pooButton.style.transform = '';
|
| 482 |
+
}, 300);
|
| 483 |
+
|
| 484 |
+
// Create multiple poos
|
| 485 |
+
for (let i = 0; i < 7; i++) {
|
| 486 |
+
setTimeout(() => {
|
| 487 |
+
if (goldenPoos) {
|
| 488 |
+
createGoldenPoo();
|
| 489 |
+
} else {
|
| 490 |
+
createFloatingPoo();
|
| 491 |
+
}
|
| 492 |
+
}, i * 150);
|
| 493 |
+
}
|
| 494 |
+
}
|
| 495 |
+
|
| 496 |
+
// Power-up functions
|
| 497 |
+
powerUp1.addEventListener('click', () => {
|
| 498 |
+
activatePowerUp('turbo');
|
| 499 |
+
});
|
| 500 |
+
|
| 501 |
+
powerUp2.addEventListener('click', () => {
|
| 502 |
+
activatePowerUp('explosion');
|
| 503 |
+
});
|
| 504 |
+
|
| 505 |
+
powerUp3.addEventListener('click', () => {
|
| 506 |
+
activatePowerUp('golden');
|
| 507 |
+
});
|
| 508 |
+
|
| 509 |
+
function activatePowerUp(type) {
|
| 510 |
+
if (activatedPowerUps[type] > Date.now()) return;
|
| 511 |
+
|
| 512 |
+
powerUpSound.currentTime = 0;
|
| 513 |
+
powerUpSound.play();
|
| 514 |
+
|
| 515 |
+
switch(type) {
|
| 516 |
+
case 'turbo':
|
| 517 |
+
turboMode = true;
|
| 518 |
+
pooButton.style.boxShadow = '0 0 30px #ff5555';
|
| 519 |
+
setTimeout(() => {
|
| 520 |
+
turboMode = false;
|
| 521 |
+
pooButton.style.boxShadow = '';
|
| 522 |
+
}, 10000);
|
| 523 |
+
activatedPowerUps.turbo = Date.now() + 30000; // 30s cooldown
|
| 524 |
+
break;
|
| 525 |
+
|
| 526 |
+
case 'explosion':
|
| 527 |
+
explosionSound.currentTime = 0;
|
| 528 |
+
explosionSound.play();
|
| 529 |
+
for (let i = 0; i < 15; i++) {
|
| 530 |
+
setTimeout(() => {
|
| 531 |
+
createSplat();
|
| 532 |
+
playRandomSound();
|
| 533 |
+
}, i * 100);
|
| 534 |
+
}
|
| 535 |
+
counter += 20;
|
| 536 |
+
counterElement.textContent = `Poo Count: ${counter}`;
|
| 537 |
+
activatedPowerUps.explosion = Date.now() + 20000; // 20s cooldown
|
| 538 |
+
break;
|
| 539 |
+
|
| 540 |
+
case 'golden':
|
| 541 |
+
goldenPoos = true;
|
| 542 |
+
pooButton.style.boxShadow = '0 0 30px gold';
|
| 543 |
+
setTimeout(() => {
|
| 544 |
+
goldenPoos = false;
|
| 545 |
+
pooButton.style.boxShadow = '';
|
| 546 |
+
}, 8000);
|
| 547 |
+
activatedPowerUps.golden = Date.now() + 25000; // 25s cooldown
|
| 548 |
+
break;
|
| 549 |
+
}
|
| 550 |
+
|
| 551 |
+
// Visual feedback
|
| 552 |
+
const powerUpElement = document.getElementById(`powerUp${type === 'turbo' ? 1 : type === 'explosion' ? 2 : 3}`);
|
| 553 |
+
powerUpElement.style.transform = 'scale(1.3)';
|
| 554 |
+
powerUpElement.style.boxShadow = '0 0 20px gold';
|
| 555 |
+
setTimeout(() => {
|
| 556 |
+
powerUpElement.style.transform = '';
|
| 557 |
+
powerUpElement.style.boxShadow = '';
|
| 558 |
+
}, 500);
|
| 559 |
}
|
| 560 |
|
| 561 |
// Easter egg - long press
|
|
|
|
| 563 |
|
| 564 |
pooButton.addEventListener('mousedown', () => {
|
| 565 |
pressTimer = setTimeout(() => {
|
| 566 |
+
activatePowerUp('explosion');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 567 |
|
| 568 |
// Counter bonus
|
| 569 |
+
counter += 25;
|
| 570 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 571 |
|
| 572 |
// Visual feedback
|
| 573 |
+
pooButton.style.transform = 'scale(1.3) rotate(20deg)';
|
| 574 |
+
|
| 575 |
+
// Multiple sounds
|
| 576 |
+
for (let i = 0; i < 5; i++) {
|
| 577 |
+
setTimeout(() => {
|
| 578 |
+
playRandomSound();
|
| 579 |
+
}, i * 300);
|
| 580 |
+
}
|
| 581 |
+
}, 1500);
|
| 582 |
});
|
| 583 |
|
| 584 |
+
pooButton.addEventListener('mouseup', clearPressTimer);
|
| 585 |
+
pooButton.addEventListener('mouseleave', clearPressTimer);
|
|
|
|
| 586 |
|
| 587 |
+
function clearPressTimer() {
|
| 588 |
clearTimeout(pressTimer);
|
| 589 |
+
}
|
| 590 |
|
| 591 |
// Mobile touch support
|
| 592 |
pooButton.addEventListener('touchstart', (e) => {
|
| 593 |
e.preventDefault();
|
| 594 |
pressTimer = setTimeout(() => {
|
| 595 |
+
activatePowerUp('explosion');
|
| 596 |
+
counter += 25;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 597 |
counterElement.textContent = `Poo Count: ${counter}`;
|
| 598 |
+
pooButton.style.transform = 'scale(1.3) rotate(20deg)';
|
| 599 |
+
}, 1500);
|
| 600 |
+
}, {passive: false});
|
|
|
|
|
|
|
| 601 |
|
| 602 |
pooButton.addEventListener('touchend', (e) => {
|
| 603 |
e.preventDefault();
|
| 604 |
clearTimeout(pressTimer);
|
| 605 |
+
}, {passive: false});
|
| 606 |
</script>
|
| 607 |
+
</body>
|
| 608 |
</html>
|