Type Function Library composer.* Return value String Revision Release 2022.3683 Keywords composer, scene, getSceneName See also composer.gotoScene() composer.removeScene()
Returns the current, previous, or overlay scene name as a string. This can then be used with composer.gotoScene() or composer.removeScene().
composer.getSceneName( sceneType )
String. The name of the scene you want to retrieve. Possible values are "current"
, "previous"
, or "overlay"
.
local prevScene = composer.getSceneName( "previous" ) -- Later... composer.gotoScene( prevScene )
local currScene = composer.getSceneName( "current" ) composer.removeScene( currScene )