From a80780bf97d4bbf433100ef515445fdfc43ab018 Mon Sep 17 00:00:00 2001 From: miku-666 <74728189+NessieHax@users.noreply.github.com> Date: Sat, 9 Mar 2024 22:23:53 +0100 Subject: [PATCH] Spherical.cs - Remove GetPosition function --- PCK-Studio/Rendering/Spherical.cs | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/PCK-Studio/Rendering/Spherical.cs b/PCK-Studio/Rendering/Spherical.cs index fc4cb255..5e1498cd 100644 --- a/PCK-Studio/Rendering/Spherical.cs +++ b/PCK-Studio/Rendering/Spherical.cs @@ -43,23 +43,9 @@ namespace PckStudio.Rendering set => vector.Z = value; } - public Vector3 GetPosition() - { - float sineAzimuthal = (float)Math.Sin(MathHelper.DegreesToRadians(Phi)); - float cosineAzimuthal = (float)Math.Cos(MathHelper.DegreesToRadians(Phi)); - float sinePolar = (float)Math.Sin(MathHelper.DegreesToRadians(Theta)); - float cosinePolar = (float)Math.Cos(MathHelper.DegreesToRadians(Theta)); - - Vector3 direction = new Vector3(); - direction.X = cosinePolar * sineAzimuthal; - direction.Y = sineAzimuthal; - direction.Z = sinePolar * cosineAzimuthal; - return direction * Radius; - } - public override string ToString() { - return $"Radius: {Radius}; Theta: {Theta}; Phi: {Phi}; Position: {GetPosition()}"; + return $"Radius: {Radius}; Theta: {Theta}; Phi: {Phi};"; } } }