No Internet (Commodore VIC 20) by Huffelduff
A downloadable game
Title: No Internet
Platform: Unexpanded Commodore VIC-20
Video: PAL/NTSC
Interface: Keyboard only (spacebar = jump)
Game type: Arcade
Written by: E W de Villiers
Released: 14 March 2024
The Plot:
---------
This game is based upon the dinosaur jumping over cacti game which one gets in the web browser Google Chrome which can be played when there is no internet connection available.
In the past three weeks or so I've seen another version for an 8-bit platform being released and so here is the Vic-20 version.
Mechanics:
----------
jump = spacebar
press any keyboard key to restart the game
Every time you jump a point is deducted. If you hit a cactus or your score goes to zero the game ends.
Greetings
Huffelduff (User handle on the VIC-20 Denial forum)
'NO INTERNET' SOURCE CODE:
-------------------------------------------------------------------------------- <- 80 Character line limit 0 v=36864:fOi=0to31:rEd:pO7168+i,d:pO7424+i,0:nE:pOv+5,255:pOv+14,15:pOv+15,8 1 ?cH(5);cH(147);cH(18):fOi=3to11:pO7947+i,2:nE:y2=7932:y3=y2:a=1:df=0 2 i=pE(197):?cH(19);cH(18);spc(6);"s:";a;cH(157);" ":a=a+1+2*(i=32):y4=y3 3 y3=y2+(22*(i=32)):ca=32-(29*int(rN(0)*(1.1+df))):df=df+0.001:pO7935,ca 4 fOi=0to2:pO7928+i,pE(7929+i):nE:pOy4,32:pO7931,pE(7932):pO7932,pE(7933) 5 cd=pE(y3):pOy3,(aaN1):fOi=2to5:pO7931+i,pE(7932+i):nE:if(cd<>3)aN(a>=0)then2 6 h=(a*-1*(a>=h))+(h*-1*(a<h)):?cH(19);cH(18);cH(17);spc(6);"h:";h-1 7 ?cH(19):fOi=1to14:?spc(22);:nE:?spc(2);cH(18);"still no internet!":dA 30,94 8 fOi=50to0step-1:pOv+10,200+i:nE:pOv+10,0:wA197,64,64:gO1:dA 152,152,190,250,88 9 dA 36,30,94,152,152,190,250,112,24,255,0,0,0,0,0,0,0,0,8,24,26,90,94,120,24 -------------------------------------------------------------------------------- <- 80 Character line limit
Variables used within the program:
----------------------------------
v = start of the VIC chip registers
a = score
h = hi score
y2 = player (dino) start location
y3 = player location jumping or not
y4 = old player location
cd = collision detection variable
ca = cactus or blank character for rightmost character
df = difficulty
i = general purpose (for loops and such)
--------------------------------------------------------------------------------
Analysis:
---------
LINE: 0 v=36864:fOi=0to31:rEd:pO7168+i,d:pO7424+i,0:nE:pOv+5,255:pOv+14,15:pOv+15,8
----
fOi=0to31:rEd:pO7168+i,d:pO7424+i,0:nE - load the 4 custom characters into the start of character memory and load four blank character into character position 32 (space) and on
- only one blank character (32) is needed but because only one 'for' loop is used four characters are blanked
pOv+5,255 - change the screen character memory location
pOv+14,15 - set the sound volume to full (15)
pOv+15,8 - set black border and black background
--------------------------------------------------------------------------------
LINE: 1 ?cH(5);cH(147);cH(18):fOi=3to11:pO7947+i,2:nE:y2=7932:y3=y2:a=1:df=0
----
?cH(5);cH(147);cH(18):fOi=3to11:pO7947+i,2nE - print color to white, clear screen, inverse characters, draw the ground line
y2=7932:y3=y2:a=1:df=0 - initialize some variables
--------------------------------------------------------------------------------
Core loop: line 2 to 5
----------------------
LINE: 2 i=pE(197):?cH(19);cH(18);spc(6);"s:";a;cH(157);" ":a=a+1+2*(i=32):y4=y3
----
i=pE(197) - get keyboard input
?cH(19);cH(18);spc(6);"s:";a;cH(157);" " - draw score line
a=a+1+2*(i=32) - update score by adding one, if jumping subtract one
y4=y3 - store old player position
LINE: 3 y3=y2+(22*(i=32)):ca=32-(29*int(rN(0)*(1.1+df))):df=df+0.001:pO7935,ca
----
y3=y2+(22*(i=32)) - update player location jumping or not
ca=32-(29*int(rN(0)*(1.1+df))) - generate a cactus or a blank as rightmost character
df=df+0.001 - increase difficulty
pO7935,ca - draw the rightmost character
LINE: 4 fOi=0to2:pO7928+i,pE(7929+i):nE:pOy4,32:pO7931,pE(7932):pO7932,pE(7933)
-----
fOi=0to2:pO7928+i,pE(7929+i):nE - scroll the characters left of the dino
pOy4,32 - draw a blank over old dino position
pO7931,pE(7932):pO7932,pE(7933) - scroll from dino one left, scroll from one right of dino to dino
LINE: 5 cd=pE(y3):pOy3,(aaN1):fOi=2to5:pO7931+i,pE(7932+i):nE:if(cd<>3)aN(a>=0)then2
----
cd=pE(y3):pOy3,(aaN1) - store collision detection value, draw the player character
fOi=2to5:pO7931+i,pE(7932+i):nE - scroll the characters right of the dino
if(cd<>3)aN(a>=0)then2 - if no cactus has been hit or the score is not less than 0 loop back to 2, else drop through for game over
--------------------------------------------------------------------------------
LINE: 6 h=(a*-1*(a>=h))+(h*-1*(a<h)):?cH(19);cH(18);cH(17);spc(6);"h:";h-1
----
- update the high score and then display it
--------------------------------------------------------------------------------
LINE: 7 ?cH(19):fOi=1to14:?spc(22);:nE:?spc(2);cH(18);"still no internet!":dA 30,94
- display "still no internet"
- start of character data
--------------------------------------------------------------------------------
LINE: 8 fOi=50to0step-1:pOv+10,200+i:nE:pOv+10,0:wA197,64,64:gO1:dA 152,152,190,250,88
fOi=50to0step-1:pOv+10,200+i:nE - game over sound
wA197,64,64 - wait for a keypress
dA 152,152,190,250,88 - character data
--------------------------------------------------------------------------------
LINE: 9 dA 36,30,94,152,152,190,250,112,24,255,0,0,0,0,0,0,0,0,8,24,26,90,94,120,24
- character data
--------------------------------------------------------------------------------
Status | Released |
Rating | Rated 3.0 out of 5 stars (1 total ratings) |
Author | BASIC 10Liner |
Genre | Action |
Tags | 10liner, 8-Bit, basic, Commodore 64, VIC-20 |
Download
Install instructions
Loading:
--------
Real unexpanded VIC-20 with a tape system:
1. Type load and then press return 2. Type run and then press return
Real unexpanded VIC-20 with a disk system:
1. Type load "*",8 and then press return 2. Type run and then press return
On an emulator:
Copy the source code in this document and paste it into an opened VIC emulator with no expansion RAM. Then in the emulator type run and then press enter. OR
Drag and drop the noint.prg file into an opened VICE emulator.
Comments
Log in with itch.io to leave a comment.
Greetings Huffelduff,
we hope you are doing great. I am Areeba (aka Titania) from the BrewOtaku-Team, we are launching BrewOtaku #002 - The Homebrew Gaming Magazine soon.
We loved your work and we have featured "No Internet” in it. Kindly share your contact details so we can share it with you. You are anyhow free to share this on your social media channels or homepage.
We look forward to hearing from you soon.
Kind regards
Titania
Hi Titania,
I've only seen your message now because this game is published on the 10 liner competition page. Anyhow thank you for featuring my basic 10 liner in your mag. If you want to check out more of my stuff I publish all my VIC-20 software on my itch page.
Thanks again
H
P.S. I hang out at the Vic-20 Denial forum.
Thank you for the writeup.
Greetings
H
Sure thing. If you make something new, let us know. We have followed you on itch.io just in case anyway :