What is a "Built-In Script"?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Rodeo
:warning: Old Version Published before Godot 3 was released.

Near the bottom, directly above the Creat and Cancel buttons. When you enable it, you can’t name your script, and I’m not sure what it does or what kind of code should be in it.

:bust_in_silhouette: Reply From: avencherus

A built-in script is one that becomes part of that node, and not a separate file. Rather than creating an external .gd file and reference it, the script will be saved inside of the scene file itself.

Hmm, ok. What’s the benefit of such a thing?

Rodeo | 2017-02-13 00:07

Not many. The script is packed into the scene, so if you move it to another project, the scripts come with it, so you have less dependencies to copy and re-link.

avencherus | 2017-02-13 00:15

I see, thanks!

Rodeo | 2017-02-13 05:57