Update app.py
Browse files
app.py
CHANGED
@@ -578,7 +578,7 @@ async(c, o, p, d, n, m, s)=>{
|
|
578 |
now = new Date().getTime();
|
579 |
delta = now - then;
|
580 |
then = now - (delta % interval);
|
581 |
-
if (delta >= interval - tolerance) {
|
582 |
BABYLON.Engine.LastCreatedScene.activeCamera.target = BABYLON.Engine.LastCreatedScene.activeCamera.getDirection(parallax);
|
583 |
BABYLON.Engine.LastCreatedScene.render();
|
584 |
}
|
|
|
578 |
now = new Date().getTime();
|
579 |
delta = now - then;
|
580 |
then = now - (delta % interval);
|
581 |
+
if (delta >= interval - tolerance && BABYLON.Engine.LastCreatedScene.activeCamera) {
|
582 |
BABYLON.Engine.LastCreatedScene.activeCamera.target = BABYLON.Engine.LastCreatedScene.activeCamera.getDirection(parallax);
|
583 |
BABYLON.Engine.LastCreatedScene.render();
|
584 |
}
|