Sssnake!!!

Type
Game
Category
Snake action game
Author
Chet Walters
Published in
Antic, October 1986 (Vol. 5, No. 6), Game of the Month
Year
1986
Language
Atari BASIC
Requirements
32K RAM, Atari BASIC, joystick in port 1; disk or cassette
Sssnake title screen: the word Snake spelled out in brown snake-body segments among mushrooms, bugs and raindrops, with CHOOSE ENTRY STAGE, HIT KEY 1 2 OR 3 below

About the program

It's midnight and starting to rain, and Hector the Snake has been caught napping in a dark corner of Farmer Brown's yard. Hector hates getting wet, and he knows the rain brings up poisonous blue mushrooms and giant blue pinch bugs. He wants to bolt through the exit gate. Your job is to stop him, because he'd never make it out alive, and to keep him healthy while he panics, eating everything in front of his nose.

Sssnake!!! was Antic's Game of the Month for October 1986. The magazine called it "one of the fastest-moving BASIC action games you have ever played". Its author, Chet Walters, ran Non-Standard Magic of Girard, Ohio (publisher of Picture Plus, Lister Plus and Journal Plus), and had written the Amazing Card Shuffler in Antic a few months earlier.

Typing it in

The magazine was blunt about this one. Walters was a professional who used BASIC "shortcuts" that Antic didn't recommend: self-modifying routines, GOTOs to REM lines, and GOTOs to variables instead of line numbers. So type every line, including the REMs, and never renumber it, or the game won't work. {inv} … {/inv} means press the Atari (inverse) key before and after, and {CTRL-A}, {CTRL-K} and so on mean hold CTRL and press the letter. The REMs in lines 855, 940 and 5015 point out where these characters go. Antic printed TYPO II checksums beside each line of the magazine listing. They are not part of the program.

How to play

At the title screen, press 1, 2 or 3 to choose the stage to start on. Steer Hector with the joystick. He never stops.

  • Raindrops keep him dry, so eat them all. They fall in straight lines, so eat a whole row in one sweep.
  • Blue mushrooms poison him. They spoil his night vision, drain his energy and slow him down. Only yellow mushrooms cure the poisoning, so don't waste them on points. Glow worms are good food too.
  • Biting himself brings more rain and makes him shrink. Flashing new snakeskin makes him grow, but deadly blue pinch bugs like snakeskin too, and eating one costs half his energy.
  • Keep away from the gate.

There are 15 levels in three stages. In stage 1 the fence just makes mushrooms grow. In stage 2, bumping it shrinks Hector. In stage 3 it's an electric fence that shrinks him and brings rain. Clear every raindrop before his energy falls below 250 for a double bonus. Below 50 he turns sickly green and an alarm sounds. A round ends at zero energy or when Hector is down to one or two sections. Any key pauses the game, and START returns to the title. "There are a few surprises left," Walters warned.

How it works

Everything is BASIC, with redefined characters and a display list interrupt (set up at line 5000) for extra colours. The playfield is a 20-column character screen, and Hector is drawn by POKEing head, body and tail characters straight into screen memory. His body is a ring buffer: the array TRACK() holds the screen address of every segment, with head and tail indexes H and T that wrap around (lines 70–85). Each move writes one new head and erases one tail, however long the snake is. Line 75 switches between two character sets on alternate moves, which animates the snake for free. Constants are kept in variables (N, N2, N6 and so on), which saves memory and lets lines such as GOTO use variable targets. If Hector is too fast for you, Walters suggested a delay loop in line 20: 20 FOR X=1 TO 100:NEXT X:IF PEEK(53279)=N6 THEN 2000. For more yellow mushrooms, change one 420 and one 430 to 440 in the ON 23*RND(0) GOTO list in line 415.

Changes from the published listing

One change, so the program also runs under Altirra BASIC, the free replacement BASIC built into many emulators. Altirra BASIC adds a command called ERASE, so it rejected the published lines that use that word as the start of a variable name. The variable is renamed everywhere in the program. The new name is the same length, so the memory layout is unchanged and the program behaves exactly as published on genuine Atari BASIC. If you type it in from the magazine, the original names work fine on a real Atari.

Published Now Lines
ERASE ERAZE 450, 470, 480, 3010

Listing

1 REM SSSNAKE
2 REM BY CHET WALTERS
3 REM (c) 1986, ANTIC PUBLISHING
10 GOTO 4000
20 IF PEEK(53279)=N6 THEN 2000
25 S=STICK(0):IF PEEK(KEY)<>TFF THEN POKE KEY,TFF:GOSUB 700
30 X=X+STX(S):IF X>ETN THEN X=ETN:GOSUB 500
35 IF X<N THEN X=N:GOSUB 500
40 Y=Y+STY(S):IF Y>20 THEN Y=20:GOSUB 500
45 IF Y<N THEN Y=N:GOSUB 500
50 NPOS=SCR+X+20*Y:BYTE=PEEK(NPOS):IF ENG<=0 THEN 70
60 IF BYTE THEN GOSUB 200
70 POKE NPOS,HEAD(S):POKE TRACK(H-N),BODY:POKE TRACK(T),TAIL:POKE TRACK(T-N),0:TRACK(H)=NPOS:TAIL=106
75 FONT=FONT+N-4*(FONT=N3):IF FONT=0 OR FONT=N2 THEN POKE CHP,CHSET+FONT
80 H=H+N:IF H>TMAX THEN H=TMIN:TRACK(H-N)=TRACK(TMAX)
85 T=T+BT:BT=N:IF T>TMAX THEN T=TMIN:TRACK(T-N)=TRACK(TMAX)
90 POKE VF,0:IF BTN>=FTN THEN BTN=FTN:GOSUB FINIS
95 IF ENG<=0 THEN S=5:GOTO THUNDER
100 IF STICK(0)=FTN THEN GOSUB 400
110 IF PEEK(BLF)>N3 THEN 20
120 POKE VF,WEAK:ENG=ENG-E-(4-FNC):IF WEAK<197 THEN GOTO 130+5*(WEAK=36)
125 IF ENG<=250 THEN WEAK=196:POKE VVD,DIS:FOR I=0 TO 75:POKE VF,I:NEXT I:POKE SNK,WEAK:POKE VVD,PUR
130 IF ENG<FTY THEN WEAK=N6*N6:POKE SNK,WEAK
135 POSITION 0,23:? #N6;ENG;" ";:POKE VF,0:GOTO 20
200 REM SCORING ROUTINE
205 POKE VF,BYTE:IF BYTE=BUG-64 THEN GOSUB 270:POKE NPOS,BYTE:GOTO 260
210 IF BYTE=BM OR BYTE=BUG THEN 265
215 IF BYTE=BODY THEN GOSUB 540:GOSUB 270:GOSUB 300:POKE SNK,WEAK:TAIL=BUG:RETURN
225 IF BYTE=TAIL THEN POKE VF,20:BT=0:BTN=BTN-(BTN>-TN):BYTES=BYTES+BYTE:BYTE=GM
230 IF BYTE=DROP THEN DRY=DRY-N:IF DRY=0 THEN POKE BLF,TRQ:GOSUB 270:POP :GOTO 600
235 IF BYTE=GM THEN POKE BLF,BLU:POKE DLC,GRN:POKE SNK,WEAK:POKE SHT,TRQ
240 BYTES=BYTES+BYTE+E:POSITION 12,23:? #N6;BYTES;" ";
250 IF BYTES>FS THEN FS=FS+9999:GOSUB 270:GOTO 900
255 RETURN
260 POKE VVD,DIS:FOR I=N TO 100:POKE VF,I:POKE VF,GM:POKE SHT,I:NEXT I:ENG=INT(ENG/N2):POKE VVD,PUR
265 POKE BLF,RED:POKE DLC,RED:GOSUB 400:BT=BT+(FNC<N2):BTN=BTN+(FNC<N2):TAIL=BYTE:POKE BLF,N2:RETURN
270 POKE NPOS,HEAD(S):POKE TRACK(H-N),BODY:RETURN
300 REM MAKE IT 300
305 POKE 77,0:GOSUB 400:POKE VVD,DIS:FOR I=0 TO FNC+TN-DIFF:SETCOLOR 3,PEEK(20),N6
310 B=PEEK(R):POKE VF,B:A=SCR+393*RND(0)+TT:IF PEEK(A) THEN 310
315 IF BYTE=BODY THEN POKE SNK,RED
320 POKE VF,0:POKE A,DROP:DRY=DRY+N:NEXT I:IF CLEAN THEN SETCOLOR 4,B,4
325 POKE VVD,PUR:ENG=ENG-5:IF PEEK(DLC) THEN POSITION 0,TT+N:? #N6;ENG;" ";
400 REM PUT IN SOME HAZARDS
410 POKE VF,30:A=SCR+418*RND(0)+19:IF PEEK(A)=N3 OR PEEK(A)=DROP THEN 410
415 ON 23*RND(0) GOTO 430,420,450,440,470,430,420,460,430,440,440,430,470,440,460,440,470,480,470,420,440,460
420 POKE A,WRM:RETURN
430 POKE A,BM:RETURN
440 POKE A,GM:RETURN
450 ERAZE=SCR+418:POKE ERAZE,TAIL:RETURN
460 POKE A,BUG:RETURN
470 POKE ERAZE,BUG-64:RETURN
480 ERAZE=A:POKE A,TAIL:RETURN
500 REM HIT FENCE AND END CHECK
510 IF ENG<=0 OR NPOS>SCR+419-FONT THEN GOSUB FINIS+CLEAN:ENG=0:POKE NPOS,0:GOTO 545
520 IF WEAK=N6*N6 OR STICK(0)=FTN THEN RETURN
525 IF FNC THEN POKE VF,200:POKE NPOS,0:GOSUB 400:GOTO 530+TN*FNC
530 POKE VVD,DIS:FOR I=N TO TN:POKE SNK,14:POKE SNK,0:POKE VF,70:NEXT I:GOSUB 300:POKE VF,0
540 BTN=BTN+N:BT=N2:TAIL=BM
545 B=PEEK(R):POKE VF,B:SETCOLOR 1,B,N8:IF Y=20 AND X=ETN THEN OVER=OVER+N:GOTO 560
550 POKE VF,0:POKE VVD,PUR:RETURN
560 IF OVER>42-BTN THEN OVER=0:FS1=FS1+CLEAN:POKE SHT,TRQ:GOTO 570
565 RETURN
570 FS1=FS1-N*(FS1>N):IF FS1=N THEN POKE VVD,PUR:FOR I=N TO 200:POKE VF,I:POKE VF,I+TN
571 POKE BLF,I:NEXT I:GOTO 2000
575 FS$(LEN(FS$)+CLEAN)="":IF  NOT DIFF AND FNC=N THEN PRESS=26:GOTO 595
580 IF  NOT DIFF AND FNC=N2 THEN PRESS=30:GOTO 595
581 IF  NOT (FNC OR DIFF) AND CLEAN THEN POKE DLC,0:GOTO 1010
585 GOTO 3000
590 BOP=BOP+DBL*(ENG+(10*FTN-BTN)):BYTES=BYTES+BOP:FINIS=591:ENG=0
591 RETURN
592 RETURN
595 POKE DL+24,132:POSITION 0,0:? #N6;"{CLEAR}";:GOTO 2065
600 REM ATE ALL RAINDROPS BONUS
605 GOSUB FINIS:IF WEAK>197 THEN DBL=N2:GOTO 670
610 DIS=PUR:POKE DLC,0:SNK=SKR:FOR CLEAN=FTN TO N2 STEP -N:GOSUB 300:NEXT CLEAN:POKE DLC,GRN
615 DIS=202:GOSUB THUNDER:POKE BAK,0:POKE BLF,BLU:POKE CHP,CHSET:SNK=711:POKE SKR,20*N2
620 FOR I=SCR TO SCR+439:POKE VF,PEEK(I)+TN:POKE SHT,PEEK(20)
625 BOP=BOP+E+(INT(PEEK(I)/N6))*DBL:POSITION FTN,TT:? #N6;BOP;
630 IF PEEK(I) THEN POKE I,N8*RND(0)+97
640 POKE VF,0:NEXT I:BYTES=BYTES+BOP:POSITION TN+N,20+N3:? #N6;"       ";
650 POKE DLC,GRN:DIFF=DIFF-N*(DIFF>0):POKE SHT,200+N2:BODY=TAIL
660 FOR I=230 TO TN STEP -N6:POKE VF,I+FTN:POKE VF,I+TN:POKE VF,I:NEXT I:GOSUB 240:GOTO 30
670 FOR I=230 TO TN STEP -N6:POKE VF,I+FTN:POKE VF,I+TN:POKE VF,I:NEXT I
680 POSITION 0,TT+N:? #N6;"   double bonus{CTRL-A}{CTRL-A}{CTRL-A}{CTRL-A}d";:POKE VVD,DIS:WEAK=197:FOR I=N TO FTY:NEXT I:REM >CNTRL<"A"
685 FOR I=150 TO 0 STEP -N:POKE VF,I+TN:POKE VF,I:POKE SHT,I:NEXT I
690 POKE SHT,TRQ:GOTO 610
700 REM PAUSE ROUTINE
710 POKE VF,0:I=PEEK(DLC):POKE DLC,0:POKE DL+26,134
720 POSITION 0,TT:? #N6;"   press trigger ";
730 IF STRIG(0) THEN POSITION N3,TT:? #6;"{inv}PRESS TRIGGER{/inv}":GOTO 720
740 POSITION N3,TT:? #N6;"             ";:POKE DLC,I:POKE DL+26,N6:POKE 77,0:POSITION 0,TT:? #N6;FS$;
750 POKE KEY,TFF:RETURN
800 REM {inv} ROUND OVER, MAKE THUNDER {/inv}
810 GOSUB FINIS:GOSUB 250:THUNDER=30:POKE DL+26,134:POSITION 0,TT:? #N6;"LIVES ";FS1-N2+CLEAN;
815 ? #N6;" BONUS ";ABS(BOP):? #N6;"     BYTES ";BYTES;" ";:IF CLEAN THEN 850
820 POKE DLC,RED:POKE 20,0:POKE VVD,DIS1:FOR I=N TO 30:POKE BAK,PEEK(R):POKE VF,PEEK(20):NEXT I:POKE VVD,DIS
825 FOR I=175 TO 200:POKE VF,55*RND(0)+I:SOUND N,PEEK(20),N8,TN:SOUND N2,I+50,N8,TN:POKE VVD,DIS1
830 POKE VF,TFF:POKE BAK,PEEK(R):NEXT I:POKE BAK,0:POKE 20,RED:FOR I=100 TO O STEP -0.5:POKE VF,PEEK(20)
835 POKE BLF,I:POKE VVD,I:POKE BLF,BLU:NEXT I:POKE VVD,DIS:FOR I=N TO N3:SOUND I,0,0,0:POKE VF,PEEK(20):NEXT I
840 POKE VF,0:GOTO 30
850 POKE SKR,40:POKE BAK,0:FOR I=SCR+448 TO SCR+459:POKE I,75*(I<SCR+457):FOR DLY=0 TO TN:POKE VF,PEEK(20)
855 NEXT DLY:POKE 20,PEEK(R):NEXT I:POSITION 9,TT:? #N6;"bonus{CTRL-K}  ";:RETURN :REM >CNTRL<"K"
900 REM FREE SNAKE ROUTINE
910 FS1=FS1+N:IF FS1>TN THEN FS1=TN:GOTO 950
915 POSITION 0,TT:? #N6,"        ";:POKE SCR+458,0:POKE VVD,PUR
920 FOR I=80 TO 61 STEP -N:POKE VF,I:ROT=PEEK(SKR):POKE SKR,PEEK(SHT):FOR DLY=N TO N2:POKE VF,PEEK(20)
925 NEXT DLY:POKE SHT,PEEK(BLF):POKE BLF,PEEK(SNK):POKE SNK,PEEK(DLC):POKE DLC,ROT:NEXT I:POKE VF,0
930 FS$(LEN(FS$)+N)="d":POSITION 0,TT:? #N6;FS$:IF CLEAN THEN POSITION 0,TT:? #N6;"    free snake{CTRL-A}{CTRL-A}{CTRL-A}{CTRL-A}";
940 RETURN :REM >CNTRL<"A"
950 IF CLEAN THEN FOR I=THD TO 0 STEP -N3:POKE VF,I:NEXT I
955 POKE VF,0:POSITION 0,TT:? #6;"maximum {CTRL-Y} lives";:RETURN
960 FOR ST=0 TO TN:FOR I=0 TO TFF STEP 64:POKE SCR+448,36+I:POKE VF,I:NEXT I:NEXT ST
970 RETURN
1000 REM COMPLETED LEVELS BONUS
1010 E=E+N2*(E<20):BOP=E*250:BYTES=BYTES+BOP:POKE DL+N8,134:? #N6;"{CLEAR}"
1011 POSITION N2,N6:? #6;"{inv}congratulations{/inv}":POKE 85,N8:? #N6;"you"
1015 POKE VF,PEEK(20):POKE 85,N6:? #6;"made it":POSITION N6,20:? #N6;BYTES:? #N6:? #6;"   {inv}press trigger{/inv}"
1016 POSITION 5,12:? #N6;"bonus ";BOP:POKE SCR+RND(I)*400,10
1020 POKE SHT,PEEK(20):POKE VF,PEEK(R):IF STRIG(0) THEN 1011
1025 POKE DL+N8,N6:PRESS=26:POKE SHT,BLU:GOTO 595
2000 REM NEW GAME & TITLE ROUTINE
2005 POP :SCR=PEEK(88)+TFX*PEEK(89):FNC=0:CLEAN=0:ENG=250:E=0:POKE SHT,TRQ
2010 FS$=" dd":FS=9999:FS1=4:DIFF=TN-N3:POSITION 0,0:POKE SNK,GRN+N6:POKE DLC,0:POKE BAK,0
2015 POKE DL+24,134:POKE 16,64:POKE 53774,64:POKE BLF,BLU:POKE CHP,CHSET+N2:IF BYTES>HI THEN HI=BYTES
2020 ? #N6;"{CLEAR}":IF BYTES THEN POSITION 0,TT:? #N6;"hi score     bytes":? #N6;HI:POSITION TN+N3,TT+N:? #N6;BYTES;
2025 FOR I=1561 TO 1757 STEP N2:COLOR ASC("e"):PLOT PEEK(I-N),PEEK(I):COLOR ASC("{inv}i{/inv}"):PLOT PEEK(I-N3),PEEK(I-N2)
2030 IF I>1746 THEN COLOR ASC("j"):PLOT PEEK(I-187),PEEK(I-186):A=SCR+128:POKE VF,GM:POKE A,WRM:POKE A+2,BM
2035 IF I>1748 THEN COLOR 0:PLOT PEEK(I-189),PEEK(I-188):PLOT 0,0:POKE A+20,GM:POKE VF,BM:POKE A+TT,BUG
2040 POKE VF,PEEK(I)+N8:NEXT I:GOSUB 300:POSITION N,20+N:? #N6;"{inv}HIT KEY>{/inv} 1 2 {inv}OR{/inv} 3";
2045 RESTORE 5105:FOR I=N TO 500:PRESS=PEEK(KEY):IF PRESS<>TFF THEN POP :BYTES=0:POSITION 0,20:GOTO 2065
2050 FONT=FONT+N:IF FONT>N3 THEN FONT=-N:POSITION 0,20:? #N6;"choose  entry stage";:READ A:POKE VF,A+N8
2055 IF FONT=0 OR FONT=N2 THEN POSITION 0,20:? #N6;"{inv}CHOOSE  ENTRY STAGE{/inv}";:POKE VF,0:POKE CHP,CHSET+FONT
2060 NEXT I:GOTO 2020
2065 ? #6;"                   ";:POSITION 0,20+N2:? #6;"                   ";:POSITION N,20+N:POKE DLC,0
2070 POKE KEY,TFF:IF PRESS=31 THEN FNC=N2:? #N6;"  {inv}HARMLESS FENCE{/inv}  ";:GOTO 2090
2075 IF PRESS=30 THEN FNC=N:? #N6;" {inv}SHRINKING SNAKE!{/inv} ";:GOTO 2090
2080 IF PRESS=26 THEN FNC=0:? #N6;"{inv}FENCE ELECTRIFIED!{/inv}";:GOTO 2090
2085 ? #N6;"hit only 1 2 or 3  ";:POKE DLC,RED:FOR I=N TO 20:POKE VF,PEEK(20):NEXT I:POKE DLC,0:GOTO 2045
2090 FOR I=TFF TO 0 STEP -N:POKE VF,I:POKE VF,PEEK(20):POKE BLF,I:NEXT I:POKE DL+24,N6:DIFF=N6-N
3000 REM DRAW FENCE AND GO
3010 H=20:T=4:BTN=0:DRY=0:CLEAN=0:BOP=0:THUNDER=800:ERAZE=SCR+418:POKE BLF,TRQ:POKE DLC,0:POKE 84,0:? #6;"{CLEAR}"
3015 COLOR 35:PLOT 0,0:DRAWTO 20-N,0:DRAWTO 20-N,20:PLOT 20-N3,20+N:DRAWTO 0,20+N:DRAWTO O,0:POKE VVD,PUR
3020 POKE DL+26,N6:POSITION 0,TT:? #6;FS$:POKE 85,(DIFF>N):? #6;" {inv}STAGE>{/inv}";N3-FNC;" {inv}LEVEL>>>L{/inv}";N6-DIFF;
3025 POKE 20,0:FOR I=SCR+TT TO SCR+400 STEP 24:FOR A=N TO N8:POKE VF,PEEK(20):NEXT A:POKE VF,DROP
3030 POKE I,BM:NEXT I:POKE BLF,BLU:FOR ST=N TO N8-FNC:GOSUB 300:NEXT ST:ENG=250+5*(5-DIFF)+FTY*(3-FNC)
3035 FOR I=0 TO TN-DIFF:POKE VF,PEEK(R):GOSUB 400:NEXT I:POSITION 0,TT+N:? #N6;ENG;"   BYTES ";BYTES;" ";
3040 FOR I=100 TO 0 STEP -N:TRACK(I)=SCR+21:POKE VF,I+TN:POKE VF,I:NEXT I:POKE VF,TN:WEAK=GRN+N6:POKE SNK,WEAK
3045 POKE DLC,GRN:POKE TRACK(1),0:X=0:Y=0:DBL=N:S=5:FINIS=590:BODY=233:POKE SCR,N3+64*FNC:GOTO 30
4000 REM ONE-TIME INITIALIZATIONS
4005 N=1:N2=2:N3=3:N6=6:N8=8:TN=10:FTN=15:ETN=18:TT=22:FTY=50:THD=200:TFF=255:TFX=256
4010 RED=48:BLU=150:GRN=194:TRQ=202:DLC=1546:DROP=12:BM=171:BUG=172:WRM=60:GM=50
4015 TMAX=100:TMIN=N:DIM FS$(20),HEAD(FTN),TRACK(100):HEAD(14)=97:HEAD(6)=98:HEAD(7)=99:HEAD(5)=100:HEAD(13)=101
4020 HEAD(9)=102:HEAD(11)=103:HEAD(TN)=104:HEAD(FTN)=100:BODY=233:TAIL=106
4025 DIM STX(FTN):STX(14)=0:STX(13)=0:STX(9)=-N:STX(TN)=-N:STX(11)=-N:STX(5)=N:STX(FTN)=N:STX(6)=N:STX(7)=N
4030 DIM STY(FTN):STY(11)=0:STY(7)=0:STY(6)=-N:STY(TN)=-N:STY(14)=-N:STY(5)=N:STY(FTN)=N:STY(9)=N:STY(13)=N
4035 KEY=764:CHP=756:SKR=708:SHT=709:BLF=710:SNK=711:BAK=712:R=53770:VF=53760:VVD=53761:PUR=170:DIS=202:DIS1=138
5000 REM SET UP DLI & REDEFINED CHARACTERS
5010 POKE 106,PEEK(740)-5:GRAPHICS 18:CHSET=(PEEK(106)+N)*TFX
5015 POSITION 4,N2:? #N6;"{inv}ssssnake{CTRL-A}{CTRL-A}{CTRL-A}{CTRL-A}{/inv}":REM INVERS >CNTRL< "A"
5020 POSITION N8,4:? #N6;"{inv}BY{/inv}":POSITION 4,N6:? #N6;"chet walters":POSITION 5,N8:? #N6;"FOR ANTIC":POKE BAK,RED
5025 FOR I=1536 TO 1551:READ Y:POKE I,Y:NEXT I:POKE VVD,PUR
5030 FOR I=1557 TO 1758:READ Y:POKE I,Y:POKE VF,Y:SOUND N,PEEK(R),TN,TN:POKE SNK,Y:NEXT I
5035 RESTORE 5110
5040 READ X:X=X*N8:IF X<0 THEN POKE VF,0:SOUND N,0,0,0:GRAPHICS 17:GOTO 5075
5050 FOR Y=0 TO 7:READ A:SOUND 0,A,TN,TN:SOUND N,PEEK(R),TN,TN:POKE CHSET+X+Y,A:POKE SNK,A:NEXT Y:GOTO 5040
5075 DL=PEEK(560)+TFX*PEEK(561):POKE DL+27,134:POKE 512,0:POKE 513,N6
5080 POKE 54286,192:CHSET=CHSET/TFX:GOTO 2000
5100 REM DL SERVICE ROUTINE
5101 DATA 72,169,224,141,10,212,141,9,212,169,0,141,26,208,104,64
5102 REM START DISPLAY & TRACK DATA
5103 DATA 0,0,0,0,1,1,2,2,3,3,4,4,4,4,3,3,2,2,2,1,3,1,4,1,5,1,6,1,7,2,8,3,8,4,9,4,10,4,11,4,12,4,13,4,14,4,15,3
5104 DATA 16,2,16,1,15,1,14,1,15,5,12,6,13,6,14,6,15,6,16,6,15,6,14,6,13,6,12,7,11,8,12,8,13,8,14,8,15,8,16,9,16
5105 DATA 10,15,10,14,10,13,11,12,12,12,13,13,13,14,13,15,12,16,11,16,10,15,11,16,12,16,13,15,13,16,14,14,14,13
5106 DATA 14,12,14,11,14,10,14,9,14,8,14,7,14,6,14,7,14,8,14,9,14,10,14,11,14,12,14,13
5107 DATA 14,14,14,15,14,16,15,12,16,12,17,13,17,14,16,14,15,14
5108 DATA 16,15,16,16,17,16,18,16,19,15,19,14,19,13,19,12,18,12,18,12,18,13,18,14,18,15,18,16,18,17,18,18,18,19
5109 REM CHARACTER SET DATA
5110 DATA 0,0,0,0,0,0,0,0,0
5111 DATA 64,0,0,0,0,0,0,0,0
5112 DATA 60,0,0,4,142,122,49,0,0
5113 DATA 124,0,0,33,58,76,140,0,0
5114 DATA 43,60,110,118,255,24,24,0,0
5115 DATA 107,60,110,118,255,24,24,0,0
5116 DATA 50,0,0,16,56,124,246,56,56
5117 DATA 114,0,0,16,56,124,246,56,56
5118 DATA 12,0,0,0,0,32,48,48,0
5119 DATA 76,0,0,0,0,32,48,48,0
5120 DATA 44,34,34,54,93,42,62,127,62
5121 DATA 108,28,20,20,93,42,62,127,62
5122 DATA 97,36,24,24,60,90,255,255,126
5123 DATA 33,0,0,24,60,90,255,255,126
5124 DATA 98,0,60,110,126,122,62,28,0
5125 DATA 34,2,63,110,126,122,62,28,0
5126 DATA 99,96,240,233,254,254,233,240,96
5127 DATA 35,96,240,232,252,252,232,240,96
5128 DATA 100,0,28,62,122,126,110,63,2
5129 DATA 36,0,28,62,122,126,110,60,0
5130 DATA 101,126,255,255,90,60,24,24,36
5131 DATA 37,126,255,255,90,60,24,0,0
5132 DATA 102,0,56,124,94,126,118,60,0
5133 DATA 38,0,56,124,94,126,118,252,64
5134 DATA 103,6,15,151,127,127,151,15,6
5135 DATA 39,6,15,23,63,63,23,15,6
5136 DATA 40,64,252,118,126,94,124,56,0
5137 DATA 104,0,60,118,126,94,124,56,0
5138 DATA 41,24,60,90,231,231,90,60,24
5139 DATA 105,24,60,90,231,231,90,60,24
5140 DATA 42,24,60,90,231,231,90,60,24
5141 DATA 106,0,24,36,90,90,36,24,0
5142 DATA 3,102,102,255,102,102,255,102,102
5143 DATA 67,102,102,255,102,102,255,102,102
5199 DATA -1

Download

The original program from the Antic disk, to LOAD or ENTER instead of typing it: SNAKE.BAS.

Credits