summaryrefslogtreecommitdiff
path: root/modules/navigation/navigation_mesh_editor_plugin.cpp
diff options
context:
space:
mode:
authorRémi Verschelde <remi@verschelde.fr>2022-02-14 21:10:38 +0100
committerGitHub <noreply@github.com>2022-02-14 21:10:38 +0100
commitd02db6306ebcb57296dece3e8d990ae188b39aad (patch)
tree880627af652df9f6061bbc8537c894c25ea57bd1 /modules/navigation/navigation_mesh_editor_plugin.cpp
parent620813283436386096c2e4e66dbe46a73e347571 (diff)
parentcd1d7294d8d150788c8d9a19ca56038b864360a0 (diff)
Merge pull request #58105 from trollodel/nuke_p_editor_editor_plugin
Diffstat (limited to 'modules/navigation/navigation_mesh_editor_plugin.cpp')
-rw-r--r--modules/navigation/navigation_mesh_editor_plugin.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/modules/navigation/navigation_mesh_editor_plugin.cpp b/modules/navigation/navigation_mesh_editor_plugin.cpp
index af02bff4ca..04eca5fb0b 100644
--- a/modules/navigation/navigation_mesh_editor_plugin.cpp
+++ b/modules/navigation/navigation_mesh_editor_plugin.cpp
@@ -140,10 +140,9 @@ void NavigationMeshEditorPlugin::make_visible(bool p_visible) {
}
}
-NavigationMeshEditorPlugin::NavigationMeshEditorPlugin(EditorNode *p_node) {
- editor = p_node;
+NavigationMeshEditorPlugin::NavigationMeshEditorPlugin() {
navigation_mesh_editor = memnew(NavigationMeshEditor);
- editor->get_main_control()->add_child(navigation_mesh_editor);
+ EditorNode::get_singleton()->get_main_control()->add_child(navigation_mesh_editor);
add_control_to_container(CONTAINER_SPATIAL_EDITOR_MENU, navigation_mesh_editor->bake_hbox);
navigation_mesh_editor->hide();
navigation_mesh_editor->bake_hbox->hide();