Skip to content

Commit

Permalink
Merge pull request #100306 from Uumutunal/master
Browse files Browse the repository at this point in the history
Fix 3D editor snap setting values not being displayed correctly
  • Loading branch information
akien-mga committed Dec 12, 2024
2 parents 562dd1a + 63b9138 commit 19e003b
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions editor/plugins/node_3d_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6630,9 +6630,12 @@ void Node3DEditor::_snap_changed() {
}

void Node3DEditor::_snap_update() {
snap_translate->set_text(String::num(snap_translate_value));
snap_rotate->set_text(String::num(snap_rotate_value));
snap_scale->set_text(String::num(snap_scale_value));
double snap = EDITOR_GET("interface/inspector/default_float_step");
int snap_step_decimals = Math::range_step_decimals(snap);

snap_translate->set_text(String::num(snap_translate_value, snap_step_decimals));
snap_rotate->set_text(String::num(snap_rotate_value, snap_step_decimals));
snap_scale->set_text(String::num(snap_scale_value, snap_step_decimals));
}

void Node3DEditor::_xform_dialog_action() {
Expand Down

0 comments on commit 19e003b

Please sign in to comment.