From: CMDR furrycat Date: Fri, 9 Nov 2018 08:35:02 +0000 (+0000) Subject: Bearings were inverted. X-Git-Url: http://git.furryclan.net/?a=commitdiff_plain;h=931e1f386b5f40f4aad98b1e261a3a64bcac541a;p=furrycat%2Fcatbot.git Bearings were inverted. --- diff --git a/plugin/heading/heading.py b/plugin/heading/heading.py index d4fac92..ecbaddb 100644 --- a/plugin/heading/heading.py +++ b/plugin/heading/heading.py @@ -117,4 +117,4 @@ class Heading(object): x = (math.cos(slat) * math.sin(elat)) - (math.sin(slat) * math.cos(elat) * math.cos(elong - slong)); y = math.sin(elong - slong) * math.cos(elat) - return int(math.degrees(math.atan2(x, y)) % 360) + return int(math.degrees(math.atan2(y, x)) % 360)