summaryrefslogtreecommitdiff
path: root/editor/editor_run_script.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_run_script.cpp')
-rw-r--r--editor/editor_run_script.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/editor/editor_run_script.cpp b/editor/editor_run_script.cpp
index 8bd1b8f4fd..990c0cfbe9 100644
--- a/editor/editor_run_script.cpp
+++ b/editor/editor_run_script.cpp
@@ -46,6 +46,11 @@ void EditorScript::add_root_node(Node *p_node) {
//editor->set_edited_scene(p_node);
}
+EditorInterface *EditorScript::get_editor_interface() {
+
+ return EditorInterface::get_singleton();
+}
+
Node *EditorScript::get_scene() {
if (!editor) {
@@ -83,6 +88,7 @@ void EditorScript::_bind_methods() {
ClassDB::bind_method(D_METHOD("add_root_node", "node"), &EditorScript::add_root_node);
ClassDB::bind_method(D_METHOD("get_scene"), &EditorScript::get_scene);
+ ClassDB::bind_method(D_METHOD("get_editor_interface"), &EditorScript::get_editor_interface);
BIND_VMETHOD(MethodInfo("_run"));
}