Skip to content

Commit

Permalink
No commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
ProfHoekstra committed Jan 10, 2019
1 parent 33c3c2f commit 47bc5a6
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 13 deletions.
26 changes: 13 additions & 13 deletions plugins/trafgenclasses.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ def update(self,gain):
stack.stack(acid+" ALT FL100")
# TBD: Add waypoint for after take-off?

if self.name[:4] != "SEGM":
if self.dest[idest][:4] != "SEGM":
stack.stack(acid + " DEST " + self.dest[idest])
else:
stack.stack(acid + " DEST " + str(self.destlat[idest])
Expand Down Expand Up @@ -337,7 +337,7 @@ def __init__(self,name,cmd,cmdargs):
self.segdir = None # Segment direction in degrees

# Is location a circle segment?
if swcircle and self.name[:4]=="SEGM":
if self.name[:4]=="SEGM":
self.type = "seg"
self.lat,self.lon,brg = getseg(self.name) # For SEGMnnn to SEGMnnn for crossing flights optional
pass
Expand Down Expand Up @@ -550,7 +550,7 @@ def update(self,gain):
else:
stack.stack(acid + " ORIG " + str(self.origlat[iorig]) + " " +\
str(self.origlat[iorig]))
if not self.name[:4]=="SEGM":
if not (self.name[:4]=="SEGM"):
stack.stack(acid + " DEST " + self.name)
else:
stack.stack(acid + " ADDWPT " + str(self.lat) + " " + str(self.lon))
Expand All @@ -573,20 +573,20 @@ def randacname(orig,dest):
company = chr(ord("A") + int(random.random()*26))+ \
chr(ord("A") + int(random.random()*26))

if orig=="EHKD"

# Make flight number or Dutch call sign for VFR traffic
if not (company=="PH"):
fltnr = str(int(random.random()*900+100))
else:
fltnr = "-" + chr(ord("A") + int(random.random()*26))+ \
firstx = True
while firstx or (acname in traf.id):
if not (company=="PH"):
fltnr = str(int(random.random()*900+100))
else:
fltnr = "-" + chr(ord("A") + int(random.random()*26))+ \
chr(ord("A") + int(random.random() * 26)) + \
chr(ord("A") + int(random.random() * 26))

acname = company+fltnr
i = 0
while (acname in traf.id):
fltnr = fltnr+str(i)
i = i + 1
acname = company+ fltnr
acname = company+fltnr
firstx = False

return company+fltnr

Expand Down
2 changes: 2 additions & 0 deletions run-client-on-windows.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
python.exe Bluesky.py --client
pause
2 changes: 2 additions & 0 deletions run-headless-on-windows.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
python.exe Bluesky.py --headless
pause
2 changes: 2 additions & 0 deletions scenario/trafgen-slr.scn
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
00:00:00.00>plugin load trafgen
00:00:00.00>CALL EHAM/FIR-NL-EHAA
00:00:00.00>TAXI OFF 1800
00:00:00.00>DTLOOK 20


# Add more oil rigs
00:00:00.00>DEFWPT EHFE, N54'59'07",E004'54'00"
Expand Down

0 comments on commit 47bc5a6

Please sign in to comment.