From e218a13a64d417505ba8ca0abb79dddfb943f2c7 Mon Sep 17 00:00:00 2001 From: Ignacio Etcheverry Date: Tue, 24 Oct 2017 01:54:47 +0200 Subject: Add ScriptLanguage::supports_builtin_mode and improve ScriptCreateDialog - Make ScriptCreateDialog disable the built-in script checked button if the language does not support it. - ScriptLanguage's get_template and make_template now receive the script path as class name if the the script language does not have named classes. --- core/script_language.h | 1 + 1 file changed, 1 insertion(+) (limited to 'core/script_language.h') diff --git a/core/script_language.h b/core/script_language.h index 25767a2f7a..c243ef781b 100644 --- a/core/script_language.h +++ b/core/script_language.h @@ -202,6 +202,7 @@ public: virtual bool validate(const String &p_script, int &r_line_error, int &r_col_error, String &r_test_error, const String &p_path = "", List *r_functions = NULL) const = 0; virtual Script *create_script() const = 0; virtual bool has_named_classes() const = 0; + virtual bool supports_builtin_mode() const = 0; virtual bool can_inherit_from_file() { return false; } virtual int find_function(const String &p_function, const String &p_code) const = 0; virtual String make_function(const String &p_class, const String &p_name, const PoolStringArray &p_args) const = 0; -- cgit v1.2.3