From f044c7c1d16fdb65554a896fb3c5a720c9b9e4c1 Mon Sep 17 00:00:00 2001 From: Raul Santos Date: Fri, 28 Mar 2025 00:46:34 +0100 Subject: [PATCH] Fix C# example about interpolating with quaternions The `GetQuaternion` method was unexposed in 4.0. The example now uses the `Quaternion(Basis)` constructor which matches the GDScript example. --- tutorials/3d/using_transforms.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tutorials/3d/using_transforms.rst b/tutorials/3d/using_transforms.rst index 1041109ae3e..821e04a5668 100644 --- a/tutorials/3d/using_transforms.rst +++ b/tutorials/3d/using_transforms.rst @@ -383,8 +383,8 @@ Converting a rotation to quaternion is straightforward. .. code-tab:: csharp // Convert basis to quaternion, keep in mind scale is lost - var a = transform.Basis.GetQuaternion(); - var b = transform2.Basis.GetQuaternion(); + var a = new Quaternion(transform.Basis); + var b = new Quaternion(transform2.Basis); // Interpolate using spherical-linear interpolation (SLERP). var c = a.Slerp(b, 0.5f); // find halfway point between a and b // Apply back