Bee Trap
Robert L. Lykins
You're a scout who leads worker bees - one at a time - from the bottom of the screen to the flower bed at the top. Beware the Venus Bee Traps along the way. Versions for VIC, Atari, and the TRS-80 Color Computer.
Spring has sprung. The air is clear and cool; a light northerly breeze carries the fresh scent of new flowers. A hum fills the air as seemingly lost bees from the southern colony, lured by the sweet winds, fly lazily toward the flower bed.
The Queen's Commission
Alas, all is not as rosy as it seems. As the midday sun warms the soil between the colony and the flowers, strangely beautiful, enticing blossoms appear throughout the field. Unknown to the lost worker bees, these are not gentle flowers. They are deadly Venus Bee Traps.
As Guide Bee, you must take the lost bees safely to the flower bed. You are credited only for the bees you take (one at a time), not those that find the flowers on their own. You lose credit for one bee if you enter the flower bed empty-handed. If 50 bees meet a fateful end or if you are caught by a Venus Bee Trap yourself, you lose your commission as Guide.
Multicolor Graphics
This program is a good example of the value of multicolor graphics on the VIC. By POKEing the character color location with a number ranging from 8 to 15 (instead of the usual 0 to 7), you get not only a different color but also a different character shape. The bees are really asterisks and the Venus Bee Traps are club symbols.
To illustrate this mode, first POKE in the screen and border color combination desired.
This is important because these colors play a role in the color and apparent shape of the
multicolor mode characters. Next, POKE 646 with a number from 8 to 15. Then type
characters from the keyboard to see the resulting shape and color combinations. Beautiful
designs may be drawn by repeating the same character many times. Make this easier by
POKEing 650 with # 128. This makes all keys repeat.
Keyboard Play
For play without a joystick, add KB=197 to line 10 and eliminate lines 3, 5, 7, 30, 32, 35, and 40. Change FIRE BUTTON to SPACE BAR in line 120 and line 3400. Eliminate line 312. Re-enter the following lines:
130 IFPEEK(KB) < > 32THEN130
310 REM READ KEYS: Y (UP), B (DOWN), G (LEFT),
H (RIGHT)
315 IFPEEK(KB) = 11THEND1 = Dl -22: GOTO 335
320 IFPEEK(KB) = 35THEND1 = Dl -1 :GOTO 335
325 IFPEEK(KB) = 19THEND1 = Dl -1:GOTO 335
330 IFPEEK(KB) = 43THEND1 = Dl + 1
3415 IFPEEK(KB) = 32THEN150
Readers who would like a tape copy of this program may send $3 with a blank tape and a self-addressed, stamped mailer to:
Robert L. Lykins
P.O. Box 8140
Anchorage, AK 99508
Atari And TRS-80 Color Computer Version Notes For Bee Trap
To play these versions of Bee Trap you follow the same rules as the VIC version. A guide bee safely leads stray bees to the flower bed while avoiding the deadly Venus Bee Trap. The guide is controlled with the joystick. On the Atari, plug the joystick into controller jack #1; on the Color Computer, plug the joystick into the right port.
The game ends either when 50 lost bees have been taken by the Venus Bee Traps or when the guide bee collides with a Bee Trap. As the guide bee, be sure not to enter the flower bed without a lost bee. Terrible sounds will result, and you will be penalized one credit.
Program 1: VIC Version
Two bees evade Venus Beetraps in the VIC-20 version of "Bee Trap."
3 GOTO 10
5 Jl=NOTPEEK(37151)AND60-((PEEK(JS)AND128)=0)
7 RETURN
10 Q=36879:J=37137:JS=37152
30 POKEQ,110:PRINT"{CLEAR}{06 DOWN}{02 RIGHT}{WHT}PLUG IN JOYSTICK","{02 DOWN}{02 RIGHT}PRESS FIRE BUTTON
32 POKE 37154,127:REM ACTIVATE PORT B
35 GOSUB 5
40 IFJ1<>32THEN35
50 PRINT"{CLEAR}":POKEQ,93:FORL=lTO3:PRINT"{03 DOWN}{05 RIGHT}
B E E T RA P{02 DOWN}";:NEXT:FORL=1TO999:NEXT
60 POKEQ,127:FORL=lTO999:NEXT:POKEQ,42:FORL=lTO2000:NEXT
80 PRINT"{CLEAR}{BLK}YOU ARE A GUIDE BEE
{DOWN}COMMISSIONED BY THE {DOWN}QUEEN BEE TO TAKE LOST
90 PRINT"BEES SAFELY TO THE {DOWN}FLOWER BED. YOU WILL {DOWN}GET CREDIT FOR ONLY l{DOWN}
100 PRINT"BEE{RIGHT}AT A TIME. BEWARE{DOWN}
THE LOVELY VENUS BEE {DOWN}TRAPS WHICH BLOOM PRO-
110 PRINT"FUSELY ACROSS THE {DOWN}FIELD. {GRN}{REV}GOOD LUCK!?!{DOWN}
115 FORL=lTO200:NEXT
120 PRINT"{WHT}{REV}{RIGHT}(PRESS FIRE BUTTON){UP}
130 GOSUB 5:IFJ1<>32 THEN 130
150 C=30720:P=7680:N=36877:V=3687B:B=36875:K=8248:HH=36874
175 Kl=7735:H=240:SC=0:S=0:Dl=0:D2=0:R=0
190 REM PRINT FLOWERS
200 POKEQ,191:PRINT"{CLEAR}":FORL=0TO43
225 POKEP+L,42
230 POKEP+L+C,INT(RND(l)*8):NEXT
305 POKEK1+D1,32:REM ERASE GUIDE BEE
310 REM READ JOYSTICK
312 Jl=NOTPEEK(37151)AND60-((PEEK(JS)AND128)=0)
315 IFPEEK(JS)=119THEND1=Dl+l:GOTO335
320 IFJ1=4THEND1=D1-22:GOTO 335
325 IFJ1=8THEND1=Dl+22:GOTO 335
330 IFJ1=16THEND1=Dl-l
335 IFK1+Dl>8185THEND1=450:REM PREVENT SCREEN EXIT
340 IFK1+Dl<7724ANDS>0THEN2000:REM ENTER FLOWERS WITH BEE
345 IFK1+Dl<7724THEND1=0:POKEQ,110:FORL=1TO2000:NEXT:
SC=SC-l:POKEQ,191:REM ENTER W/0 BEE
350 IFD2<50ANDX<2THENXX=INT(RND(1)*351)+44:
POKEK1+C+XX,X+12:POKEK1+XX,88
351 REM RANDOM TRAP PLACEMENT
360 IFPEEK(Kl+Dl)=42THEND2=0:S=S+1:H=H-10:REM CATCH LOST BEE
370 IFPEEK(Kl+Dl)=88THEN3000:REM GUIDE BEE IS ZAPPED
380 POKEK1+Dl+C,8:POKEK1+D1,42:REM PRINT GUIDE BEE
425 REM BUZZING SOUNDS
440 IFH<130THENH=240
450 POKEV,6-X/6:POKEB,160-X:POKEHH,H
505 POKEK-D2,32:REM ERASE LOST BEE
515 REM LOST BEE MOVEMENT
520 X=INT(RND(l)*(H/5-22))
530 IFX<3THEND2=D2+22
540 IFX=3ORX=4THEND2=D2+1
550 IFX=5THEND2=D2-1
560 IFK-D2<7724THEND2=0:REM BEE FINDS FLOWERS WITHOUT GUIDE
570 IFPEEK(K-D2)=42ANDD2>62THEND2=0:S=S+I:H=H-10:
REM LOST BEE FINDS GUIDE BEE
580 IFPEEK(K-D2)=88THEN1000:REM LOST BEE IS ZAPPED
590 POKEK-D2+C,14:POKEK-D2,42:REM PRINT LOST BEE
600 GOT0305
1000 POKEQ,42:FORL=lTO10STEP.l:POKEV,10-L:POKEN,200-L*5:
NEXT:POKEN,O:D2=0
1050 R=R+l:IFR=50THEN3000
1075 IFR>40THENPOKEQ,249:GOTO305
1100 POKEQ,191:GOTO305
2000 POKEQ,127:SC=SC+l:PRINT"{HOME}{02 DOWN}{04 RIGHT}{RED}CREDIT"SC;
2100 IFSC=1THENPRINT"BEE":GOTO2300
2200 PRINT"BEES
2300 FORL=lTO75STEP.3:POKEB,175+L:NEXT:PRIN T"[UP] ":S=O:
Dl=0:GOTO1100
3000 POKEQ,10:FORL=lTO10STEP.l:POKEV,15-L:POKEB,200-L*5:NEXT:POKEB,0:POKEHH,0
3100 PRINT"{HOME}{02 DOWN}{RIGHT}{CYN}FINAL CREDIT"SC;
3200 IFSC=lTHENPRINT"BEE":GOTO3400
3300 PRINT"BEES
3400 PRINT"{DOWN} HIT {REV}S{OFF} TO STOP,
PRESS FIREBUTTON TO REPLAY"
3403 GET A$
3410 IF A$="S" THEN 3500
3415 GOSUB 5:IF Jl=32 THEN 150
3420 GOTO 3403
3500 POKE 37154,255:POKE Q,27:PRINT"{CLEAR}{BLU}":END
Program 2: Atari Version
105 DL=PEEK(560)+256*PEEK(561)+4
110 SCREEN=PEEK(88)+256*PEEK(89)
120 GRAPHICS 2:SETCOLOR 2,0,0
125 POKE 752,1
130 SETCOLOR 0,7,10:POSITION 3.4:PRINT #6;"B E E{3 SPACES}T R A P"
135 FOR 1=1 TO 3:SOUND 0,0,0,0:SOUND 1,0,0,0:SOUND 1,140,12,4:SOUND
1,45,12,4:FOR K=l TO 200:NEXT K:NEXT I
140 PRINT "{3 SPACES} - PLUG JOYSTICK INTO JACK #1 -":
FOR I=1 TO 950:NEXT I:SOUND 0,0,0,0:SOUND 1,0,0,0:GRAPHICS 0
150 PRINT :? :PRINT "{4 SPACES} YOU ARE A GUIDE BEE COMMISSIONED":
160 PRINT "BY THE QUEEN BEE TO TAKE LOST BEES":?
170 PRINT "SAFELY TO THE FLOWER BED. YOU WILL":?
180 PRINT "GET CREDIT FOR ONLY 1 BEE AT A TIME.":?
190 ? "BEWARE THE VICIOUS VENUS BEE TRAPS":?
200 PRINT "WHICH BLOOM PROFUSELY ACROSS THE"
210 ? :PRINT "FIELD!"
220 POSITION 14,17:PRINT "{REV}GOOD LUCK{OFF}!!!!"
225 POKE 752,1
230 POSITION 2,20:PRINT " PRESS THE {REV}FIRE BUTTON{OFF}
TO START"
240 IF STRIG(0)<>0 THEN 240
245 K=SCREEN+1074:K1=SCREEN+100:H=240:SC=0:S=0:D1=0:D2=0:R=0
248 GRAPHICS 0:SETCOLOR 4,1,12:SETCOLOR 2,2,11
250 POKE 752,1:POSITION 0,0:FOR I=l TO 20:PRINT CHR$(123);CHR$( 32);:
NEXT I
255 FOR 1=2 TO 24:POKE DL+I,4:NEXT I :POKE DL-1,4+64
260 POSITION 0,1:FOR J=l TO 20:PRINT CHR$(124):CHR$(0);:NEXT J:REM PRINT FLOWER BED
305 POKE Kl+D1,0:REM ERASE GUIDE BEE
310 REM READ JOYSTICK
312 IF STICK(0)<>15 THEN POKE 77,0
315 IF STICK(0)=7 THEN Dl=Dl+l:GOTO 335
320 IF STICK(0)=14 THEN D1=D1-40:GOTO 335
325 IF STICK(0)=13 THEN D1=D1+40:GOTO 335
330 IF STICK(0)=11 THEN D1=Dl-l
335 IF K1+D1>SCREEN+959 THEN D1=D1-40:REM PREVENT SCREEN EXIT
340 IF K1+D1<SCREEN+80 AND S>0 THEN 2000:REM ENTERS FLOWERS W/ BEE
345 IF K1+Dl<SCREEN+80 THEN DL=0:SET COLOR 4,9,12:FOR I=l TO 300:
NEXT I:SC=SC-1:SETCOLOR 4,1,12:REM E NTER W/O BEE
350 IF D2<90 AND X<2 THEN XX=INT(RND (1)*680)+80:POKE Kl+XX,28:
REM ANDOM TRAP PLACEMENT
360 IF PEEK(K1+Dl)=3 THEN D2=0:S=S+l :H=H-I0:REM CATCH LOST BEE
370 IF PEEK(K1+Dl)=28 THEN 2900:REM GUIDE BEE IS ZAPPED
380 POKE Kl+Dl,32:REM PRINT GUIDE BEE
425 REM BUZZING SOUNDS
440 IF H<130 THEN H=240
450 SOUND 0,140,12,4:SOUND 1,H,12,4: SOUND 2,45,12,2
505 POKE K-D2,0:REM ERASE LOST BEE
515 REM LOST BEE MOVEMENT
520 X=INT(RND(l)*(H/5-22))
530 IF X<3 THEN D2=D2+40
540 IF X=3 OR X=4 THEN D2=D2+1
550 IF X=5 THEN D2=D2-1
560 IF K-D2<SCREEN+80 THEN D2=0:REM BEE FINDS FLOWERS W/O GUIDE
570 IF PEEK(K-D2)=3 AND D2>120 THEN D2 = 0: S = S+1:
H=H-10:REM LOST BEE FINDS GUIDE BEE
580 IF PEEK(K-D2)=28 -THEN 1000:REM LOST BEE IS ZAPPED
590 POKE K-D2,3:REM PRINT LOST BEE
600 GOTO 305
1000 SETCOLOR 4,4,12:FORI=50 TO 150:SOUND 3,I,10,4:NEXT I:SOUND 3, 0,0,0
1050 D2=0:R=R+l : IF R=50 THEN 2900
1060 FOR I=1 TO 200:NEXT I
1100 SETCOLOR 4,1,12:GOTO 3705
2000 SETCOLOR 4, 4,12: SETCOLOR 2, 2,6: SC=SC+1:POKE DL+3,2
2050 FOR I =0 TO 70: SOUND 1,I,10,4: NE XT I;FOR I=0 TO 30:NEXT I:SOUND 1,0,0,0
2100 POSITION 12,2:PRINT "{REV}CREDIT{OFF}";SC;:
IF SC=l THEN PRINT "{REV}BEE{OFF}: GOTO 2300
2200 PRINT "{REV}BEES{OFF}
2300 FOR L=l TO 500:NEXT L:FOR L=5 TO 27:POSITION L,2:PRINT " ":NEXT L:
POKE DL+3,4
2310 S=0:D1=0:SETCOLOR 2,2,10:GOTO 1100:REM SCORE SOUND
2900 SOUND 0,0,0,0:SOUND 1,0,0,0:SOUND 2,0,0,0
3000 SETCOLOR 4,7,12: SETCOLOR 2,2,8: FOR I=100 TO 255:SOUND 1,I,10,4 :
NEXT I:SOUND 1,25,2,4:FORI=0 TO 30:NEXT 1
3100 SOUND 1,0,0,0:FOR I=3 TO 4:POKE DL+I,2:NEXT I
3200 POSITION 9,2:PRINT"{REV} FINAL CREDIT {OFF}";SC;:IF SC=1 THEN PRINT "{REV} BEE {OFF}":GOTO 3400
3300 PRINT "{REV} BEES {OFF}"
3400 POKE 764,255:PRINT " HIT {REV} O {OFF} TO STOP/FIREBUTTON TO REPLAY"
3420 IF STRIG(0)=0 THEN 245
3425 IF PEEK(764)=47 THEN POKE 764,255:GRAPHICS 0:END
3430 GOTO 3420
The Atari version of "Bee Trap" uses multicolored characters for the flowers (top),
bees (center and lower right), and the bee traps.
Program 3: Color Computer Version
100 CLS
110 PRINT@232, "{REV}B E E{3 SPACES}T R A P{OFF}"
120 PRINT@389,"PLUG IN RIGHT JOYSTICK"
130 SOUND 1,30:FOR I=1 TO 500
140 NEXTI
1 50 CLS
160 PRINT:PRINT"{3 SPACES}YOU ARE A GUIDE BEE COMMIS-"
170 PRINT"SIONED BY THE QUEEN BEE TO TAKE"
180 PRINT"LOST BEES SAFELY TO THE FLOWER"
190 PRINT"BED. YOU WILL GET CREDIT FOR"
200 PRINT"ONLY ONE BEE AT A TIME. BEWARE"
210 PRINT"THE VICIOUS VENUS BEE TRAPS"
220 PRINT"WHICH BLOOM PROFUSELY ACROSS"
230 PRINT"THE FIELD."
240 PRINT@362,"GOOD LUCK !!!"
250 FOR I=1 TO 300:NEXT I
260 PRINT@451,"PRESS {REV} FIRE BUTTON {OFF}TO BEGIN"
270 GOSUB 600:IF FIRE=0 THEN 270
280 CLS:E=0
290 K1=1104:P=1024:SC=0:S=0:D1=0:D2 =0:R=0:H=240:K=1503+RND(32)
300 REM PRINT FLOWERS
310 FOR I=1 TO 32:C=128+16*RND(7)+6 :PRINT CHR$(C);:NEXT I
320 FOR I=1 TO 32:PRINT"^";:NEXT I
330 E=E+l:POKE K1+D1,96:REM ERASE GUIDE BEE
340 H1=JOYSTK(0):V=JOYSTK(1):REM READ RIGHT JOYSTICK
350 IF H1=OH AND V=OV THEN 370
360 SOUND 1,l
370 IF H1=0 THEN D1=D1-1:GOTO 410
380 IF H1=63 THEN D1=D1+1:GDTO 410
390 IF V=0 THEN Dl=D1-32:GOTO 410
400 IF V=63 THEN D1=D1+32
410 OH=H1:OV=V:IF Kl+D1>1535 THEN D1=D1-32:REM PREVENT SCREEN EXIT
420 IF K1+D1<1088 AND S>O THEN 680: REM ENTER FLOWERS WITH BEE
430 IF K1+D1<1088 THEN D1=0:SC=SC-1 :SOUND 50,3:REM ENTER W/O BEE
440 IF D2<70 AND X<2 THEN XX=RND(304)+64:POKE K1+XX,126:REM RANDOM TRAP PLACEMENT
450 IF PEEK(Kl+Dl)=64THEN D2=0:S=S+l :H=H-10:E=-30:REM CATCH LOST BEE
460 IF PEEK(K1+Dl)=126 THEN 760:REM GUIDE BEE IS ZAPPED
470 POKE K1+D1,99:REM PRINT GUIDE BEE
480 IF H<130 THEN H=240
490 POKE K-D2,96:REM ERASE LOST BEE
500 REM LOST BEE MOVEMENT
510 X=RND(H/5-23)
520 IF X<3 AND E>5 THEN D2=D2+32
530 IF X=3 OR X=4 THEN D2=D2+1
540 IF X=5 THEN D2=D2-1
550 IFK-D2<1088 THEN D2=0:K=RND(32) +1503:REM BEE FINDS FLOWERS W/OUT GUIDE
560 IF PEEK (K-D2)=99 AND D2>90 THEN D2=0:S=S+1:H=H-10:
E=-35:REM LOST BEE FINDS GUIDE BEE
570 IF PEEK (K-D2)=126 THEN 630:REM LOST BEE IS ZAPPED
580 IF E>5 AND S=0 THEN POKE K-D2,64:REM PRINT LOST BEE
590 GOTO 330
600 REM JOYSTICK FIRE BUTTON ROUTINE
610 Z=PEEK (65280) :FIRE=(Z=126)OR(Z= 254)
620 RETURN
630 REM LOST BEE ZAPPED
640 D2=0:E=-5
650 R=R+1:IF R=50 THEN 760
660 SOUND 50,5:K=1503+RND(32)
670 GOTO 330
680 REM GUIDE SUCCESSFULLY CARRIES LOST BEE INTO FLOWER BED
690 SC=SC+1:E=-2
700 FOR I=130 TO 190 STEP 5:SOUND I,1: NEXT I
710 PRINT@72, "{REV}CREDIT{OFF} ";SC;
720 IF SC=l THEN PRINT" {REV}BEE{OFF}":GOTO 740
730 PRINT" {REV}BEES{OFF}"
740 FOR I=1 TO 500:NEXTI:PRINT@70," {24 SPACES}"
750 S=O:D1=O:D2=0:K=150@+RND(32):Go TO 330
760 FOR I=190 TO 110 STEP -5:SOUND I, 1: NEXT I
770 PRINT@68," {REV}FINAL CREDIT{OFF}";SC;
780 IF SC=l THEN PRINT" {REV}BEE{OFF}":GOTO 810
790 PRINT" {REV}BEES{OFF}"
800 FOR I=l TO 200:NEXT I
810 PRINT@101,"PLAY AGAIN ({REV}Y{OFF} OR {REV}N{OFF})"
820 INPUT A$:IF A$="Y" THEN 280
830 CLS:END
"Bee Trap," TRS-80 Color Computer version.