I’m trying to scroll text up the screen in about 4min +/- a few seconds doesn’t even matter, along with a 4min audio.
To follow it, I’ve muted the audio 1 second every 10 seconds.
I display the elapsed time in the console. In Chrome and Edge, the counter in the console is precisely on the 10 second mark every time the song mutes. 10, 20, 30, 40, etc., and the text follows the audio.
In Firefox, 133.0.3 (64bit), the song seems to mute when the counter counts 8 seconds, 8, 16, 24, 32… Despite the song still playing its exact time duration.
My script has 1400 lines, here are the lines in question. Perhaps I’m not writing the setInterval properly for Firefox?? Is this a Firefox bug? Any idea what’s going on?
var pri;
var tm3 = 70;
var pry = 650;
var pryc = 0;
pri = setInterval(rosary.promise, tm3);
this.promise = function() {
pryc++;
console.log(pryc * tm3 / 1000); // Display elapsed seconds
pry -= 1;
texts.promise(pry);
if (pry < -2677) {
clearInterval(pri);
}
}
var Texts = function() {
this.promise = function(yp) {
yp = (yi + yp) * rtr;
t[gdPro].style.top = yp + 'px';
t[gdPro].style.visibility = 'visible';
}
}
var texts = new Texts();