From f06504ca0b7a3e3445df3ab72b80808690d4c53b Mon Sep 17 00:00:00 2001 From: HolonProduction Date: Fri, 19 Jul 2024 09:40:42 +0200 Subject: [PATCH] Add note about `Script.has_source_code` and GDScript binary tokenization --- doc/classes/Script.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/classes/Script.xml b/doc/classes/Script.xml index fa8e4ef5f27..45f0bbb8aac 100644 --- a/doc/classes/Script.xml +++ b/doc/classes/Script.xml @@ -93,6 +93,7 @@ Returns [code]true[/code] if the script contains non-empty source code. + [b]Note:[/b] If a script does not have source code, this does not mean that it is invalid or unusable. For example, a [GDScript] that was exported with binary tokenization has no source code, but still behaves as expected and could be instantiated. This can be checked with [method can_instantiate].