summaryrefslogtreecommitdiff
path: root/editor/plugins
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2017-07-03 23:43:33 +0200
committerGitHub <noreply@github.com>2017-07-03 23:43:33 +0200
commite54c7d5715e70c4ef08b6a3f7039c2bdf2473045 (patch)
treef782dfef613af8fa5c211d7069e061e380a1f7c2 /editor/plugins
parent2036273f944084ccbe2483619d4f4b3de48a322c (diff)
parent44ecfb028d21975944b47b6496712a29f17f3848 (diff)
Merge pull request #9457 from TwistedTwigleg/Fixed_Vector3_snap
Fixed syntax inconsistency in Vector3.snap and Vector3.snapped
Diffstat (limited to 'editor/plugins')
-rw-r--r--editor/plugins/path_editor_plugin.cpp2
-rw-r--r--editor/plugins/spatial_editor_plugin.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/editor/plugins/path_editor_plugin.cpp b/editor/plugins/path_editor_plugin.cpp
index 877707d77b..3524c34d62 100644
--- a/editor/plugins/path_editor_plugin.cpp
+++ b/editor/plugins/path_editor_plugin.cpp
@@ -104,7 +104,7 @@ void PathSpatialGizmo::set_handle(int p_idx, Camera *p_camera, const Point2 &p_p
if (SpatialEditor::get_singleton()->is_snap_enabled()) {
float snap = SpatialEditor::get_singleton()->get_translate_snap();
- inters.snap(snap);
+ inters.snap(Vector3(snap, snap, snap));
}
Vector3 local = gi.xform(inters);
diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp
index c55bef1b03..995d13f6a8 100644
--- a/editor/plugins/spatial_editor_plugin.cpp
+++ b/editor/plugins/spatial_editor_plugin.cpp
@@ -1180,7 +1180,7 @@ void SpatialEditorViewport::_sinput(const Ref<InputEvent> &p_event) {
if (_edit.snap || spatial_editor->is_snap_enabled()) {
snap = spatial_editor->get_translate_snap();
- motion.snap(snap);
+ motion.snap(Vector3(snap, snap, snap));
}
//set_message("Translating: "+motion);