Skip to content

Commit

Permalink
clean fixedwing identification
Browse files Browse the repository at this point in the history
  • Loading branch information
AviationSFO committed Jan 27, 2022
1 parent 17b5af9 commit 10ffc05
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions MSFS/DCS_MSFS_CONNECT.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,19 @@ def keepalive(data, ip):
pilotName = fields[2]

if ('UH-1' in aircraftName): aircraftType = 'HELI'
if ('FA-1' in aircraftName): aircraftType = 'FIXEDWING'
elif ('FA-1' in aircraftName): aircraftType = 'FIXEDWING'
# Allows other aircraft than aircraft with F-1 in their name like the F-22, F-35, A-4, F-5, etc
if ('F-1' or 'F1' or 'F-2' or 'F2' or 'F-3' or 'F3' or 'F-4' or 'F-5' or 'A-4' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F-1' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F1' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F-2' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F2' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F-3' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F3' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F-4' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F4' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F-5' in aircraftName): aircraftType = 'FIXEDWING'
elif ('F5' in aircraftName): aircraftType = 'FIXEDWING'
elif ('A-4' in aircraftName): aircraftType = 'FIXEDWING'
print (bcolors.OKBLUE, "\nHello", pilotName, "Aircraft:", aircraftName, "Type:", aircraftType, "! DCS is loading...", bcolors.ENDC)
data = addr = 0
elif stringData == "EXIT_DCS":
Expand Down

0 comments on commit 10ffc05

Please sign in to comment.