Skip to content

armgit / godot

Public Imported from GitHub
0

Godot Engine – Multi-platform 2D and 3D game engine

Merge pull request #117569 from YeldhamDev/gridmap_viewport_axis

Thaddeus Crewsbc3436936765
diff --cc modules/gridmap/editor/grid_map_editor_plugin.cpp
index 94d2f8f5744,4ed7a798b2f..0e79bac2381
--- a/modules/gridmap/editor/grid_map_editor_plugin.cpp
+++ b/modules/gridmap/editor/grid_map_editor_plugin.cpp
@@@ -1384,11 -1438,9 +1447,12 @@@ void GridMapEditor::edit(GridMap *p_gri
return;
}
+ // Prevent the cursor from being at an incorrect position before any inputs happen.
+ cursor_origin = (Vector3(cursor_gridpos) + Vector3(0.5 * node->get_center_x(), 0.5 * node->get_center_y(), 0.5 * node->get_center_z())) * node->get_cell_size();
+
update_palette();
_update_cursor_instance();
+ _update_edit_axis();
set_process(true);