
[ESC] = quit
[F2] = load
[F3] = save
Download right click and save as: c64.bas
A little bit about the C64 BASIC
first all what you type on the C64 are in upper case
print "hello"
are
PRINT "HELLO"
In "direct mode"
BASIC commands can be typed and are directly executed after you press [enter]
command[:command][enter]
Example: show the number of free bytes for BASIC in direct mode
PRINT FRE(0)+65536[enter]
In "program mode"
BASIC commands are entered after a line number and stored in BASIC memory
number command [: command]
Example: print the numbers 1-10
10 FOR I=1 to 10
20 PRINT I
30 NEXT I
RUN[enter]
A BASIC program can be "list"ed
LIST[enter]
many commands have a shortcut
for example RUN or LIST
R[shift]+U
L[shift]+I
If your C64 BASIC program are longer than the screen
you can "list" only program lines you are looking for:
list 20
20 PRINT I
list -20
10 FOR I=1 to 10
20 PRINT I
list 20-
20 PRINT I
30 NEXT I
list 10-20
10 FOR I=1 to 10
20 PRINT I
In C64 BASIC you don't have label's or sub's
you jump from current executed line to another with:
goto linenumber
or you jump to a sub routine with:
gosub linenumber
the end of a sub routine must be marked with:
return
here are a short gosub example
10 print "line 10"
20 gosub 100
30 print "line 30"
40 end
100 print "line 100"
110 return
This mini C64 emulator I wrote in one night
has no fancy sprites or sound but you can
create fumy games with the famous Commodore font chars
the chars and colors can be poked directly in the video and color ram.
All about the C64 BASIC commands !
german:
https://www.c64-wiki.de/wiki/BASIC
english:
https://www.c64-wiki.com/wiki/BASIC
Joshy