This is a thread for useful subroutines... in BASIC. Because I'm a glutton for nostalgic punishment.
Submissions to this library SHALL MAKE EFFORTS TO BE:
(0) One subroutine per post, just for sanity's sake. Does this make sense?
(1) Traveller-oriented. Useful for Traveller.
(2) Good citizens. Remarks will state expectations for IN variables, and note what OUT variables will be clobbered and what that data will look like.
(3) Lightly commented where needed. Because BASIC is not the best self-documenting code out there.
(4) Reasonably short.
(5) Line-number free. Labels will take the place of line numbers. I use C64List's notation for this:
But the requirement is just for it to be obvious.
Submissions to this library SHALL MAKE EFFORTS TO BE:
(0) One subroutine per post, just for sanity's sake. Does this make sense?
(1) Traveller-oriented. Useful for Traveller.
(2) Good citizens. Remarks will state expectations for IN variables, and note what OUT variables will be clobbered and what that data will look like.
(3) Lightly commented where needed. Because BASIC is not the best self-documenting code out there.
(4) Reasonably short.
(5) Line-number free. Labels will take the place of line numbers. I use C64List's notation for this:
Code:
{:Label Name}
...BASIC goes here...
GOTO {:My Other Cool Label}
... and so on...
But the requirement is just for it to be obvious.