-Split EditorPlugin into EditorPlugin and EditorInterface
-Added EditorInterface to EditorScript -Added functions to save the scene to EditorInterface
This commit is contained in:
parent
f634973acb
commit
dd7145b778
7 changed files with 186 additions and 125 deletions
|
|
@ -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"));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue