fix homoween award function name conflict

master
Aevann 2024-11-11 16:33:33 +02:00
parent be9e3c1372
commit 5d4667b50f
3 changed files with 8 additions and 8 deletions

View File

@ -24,7 +24,7 @@ for (let i1 = 0 ; i1 < puffs; i1++)
}
draw(new Date().getTime(), 3000)
draw_fog(new Date().getTime(), 3000)
@ -60,7 +60,7 @@ function addNewParticle(delay)
}
function draw(startT, totalT)
function draw_fog(startT, totalT)
{
//Timing
let timeDelta = new Date().getTime() - startT;
@ -108,7 +108,7 @@ function draw(startT, totalT)
//Repeat if there's still a living particle
if (stillAlive)
{
requestAnimationFrame(function(){draw(startT,totalT);});
requestAnimationFrame(function(){draw_fog(startT,totalT);});
}
else
{

View File

@ -89,7 +89,7 @@ function getRandom(min, max) {
return Math.floor(Math.random() * (max - min + 1) + min);
}
function draw() {
function draw_stalker() {
let stalker = stalkers[0];
let prevstalker = stalkers[0];
stalker.x = stalker.X += (mouse.x - stalker.X) * speed;
@ -104,7 +104,7 @@ function draw() {
stalker.y = stalker.Y += (prevstalker.y - stalker.Y) * speed;
}
makeCircle();
requestAnimationFrame(draw);
requestAnimationFrame(draw_stalker);
}
draw();
draw_stalker();

View File

@ -30,7 +30,7 @@ if (innerWidth >= 768) {
num_fireflies = 50
}
function draw() {
function draw_upsidedown() {
if (f.length < num_fireflies) {
for (let j = 0; j < 10; j++) {
f.push(new firefly());
@ -58,7 +58,7 @@ function init(elemid) {
function loop() {
st.clearRect(0, 0, w, h);
draw();
draw_upsidedown();
}
loop();