-
Notifications
You must be signed in to change notification settings - Fork 3
Automatic line numbering
Line numbering in Retro Rocket BASIC is an all-or-nothing affair. Retro Rocket will examine your program when it loads it, and if the first character is a digit, the program is assumed to be line numbered. The line numbers you specify will be used without any adjustment, this will effectively enable use of GOTO
and GOSUB
in your program.
If the first character of your program is not a digit, the program is assumed to not have line numbers, and the interpreter will automatically number the lines for you starting at 10 with increments of 10. It is important to note that in this case, although you could still use GOTO
and GOSUB
it would be much more difficult in this scenario as you have to figure out the line numbers using your editor. As GOTO
and GOSUB
are discouraged anyway, and there are better alternatives such as FOR
, REPEAT
, PROC
and FN
, there are very few situations where GOTO
or GOSUB
are required in your program.
(C) Brainbox.cc 2010-2023
- Home
- Builtin Commands
- Included Programs
-
Creating BASIC programs
- Automatic line numbering
- Variable Naming
- Builtin Variables
- Variable Types
- Builtin Variables
- Parameter types
-
Statements
- BACKGROUND
- CALL
- CHAIN
- CHDIR
- CIRCLE
- CLOSE
- CLS
- COLOUR/COLOR
- CONNECT
- CURSOR
- DEF
- DIM
- ELSE
- END
- ENDIF
- EVAL
- FN
- FOR
- GCOL
- GLOBAL
- GOSUB
- GOTO
- IF
- INPUT
- LET
- LIBRARY
- LINE
- LOCAL
- NEXT
- PLOT
- POINT
- POP
- PROC
- PUSH
- RECTANGLE
- REDIM
- REM
- REPEAT
- RETURN
- SETVARI
- SETVARR
- SETVARS
- SPRITELOAD
- SPRITEFREE
- SOCKCLOSE
- SOCKREAD
- SOCKWRITE
- TRIANGLE
- UNTIL
- WRITE
- YIELD
-
Builtin Functions
-
Integer Functions
- ABS
- ASC
- CHR
- CPUID
- CURRENTX
- CURRENTY
- EOF
- EXISTSVARI
- EXISTSVARR
- EXISTSVARS
- GETNAMECOUNT
- GETPROCCOUNT
- GETPROCCPUID
- GETPROCID
- GETPROCPARENT
- GETSIZE
- GETVARI
- HEXVAL
- INSTR
- LCPUID
- LGETLASTCPUID
- LEN
- MEMFREE
- MEMORY
- MEMUSED
- OCTVAL
- OPENIN
- OPENOUT
- OPENUP
- RADIX
- RGB
- RND
- SHL
- SHR
- SOCKCLOSE
- SOCKREAD
- SOCKSTATUS
- TERMHEIGHT
- TERMWIDTH
- VAL
- String Functions
- Real Functions
-
Integer Functions
- System Libraries