Open Arjunxxxl opened 1 year ago
Now the issue is when we are putting playcanvas in background, the tweens are not working.
PlayCanvas uses the animation frame callback for 'frame updates' and tween manager is dependent on the engine's update loop.
When the tab is in the background, the browser callback for animation is not called by the browser for the tab so no engine update is done while the tab is in the background.
and when the playcanavas is moved to foreground only the rotation tween works and position tween doesn't works.
Surprised that it isn't consistent. Can you provide a simple example project that could be investigated please?
We are making a game in which we are updating entity's position and rotations using tween library using the following code.
And the both of the functions are executed after a settimeout call. Now the issue is when we are putting playcanvas in background, the tweens are not working. and when the playcanavas is moved to foreground only the rotation tween works and position tween doesn't works. Can anyone help me out here? thanks.