System managing scenes display and lifecycle. Use it to structure your app in different scenes.
Static variables
Variables
keepAssetsForNextMain:Bool = false
If true
, when assigning a new main scene, assets of the previous
main scene will be kept instead of being destroyed and can be
reused by the new main scene without having to reload these
fadeOutWhenNextMainCanFadeIn:Bool = true
If true
, when assigning a new main scene, previous main
scene will wait until the next scene is properly loaded and can fade-in
before starting its own fade-out transition.
autoDestroyFilter:Bool = true
If set to true
(default), any filter assigned to the system will be destroyed
if replaced by another filter, set to null, or if the system is destroyed.
autoScaleFilter:Bool = true
If set to true
(default), a filter assigned to the system will
be auto-scaled to fit screen size.
Methods
set(name:String, scene:Scene, bindToScreenSize:Bool = true, keepAssets:Bool = false):Void
Assign secondary scenes to display them directly on screen.
Parameters:
name | The slot name of the scene |
---|---|
scene | The scene to assign |
bindToScreenSize | (optional) Set to |
keepAssets | (optional) Set to |
get(name:String):Scene
Retrieve a secondary scene from the given slot name
Parameters:
name | The slot name of the scene to retrieve |
---|
Returns:
A Scene
instance or null
if nothing was found