Undocumented 8.1 commands

From Color 64 BBS Wiki

At the time of this revision for Color 64 v8.1a, there are notably several ML related commands and variables that are not documented as well as some basic shortcuts and appear to have been introduced from the 8.1 upgrade that never received any manual documentation. I find that comparing 8.0 code with 8.1 helps you along in figuring out what these undocumented items perform. Below are some of my notes and observations of what the code was in 8.0 and the observed shortcuts implemented in 8.1 Please note it is a work-in-progress and I don’t have all the answers (yet), so some of this is just “observation” without any conclusion!

Topic Found in
Branch Shortcuts √bbs.init
Example 8.0 8.1
1
2
3
4

Conclusion: “[“ and “@” are used for loops with “[“ being the starting position and “@” being the condition that will cause the function to return to the starting point of the loop. Also note in line 8220 how the “RETURN” statement moved from line 8230 up into the 8220 loop in version 8.1 (example 2), indicating that it will execute the return if a$ <> “” and a$ <> home key.

[ starts loop
@ loop condition – goes back to bracket when used after “@”, consider an “ELSE” statement in this loop (example 2)
] breaks loop condition (Example 3)
A break “]” can occur as part of an IF statement to exit prior to “@” for loop (example 4)
Topic Found in
Use of "THEN" in IF all
Example 8.0 8.1
1

Conclusion: “then” statements are not required for “if/then” – if <condition> <action> is legal

Topic Found in
.36 √bbs.init
Example 8.0 8.1
1

Conclusion: Undetermined, although notice line in 8.0 version that line 13645 has been dropped for the 8.1 variant. This command only occurs on this line in the overlays as part of the command prompt. When I dropped everything in line 13640 and just had “.36:return”, there was no box printed (of course), but the command entry functioned normally. This was also true if I just omitted everything except “return” – so I’m not sure what “.36” brings to the table.

Topic Found in
.31 and !55 √bbs.msgs
Example 8.0 8.1
1

Conclusion: Documentation originally stated “.31” was not used - but it clearly is - and may be a more-refined or customized version of inputting data from disk (.01). “!55” was undocumented and appears to be a variable replacement for “@0=<reverse n>”, where @0 is for disk-and-key input and stores a result. There are several cases where “.31” and “!55” are used in conjunction with each other.

Topic Found in
.38 / .39 / .40 / .41 and “;” variables √bbs.msgs
Example 8.0 8.1
1 (current message vs high message):
(current message vs high message):
2 (reading message):
(reading message):
3 (storing message):
(storing message):

Observation (no conclusion): This is one of the more intriguing finds and it’s a hot mess – lines 3140, 3555 and 1525 are obviously the topics of interest. I can’t tell you what’s going on here, but here are some observations from my research:

  • Example 1 is very close to Example 2, so read on….
  • Example 2 is reading a message after the user has selected a message number.
From 8.0, m=last message read, mn(.) is our message numbers array, mr%(m) tracks messages that have been read, and mn (not arrayed) is undocumented, but suspect it is “current message number”.
  • Breaking down line 3140:
You can see the loop function “[“, “@” and “]” replacing our for-next in line 3140, and in same line variable “m” is being decremented, replacing the “step -1”. “@m” appears to be our “next m” of the for next loop replacement.
Our preparation for the loop is present:
8.0 statement for m=mn(.) can be tied to 8.1 statement m=mn(.).
I suggest the following matches from line 3140 comparison:
  • 8.0 statement ifmn(m)>ithennext = 8.1 statements if;0f<=I]£ and @m
  • 8.0 statement mr%(m)=. = 8.1 statement ;1k=.
  • both of these statements are occurring inside the loop; and that covers all of the original 8.0 line of 3140.
So what are the 8.1 statements .38,0mn,1mr% and .39,fm,km doing before we enter the loop? There is no equivalent statement I can derive from 8.0. Printing the value of these parameters did not provide any insight either, although we know what mn and mr% are, and fm – if being used correctly – is word-wrap. Variable km is undefined and it is not set anywhere in the basic code of √bbs.msgs.
  • Example 3 is storing a new message and updating the message links
It appears the 8.1 version of line 1525 uses “old to new” assignments to replace the incrementation we see in the 8.0 version. The 8.1 statement .40,fgkl is a mystery, but appears to be a new ML routine to use the new assignments of the variables f, g, k, and l that occurred on the same line.
  • Examples 1 & 2 appear to use different subject parameter for parameter #2 in the .38 function. Example 1 shows .38 receiving last message read as parameter 1 and category as parameter 2. Example 2 shows message number as parameter 1 and .38 is taking two parameters: “0mr%” and “1ca%” separated by a comma
Topic Found in
£if √bbs.msgs
Example 8.0 8.1
1

Observation: Observe the 8.1 authors reversed the checks in variable comparisons as the conditions, with end-result being the same.

Conclusion: Serves as an “and not” function

“(lv is not less than cm%(2,2) and lv not less than cm%(29,2) and fr does not equal 1, then print (P)rivate)”

Topic Found in
@ √bbs.msgs
Example 8.0 8.1
1

Conclusion: Can serve as an “if” keyword

Topic Found in
[var$] √bbs.msgs
Example 8.0 8.1
1

Conclusion: Can serve as an empty variable check (null)

Topic Found in
] as goto √bbs.msgs
Example 8.0 8.1
1

Conclusion: Can serve as a “goto” function

Topic Found in
.32 √bbs.msgs

Researching / Unknown