Skip to content

Commit

Permalink
revert seconds mode snapping fix
Browse files Browse the repository at this point in the history
so PR godotengine#99013 could be merged properly
  • Loading branch information
UnfavorableEnhancer committed Nov 11, 2024
1 parent 5408bea commit f57d5b6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion editor/animation_track_editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7321,7 +7321,10 @@ void AnimationTrackEditor::_update_snap_unit() {
if (timeline->is_using_fps()) {
snap_unit = 1.0 / step->get_value();
} else {
snap_unit = step->get_value();
double integer;
double fraction = Math::modf(step->get_value(), &integer);
fraction = 1.0 / Math::round(1.0 / fraction);
snap_unit = integer + fraction;
}
}

Expand Down

0 comments on commit f57d5b6

Please sign in to comment.