const locoEmojis = ['πŸ€ͺ', '😡', 'πŸŒ€', 'πŸ’₯', 'πŸ”₯', '⚑']; for (let i = 0; i < 18; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'loco-particle'; particle.textContent = locoEmojis[Math.floor(Math.random() * locoEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 3000); }, i * 80); } } function createYellowEffect() { const yellowEmojis = ['πŸ’›', '🌻', '⭐', '🌟', '✨', 'πŸ’«']; for (let i = 0; i < 15; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'yellow-particle'; particle.textContent = yellowEmojis[Math.floor(Math.random() * yellowEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 2500); }, i * 120); } } function createCrazyEffect() { const crazyEmojis = ['πŸ’₯', 'πŸŒͺ️', 'πŸ”₯', '⚑', 'πŸŽ†', 'πŸ’«', 'πŸŒ€']; for (let i = 0; i < 20; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'crazy-particle'; particle.textContent = crazyEmojis[Math.floor(Math.random() * crazyEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; particle.style.color = `hsl(${Math.random() * 360}, 100%, 60%)`; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 2800); }, i * 60); } } function createUpDownEffect() { // Create full screen up & down effect const upDown = document.createElement('div'); upDown.className = 'updown-effect'; document.body.appendChild(upDown); // Remove after animation setTimeout(() => { if (document.body.contains(upDown)) { document.body.removeChild(upDown); } }, 3000); // Additional up & down particles const upDownEmojis = ['⬆️', '⬇️', '🎒', 'πŸ“ˆ', 'πŸ“‰']; for (let i = 0; i < 12; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'particle'; particle.textContent = upDownEmojis[Math.floor(Math.random() * upDownEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; particle.style.color = i % 2 === 0 ? '#32CD32' : '#FF1493'; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 4000); }, i * 150); } } function createKittyEffect() { const kittyEmojis = ['🐱', '😺', '😸', '😻', 'πŸ™€', '😿', '😾']; for (let i = 0; i < 12; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'kitty-particle'; particle.textContent = kittyEmojis[Math.floor(Math.random() * kittyEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 4000); }, i * 200); } } function createDangerousEffect() { const dangerousEmojis = ['⚠️', '☠️', 'πŸ’€', '🚨', 'β›”', 'πŸ”₯', 'πŸ’₯']; for (let i = 0; i < 10; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'particle'; particle.textContent = dangerousEmojis[Math.floor(Math.random() * dangerousEmojis.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; particle.style.color = '#DC143C'; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 4000); }, i * 180); } } function createCelebrationParticles() { const celebrations = ['πŸŽ‰', '🎊', 'πŸ€ͺ', 'πŸ’«', '🎒', 'πŸ’›', 'πŸ†', 'πŸ‘‘', '🌟', '✨', 'πŸ”₯', 'πŸ’₯']; for (let i = 0; i < 50; i++) { setTimeout(() => { const particle = document.createElement('div'); particle.className = 'particle'; particle.textContent = celebrations[Math.floor(Math.random() * celebrations.length)]; particle.style.left = Math.random() * window.innerWidth + 'px'; particle.style.top = Math.random() * window.innerHeight + 'px'; particle.style.color = `hsl(${Math.random() * 360}, 100%, 60%)`; document.body.appendChild(particle); setTimeout(() => { if (document.body.contains(particle)) { document.body.removeChild(particle); } }, 4000); }, i * 60); } } function showComboEffect() { const comboDisplay = document.getElementById('comboDisplay'); const messages = [ `${gameState.combo} COMBO! LOCO!`, `${gameState.combo} COMBO! CRAZY!`, `${gameState.combo} COMBO! λ―ΈμΉœλ‹€!`, `${gameState.combo} COMBO! YELLOW!`, `${gameState.combo} COMBO! UP & DOWN!` ]; comboDisplay.textContent = messages[Math.floor(Math.random() * messages.length)]; comboDisplay.classList.add('show'); setTimeout(() => { comboDisplay.classList.remove('show'); }, 2000); } function showAchievement(text) { const toast = document.getElementById('achievementToast'); const textElement = document.getElementById('achievementText'); textElement.textContent = text; toast.classList.add('show'); setTimeout(() => { toast.classList.remove('show'); }, 5000); } // Initialize on load document.addEventListener('DOMContentLoaded', initGame); // Console Easter Egg console.log('%cπŸ€ͺ LOCO Typing Master πŸ’«', 'font-size: 24px; font-weight: bold; color: #FF1493;'); console.log('%cI\'m gettin\' LOCO LOCO! λ―ΈμΉœλ‹€! πŸ”₯', 'font-size: 14px; color: #FFFF00;');