Pārlūkot izejas kodu

introduce the runway

Sven Czarnian 3 gadi atpakaļ
vecāks
revīzija
e5a773cdcb
1 mainītis faili ar 12 papildinājumiem un 0 dzēšanām
  1. 12 0
      aman/types/Runway.py

+ 12 - 0
aman/types/Runway.py

@@ -0,0 +1,12 @@
+#!/usr/bin/env python
+
+from aman.types.Waypoint import Waypoint
+
+class Runway:
+    def __init__(self, start : Waypoint, end : Waypoint):
+        self.name = start.name
+        self.start = start
+        self.end = end
+
+    def heading(self):
+        return self.start.bearing(self.end)