Odell Lake is an educational ecology simulation where the player role-plays as one of six fish species — Whitefish, Chub, Blueback Salmon, Rainbow Trout, Mackinaw Trout, or Dolly Varden — navigating predator encounters and feeding decisions in a freshwater lake environment. The program uses a score variable C to track wasted energy, ending the game with starvation if C reaches 30, and a counter R to track repeated failed escapes from the Mackinaw Trout. All output scrolls through the bottom two lines of the display using repeated SCROLL commands rather than filling the screen, giving the game a teletype-style presentation. A subroutine at line 3940 clears the display by issuing 22 consecutive SCROLL commands, used as a screen-clear substitute. Random events are driven by RND scaled to 0–99 via INT(100*(RND*1)) and compared against threshold values to determine escape or capture outcomes.
Program Analysis
Program Structure
The program is divided into several logical regions across its roughly 150 lines of BASIC:
- Lines 10–70: REM header block identifying the program and author.
- Lines 80–190: Initialization, random seed, and instructions prompt.
- Lines 200–2640: Main game logic — a long branching narrative driven by the chosen fish species (
A) and the player’s numeric decisions (B). - Lines 2650–3110: Shared message subroutines (escape messages, hunger warnings, energy-waste notices).
- Lines 3120–3210: Starvation death ending.
- Lines 3220–3810: Instructions text, displayed on request or at first run.
- Lines 3830–3980: End-of-game handler: pause, replay prompt, and STOP.
- Lines 3940–3970: Screen-clear subroutine (22 × SCROLL).
Game Variables
| Variable | Purpose |
|---|---|
A | Player’s chosen fish species (1–6) |
B | Player’s decision input each turn (1–5) |
C | Energy waste / hunger score; game ends at ≥30 |
D | Scene/depth state tracker (1–5) |
R | Counter for repeated Mackinaw Trout escape attempts |
Y | Random number (0–99) for probabilistic outcomes |
T$ | Instructions prompt response (“YES”/”NO”) |
I$ | Replay prompt keypress (“Y”/”N”) |
X | Loop counter in the screen-clear subroutine |
Screen Output Technique
Rather than using CLS or PRINT AT for full-screen layout, almost every line of output is followed by a SCROLL command. This produces a scrolling teletype effect at the bottom of the screen. The subroutine at line 3940 issues 22 consecutive SCROLL commands inside a FOR/NEXT loop to act as a full screen clear, used before major scene transitions and the replay prompt.
Random Number Generation
Random outcomes are computed using the idiom INT(100*(RND*1)), yielding an integer in the range 0–99. The multiplication by 1 is redundant but harmless. Threshold comparisons such as IF Y>19 (line 400) or IF Y>25 (line 2510) implement simple probability gates. RAND at line 80 seeds the random number generator without a specific value, which on this platform uses the system’s frame counter as the seed.
Fish Species and Branching Logic
The player selects a species number 1–6. The main game loop uses A in a series of comparisons (IF A<5, IF A=3, IF A=2, etc.) to differentiate valid actions and outcomes by species. Species 5 (Mackinaw Trout) and 6 (Dolly Varden) are the apex predators and share a separate decision branch for encounters. Smaller fish (species 1–4) are subject to predation and have feeding restrictions reflecting ecological niche — for example, species 1–4 cannot survive on animal plankton (line 3070 subroutine), and only certain species can attempt territorial chase (option 5).
Energy / Hunger Mechanic
The variable C accumulates in increments of 5 or 10 when the player wastes energy or passes up food. If C reaches 30 or more, execution branches to line 3120 where the starvation death message is printed. Successful feeding calls the subroutine at line 2760 which prints a success message and resets R to 0, but notably does not reset C — only the escape actions at lines 1170 and 2120 reset C to 0, representing flight rather than recovery. This is a potential design oddity: successful predation does not relieve the hunger counter.
Replay and Input Handling
The end-of-game handler at line 3830 uses a busy-wait loop at line 3860: IF INKEY$="" THEN GOTO 3860 waits for any key, then captures the key into I$. A second check ensures only “Y” or “N” are accepted; any other key causes the loop to restart. This is a clean debounce-style input pattern. On “Y”, the program jumps to line 10 to restart completely, re-randomizing and re-prompting for instructions.
Notable Bugs and Anomalies
- Line
3860readsINKEY$into nothing (the condition just checks for empty), then line3870readsINKEY$again intoI$. BecauseINKEY$is instantaneous and the key may have been released,I$could occasionally be empty, sending the program back to3860— effectively requiring the user to hold the key briefly. This is a known fragility of the two-readINKEY$pattern. - Line
3820(STOP) is unreachable dead code placed between the instructions section and the end-of-game handler. - The
GOSUB 3940at line3510is called from within the instructions section before displaying the decision menu, but line3200ends withRETURNfollowing the starvation message, meaning if execution ever falls through from line3200, line3210(SCROLL) would execute before reaching the instructions at3220— a minor structural leftover. - The
GOTO 0200style of zero-padded line number targets is a memory optimization to store the number as a shorter token sequence in some BASIC implementations, though on this platform it is functionally equivalent toGOTO 200.
Content
Source Code
10 REM ***********************
20 REM * ODELL LAKE *
30 REM * MODIFIED FOR TIMEX *
40 REM * SINCLAIR COMPUTERS *
50 REM * BY TIM L. WARD *
60 REM * 3/23/86 *
70 REM ***********************
80 RAND
90 LET Y=INT (100*(RND*1))
100 LET R=0
110 PRINT AT 21,0;"DO YOU WISH TO SEE ANY"
120 SCROLL
130 PRINT AT 21,0;"INSTRUCTIONS? ""YES"" OR ""NO"""
140 SCROLL
150 INPUT T$
160 SCROLL
170 SCROLL
180 IF T$="NO" THEN GOTO 0200
190 GOTO 3220
200 GOSUB 3940
210 PRINT "CHOOSE THE NUMBER OF THE FISH"
220 SCROLL
230 PRINT "YOU WISH TO ROLE PLAY."
240 SCROLL
250 SCROLL
260 INPUT A
270 LET C=0
280 LET D=1
290 PRINT "YOU SEE AN OSPREY CLOSE TO THE"
300 SCROLL
310 PRINT "SURFACE OF THE LAKE."
320 SCROLL
330 PRINT "WHAT DO YOU WISH TO DO?"
340 SCROLL
350 INPUT B
360 IF B>2 THEN GOTO 2650
370 IF A>4 THEN GOTO 0420
380 IF B=1 THEN GOTO 0440
390 LET Y=INT (100*(RND*1))
400 IF Y>19 THEN GOTO 0570
410 GOTO 2680
420 GOTO 0570
430 GOTO 0580
440 GOSUB 2710
450 PRINT "YOU SEE A MACKINAW TROUT."
460 SCROLL
470 LET R=R+1
480 IF R<2 THEN GOTO 0560
490 PRINT "HE GOT YOU. YOU ARE NOT BIG"
500 SCROLL
510 PRINT "ENOUGH TO FOOL WITH A MACKINAW"
520 SCROLL
530 PRINT "TROUT."
540 SCROLL
550 GOTO 3830
560 GOTO 0330
570 GOSUB 2760
580 IF D=2 THEN GOTO 1000
590 PRINT "NOW YOU ARE SWIMMING IN SHALLOW"
600 SCROLL
610 PRINT "WATER AND YOU SEE A WATER INSECT"
620 SCROLL
630 PRINT "MOVING THROUGH THE WATER"
640 SCROLL
650 PRINT "DIRECTLY IN FRONT OF YOU."
660 SCROLL
670 PRINT "WHAT DO YOU DO?"
680 SCROLL
690 INPUT B
700 IF A<5 THEN GOTO 0800
710 IF B=3 THEN GOTO 0780
720 IF B=4 THEN GOTO 0760
730 GOSUB 2970
740 LET C=C+10
750 GOTO 0940
760 GOSUB 3070
770 GOTO 0740
780 GOSUB 2870
790 GOTO 0940
800 IF B=4 THEN GOTO 0830
810 GOSUB 3020
820 GOTO 0740
830 LET Y=INT (100*(RND*1))
840 IF Y<15 THEN GOTO 0870
850 GOSUB 2760
860 GOTO 0940
870 PRINT "WITH THE INSECT WAS A HOOK. YOU"
880 SCROLL
890 PRINT "HAVE JUST BEEN CAUGHT BY A"
900 SCROLL
910 PRINT "FISHERMAN."
920 SCROLL
930 GOTO 3830
940 PRINT "OFF TO YOUR RIGHT NEAR THE"
950 SCROLL
960 PRINT "SHORELINE IS AN OTTER."
970 SCROLL
980 LET D=2
990 GOTO 0330
1000 IF A=3 THEN GOTO 1300
1010 PRINT "MOVING INTO YOUR VICINITY IS A"
1020 SCROLL
1030 PRINT "BLUEBACK SALMON."
1040 SCROLL
1050 PRINT "WHAT DO YOU WISH TO DO?"
1060 SCROLL
1070 INPUT B
1080 IF A<5 THEN GOTO 1190
1090 IF B<3 THEN GOTO 1140
1100 IF B=4 THEN GOTO 1160
1110 GOSUB 3020
1120 LET C=C+10
1130 GOTO 1300
1140 GOSUB 2970
1150 GOTO 1120
1160 GOSUB 2760
1170 LET C=0
1180 GOTO 1300
1190 IF B=3 THEN GOTO 1230
1200 IF B=4 THEN GOTO 1280
1210 GOSUB 2970
1220 GOTO 1120
1230 PRINT "GOOD, IT DOES NOT OCCUPY THE"
1240 SCROLL
1250 PRINT "SAME NICHE AS YOU."
1260 SCROLL
1270 GOTO 1300
1280 GOSUB 2900
1290 GOTO 1120
1300 IF C<30 THEN GOTO 1320
1310 GOTO 3120
1320 IF A=1 THEN GOTO 1840
1330 LET D=3
1340 PRINT "AND NOW YOU FIND YOURSELF CLOSE"
1350 SCROLL
1360 PRINT "TO A WHITEFISH."
1370 SCROLL
1380 PRINT "WHAT DO YOU DO?"
1390 SCROLL
1400 INPUT B
1410 IF A<5 THEN GOTO 1510
1420 IF B=3 THEN GOTO 1460
1430 IF B=4 THEN GOTO 1480
1440 GOSUB 2970
1450 LET C=C+10
1460 GOSUB 3020
1470 GOTO 1800
1480 GOSUB 2760
1490 LET C=0
1500 GOTO 1840
1510 IF A=3 THEN GOTO 1760
1520 IF A=2 THEN GOTO 1640
1530 IF B=3 THEN GOTO 1580
1540 IF B=4 THEN GOTO 1620
1550 IF B=5 THEN GOTO 1600
1560 GOSUB 2970
1570 GOTO 1800
1580 GOSUB 2800
1590 GOTO 1800
1600 GOSUB 2760
1610 GOTO 1810
1620 GOSUB 2900
1630 GOTO 1800
1640 IF B=3 THEN GOTO 1690
1650 IF B=4 THEN GOTO 1710
1660 IF B=5 THEN GOTO 1730
1670 GOSUB 2970
1680 GOTO 1800
1690 GOSUB 2800
1700 GOTO 1800
1710 GOSUB 2900
1720 GOTO 1800
1730 PRINT "YOU ARE TOO LITTLE."
1740 SCROLL
1750 GOTO 1800
1760 IF B=3 THEN GOTO 1690
1770 IF B=4 THEN GOTO 1710
1780 IF B=5 THEN GOTO 1600
1790 GOTO 1670
1800 LET C=C+5
1810 IF C<30 THEN GOTO 1840
1820 GOTO 3120
1830 SCROLL
1840 IF D=5 THEN GOTO 1980
1850 IF D=4 THEN GOTO 1910
1860 IF A=2 THEN GOTO 1910
1870 PRINT "AND ALONG COMES A CHUB."
1880 SCROLL
1890 LET D=4
1900 GOTO 1380
1910 IF A=4 THEN GOTO 1980
1920 PRINT "YOU NOW SEE A RAINBOW TROUT"
1930 SCROLL
1940 PRINT "DIRECTLY IN FRONT OF YOU."
1950 SCROLL
1960 LET D=5
1970 GOTO 1380
1980 IF A=6 THEN GOTO 2280
1990 PRINT "AND NOW YOU FIND THAT A DOLLY"
2000 SCROLL
2010 PRINT "VARDEN IS VERY NEAR."
2020 SCROLL
2030 PRINT "WHAT DO YOU WISH TO DO?"
2040 SCROLL
2050 INPUT B
2060 IF A<5 THEN GOTO 2170
2070 IF B=4 THEN GOTO 2110
2080 IF B=3 THEN GOTO 2140
2090 GOSUB 2970
2100 GOTO 2150
2110 GOSUB 2760
2120 LET C=0
2130 GOTO 2280
2140 GOSUB 3020
2150 LET C=C+10
2160 GOTO 2260
2170 IF B=2 THEN GOTO 2200
2180 IF B=1 THEN GOTO 2220
2190 GOTO 2650
2200 GOSUB 2760
2210 GOTO 2280
2220 GOSUB 2710
2230 PRINT "YOU NOW SEE A MACKINAW TROUT."
2240 SCROLL
2250 GOTO 2030
2260 IF C<30 THEN GOTO 2280
2270 GOTO 3120
2280 PRINT "DIRECTLY IN FRONT OF YOU AT THE"
2290 SCROLL
2300 PRINT "SURFACE LIES SOME ANIMAL"
2310 SCROLL
2320 PRINT "PLANKTON."
2330 SCROLL
2340 PRINT "WHAT DO YOU WISH TO DO?"
2350 SCROLL
2360 INPUT B
2370 IF A<5 THEN GOTO 2470
2380 IF B=3 THEN GOTO 2430
2390 IF B=4 THEN GOTO 2450
2400 GOSUB 2970
2410 LET C=C+10
2420 GOTO 2590
2430 GOSUB 2870
2440 GOTO 2410
2450 GOSUB 3070
2460 GOTO 2610
2470 IF B=4 THEN GOTO 2500
2480 GOSUB 2970
2490 GOTO 2410
2500 LET Y=INT (100*(RND*1))
2510 IF Y>25 THEN GOTO 2570
2520 PRINT "THIS WAS PART OF A FISH TRAP AND"
2530 SCROLL
2540 PRINT "YOU WERE CAUGHT."
2550 SCROLL
2560 GOTO 3830
2570 GOSUB 2760
2580 GOTO 2610
2590 IF C<30 THEN GOTO 2610
2600 GOTO 3120
2610 PRINT "YOU HAVE SURVIVED. VERY GOOD JOB"
2620 SCROLL
2630 GOTO 3830
2640 SCROLL
2650 PRINT "YOU WERE JUST ATTACKED AND EATEN"
2660 SCROLL
2670 GOTO 3830
2680 PRINT "YOU DID NOT GET AWAY IN TIME."
2690 SCROLL
2700 GOTO 3830
2710 PRINT "YOU GOT AWAY FOR THE TIME BEING"
2720 SCROLL
2730 PRINT "BUT NOW IN DEEPER WATER----"
2740 SCROLL
2750 RETURN
2760 PRINT "YOU HAVE BEEN SUCCESSFUL."
2770 SCROLL
2780 LET R=0
2790 RETURN
2800 PRINT "THAT FISH JUST ATE THE LUNCH YOU"
2810 SCROLL
2820 PRINT "COULD HAVE HAD. YOU MAY GO"
2830 SCROLL
2840 PRINT "HUNGRY."
2850 SCROLL
2860 RETURN
2870 PRINT "OKAY. AND NOW-----"
2880 SCROLL
2890 RETURN
2900 PRINT "YOU CAN NOT KILL THIS ANIMAL AND"
2910 SCROLL
2920 PRINT "YOU USE A LOT OF ENERGY"
2930 SCROLL
2940 PRINT "NEEDLESSLY."
2950 SCROLL
2960 RETURN
2970 PRINT "YOU USE A LOT OF FOOD ENERGY FOR"
2980 SCROLL
2990 PRINT "NO PRACTICAL PURPOSE."
3000 SCROLL
3010 RETURN
3020 PRINT "YOU ARE GETTING HUNGRY. DO NOT"
3030 SCROLL
3040 PRINT "PASS UP ANOTHER CHANCE TO EAT."
3050 SCROLL
3060 RETURN
3070 PRINT "YOU CAN NOT SURVIVE ON THIS TYPE"
3080 SCROLL
3090 PRINT "OF FOOD."
3100 SCROLL
3110 RETURN
3120 PRINT "YOU PASSED UP TOO MANY CHANCES"
3130 SCROLL
3140 PRINT "AT FOOD AND USED YOUR ENERGY"
3150 SCROLL
3160 PRINT "WASTEFULLY. YOU NOW STARVED TO"
3170 SCROLL
3180 PRINT "DEATH."
3190 SCROLL
3200 RETURN
3210 SCROLL
3220 PRINT "IN THIS PROGRAM YOU WILL ROLE"
3230 SCROLL
3240 PRINT "PLAY ONE OF THE FOLLOWING FISH."
3250 SCROLL
3260 SCROLL
3270 PRINT "1. WHITEFISH"
3280 SCROLL
3290 PRINT "2. CHUB"
3300 SCROLL
3310 PRINT "3. BLUEBACK SALMON"
3320 SCROLL
3330 PRINT "4. RAINBOW TROUT"
3340 SCROLL
3350 PRINT "5. MACKINAW TROUT"
3360 SCROLL
3370 PRINT "6. DOLLY VARDEN"
3380 SCROLL
3390 SCROLL
3400 PRINT "AFTER ROLE PLAYING ALL OF THE"
3410 SCROLL
3420 PRINT "ABOVE FISH AND DISCOVERING THE"
3430 SCROLL
3440 PRINT "RELATIONSHIPS THAT EXIST, YOU"
3450 SCROLL
3460 PRINT "SHOULD BE ABLE TO DRAW A FOOD"
3470 SCROLL
3480 PRINT "WEB FOR ODELL LAKE."
3490 SCROLL
3500 PAUSE 600
3510 GOSUB 3940
3520 PRINT "DECISION SITUATIONS SHOULD BE"
3530 SCROLL
3540 PRINT "MADE BY NUMBER FROM ONE OF THE"
3550 SCROLL
3560 PRINT "FOLLOWING:"
3570 SCROLL
3580 SCROLL
3590 PRINT "1. ATTEMPT TO ESCAPE TO DEEPER"
3600 SCROLL
3610 PRINT " WATER."
3620 SCROLL
3630 PRINT "2. ATTEMPT TO ESCAPE IN THE"
3640 SCROLL
3650 PRINT " SHALLOW WATER."
3660 SCROLL
3670 PRINT "3. JUST IGNORE IT."
3680 SCROLL
3690 PRINT "4. ATTACK AND ATTEMPT TO PREY"
3700 SCROLL
3710 PRINT " UPON IT."
3720 SCROLL
3730 PRINT "5. ATTEMPT TO CHASE IT OUT OF"
3740 SCROLL
3750 PRINT " YOUR TERRITORY."
3760 SCROLL
3770 SCROLL
3780 PRINT "GOOD LUCK..."
3790 SCROLL
3800 PAUSE 600
3810 GOTO 0200
3820 STOP
3830 PAUSE 450
3840 GOSUB 3940
3850 PRINT "DO YOU WISH TO TRY AGAIN? Y/N"
3860 IF INKEY$="" THEN GOTO 3860
3870 LET I$=INKEY$
3880 IF I$<>"Y" AND I$<>"N" THEN GOTO 3860
3890 IF I$="N" THEN GOTO 3980
3900 GOSUB 3940
3910 GOTO 0010
3920 SAVE "1015%9"
3930 RUN
3940 FOR X=1 TO 22
3950 SCROLL
3960 NEXT X
3970 RETURN
3980 STOP
Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.
