From 85766ddeb37a5d5bdf4af3437e5f0bc36898175b Mon Sep 17 00:00:00 2001 From: lufimio <67525443+PA055@users.noreply.github.com> Date: Fri, 31 May 2024 20:31:50 -0400 Subject: [PATCH] fixed compass operator bugs --- include/units/Angle.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/units/Angle.hpp b/include/units/Angle.hpp index 8d0fab6..e0d689e 100644 --- a/include/units/Angle.hpp +++ b/include/units/Angle.hpp @@ -31,13 +31,13 @@ constexpr Angle operator""_stRad(long double value) { return Angle(static_cast(value)); } -constexpr Angle operator""_cDeg(long double value) { return static_cast(value) * deg; } +constexpr Angle operator""_cDeg(long double value) { return 90_stDeg - static_cast(value) * deg; } -constexpr Angle operator""_cDeg(unsigned long long value) { return static_cast(value) * deg; } +constexpr Angle operator""_cDeg(unsigned long long value) { return 90_stDeg - static_cast(value) * deg; } -constexpr Angle operator""_cRad(long double value) { return Angle(static_cast(value)); } +constexpr Angle operator""_cRad(long double value) { return 90_stDeg - Angle(static_cast(value)); } -constexpr Angle operator""_cRad(unsigned long long value) { return Angle(static_cast(value)); } +constexpr Angle operator""_cRad(unsigned long long value) { return 90_stDeg - Angle(static_cast(value)); } // Angle functions namespace units {