From ea94b17a2165e80b1001aadeb28e2ae5cc255dcb Mon Sep 17 00:00:00 2001 From: luboslenco Date: Thu, 18 Sep 2025 12:18:20 +0200 Subject: [PATCH] Fix gizmo rotate direction --- paint/sources/gizmo.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/paint/sources/gizmo.ts b/paint/sources/gizmo.ts index 361fecf0..b4f74b95 100644 --- a/paint/sources/gizmo.ts +++ b/paint/sources/gizmo.ts @@ -64,11 +64,11 @@ function gizmo_update() { paint_object.transform.scale.z += context_raw.gizmo_drag - context_raw.gizmo_drag_last; } else if (context_raw.rotate_x) { - gizmo_q0 = quat_from_axis_angle(vec4_x_axis(), context_raw.gizmo_drag - context_raw.gizmo_drag_last); + gizmo_q0 = quat_from_axis_angle(vec4_x_axis(), -(context_raw.gizmo_drag - context_raw.gizmo_drag_last)); paint_object.transform.rot = quat_mult(paint_object.transform.rot, gizmo_q0); } else if (context_raw.rotate_y) { - gizmo_q0 = quat_from_axis_angle(vec4_y_axis(), context_raw.gizmo_drag - context_raw.gizmo_drag_last); + gizmo_q0 = quat_from_axis_angle(vec4_y_axis(), -(context_raw.gizmo_drag - context_raw.gizmo_drag_last)); paint_object.transform.rot = quat_mult(paint_object.transform.rot, gizmo_q0); } else if (context_raw.rotate_z) {