rominet wrote in Tue May 24, 2016 10:12 am:Your bad install probably comes from 'sudo pip install ffgo' (don't do that at home, kids!!)
PINTO wrote in Tue May 24, 2016 10:26 pm:
{ name_of_your_choice = "" }
# Put your "normal", all-situations, fgfs options here
--prop:string:/sim/terrasync/http-server=automatic # for new TerraSync (FG 2016.2.1 and later)
--download-dir=/some/path/of/your/choice
--enable-fullscreen
[ name_of_your_choice == "MP-carrier-LXGB" ]
--prop:/ai/models/carrier/position/latitude-deg=36.01811
--prop:/ai/models/carrier/position/longitude-deg=-5.32529
--prop:/ai/models/carrier/position/altitude-ft=0
--prop:/ai/models/carrier/orientation/true-heading-deg=230
#--prop:/ai/models/carrier/navaids/tacan/channel-ID=029Y
--prop:/ai/models/carrier/velocities/speed-kts=0
name_of_your_choice == "MP-carrier-LXGB"
--prop:string:/sim/terrasync/http-server=automatic
--download-dir=/some/path/of/your/choice
--enable-fullscreen
{ name_of_your_choice = "MP-carrier-LXGB" }
[ name_of_your_choice == "MP-carrier-Seine" ]
--prop:/ai/models/carrier/position/latitude-deg=48.86338
--prop:/ai/models/carrier/position/longitude-deg=2.30667
--prop:/ai/models/carrier/position/altitude-ft=20
--prop:/ai/models/carrier/orientation/true-heading-deg=260
--prop:/ai/models/carrier/velocities/speed-kts=0
[ name_of_your_choice == "MP-carrier-EDNY" ]
--prop:/ai/models/carrier/position/latitude-deg=47.57024
--prop:/ai/models/carrier/position/longitude-deg=9.47860
# Unfortunately, I believe the glide slope assumes the carrier is at sea level
--prop:/ai/models/carrier/position/altitude-ft=1279.11
--prop:/ai/models/carrier/orientation/true-heading-deg=230
--prop:/ai/models/carrier/velocities/speed-kts=0
MERGED_OPTIONS = ["--airport=", "--aircraft=", "--parking-id=",
"--runway=", "--carrier=", "--parkpos=",
"--com1=", "--com2="]
def airportListTooltipFunc(region, itemID, column, self=self):
if region == "cell":
icao = self.airportList.set(itemID, "icao")
found, airport = self.readAirportData(icao)
return airport.tooltipText() if found else None
def readAirportData(self, icao):
"""Read airport data from self.config.aptDatCache or apt.dat.
Return a tuple of the form (found, airport) where 'found' is a
boolean and airport an Airport instance, or None when 'found' is
False.
"""
for cachedIcao, cachedAirport in self.config.aptDatCache:
if cachedIcao == icao:
found = True
airport = cachedAirport
break
with AptDat(aptPath) as aptDat:
found, airport = aptDat.readAirportDataUsingIndex(icao, index)
def readAirportDataUsingIndex(self, icao, index):
"""Read detailed airport data from apt.dat using an index.
'index' should be a sequence (byteOffset, lineNb) where
'byteOffset' points to the start of the first line defining the
airport in apt.dat, and 'lineNb' is the corresponding line
number (starting from 1).
Return a tuple of the form (found, data) where:
- 'found' is a boolean indicating whether airport data for
the specified 'icao' was found at 'index';
- 'data' is an Airport instance if the data was found,
otherwise None.
"""
[...]
self.lineNb = index[1]
code, payload = self._readRecord()
# 1, 16, 17: land airport, seaplane base or heliport
if code not in (1, 16, 17):
return (False, None)
try:
foundIcao, type_, name, elev = self._processAirportHeader(code,
payload)
except UnableToParseAptDat:
return (False, None)
[...]
# Will give the coordinates of the centroid of all runway ends +
# helipads of the airport (each runway has a sort of “double weight”
# because of its two ends, contrary to a helipad).
avgLat, avgLon = None, None
nvecSum = NVector(0.0, 0.0, 0.0)
avgLat, avgLon = map(misc.DecimalCoord,
nvecSum.scalarDiv(n).latLon())
Users browsing this forum: No registered users and 10 guests