From 8c1d94ebae2eb5f8563c40754ce1ceed04f05978 Mon Sep 17 00:00:00 2001 From: Aaron Franke Date: Wed, 9 Dec 2020 06:30:23 -0500 Subject: [PATCH] Fix trying to set grid visibility on an invalid instance --- editor/plugins/node_3d_editor_plugin.cpp | 4 ---- 1 file changed, 4 deletions(-) diff --git a/editor/plugins/node_3d_editor_plugin.cpp b/editor/plugins/node_3d_editor_plugin.cpp index f52f8c1d010..8f2fc968e3b 100644 --- a/editor/plugins/node_3d_editor_plugin.cpp +++ b/editor/plugins/node_3d_editor_plugin.cpp @@ -4999,9 +4999,6 @@ void Node3DEditor::_menu_item_pressed(int p_option) { for (int i = 0; i < 3; ++i) { if (grid_enable[i]) { grid_visible[i] = grid_enabled; - if (grid_instance[i].is_valid()) { - RenderingServer::get_singleton()->instance_set_visible(grid_instance[i], grid_enabled); - } } } _finish_grid(); @@ -6160,7 +6157,6 @@ void Node3DEditor::clear() { view_menu->get_popup()->set_item_checked(view_menu->get_popup()->get_item_index(MENU_VIEW_ORIGIN), true); for (int i = 0; i < 3; ++i) { if (grid_enable[i]) { - RenderingServer::get_singleton()->instance_set_visible(grid_instance[i], true); grid_visible[i] = true; } }