Set up bullseye early, create waypoints.

Setting this up as part of the game makes it possible for us to show in
the UI.

https://github.com/dcs-liberation/dcs_liberation/issues/136
This commit is contained in:
Dan Albert
2021-05-20 18:18:13 -07:00
parent 3c8c76f50d
commit a382e74a89
12 changed files with 104 additions and 22 deletions

View File

@@ -375,6 +375,7 @@ class WaypointJs(QObject):
timingChanged = Signal()
isTakeoffChanged = Signal()
isDivertChanged = Signal()
isBullseyeChanged = Signal()
def __init__(
self,
@@ -439,6 +440,10 @@ class WaypointJs(QObject):
def isDivert(self) -> bool:
return self.waypoint.waypoint_type is FlightWaypointType.DIVERT
@Property(bool, notify=isBullseyeChanged)
def isBullseye(self) -> bool:
return self.waypoint.waypoint_type is FlightWaypointType.BULLSEYE
@Slot(list, result=str)
def setPosition(self, position: LeafletLatLon) -> str:
point = self.theater.ll_to_point(LatLon(*position))