Soli Pong (C16) by Haegar of Synergy
A downloadable game
SOLI-PONG by Haegar of Synergy 2023
Commodore Basic 3.5 - Commodore C16/C116/plus4
The Game
-----------------------------
Soli-Pong is a small 10 line game in basic for 1 Players. You control your racket with the key a = up and z = down.
Try to keep the pong in the field with the racket as long as possible. If you fail, you lose a life. You have 5 lives in total.
Good luck
Variabelen
--------------
P = Y position racket
X = X position Pong
Y = Y position Pong
V = previous X position Pong
W = previous Y position Pong
A = X drirection Pong
B = Y drirection Pong
C = collision query
K = lives
R = field construction
T$ = query buttons
TI$ = Timer
line
--------------------------------------------------------------------------------------------
0 P=4:SCNCLR:Y=2:A=1:B=1:W=0:COLOR0,1:COLOR4,1:VOL6:TI$="000000":K=5
Clear Sreen, Set Frame and Background Color, Set Var., set volume
1 PRINT"× SOLI-PONG BY HAEGARÁ‘":PRINT"UDHDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDI
Print Headline and Top field
2 R=R+1:PRINT"B H":IFR<19THENGOTO2
Print flied
3 PRINT"JFHFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFK":X=INT(RND(1)*10)+5:Y=INT(RND(1)*10)+5
Print Botton field, random x and y Start Position of Pong
4 X=X+A:Y=Y+B:IFX>35THENA=-1:ELSEIFY>20THENB=-1:ELSEIFX<2THENA=1:K=K-1:ELSEIFY<4THENB=1
Note old position, Change of direction at the end of the field, if the ponk is behind the racket, a life is deducted
5 IFK=0THENEND:ELSEC=PEEK(3072+X+(Y*40)):IFC=72THENA=1:SOUND1,300,20
No lives = End, Collision with racket, change of direction and make sound
6 CHAR1,V,W," ":CHAR1,X,Y,"Q":V=X:W=Y:GETT$:IFT$="Z"GOTO8:ELSEIFT$="A"GOTO9
clear old position of pong, print new position of pong, Keyboard query for racket movement
7 CHAR,2,23,"Ø":PRINT"LIVES",K,"TIME",TI$:IFP<3THENP=3:ELSEIFP>20THENP=18:ELSEGOTO4
print points and time, check racket at the top or at the buttom
8 CHAR,2,P," ":P=P+1:CHAR,2,P,"H":CHAR1,2,P+1,"H":GOTO7
move racket down
9 CHAR,2,P+1," ":P=P-1:CHAR,2,P,"H":CHAR,2,P+1,"H":GOTO7
move racket up
Code
---------------------
0 P=4:SCNCLR:Y=2:A=1:B=1:W=0:COLOR0,1:COLOR4,1:VOL6:TI$="000000":K=5 1 PRINT"× SOLI-PONG BY HAEGARÁ‘":PRINT"UDHDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDI 2 R=R+1:PRINT"B H":IFR<19THENGOTO2 3 PRINT"JFHFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFK":X=INT(RND(1)*10)+5:Y=INT(RND(1)*10)+5 4 X=X+A:Y=Y+B:IFX>35THENA=-1:ELSEIFY>20THENB=-1:ELSEIFX<2THENA=1:K=K-1:ELSEIFY<4THENB=1 5 IFK=0THENEND:ELSEC=PEEK(3072+X+(Y*40)):IFC=72THENA=1:SOUND1,300,20 6 CHAR1,V,W," ":CHAR1,X,Y,"Q":V=X:W=Y:GETT$:IFT$="Z"GOTO8:ELSEIFT$="A"GOTO9 7 CHAR,2,23,"Ø":PRINT"LIVES",K,"TIME",TI$:IFP<3THENP=3:ELSEIFP>20THENP=18:ELSEGOTO4 8 CHAR,2,P," ":P=P+1:CHAR,2,P,"H":CHAR1,2,P+1,"H":GOTO7 9 CHAR,2,P+1," ":P=P-1:CHAR,2,P,"H":CHAR,2,P+1,"H":GOTO7
Status | Released |
Author | BASIC 10Liner |
Genre | Action |
Tags | basic, basic10liner, c16, commodore, plus4 |
Development log
- Documentation updatedMar 23, 2023
Leave a comment
Log in with itch.io to leave a comment.