Skip to content

Commit

Permalink
fixed toggelling snap mode while transforming
Browse files Browse the repository at this point in the history
  • Loading branch information
Janglee123 committed Mar 16, 2019
1 parent 86d6a72 commit 05446e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions editor/plugins/spatial_editor_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1021,7 +1021,7 @@ void SpatialEditorViewport::_sinput(const Ref<InputEvent> &p_event) {
}

_edit.mouse_pos = b->get_position();
_edit.snap = false;
_edit.snap = spatial_editor->is_snap_enabled();
_edit.mode = TRANSFORM_NONE;

//gizmo has priority over everything
Expand Down Expand Up @@ -1772,7 +1772,7 @@ void SpatialEditorViewport::_sinput(const Ref<InputEvent> &p_event) {

if (ED_IS_SHORTCUT("spatial_editor/snap", p_event)) {
if (_edit.mode != TRANSFORM_NONE) {
_edit.snap = true;
_edit.snap = !_edit.snap;
}
}
if (ED_IS_SHORTCUT("spatial_editor/bottom_view", p_event)) {
Expand Down

0 comments on commit 05446e8

Please sign in to comment.