summaryrefslogtreecommitdiff
path: root/core/object.h
diff options
context:
space:
mode:
authorIgnacio Etcheverry <ignalfonsore@gmail.com>2019-02-04 20:39:02 +0100
committerIgnacio Etcheverry <ignalfonsore@gmail.com>2019-02-09 00:32:18 +0100
commit9df44c2d2cbae10aa7b27b2562d00d69c2caecb8 (patch)
treea27782b053e2603dedf350fdd7fd49e39b76c530 /core/object.h
parent16d402147b9057c9f7d43ef9b46eb8654e5483cc (diff)
Use script instance binding for objects constructed from C#
Only possible if the object class is a "native type". If the object class is a user class (that derives a "native type") then a script is needed. Since CSharpLanguage does cleanup of script instance bindings when finished, cases like #25621 will no longer cause problems. Fixed ~Object() trying to free script instance bindings after the language has already been removed, which would result in a NULL dereference.
Diffstat (limited to 'core/object.h')
-rw-r--r--core/object.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/object.h b/core/object.h
index 5bfef8a439..9a5217e3de 100644
--- a/core/object.h
+++ b/core/object.h
@@ -730,6 +730,7 @@ public:
//used by script languages to store binding data
void *get_script_instance_binding(int p_script_language_index);
bool has_script_instance_binding(int p_script_language_index);
+ void set_script_instance_binding(int p_script_language_index, void *p_data);
void clear_internal_resource_paths();