How add autoload in script?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Dillon

How add .tscn file in autoload with script?

:bust_in_silhouette: Reply From: gate120

I guess you cannot just set a .tscn directly with autoload feature, but you can add an autoload script which provides a function to create your target scene. Then just call it in first main scene’s script.