diff options
Diffstat (limited to 'editor/editor_run_script.cpp')
-rw-r--r-- | editor/editor_run_script.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/editor/editor_run_script.cpp b/editor/editor_run_script.cpp index 8bd1b8f4fd..87eba78a3e 100644 --- a/editor/editor_run_script.cpp +++ b/editor/editor_run_script.cpp @@ -3,7 +3,7 @@ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ -/* http://www.godotengine.org */ +/* https://godotengine.org */ /*************************************************************************/ /* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ /* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ @@ -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")); } |