3 ms·
To be more clear: The TIME_CURVES array is filled (js/app.js:763) with objects in the shape of {time_ut, coords}. Then, the crossings array, which is built fro
by genezeta 2mo ago
To be more clear:
The TIME_CURVES array is filled (js/app.js:763) with objects in the shape of {time_ut, coords}. Then, the crossings array, which is built from TIME_CURVES (js/app.js:364-380), is filled with objects in the shape of {tUT, p} but, and here is the problem, you try to set the tUT property from a nonexistent tUT property in the TIME_CURVES element -it should be tc.time_ut or something derived from it- (js/app.js:377).
What happens then is that positionAt (js/app.js:382) goes through all the elements in crossings comparing the tUT argument passed into the function to undefined because the items in crossings all have their tUT property as undefined. This results in positionAt always returning crossings[crossings.length - 1].
And so, no matter what tMinutes argument you pass to updateLive (js/app.js:404), it will always get the same position into pos and it will always set the umbraCircle and the penumbraCircle at the same latitude and longitude. And so, nothing gets animated in the map. Or, to be more precise, it does get animated but is always painted at the same position.
Next time, you might want to consider skipping the insults.