Preload next scene

Hi all,

Does anyone know how to preload next scene?

I’ve looked at the docs, and it is not clear wheather to preload/store it in a variable, and at what point/code section to preload it?

In scene:show … or where?

Tnx!
G

Maybe this will be helpful composer.loadScene()

No. Tried that.

When you call composer.gotoScene() it check’s to see if that scene has been pre-loaded (i.e. it has been required and its scene:create()  function has been called). If so, composer.gotoScene() starts by transitioning the scene on screen calling scene:show() and scene:hide() on the previous scene.

Rob

Maybe this will be helpful composer.loadScene()

No. Tried that.

When you call composer.gotoScene() it check’s to see if that scene has been pre-loaded (i.e. it has been required and its scene:create()  function has been called). If so, composer.gotoScene() starts by transitioning the scene on screen calling scene:show() and scene:hide() on the previous scene.

Rob