Skip to content

Instantly share code, notes, and snippets.

@tomaes tomaes/fluffy.bas
Created May 19, 2019

Embed
What would you like to do?
10 REM フワフワ GW-BASIC port /w sound
11 CLS: RANDOMIZE TIMER
12 XM=80: YM=24: X=XM/2: Y=1: OC=239: L=30
14 B=INT(RND*(XM-L*2))+L: SOUND 200,.5
15 UP=0: L=30-S/10: IF L<1 THEN L=1
16 LOCATE YM,B: PRINT CHR$(OC)
17 A$=INKEY$: X=X+(A$="a")-(A$="s")
18 IF SCREEN(Y+1,X)=OC THEN Y=Y+1: SOUND 800,1
19 IF SCREEN(Y,X)=OC THEN GOSUB 40 ELSE Y=Y+1
20 IF X<1 OR X>XM OR Y<1 OR Y>YM THEN 30
22 LOCATE Y,X: PRINT CHR$(1+UP);: S=S+1
24 T=TIMER: WHILE TIMER < T+.2: WEND
26 LOCATE Y,X: PRINT CHR$(249): GOTO 14
30 LOCATE YM,1: PRINT "SCORE:";S: BEEP: END
40 Y=Y-1: UP=1: SOUND 600-Y*20,1: RETURN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.