ptit flop

This commit is contained in:
thaaoblues 2024-12-14 20:15:44 +01:00
parent 2aa25f13d3
commit a3f77dc11d
2 changed files with 18 additions and 19 deletions

View file

@ -23,34 +23,31 @@
}
/* Define keyframes for the confetti */
@keyframes confettiFall {
@keyframes PluieConfetti {
0% {
transform: translateY(-100px) rotate(0deg);
opacity: 1;
transform: translateY(-100px) rotate(0deg);
opacity: 1;
}
100% {
transform: translateY(100vh) rotate(720deg);
opacity: 0;
transform: translateY(100vh) rotate(720deg);
opacity: 0;
}
}
}
/* Confetti styles */
.confetti {
.confetti {
position: absolute;
width: 10px;
height: 20px;
animation: confettiFall 5s linear;
animation: confettiFall 5s linear infinite;
opacity: 0;
}
}
/* Confetti container to spawn confetti randomly */
.confetti-container {
.confetti-container {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
overflow: hidden;
pointer-events: none; /* Prevent interaction */
}
pointer-events: none; /* pour ne pas interagir avec les confettis */
}

View file

@ -219,7 +219,7 @@ async function remplirMagasinCollegues(){
// on ajoute l'amélioration dans l'abre des compétences débloquées
sacado[key] = 1
// on change le futur cout dans le tableau
document.getElementById("case_cout_"+key).innerText = Number(c.cout * (1.1)**sacado[key]).toFixed(1)
@ -310,7 +310,7 @@ function genererConfetti() {
// couleurs des confetti à generer
const colors = ["#FF5733", "#33FF57", "#3357FF", "#FF33A1", "#FFD633", "#A833FF", "#33FFF6"]
const nb_confetti = 50 // nombre de confettis
const nb_confetti = 150 // nombre de confettis
for (let i = 0; i < nb_confetti; i++) {
@ -336,7 +336,9 @@ function genererConfetti() {
}
// vide le conteneur à la fin pour ne pas surcharger la page d'elements
setTimeout(() => {
// vide le conteneur à la fin pour ne pas surcharger la page d'elements
container.innerHTML = ""
}, 10000);
container.innerHTML = ""
}