Flight Simulator

Date: 1983
Type: Cassette
Platform(s): TS 1000

This program is a flight simulator that models takeoff, navigation, and landing approaches for a fictional airport with six named waypoints (IW, IE, ONW, ONE, OSE, OSW). It uses machine code routines called via USR at addresses such as 17160, 17163, 17166, 17169, 18303, 18360, 19230, and 19369 to handle the real-time instrument display, graphics updates, and flight physics calculations that would be too slow in pure BASIC. The instrument panel, rendered with PRINT statements using block graphics characters, shows heading, altitude in feet, airspeed in knots, flap setting, landing gear state, and other parameters stored in a 44-element array C(). Wind effects, stall detection, ILS approach mode, and a navigation chart screen are all implemented, with crash reports providing specific failure reasons such as flap overspeed, gear-up landings, and stalls.


Program Analysis

Program Structure

The program is organized into distinct functional blocks separated by line number ranges:

Line RangeFunction
1–2REM blocks containing embedded machine code data
10–20Array and string initialization
55–106Flight parameter constants loaded into C()
200–999Startup, initial position setup, POKE of timer value
1500–2490Main flight loop dispatcher
3000–3295Crash and stall handling routines
4000–4900Game setup menus (final approach vs. full feature, wind)
5010–5496Crash report display and scroll routines
5515–5900Navigation map display and waypoint logic
6050–6900Landing quality assessment
7020–7920ILS (instrument landing system) approach mode
8000–8390Instrument panel display and navigation chart
9010–9090Waypoint data initialization
9990–9999SAVE and RUN

Machine Code Usage

The simulator relies heavily on machine code routines invoked through USR calls. These handle the computationally intensive tasks of rendering the instrument panel, updating graphics, and running the flight physics model at a speed BASIC alone could not sustain. The machine code is stored in the two REM lines at lines 1 and 2, a standard technique for embedding binary data in BASIC programs.

USR AddressApparent Purpose
17160Graphics plot/timing call in main loop
17163Navigation map graphics update
17166Main flight physics/display update
17169Crash/spin physics update
18303Instrument panel render (called from multiple screens)
18360Alternative stall/spin physics
19230ILS approach display update
19369Screen clear/reset helper

The return value of each USR call is discarded via assignment to T, a common idiom when the machine code routine is called purely for its side effects.

The C() Parameter Array

A 44-element numeric array C() serves as the shared memory interface between BASIC and the machine code routines. Key slots include:

  • C(1) – heading in degrees
  • C(2) – airspeed in knots
  • C(3) – altitude in feet
  • C(4), C(5) – flap state and setting
  • C(7) – used in stall condition check (C(2)+2*C(7)<90)
  • C(10), C(11) – screen plot coordinates
  • C(12) – throttle/engine setting
  • C(16)C(18) – lift and wind velocity components
  • C(19), C(20) – aircraft position relative to waypoint
  • C(21) – landing gear state (0=up, 1=down)
  • C(29) – keypress/mode flag from machine code
  • C(30) – landing roughness measure
  • C(31)C(38) – various physics and display constants
  • C(40), C(41) – additional simulation parameters

Waypoint System

Six named waypoints are defined in the 9000 subroutine using parallel arrays N$(6,3), X(6), and Y(6). The variable BN indexes the current beacon. Waypoint offsets are measured in nautical miles from the airport center.

IndexNameX (nm)Y (nm)
1IW-2.750
2IE3.250
3ONW-9.755
4ONE11.254
5OSE2.25-7
6OSW-12.75-8

Flight Modes

At startup the player chooses between two modes via the menu at line 4000. “Final Approach” places the aircraft 2 nm out on a fixed heading at 800 feet and 90 knots. “Full Feature” randomizes starting position, heading, altitude (3000–5000 ft), and beacon. A separate wind setup routine at line 4500 optionally introduces a randomized wind speed (2–19 knots) and direction, stored as velocity components in C(17) and C(18).

ILS Approach Mode

Lines 70207920 implement an ILS (Instrument Landing System) mode. On entry, physics constants are rescaled (e.g., C(25) is multiplied by 3830, distances converted to feet by multiplying by 6080), and a specialized display is activated via USR 19230. On exit the constants are restored by dividing by the same factors. The ILS mode checks for gear-down status, runway alignment (ABS C(19)<4096, ABS C(20)<64), and minimum throttle conditions before allowing a touchdown.

Crash Detection and Reporting

Several distinct crash conditions are checked both in the main loop and the navigation map loop:

  • Altitude below zero → “GROUND” or “HILLS” depending on position
  • Too close to hills with insufficient altitude (C(19)+X(BN)>7.5 AND C(3)<1500)
  • Airspeed stall condition (C(2)+2*C(7)<90)
  • Flap overspeed (C(7)*C(2)>1200) → “YOUR FLAPS WERE RIPPED OFF”
  • Gear-up landing → “YOU ‘LANDED’ WITH YOUR GEAR UP”
  • Landing gear torn away if gear lowered above 170 knots

The crash report routine at line 5010 uses repeated SCROLL calls and a variable number of blank scroll lines controlled by IS to format the output neatly regardless of screen state. Fuel exhaustion is detected by PEEK 16519 checking the high byte of the fuel timer against 99.

Instrument Panel Display

The instrument panel at line 8000 is built by assigning block-graphic-heavy strings to L$ and M$ before calling the machine code renderer at USR 18303. This pattern — prepare label strings in BASIC, then call machine code to composite them onto the display — is used for the main instrument panel, the ILS display, and the navigation chart, allowing different screen layouts to share a single rendering engine.

Navigation Chart

A navigation chart is displayed when C(29)=4 (line 2440 dispatches to line 8100). The chart is rendered entirely with PRINT statements using block graphics, showing compass rose markings at 000, 090, 180, and 270 degrees, along with scale and the waypoint labels IW, IE, ONW, ONE, OSE, OSW. The current aircraft position relative to the active beacon is plotted using PLOT/UNPLOT pairs.

Timer via POKE

Lines 352353 store a 16-bit value T across two memory locations 16518 and 16519 using the standard split T-256*INT(T/256) for the low byte and INT(T/256) for the high byte. This is how the fuel quantity or an elapsed-time counter is passed to the machine code, since the machine code cannot directly read BASIC variables.

Landing Quality Grading

After a successful touchdown, lines 60506900 grade the landing using C(30) as a sink-rate measure: values of 2 or below earn “SMOOTH TOUCH-DOWN,” 3–5 earn “NOT BAD … A BIT BOUNCY,” and above 5 gives “SEVERELY HEAVY LANDING.” Runway alignment is then checked using C(19) (along-track) and C(20) (cross-track) with thresholds at 20, 50 feet cross-track and 3700, 4096 feet along-track.

Content

Appears On

Related Products

Full controls, instrumentation and a view of the horizon. Use the radio beams and radio compass to navigate. Avoid hazards...

Related Articles

Related Content

Image Gallery

Source Code

   1 REM  ▛ -  0▛# # UNPLOT  #~~ ##[)]#2# LOAD ▖?▖?OTAN ##[)]#2# LOAD ▖?▖?OTAN ▗[£]2#[J] LOAD ▀▖▖OTAN 77#▗ LOAD ▖?OTAN NOT 2[O]R LPRINT #[T]M[Y]▗>= LOAD ▖""▝▖ STEP ▀""▝▖AT ▝▖ LPRINT ??▖ STEP ▘▀OTAN 22[-]NOT  LOAD ▖?OTAN  COPY[.][4]#[4]######## LOAD ▖""▝▖ STEP ▀AT ▝▖""▝▖ STEP ?? LPRINT ▘▌▖?8OTAN CC## LOAD "" STEP ▖▘"" STEP ▖?▘"" STEP ▖▀ STEP  STEP ?▌ STEP ?OTAN WCOS [4]▗ LOAD ??8OTAN  COPY#LN [4]▙# LOAD ▖?8?OTAN #ABS [4]▙# LOAD ▖?8?OTAN  COPY▘4[9]▒ COPY▒4#▘▒(4#▘?((# COPY▘(▒# COPY SAVE 4▝M▘~~4▖M COPY ▝(R▘▒▝▒R COPY ▝4[9]▘ COPY█4[9]▝ COPY█▒[9]▖ COPY COPY ▝▖▛,,"$?>=-/,13579BDFIKMOQSUWYZINKEY$ #####################################################################################################################INKEY$ RNDYWUSQOMKIFDB97531,/-=>?$",,▛▖▝  RETURN UNPLOT  RAND  RUN  PRINT  NEXT  LET  INPUT  GOTO  REM  CONT  NEW STOP LPRINT  TO <><= OR NOT STR$ ABS SQR EXP ATN ASN COS LEN CODE TAB AT [Z][X][V][T][R][P][O][M][K][I][H][F][D][C][A][9][7][6][4][3][1][0][.][;][/][*][+][=][<][>][)][(][?][:][$][£]["][~~][,,][,,][▒]▗▗▚▐▐▜▜▄▄▄▙▙▙▟▟▟▟▟▟▟▟▟▟▟▙▙▙▄▄▄▜▜▐▐▚▗▗[▒][,,][,,][~~]["][£][$][:][?][(][)][>][<][=][+][*][/][;][.][0][1][3][4][6][7][9][A][C][D][F][H][I][K][M][O][P][R][T][V][X][Z]AT TAB CODE LEN COS ASN ATN EXP SQR ABS STR$ NOT  OR <=<> TO  LPRINT  STOP NEW CONT  REM  GOTO  INPUT  LET  NEXT  PRINT  RUN  RAND  UNPLOT  RETURN COPY5▖ ) FAST▘LN ["]#5$ )[F]▝LN ["]#5; ######LN ##5▖ ) FAST▘LN [D]#5$ )[F]▝LN [D]#5; )P▘Y▀LN [T]#52 )#▘Y▀LN [T]#57 )Y▘Y▖LN [T]#5C )#▝Y▀LN [T]#5H )#▝Y▀LN [T]#5M ) GOTO ▘Y▌LN =#5R )[M]▝Y▖LN =#5W )SGN ▘Y▌LN =#5INKEY$  )[*]▝Y▖LN =#▞▒LN ##▞~~LN [,,]#▞▘LN [$]#▞~~LN [,,]#▞▘LN [$]#▞~~#[,,]#LN [V]▝6▙RNDY M▜RND▘  5[9] LN ##5#INKEY$ #7#7 FOR LN [>]# FOR #7#7#74▒ FASTA #LN [1]# LPRINT # RETURN COPY4 LLIST #[>]#5; LN -#LN ##5[>]RNDLN ##5; )# LN [K]###5; ###5H LN -#LN ##5 FOR RNDLN ##5H )[.] LN [K]# FASTLN Q#5#  GOSUB #(RND,,# LPRINT ▘[O] ##[B] IF N# GOSUB PISQR  FOR ,,#Q# GOSUB PI**##5H ###5H LN -#VAL 5; LN -# LPRINT [R] GOSUB PILN [X]#LN ##5OINKEY$ ###LN Y#LN  UNPLOT #LN [8]##)#LN >=##[8]###LN █#VAL 5# LN ▗# LET 5# #▗#5[~~]INKEY$ ,,#5# ,,LN [X]#▘[~~]INKEY$ ,,#TAN  GOSUB #▚RND" GOSUB #▚RND#5INKEY$  [B] PAUSE ▗#▀ GOSUB #▚RNDY 5M #▗#STR$ LN -# LPRINT VAL LN -# LPRINT [R] GOSUB PI▘#▘ACS #C▝,,TAN  FAST[R] GOSUB PIK▝ LPRINT TAN AT TAN #M▙RND7LN  THEN#E▙RND# UNPLOT ## RETURN LOAD C"7 FAST#A LN  PAUSE # LPRINT / LIST 6▜RND DIM LN ,,# GOSUB [K] GOSUB #0RNDTAN LN ,,# FOR [R] GOSUB PI60RND GOSUB [K]TAN  GOSUB #(RND; GOSUB #0RND▘▌ TAN  GOSUB #(RND,,# RETURN[(]▘ COPY#SQR CHR$ █▘  **#7# PRINT  PLOT █#7#5  ACS 7ACS >ACS +ACS =( PLOT ## LET ACS #COS 5  [R] GOSUB PI##TAN STR$ LN -#SGN #TAN  GOSUB #(RND;)  #[L]C.ACS #C▛ FASTLN ## LPRINT -█2[)]ACS 5ACS (1K RAND ACS SACS ;#[M]##LN ▙#▘  7#7#TAN ▞ #ACS #CLEN ▞ COPY/TAB  GOSUB #▙RND#[4]##[5][O]TAN  FASTLN ## LPRINT [U]COS #▟#▗#LN "# GOSUB #(RND,,#▞ 77 GOSUB [K]TAN #▞ STR$ VAL LN -# LPRINT SGN STR$  FASTLN PEEK #AT SGN LN "#5#RND GOSUB [S]TAN ##)(BLN  #M#RND) CONT ▀LN  #M#RND)# LN  #M#RND)~~ LN  #M#RND#LEN 0M#RNDTAN  PLOT  COPY GOSUB #WK CLS;LEN 0TAN  FASTE£RND;## LPRINT TAN  PRINT LN ##E£RND; LET #Y )5 [B]ACS #4.ACS TK▘W£[B]$C▛Q▒ GOSUB #( RUN TAN X4▛Q,, GOSUB #(▘TAN Q  GOSUB #( IF TAN [J]M▄RNDLN SQR #E▜RND▘ COPY YO GOSUB [L]# RETURNTAN ""7# RETURN COPY4 DIM TAN :  GOSUB #▜RND5# LN -#INKEY$ VAL 5# LN -#SGN ACS 6ACS 6#[>]#- E£RND7TAN #LN [2]##▄#ACS JACS J▟#Y▀[6]#7( GOTO TAN STR$ VAL  FAST GOSUB #▜RND)5 [B] IF LEN #ACS JK▘£X IF [W]#Q[▒];( RUN /?$4▛Q[~~];(▝/▌Q█;( CLS LPRINT AT SGN TAN W▘C▘= ▖▒$>.3AHOVZ#####= ▝▘ ▘ ▘ ▘   COPY  COPY▘ ▘ ▘  CLEAR COPY  COPY COPY  COPY  COPY  COPY  COPY  COPY  COPY  COPY  ▘ ▘ COPY  COPY  COPY ▀▘ ▘▘ ▘ ▘ $▞>▞+▞-▞*▞;▞,▞,▞,▞,▞.▞1▞1▞1▞2▞3▞7▛######################## UNPLOT ▛▒I▝WWLN ▄#( CLS TO  4 Z ~~     2▀ SAVE ▀ RETURN COPY▞Y#[)]#5 RAND  )NOT ▝LN [D]#53▘) SAVE ▝#[D]#LN "#LN [S]# GOSUB ###LN ##5# LN -#VAL 5# ▘  LN ##LN "#AT 5# LN ##LN  STOP#▞-LN ##▞4LN [,,]#56#▞2LN ##52 ) SCROLL▝Y▀LN [T]#57 ) LIST ▝Y▖#[T]#Y▘M5RND5# LN B#6[▒]RND5# LN B#6[~~]RND57 LN -#ACS #C;5[E] LN -#▀5[E] LN ##▘  57 LN ##▘  5~~ ,,6[(]RND#[O]#LN -#5  [R] GOSUB PIACS #C▘#Y#[S]SQR [J]M5RNDTAN LN ##[L]###LN ##J[L]J###Y▘ACS TK▘▛ACS SK▝▛▛A # FAST▞▌D( CLEARSGN ;,,# GOSUB #£RND;7#ACS #C▝ INPUT [?]TAN ACS #C▝ INPUT [?]#TAN U5RND[R]COS VAL #7#7YF[S]S~~YZ[T]S▌ FASTLN ## LPRINT AT ( DIM TAN #WC"XC$*Y#K▝WWTAN ▟ SAVE Y▟TAN ▟ LIST Y#TAN 5# LN -##WM##5; LN -#LN █#M[£]RND#M[$]RND5# LN -#5>=#,,#▞ 5V▘,,LN [X]###LN █#M[:]RND#M[?]RND GOSUB #[▒]RNDE[~~]RND GOSUB #[£]RNDLN ##6##E[▒]RND GOSUB #[~~]RND GOSUB #[£]RND# GOSUB ##LN ## FAST GOSUB #[(]RND GOSUB #[:]RND## GOSUB ##LN ##6## LPRINT  GOSUB #[(]RND GOSUB #[:]RND# GOSUB ##LN ##6##U[£]RND GOSUB ##U[:]RNDLN ##6##U[$]RND GOSUB ##U[?]RNDLN ##6##U[£]RND#U[?]RNDLN ##6##U[$]RND#U[:]RNDLN ##6##U[£]RND#LN ▙#6##U[$]RND#LN ##6##Y2M▙RND) NEW#56# FAST,<STR$ [R]CC#E## GOSUB ###LN ##6##E## GOSUB ###LN ##6##E## GOSUB ###LN ##6##SGN ,<STR$ [R]CC#E## GOSUB ###LN ##6##E## GOSUB ###LN ##6##E## GOSUB ###LN ##6##E##ACS #C▛Y#M▄RND/Q▞▛[J][O]C"▌ACS ZC▖ACS 1/ RUN ACS 1#VAL  GOSUB ###LN [$]##LN  SLOW##U##█M▄RNDAT  GOSUB ###LN [$]##LN  SLOW# GOSUB #LEN 3SGN  LPRINT #7U▄RND#7U▙RNDXM▙RNDTAB [(]#TAN  FASTVAL #LN [2]# LET SGN  FASTLN [2]#SGN ;TAN LN ## FOR #[2]#LN ▙# FOR #[2]##[B] IF ###;( CLEARTAN  GOSUB ##[R] GOSUB #( CLSTAN A ACS #C▘9ACS GACS 1TAN A ACS #C▘9DDDTAN #[R]COS  FOR  GOSUB # REM [,]#( RAND  FOR TAN ) COPY#TAN [B] PAUSE [F]#5  [R] GOSUB # FOR  GOSUB ###- #ACS #C▘+#ACS 5ACS <ACS >#*##*ACS +ACS =▟# GOSUB # FOR 5  #▞▛3K▒;ACS 5K▌7/▝ACS 5ACS <ACS >( GOSUB TAN [B]COPI: ACS (K,,5  [R] GOSUB #$/▘ FOR #D#[U]K12 ACS UACS .▞▛[R] GOSUB #K▞;D( RUN /▖DG( LET #£"" GOSUB #TAN Y#TAN LN ##E[▒]RND GOSUB #[~~]RNDACS #C?##5  [R] GOSUB # FOR 5  [R] GOSUB PI▘[4]?[R] GOSUB PI**▞▀ACS WACS 1( IF # RETURN▒SQR U["]RNDACS #C▝ GOSUB # RETURN▖SQR U[)]RND RETURN▖SQR  FOR ▞▌D( CLEARY,,STR$ LN [.]#SGN M##STR$ Y<LN  SLOW#A #▞▀D( CLEAR GOSUB #[(]RND[R] GOSUB #SGN ▞▌D( CLEARYHLN [.]#M###U####Y#ACS #4▞[R] GOSUB #**XTAN ;**WTAN 5 RETURN3#F NEW### NEWZ RETURNJS▝CHR$ 4█#ACS ; FASTS▌LN Y#/▀LN ## LPRINT #[R]4 THENTAN LN 000000000000000000000000000000000
   2 REM 
  10 DIM B$(3)
  11 DIM G$(4)
  12 DIM C(44)
  13 DIM L$(32)
  14 DIM M$(32)
  15 LET Y$=""
  16 LET Z$=""
  20 GOSUB 9000
  25 GOSUB 4000
  55 LET C(16)=5
  60 LET C(31)=12
  61 LET C(32)=16
  62 LET C(33)=2
  63 LET C(34)=515
  64 LET C(35)=180/PI
  65 LET C(36)=5
  66 LET C(37)=20
  67 LET C(38)=12
  68 LET C(40)=200
  69 LET C(41)=1
  73 LET C(22)=9/127
  75 LET C(24)=.005
  76 LET C(25)=.6/(127*3600)
  77 LET C(26)=.001
  79 LET C(28)=.5
 102 LET C(12)=12
 103 LET C(6)=5
 105 LET C(2)=150
 106 LET C(5)=45
 200 GOSUB 4500
 304 LET C(19)=R*SIN A
 306 LET C(20)=R*COS A
 352 POKE 16518,T-256*INT (T/256)
 353 POKE 16519,INT (T/256)
 380 LET C(21)=0
 381 LET G$="█UP█"
 999 SLOW
 1500 GOTO 8000
 2010 LET T=USR 17166
 2100 IF C(3)<0 THEN GOTO 3000
 2105 IF C(19)+X(BN)>7.5 AND C(3)<1500 THEN GOTO 3020
 2110 IF C(2)+2*C(7)<90 THEN GOTO 3100
 2115 IF C(7)*C(2)>1200 THEN GOTO 3040
 2340 PLOT C(10),C(11)
 2345 LET T=USR 17160
 2346 UNPLOT C(10),C(11)
 2410 IF C(29)=0 THEN GOTO 2000
 2430 IF C(29)=2 THEN GOSUB 5800
 2440 IF C(29)=4 THEN GOTO 8100
 2450 IF C(29)=8 THEN GOTO 7000
 2460 IF C(29)=1 THEN GOTO 5900
 2490 GOTO 2000
 3000 LET X$="GROUND"
 3010 GOTO 5000
 3020 LET X$="HILLS"
 3030 GOTO 5000
 3040 LET X$="GROUND"
 3042 LET Y$="YOU CRASHED BECAUSE"
 3044 LET Z$="YOUR FLAPS WERE RIPPED OFF"
 3049 GOTO 3105
 3100 LET Y$="YOU LET THE PLANE STALL"
 3105 LET D=1
 3110 LET T=USR 17169
 3120 LET C(12)=4*RND
 3130 LET C(13)=C(13)+D
 3132 IF ABS C(13)>8 THEN LET D=-D
 3140 LET C(3)=C(3)-77
 3180 IF C(3)>0 THEN GOTO 3110
 3190 IF C(19)<7.5 THEN GOTO 3000
 3195 GOTO 3020
 3200 LET Y$="YOU LET THE PLANE STALL"
 3205 LET D=1
 3210 LET T=USR 18360
 3220 LET C(12)=4*RND
 3230 LET C(13)=C(13)+D
 3232 IF ABS C(13)>8 THEN LET D=-D
 3240 LET C(3)=C(3)-29
 3280 IF C(3)>0 THEN GOTO 3210
 3290 LET X$="AIRPORT"
 3295 GOTO 5000
 4000 GOSUB 8200
 4010 PRINT "DO YOU WANT"
 4012 PRINT 
 4014 PRINT "JUST THE FINAL APPROACH?"
 4020 GOSUB 4900
 4030 PRINT 
 4032 PRINT 
 4040 IF INKEY$ ="Y" THEN GOTO 4050
 4042 IF INKEY$ ="N" THEN GOTO 4100
 4044 GOTO 4040
 4050 PRINT "FINAL APPROACH"
 4060 LET R=2
 4061 LET A=1.5*PI
 4065 LET BN=1
 4066 GOSUB 5825
 4070 LET C(3)=800
 4075 LET C(1)=90
 4080 LET T=2200
 4090 RETURN
 4100 PRINT "FULL FEATURE"
 4110 LET R=10+RND*5
 4112 LET A=RND*2*PI
 4120 LET BN=INT (1+RND*6)
 4122 GOSUB 5800
 4130 LET C(1)=INT (RND*360)
 4150 LET T=2000+INT (RND*999)
 4160 LET C(3)=3000+INT (RND*2000)
 4490 RETURN
 4510 CLS
 4520 PRINT "DO YOU WANT TO"
 4522 PRINT 
 4530 PRINT "INCLUDE WIND EFFECTS?"
 4535 GOSUB 4900
 4540 IF INKEY$ ="Y" THEN GOTO 4600
 4542 IF INKEY$ ="N" THEN GOTO 4550
 4544 GOTO 4540
 4550 PRINT AT 16,0;"NO WIND EFFECTS"
 4560 RETURN
 4600 RAND 
 4602 LET VW=INT (RND*RND*18)+2
 4610 PRINT AT 14,0;"WIND SPEED: ";VW;" KNOTS"
 4620 LET AW=INT (RND*360)
 4624 PRINT 
 4625 PRINT "FROM ";AW;" DEGREES"
 4630 LET AW=AW*PI/180
 4632 LET VW=-127*VW
 4635 PRINT AT 21,0;"PRESS ANY KEY EXCEPT BREAK"
 4640 IF INKEY$ ="" THEN GOTO 4640
 4690 LET C(17)=VW*SIN AW
 4692 LET C(18)=VW*COS AW
 4696 RETURN
 4900 PRINT 
 4902 PRINT 
 4910 PRINT "PRESS  Y FOR YES"
 4930 PRINT "       N FOR NO"
 4990 RETURN
 5010 GOSUB 8300
 5015 LET IS=5
 5016 GOSUB 5490
 5020 PRINT AT 21,0;
 5025 PRINT "          CRASH REPORT"
 5030 SCROLL
 5032 PRINT "          ~~~~~~~~~~~~~~~~~~~~~~~~"
 5034 SCROLL
 5036 SCROLL
 5040 PRINT "YOU CRASHED INTO THE ";X$
 5042 SCROLL
 5050 PRINT "AT A SPEED OF ";INT C(2);" KNOTS"
 5052 SCROLL
 5054 SCROLL
 5060 PRINT Y$
 5062 SCROLL
 5064 SCROLL
 5070 PRINT Z$
 5080 SCROLL
 5090 LET IS=8
 5100 IF PEEK 16519<99 THEN GOTO 5150
 5110 PRINT "YOUR FUEL TANKS WERE EMPTY"
 5120 LET IS=IS-1
 5410 GOSUB 5490
 5470 PRINT "ENTER RUN TO FLY AGAIN"
 5480 STOP
 5490 FOR I=1 TO IS
 5492 SCROLL
 5494 NEXT I
 5496 RETURN
 5515 PRINT AT 1,1;"[H][D][G][:]";C(1)
 5520 LET XB=2*X(BN)+29.5
 5525 LET YB=2*Y(BN)+24
 5530 LET XP=INT (2*C(19)+XB+.5)
 5535 LET YP=INT (2*C(20)+YB+.5)
 5540 IF XP<0 THEN LET XP=0
 5542 IF XP>63 THEN LET XP=63
 5544 IF YP<0 THEN LET YP=0
 5548 IF YP>43 THEN LET YP=43
 5610 PLOT XB,YB
 5616 UNPLOT XP,YP
 5620 LET T=USR 17163
 5630 UNPLOT XB,YB
 5635 PLOT XP,YP
 5640 IF C(3)<0 THEN GOTO 3000
 5641 IF C(19)+X(BN)>7.5 AND C(3)<1500 THEN GOTO 3020
 5642 IF C(2)+2*C(7)<90 THEN GOTO 3100
 5650 IF C(29)<>2 THEN GOTO 5700
 5660 GOSUB 5800
 5670 GOTO 5520
 5780 IF C(29)=0 THEN GOTO 5530
 5790 GOTO 8000
 5810 LET C(19)=C(19)+X(BN)
 5815 LET C(20)=C(20)+Y(BN)
 5820 LET BN=BN+1
 5825 IF BN>6 THEN LET BN=1
 5830 LET B$=N$(BN)
 5835 LET C(19)=C(19)-X(BN)
 5840 LET C(20)=C(20)-Y(BN)
 5850 LET C(4)=1
 5860 LET C(5)=45
 5890 RETURN
 5900 LET C(21)=1-C(21)
 5910 IF C(21)=0 THEN GOTO 5980
 5920 LET G$="DOWN"
 5930 IF C(2)<170 THEN GOTO 2000
 5940 LET Y$="YOU CRASHED BECAUSE"
 5942 LET Z$="YOUR LANDING GEAR WAS TORN AWAY"
 5950 GOTO 3105
 5980 LET G$="█UP█"
 5990 GOTO 2000
 6050 CLS
 6060 IF C(30)>2 THEN GOTO 6100
 6062 PRINT 
 6064 PRINT 
 6070 PRINT "THAT WAS A SMOOTH TOUCH-DOWN"
 6080 GOTO 6200
 6100 IF C(30)>5 THEN GOTO 6150
 6110 PRINT "NOT BAD ... A BIT BOUNCY"
 6120 GOTO 6200
 6150 PRINT "A SEVERELY HEAVY LANDING"
 6200 PRINT 
 6205 IF ABS C(19)>4096 OR ABS C(20)>64 THEN GOTO 6300
 6210 IF ABS C(20)>20 THEN PRINT "A BIT OFF CENTRE"
 6215 PRINT 
 6220 IF ABS C(20)>50 THEN PRINT "DANGEROUSLY CLOSE TO THE EDGE"
 6225 PRINT 
 6230 IF ABS C(19)>3700 THEN PRINT "YOU ALMOST OVERSHOT"
 6290 GOTO 6800
 6300 PRINT "YOU TAXIED OFF THE RUNWAY"
 6810 PRINT 
 6820 PRINT 
 6900 PRINT 
 6910 GOTO 5450
 7020 LET C(25)=3830*C(25)
 7022 LET C(16)=.63*C(16)
 7024 LET C(26)=.63*C(26)
 7030 LET C(31)=6
 7032 LET C(12)=C(12)-6
 7070 LET C(19)=(C(19)+X(BN))*6080
 7072 LET C(20)=(C(20)+Y(BN))*6080
 7090 LET L$="█[I][L][S] ▐██████████████████████████"
 7091 LET M$="████▄▟████████[K][T][S]█████[F][E][E][T]██████"
 7095 LET T=USR 18303
 7110 LET T=USR 19230
 7130 IF C(3)=0 THEN GOTO 7900
 7150 IF C(2)+2*C(7)<90 THEN GOTO 7700
 7200 IF C(29)=0 THEN GOTO 7100
 7520 LET C(25)=C(25)/3830
 7522 LET C(16)=C(16)/.63
 7524 LET C(26)=C(26)/.63
 7530 LET C(31)=12
 7532 LET C(12)=C(12)+6
 7570 LET C(19)=C(19)/6080-X(BN)
 7572 LET C(20)=C(20)/6080-Y(BN)
 7590 GOTO 8000
 7700 IF C(3)<50 THEN GOTO 7710
 7702 LET X$="AIRPORT"
 7709 GOTO 3200
 7710 IF C(3)<12 THEN GOTO 7740
 7720 LET C(12)=1
 7730 GOTO 7100
 7740 LET C(12)=5
 7745 GOTO 7100
 7800 IF C(21)=1 THEN GOTO 7810
 7802 LET X$="AIRPORT"
 7804 LET Y$="YOU ""LANDED"" WITH YOUR GEAR UP"
 7809 GOTO 5000
 7810 IF ABS C(19)<4096 OR ABS C(20)<64 THEN GOTO 7820
 7812 LET X$="AIRPORT"
 7819 GOTO 5000
 7820 IF C(12)>=5 THEN GOTO 7830
 7822 LET C(12)=11-C(12)
 7829 GOTO 7100
 7830 LET C(32)=99
 7832 LET C(16)=0
 7834 LET C(17)=0
 7836 LET C(18)=0
 7839 GOTO 7100
 7900 IF C(32)=16 THEN GOTO 7800
 7910 IF C(2)<3 THEN GOTO 6000
 7920 GOTO 7100
 8000 PRINT AT 0,0;
 8005 LET L$="█████████[R][D][F]████████████████████"
 8006 LET M$="██████████████[P][S][I][O][N]█████████████"
 8010 PRINT "                                                                                                                                                                                                                                                                "
 8020 PRINT "▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄██████████████████████[F][E][E][T]███████[+]█[-]██████▜█████████████████[P]█[-]██[R]█[-]█████████████████[K][N][O][T][S]██[O]█[-]██[O]█[=]██▙██████▙██████████████[W]█[-]██[C]█[-]█████████████[▒][▒][▒][▒][▒][▒][▒][▒][▒]██[E]█[-]██[-]█[-]██████▐██████[▒][B][C][N][▒][▒][▒][▒][▒]██[R]█[-]██████▜██▛▀▝▀███▜█[▒][▒][▒][▒][▒][▒][▒][▒][▒]████████████████▐██████[▒][B][R][G][▒][D][S][T][▒]███████[F]█[-]█████▛▝██████[▒][▒][▒][▒][▒][▒][▒][▒][▒]██[F]█[-]██[U]█[-]█████████████[▒][▒][▒][▒][▒][▒][▒][▒][▒]██[L]█[-]█"
 8030 PRINT "█[E]█[-]██▙██████▙██████████████[A]█[-]██[L]█[-]██████▜██████[G][E][A][R]███████[P]█[-]█████████████████████████████████"
 8040 LET T=USR 18303
 8090 GOTO 2000
 8100 PRINT AT 0,0;
 8105 LET L$="████████████████████████[S][C][A][L][E]███"
 8106 LET M$="███████[N][A][V][I][G][A][T][I][O][N]█[C][H][A][R][T]█████████"
 8110 PRINT                     "███████████████[N]██████████████████████████████[0][0][0]████████████████████████████████████████████████████████████████████▜███████████████▜[O][N][W]████████████▐███████████████████████████████▐████▜[O][N][E]███████████████████████▞███████████████████████████████▌██████████"
 8120 PRINT                     "█████████████████████▌▜██████████[W]██████████▜█[,,][,,]██▜███▐███████[E]█[2][7][0]████████[I][W]████[I][E]███▐██████[0][9][0]██████████████████████▐██████████████████████████████▛▐██████████████████████████████▌████████████████████████████████▐██████████████████████████████▚██████████"
 8130 PRINT                     "█████████████████▜[O][S][E]█████████████▜[O][S][W]██████████████████████████████████████████████████████████████████████████████████[0]████[5]████████████████[1][8][0]███████▜▜▜▜▜▜█████████████████[S]████████▄▄▄▄▄▟██"
 8160 LET T=USR 18303
 8190 GOTO 5500
 8210 CLS
 8220 PRINT "        PSION  COMPUTERS"
 8230 PRINT 
 8232 PRINT 
 8234 PRINT 
 8240 PRINT "             FLIGHT"
 8250 PRINT 
 8252 PRINT "           SIMULATION"
 8260 PRINT 
 8262 PRINT 
 8264 PRINT 
 8266 PRINT 
 8268 PRINT 
 8290 RETURN
 8310 LET T=USR 19369
 8320 LET L$=""
 8322 LET M$=""
 8326 LET T=USR 18303
 8390 RETURN
 9010 DIM N$(6,3)
 9012 DIM X(6)
 9014 DIM Y(6)
 9020 LET N$(1)="IW "
 9022 LET X(1)=-2.75
 9024 LET Y(1)=0
 9030 LET N$(2)="IE "
 9032 LET X(2)=3.25
 9034 LET Y(2)=0
 9040 LET N$(3)="ONW"
 9042 LET X(3)=-9.75
 9044 LET Y(3)=5
 9050 LET N$(4)="ONE"
 9052 LET X(4)=11.25
 9054 LET Y(4)=4
 9060 LET N$(5)="OSE"
 9062 LET X(5)=2.25
 9064 LET Y(5)=-7
 9070 LET N$(6)="OSW"
 9072 LET X(6)=-12.75
 9074 LET Y(6)=-8
 9090 RETURN
 9990 SAVE "FLIGH[T]"
 9999 RUN 

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.

People

No people associated with this content.

Scroll to Top