Baja Version 2.10 Shell/Module Compiler for Synchronet
-
Upload
tfany-ezmira -
Category
Documents
-
view
220 -
download
0
Transcript of Baja Version 2.10 Shell/Module Compiler for Synchronet
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
1/230
Baja Version 2.10
Shell/Module Compiler for Synchronet BBS SoftwareCopyright 1996 Digital DynamicsUpdated 03/24/96
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
2/230
Table of Contents=================
Introduction.............................................................
3Source Files.....................................................4
BAJA.EXE.........................................................5
Modules..........................................................6ProgrammingSyntax.......................................................7
Variables........................................................7Arguments........................................................8C Strings........................................................9Integer Constants...............................................10
Command Key Constants...........................................11Include Files...................................................14Macro
Definitions...............................................15Global Variable Declarations....................................16
ProgrammingStyle.......................................................17
SuggestedRules.................................................19Functions...............................................................21
StringManipulation.............................................22
IntegerManipulation............................................29
Logic/ControlFlow..............................................32
Display.........................................................38
Input...........................................................45
Miscellaneous...................................................50
Mail............................................................65
MessageBase....................................................67File
Base.......................................................70Chat............................................................7
6Information.....................................................7
7File
I/O........................................................79File System.....................................................86Directory System................................................88
System
Variables........................................................90
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
3/230
Quick FunctionReference................................................93Index..................................................................103
_______________________________________________________________________________Synchronet 2Contents
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
4/230
Introduction============
Baja (pronounced b'h) is a high-level development tool used to create
"command shells" and "loadable modules" for Synchronet BBS software. Theprogrammable command and menu structure (PCMS) technology in Synchronetversion2 allows sysops to modify the user interface for the BBS by replacing ormodifying command shells. Synchronet version 2.0 shipped with six stockcommandshells (Classic and Novice Synchronet shells as well as emulations ofPCBoard,Wildcat, Major, and Renegade BBS packages). These shells can be modified,removed, or replaced with ease. Up to 500 shells can be made available totheusers of the BBS with configurable security access to each shell via ARS
(seethe Synchronet Sysop manual for details on ARS).
Synchronet loadable modules are used to extend or customize the abilitiesofthe BBS. Some modules are automatically loaded during specific events(login,logon, logoff, etc) while others may be executed at the request of a user(much like a door or other internal menu option).
Note:
If you come across an undefined term in this document, please read
throughthe document to possibly find the term defined later or used again toclarifyits meaning by context, or see the glossary in the Synchronet sysopmanual.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
5/230
_______________________________________________________________________________Synchronet 3Introduction
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
6/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
7/230
For more examples of Baja source code, please see the *.SRC files in yourSynchronet EXEC directory.
_______________________________________________________________________________Synchronet 4 Intro: SourceFiles
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
8/230
BAJA.EXE========
After the source file has been created, BAJA.EXE is used to compile
the .SRCfile into a binary file with a .BIN extension that Synchronet caninterpretand execute. If the source filename is EXAMPLE1.SRC, then the commandlinewould be:
BAJA EXAMPLE1
The compiler's output:
BAJA v2.00 Synchronet Shell/Module Compiler Copyright 1995 Digital
Dynamics
Compiling EXAMPLE1.BIN...Resolving labels...
Done.
This creates the binary file EXAMPLE1.BIN.
Warning: Do not attempt to edit, view, or print .BIN files.
If the compile fails, an error message will be displayed with thefilename that
contains the error and the specific line number followed by a colon andtheoffending code.
Baja source (.SRC), include (.INC), and binary (.BIN) files as well asthe Bajaprogram itself are normally stored in the Synchronet EXEC directory. Thisiswhere Synchronet loads command shells and modules from, so the .BIN filesmustbe created in or copied to this directory before they can be used.
After a command shell has been compiled, it must be added to the list ofavailable command shells in SCFG (Synchronet Configuration program) to beavailable for the users to use. If using a multinode BBS, the other nodesmust be re-run before the new command shell will be available on thosenodes.
If modifying an existing command shell, SCFG does not need to be run andnodesdo not have to be re-run since command shell binary files are dynamicallyloaded for each logon.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
9/230
_______________________________________________________________________________Synchronet 5 Intro:BAJA.EXE
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
10/230
Modules=======
Baja modules are very similar to command shells with the main difference
beingthat they are not automatically loaded upon logon as command shells are(with the exception of login and logon modules). Instead, modules must beloaded from a command shell with the EXEC_BIN function described later inthis document or launched as an external program or event configured inSCFG.Binary module files, like command shell binaries, must be located in theSynchronet EXEC directory.
Modules can be used to consolidate identical portions of multiple commandshells into one binary that can be loaded from each command shell so thatif a
modification needs to be made to that portion, then only one source fileneedsto be modified and recompiled as opposed to making the same change toeverycommand shell and recompiling them all. An example of this use is theSTR_CMDS(string commands) module that is launched from multiple command shells.
Another use for modules is for third-party add-ons. Rather thandistributingBaja source that must be merged into command shell source by sysops,developerscan distribute module binaries that can be loaded directly from a command
shell with a very small modification to the existing shells.
To load a Baja module in place of a DOS executable in SCFG, prepend anasterisk(*) to the name of the module (e.g. "*MYMOD") for the command line. If anargument is included on the command line (e.g. "*MYMOD %A") the contentswill be automatically placed into the current command string for possibleuseby the module or functions there in.
To load a Baja module while displaying a message, menu file, or TEXT.DATline
(excluding lines containing % variables) use "@EXEC:MYMOD@", were MYMODis thename of the module to execute. This is useful for executing modules inplaceswhere they cannot normally be loaded by event or command line. @-codesareonly expanded in posts and e-mail if posted locally by user #1 (thesysop).
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
11/230
_______________________________________________________________________________Synchronet 6 Intro:Modules
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
12/230
Programming Syntax==================
Basics:
Execution always begins at the top of the source code andcontinues
downward until a function is executed which changes the flow ofexecution. Only one function is allowed per line. The total length
ofeach line cannot exceed 1000 characters.
Whitespace:All whitespace (TAB and SPACE characters) at the beginning of
each lineare ignored. The first printable character of a line is
considered
the first character. Completely blank lines are ignored.
Comments:If the first character of a line is the pound symbol (#), theline is ignored. These are normally used for text comments
(remarks)about the following source code line(s). Comments may be included
onthe same lines as some (not all) functions, but in general it isconsidered best to keep comments on their own lines as to not
interferewith proper Baja syntax. Comments are more easily read if there is
a
space after the pound symbol (#) and before the comment textbegins.
Labels:If the first printable character of a line is a colon (:), the
line isconsidered a label to be used for the GOTO or CALL functions.
Labelsare not case sensitive. There should be no space between the
colon andthe name of the label. Label names may not contain spaces.
Duplicate
label names within the same module or shell are disallowed.
Case Sensitivity:Most elements of Baja syntax are not case sensitive (where upper orlower case is significant). Functions, and variable names (for
example)are not case sensitve. Character constants ('A' for example) are
casesensitive.
Variables:Variable names are not case sensitive and must begin with an
alphabetic
character or an underscore (_). Variable names can be any lengthand
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
13/230
may contain alpha, numeric, and underscore characters only. Thevariable name "str" is reserved to represent the current command
stringand should not be used as a user defined variable name.
When referencing a variable name defined by the system or another
module (global), the "!GLOBAL" compiler directive must be used todeclare the variable or the compiler will not recognize the
variablename and exit with a syntax error. Global variable declarations
shouldappear near the top of your source file.
Baja modules that use variables require SBBS v2.2 or later.
_______________________________________________________________________________Synchronet 7 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
14/230
Arguments:When a function requires one or more arguments, there must some
amountof white space between the function name and each argument.
In function definitions (in this document), required arguments arelisted in angled brackets (< >) and optional arguments are listed
insquare brackets ([ ]). The actual bracket symbols are NOT used in
thesource code. They are strictly for documentary purposes.
When a string variable argument is specified in the definition of afunction, any string variable name (either local or global) may beused. If str is used in the source code as the string variable
name,
the current command string will be used in place of an actualuser or system string variable.
An argument of # (pound sign) indicates an integer constant. Theactual
pound sign is not used in the argument. See the section on IntegerConstants for more details.
An argument of "str" (with double quotes) indicates a stringconstant
argument enclosed in double quotation marks. To place a doublequotation mark inside a string constant (as part of the actual
string
constant), use \" instead of just " where you want the quotationmark
to appear in the string.
An argument of "cstr" (with double quotes) indicates a C stringconstant argument enclosed in double quotation marks. See the nextsection on C strings for the definition of the contents.
See the beginning of the Functions section for the completedefinition
of all argument types and how they're specified in functiondefinitions.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
15/230
_______________________________________________________________________________Synchronet 8 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
16/230
C Strings:
Some character string arguments are defined as being C type (cstr).This indicates the contents of the string use the same
special/controlcharacter escape sequences as defined for the printf() function in
theANSI definition of the C programming language. The only exception
tothe ANSI definition, is that \### defines a character value in
decimal(base 10), not octal (base 8). All escape sequences begin with thebackslash (\) character. The valid escape sequences are:
\\ Backslash\? Question mark
\' Single quote\" Double quote\r Carriage return\n Line feed\t Horizontal tab\b Backspace\a Bell\f Formfeed\v Vertical tab\### Character value in decimal\x## Character value in hexadecimal
The text string must be enclosed in double quote (") symbols.
Example:
"Hello, world.\r\n"
To include an actual back-slash (\) character in a C string, youmust
prefix the back-slash with another back-slash. Example:
"C:\README.TXT"
would be an invalid path and filename.
"C:\\README.TXT"
would be the correct C string to represent C:\README.TXT.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
17/230
_________________________________________________________________________
______Synchronet 9 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
18/230
Integer Constants:
Many functions allow or require the use of integer constants (asopposed to integer variables). An integer constant is a number that
is"hard-coded" into the resulting executable file and will remainconstant (never change) from that point on.
You can specify integer constants in many ways:
Representation Range Examples-------------- ----- --------Decimal (base 10)-2147483648 to 2147483647 0, 10, -25Hexadecimal (base 16) 0x0 to 0xffffffff 0x7f, 0xA69BOctal (base 8) 00 to 037777777777 0377, 0505Bit value .0 to .31 .0, .1, .15
ASCII value '' to '' 'A', ' ', '%'Special char '\r' to '\v' (see C Strings) '\r', '\n'
Constants can be modified during specification (no variables may beused in the modification). No space is allowed between the numericconstant and the modifier symbol. Valid modifiers:
Symbol Operation Example------ --------- -------+ Addition 10+2- Subtraction 20-8* Multiplication 4*3/ Division 36/3
% Modulus (remainder) 53%8& Bit-wise AND 695&0x1f| Bit-wise OR 0x10|8~ Bit-wise NOT ~3^ Bit-wise XOR (exclusive OR) 0xff^12>> Right shift 03700>>4
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
19/230
_______________________________________________________________________________Synchronet 10 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
20/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
21/230
_______________________________________________________________________________Synchronet 11 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
22/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
23/230
_______________________________________________________________________________Synchronet 12 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
24/230
Some command key input functions allow the use of slash-commands(command keys prepended with a slash character, i.e. /A). The twocharacter slash-commands are the only multi-character commandssupported by command key functions. Example:
CMDKEYE /A
Is valid, but:
CMDKEYE -A
Is not valid.
To test specifically for digit (0-9) command keys and slash-digitcommand keys (/0-/9), use DIGIT and EDIGIT respectively. Example:
CMDKEYE DIGIT
To test if the user hit a key from 0 to 9, or:
CMDKEYE EDIGIT
To test if the user hit a slash-key combination from /0 to /9.
You may, of course, also test for a specific digit command key:
CMDKEYE 1and
CMDKEYE /1
are both valid command key constants.
To specify # for a command key, use '# (otherwise # will beinterpreted
as the beginning of a comment).
To specify SPACE bar for the command key, use ' ', example:
CMDKEY ' '
Extended ASCII characters ( for example) are not valid command
keys.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
25/230
_______________________________________________________________________________Synchronet 13 ProgrammingSyntax
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
26/230
Include Files=============
Source code segments that are to be shared amoung multiple command shells
ormodules can be placed into a separate text file (preferrably with a .INCextension) and included in the source code for multiple modules by usingthe"!INCLUDE" compiler directive to specify the filename to include.Example:
!INCLUDE MYDEFS.INC
This is useful when including files supplied by Digital Dynamics or thirdparty developers to pre-define constants (macros), common sub-routines,or
variable definitions. The following include files are distributed withBaja(and should not be modified):
ERRNO.INC Definitions for possible values of _ERRNO system variableFILE_IO.INC Constants for use with file I/O functionsDIR_ATTR.INC Constants for use with SET_FILE_ATTR & GET_FILE_ATTRfunctionsUSERDEFS.INC Synchronet User constants for use with various functionsNODEDEFS.INC Synchronet Node constants for use with various functionsSBBSDEFS.INC Synchronet system variable declarations and constants
(automatically includes USERDEFS.INC and NODEDEFS.INC)
Take care not to include the same file more than once in the same sourcecode.It is suggested you put all of your !include statements near the top ofyoursource file. If you include a file that in-turn includes other files(SBBSDEFS.INC, for example, includes USERDEFS.INC and NODEDEFS.INC), youdo not need to include the other files. If you !include SBBSDEFS.INC, youDO NOT need to !incluce NODEDEFS.INC and USERDEFS.INC as well. Take carenotto nest include files too deeply or the compilation will fail.
This compiler directive is very similar to the "#include" directive used
byC compilers, but if a specific path is not specified, only the currentdirectory will be searched for the file to include.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
27/230
_______________________________________________________________________________Synchronet 14 IncludeFiles
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
28/230
Macro Definitions=================
Commonly used character strings and integer constants can be specified as
macros by using the "!DEFINE" compiler directive to specify the macroname touse and the value of the macro. Example:
!DEFINE MAXIMUM_USERS 250
Now, any place you might want to use the number 250 in your Baja source,youcan use the macro "MAXIMUM_USERS" instead. This makes changing the valueofthe numeric or character string constant very easy.
This compiler directive is very similar to the "#define" directive usedbyC compilers with the main exception being that the macro name is not casesensitive.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
29/230
_______________________________________________________________________________Synchronet 15 Macro
Definitions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
30/230
Global Variable Declarations============================
When using variables defined by the system (see System Variables) or
anothershell or module (see GLOBAL_STR and GLOBAL_INT functions), you must firstdeclare these variables using the "!GLOBAL" compiler directive. Example:
!GLOBAL SOME_GLOBAL_VAR
Multiple global variables may be declared with one !GLOBAL statement:
!GLOBAL SOME_GLOBAL_VAR ANOTHER_GLOBAL_VAR
If you attempt to use a global variable without first delcaring it, thecompiler will fail to compile the source with an "expected variable name"
syntax error message.
This compiler directive is very similar to the "extern" keyword used by Ccompilers.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
31/230
_______________________________________________________________________________Synchronet 16 Global VariableDeclarations
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
32/230
Programming Style=================
As stated in the previous section, white space characters at the
beginningof a line are ignored and have no effect on the resulting compilation.But,whitespace can be very useful in making the source code readable byindentingconditional blocks of code, and using blank lines to separate blocks ofrelated code. Comments are also very helpful in making the code readable.
Compare the following source to the example given in the Source Fileschapter:
----------------------------------
[ Begin ]-----------------------------------
:TOPCLSMNEMONICS "~Comment to Sysop\r\n"MNEMONICS "~Goodbye (Logoff)\r\n"PRINT "\r\nCommand: "GETCMD "CG"COMPARE_KEY CIF_TRUESETSTR "1"MAIL_SEND_FEEDBACKGOTO TOP
END_IFCOMPARE_KEY GIF_TRUELOGOFFGOTO TOPEND_IF
-----------------------------------[ End ]------------------------------------
Without the whitespace and the comments, the code appears much morecryptic
(the control flow is hard to follow). But the code will compile intoexactlythe same binary file as the earlier example.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
33/230
_______________________________________________________________________________Synchronet 17 ProgrammingStyle
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
34/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
35/230
_________________________________________________________________________
______Synchronet 18 ProgrammingStyle
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
36/230
Suggested Rules of Style========================
There isn't a "right" or "wrong" way to use indentation, blank lines,
or comments, but we will present a set of suggested "rules" here. If youdecideyou prefer another style, that is fine. The most important thing is thatyouare consistent in your use of whatever style you choose.
Top of File Comments--------------------Place a comment as the very first line of the file with the name ofthe .SRCfile. Example:
# EXAMPLE.SRC
Then a block of comment lines that describe what the shell or module'spurposeis, who programmed it, when, where, etc.
Label Comments--------------Labels normally represent the beginning of a sub-routine and should bewell commented. A graphical line to show the beginning of a new sub-routineis often helpful. Example:
############################### My Sub-routine################################:MY-SUB
CMD_HOME Comments-----------------The CMD_HOME function marks the beginning of a command/menu loop andshouldbe well commented. Example:
############## MAIN MENU #
#############CMD_HOME
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
37/230
_______________________________________________________________________________Synchronet 19 Suggested Rules ofStyle
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
38/230
Conditional Indentation-----------------------Whenever a block of code is conditionally executed (only executed underspecific conditions), the block of code should be indented one tabstop
pastthe block header (IF_TRUE, IF_FALSE, ELSE, SWITCH, CASE, CMDKEY, CMDSTR,etc).The block of code to be indented includes the block terminator (END_IF,END_CMD, END_CASE, END_SWITCH, etc). Example:
GETCMD "ABCD"
CMDKEY ACOMPARE_ARS LEVEL 50IF_TRUE
PRINT "You have level 50 or higher.\r\n"
ELSE PRINT "You have level 49 or lower.\r\n"END_IF
END_CMD
Separate Code Blocks--------------------Use blank lines to separate medium to large code blocks from other code(most especially CMDKEY, CMDKEYS, CMDSTR, and SWITCH code blocks).Example:
GETCMD "ABCD"
CMDKEY APRINT "You hit A.\r\n"END_CMD
CMDKEY BPRINT "You hit B.\r\n"END_CMD
End of File Comment-------------------Place a comment at the end of the file. Example:
# End of EXAMPLE.SRC
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
39/230
_______________________________________________________________________________Synchronet 20 Suggested Rules ofStyle
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
40/230
Function Definitions====================
The remainder of this document is for defining the correct use of all
Bajafunctions. If you wish to look up a specific function by subject, pleasereferto the table of contents or the quick reference at the end of thedocument.
Argument Types--------------Each function definition will begin with the name of the functionfollowed byall possible arguments (parameters) and the type of each argument. Thepossible
argument types are:
Type Description~~~~ ~~~~~~~~~~~"str" String constant (contained in double quotes)"cstr" C string constant (contained in double quotes)txt String constant (no quotes)# Integer constant (the # symbol is not part of the syntax)str_var String variable name or 'str' for current command stringint_var Integer variable nameany_var Any string or integer variable namechar Character constant (single character, no quotes)key Command key constant
keylist List of command key constants (no space between each key)
Each argument type is contained in either angled brackets (< and >) toindicatethe argument is required, or square brackets ([ and ]) to indicate theargument is optional. An argument of [...] indicates a variable number ofoptional arguments of the last specified type. Example:
SPRINTF [any_var] [...]
This function definition indicates that the SPRINT function requires aminimum
of three arguments: a string variable, a C string constant, and one ormorevariables of either integer or string type.
Required Include Files----------------------Following the function argument types, may be one or more requiredinclude(.INC) files. If any files are listed on the same line as the function(to the right of the page), these files must be included at the top ofyour source file to use this function arguments correctly. Example:
!INCLUDE NODEDEFS.INC
Do not include the same file more than once in the same source file. Once
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
41/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
42/230
String Manipulation Functions=============================
Functions used for manipulating string variables (global or local) and/or
thecurrent command string.
STR [str_var] [...]args: new_vars------------------------------Define one or more local string variables for later use. The new_varsargumentsare the names of the variables to define. These names must not becurrentlyused by other variables (local or global).
The variable name "str" is used by other functions to refer to thecurrentcommand string, and therefore cannot be used as a user defined variablename.
After definition, the variable names can be used by other functions. Thevariables will each be initialized to a null string. The variables canonly bereferenced in the current shell or module. When the current shell ormodule isterminated, the variable names and their contents are lost. If you wishtoretain a variable name and its contents between shells or modules, use a
globalvariable instead of a local variable.
GLOBAL_STR [str_var] [...]args: new_vars
------------------------------------Define one or more global string variables for later use. The argumentsare thenames of the variables to define. Each variable name must not becurrently usedby another variable (local or global). Global variable names and theircontents
are not disposed of until the current user logs off the BBS.
SET args: dest value-----------------------Writes to the string variable dest, the contents of the C stringspecified asvalue. This function is the Baja equivalent of the standard C strcpy()functionwith the exception that the source must be a string constant. Example:
STR USER_NAMESET USER_NAME "John Doe"
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
43/230
When writing to the current command string, use the SETSTR functioninsteadof this function for best optimization.
_______________________________________________________________________________Synchronet 22 String Manipulation
Functions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
44/230
COPY args: dest source------------------------Copies the source variable (string or integer) into the specified
destinationvariable. This function is the Baja equivalent of the standard C strcpy()function with the exception that the source must be a variable, but maybeeither of integer or string type. Example:
# define two variablesSTR VAR1 VAR2# copy some text into the first variableSET VAR1 "Some Text"# copy that variable into the second variableCOPY VAR2 VAR1
# display the contents of second variablePRINT VAR2
If the source variable is an integer variable, it is converted intoa decimal (base 10) string before the copy is executed. Use SPRINTF ifyouwant to convert an integer variable into a string using hexadecimal (base16)or octal (base 8) representation instead of decimal.
SWAP args: var1 var2------------------------
Exchanges the contents of two string variables, or a string variable andaninteger variable. The first argument (var1) is the name of a stringvariableand the second argument (var2) is the name of a string or integervariable.If var2 is an integer variable, var1 will be set to the decimalrepresentationof the integer variable contents and var2 will be set the integerrepresentation of var1 (specified in hex, octal, or decimal). Example:
INT I
STR S
# set S to 100h (256)SET S "0x100"# set I to 100SET I 100# swap themSWAP S I# I now equals 256 and S is "100"
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
45/230
_______________________________________________________________________________Synchronet 23 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
46/230
STRCAT args: dest source
------------------------------------Concatenates (appends) the contents of a string variable (specified as
dest)with the contents of a C string or string variable specified as source.Thisfunction is the Baja equivalent of the standard C strcat() function.
SPRINTF [any_var] [...]args: dest format variables
----------------------------------------------------Writes the specified variables into the string variable (dest) based onthe specified format. This function is the same as PRINTF except that theoutput is written into the dest string variable instead of the console.This
function is the Baja equivalent of the standard C sprintf() function withthe exception that all the arguments following the format must bevariables(no constants allowed). See the PRINTF function definition for details.
TIME_STR args: dest time
----------------------------Writes to the string variable (specified as dest) the time and datestored inthe integer variable specified by time. This function is the Bajaequivalentto the standard C ctime() function. Example:
# Display current timeINT TTIME TTIME_STR STR TPRINTF "Current time: %s\r\n" STR
Would display the current date/time similar to:
Current time: Thu Aug 31 1995 08:34 am
DATE_STR
args: dest time----------------------------Writes to the string variable (specified as dest) the date stored in theinteger variable specified by time (obtained with TIME or similarfunction) inMM/DD/YY format or DD/MM/YY format if European date format is enabled inSCFG.Example:
# Display current dateINT TTIME TDATE_STR STR T
PRINTF "Current date: %s\r\n" STR
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
47/230
Would display the current date similar to:
Current date: 08/31/95
_______________________________________________________________________________Synchronet 24 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
48/230
SECOND_STR args: dest seconds
------------------------------Writes to the string variable (specified as dest) the number of seconds
(in HH:MM:SS format) stored in the integer variable specified by seconds.Example:
# Display number of seconds elapsedINT START ENDTIME STARTPRINT "Wait a period of time, then hit a key..."GETKEYTIME ENDSUB END STARTSECOND_STR STR ENDPRINTF "\r\n%s time elapsed.\r\n" STR
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
49/230
_______________________________________________________________________________Synchronet 25 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
50/230
FTIME_STR args: dest format time
--------------------------------------Writes to the string variable (specified as dest) the date and time
informationfrom the integer variable (specified as time) formatted according tostringconstant specified as format. The format characters are described below:
%a abbreviated weekday name%A full weekday name%b abbreviated month name%B full month name%c date and time%d day of month (01-31) (zero-padded)%H hour (24-hour clock) (00-23)
%I hour (12-hour clock) (01-12)%j day of the year (001-366)%m month (01-12)%M minute (00-59)%p AM or PM%S second (00-59)%U week number of the year (Sunday as 1st day of week) (00-52)%w weekday (0-6, Sunday is 0)%W week number of the year (Monday as 1st day of week) (00-52)%x date%X time%y year without century (00-99)%Y year with century
%Z time zone name, if any%% % (percent symbol)
This function is the Baja equivalent of the standard C strftime()function.Example:
# Display current date and timeINT TTIME TFTIME_STR STR "Current_Time:%A,%B-%d-%Y,%I:%M %p" TPRINTF "%s\r\n" STR
SHIFT_STR [str_var] args: string len
------------------------This function ("Shift String") shifts the specified string variable ifspecified (current command string if not specified) to the left 'len'number ofcharacters.
# Displays the string "ELLO"SETSTR "HELLO"
SHIFT_STR 1PRINT STR
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
51/230
This function is most often used to parse command string arguments or"stacked"commands.
_________________________________________________________________________
______Synchronet 26 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
52/230
STRIP_CTRL [str_var]args: string
--------------------Removes all control characters (and Ctrl-A codes) from specified string
variable. If string is not specified, then the current command string isprocessed.
TRUNCSP [str_var]args: string
-----------------Removes (truncates) all white space characters from end of specifiedstringvariable or current comand string (if string not specified).
STRUPR [str_var]args: string
----------------Converts specified string argument to all uppercase characters. Thisfunctionis the Baja equivalent to the standard C strupr() function.
STRLWR [str_var]args: string
----------------Converts specified string argument to all lowercase characters. Thisfunctionis the Baja equivalent to the standard C strlwr() function.
SETSTR
args: text---------------Writes to current command string, specified constant text string. Thisfunction should be used in place of "SET STR" for best optimization.
REPLACE_TEXT args: num text
-------------------------This function is used to replace a default internal text string (readfrom theCTRL\TEXT.DAT file) in a shell or module. The first argument (num) is thetext
number to replace (see TEXT.DAT for the number of the text you wish toreplace). The second argument (text) is the C type string to use in placethecurrent one. All text replacements are lost (back to default TEXT.DAT)when theuser logs off. Example, to replace the "[Hit a key]" prompt with adifferentstring:
REPLACE_TEXT 563 "\1n\1h\1b{\1wPAUSE\1b} "
When replacing a TEXT.DAT string that contains %s, %d, or other %specifiers,
you will need to change them to %%s, %%d, etc (without changing theorder).
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
53/230
If you wish to globally replace a string (for all shells and modules),you maywant to just edit the CTRL\TEXT.DAT file directly instead.
_______________________________________________________________________________Synchronet 27 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
54/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
55/230
_______________________________________________________________________________Synchronet 28 String ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
56/230
Integer Manipulation Functions==============================
Functions used for manipulating integer variables (global or local).
INT [int_var] [...]args: new_vars------------------------------Define one or more local integer variables for later use. The new_varsarguments are the names of the variables to define. These names must notbecurrently used by other variables (local or global).
After definition, the variable names can be used by other functions. Thevariables will each be initialized to a 0. The variables can only bereferenced
in the current shell or module. When the current shell or module isterminated,the variable names and their contents are lost. If you wish to retain avariable name and its contents between shells or modules, use a globalvariableinstead of a local variable.
GLOBAL_INT [int_var] [...]args: new_vars
------------------------------------Define one or more global integer variables for later use. The argumentsarethe names of the variables to define. Each variable name must not be
currentlyused by another variable (local or global). Global variable names andtheircontents are not disposed of until the current user logs off the BBS.
SET args: dest value---------------------Writes to the integer variable dest, the integer constant specified asvalue.
INT I
SET I 100
ADD args: dest value-----------------------------Adds the value specified in the second argument to the integer variablespecified as dest.
SUB args: dest value-----------------------------Subtracts the value specified in the second argument from the integervariable
specified as dest.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
57/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
58/230
DIV args: dest value-----------------------------Divides the first argument by the value specified in the second argument
and places the result into dest.
MOD args: dest value-----------------------------Divides the first argument by the value specified in the second argumentand places the remainder into dest.
AND args: dest value-----------------------------Bit-wise ANDs the value specified in the second argument with the integer
variable specified as dest.
OR args: dest value----------------------------Bit-wise ORs the value specified in the second argument with the integervariable specified as dest.
NOT args: dest value-----------------------------Bit-wise ANDs the unary opposite of the value specified in the secondargument
with the integer variable specified as dest.
XOR args: dest value-----------------------------Bit-wise exclusive ORs the value specified in the second argument withtheinteger variable specified as dest.
COPY args: dest source------------------------
Copies the source variable (string or integer) into the specifieddestinationvariable. Example:
# define two variablesINT INT1 INT2# place a value into the first variableSET VAR1 5# copy that variable into the second variableCOPY VAR2 VAR1# display the contents of second variablePRINTF "VAR2=%ld\r\n" VAR2
If the source variable is an string variable, it is converted into aninteger
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
59/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
60/230
SWAP args: var1 var2------------------------Exchanges the contents of two integer variables, or a string variable and
aninteger variable. The first argument (var1) is the name of an integervariableand the second argument (var2) is the name of a string or integervariable.
RANDOM args: dest num
---------------------Places a random number between 0 and num-1 into dest.
TIME
args: dest--------------Places the current time (in unix/time_t format) into dest. This functionisthe Baja equivalent of the standard C time() function.
STRLEN args: dest string
--------------------------Places the length (in characters) of the specified string into dest. Thisfunction is the Baja equivalent of the standard C strlen() function.
DATE_INT
args: dest date----------------------------Converts a date string (in MM/DD/YY format) into an integer and places itinto dest.
CRC16 args: dest string
-------------------------Calculates the 16-bit CRC of the specified string and places the resultintodest.
CRC32 args: dest string-------------------------Calculates the 32-bit CRC of the specified string and places the resultintodest.
CHKSUM args: dest string
--------------------------Calculates the CHKSUM of the specified string and places the result intodest.
CHARVAL args: dest string
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
61/230
---------------------------Places the ASCII value of the first character in the specified stringintodest.
_______________________________________________________________________________Synchronet 31 Integer ManipulationFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
62/230
Logic/Control Flow Functions============================
GOTO
args: label-----------This function is used to force the control flow to immediately jump toanotherpart of the code. A valid label name must follow GOTO as an argument.Thisfunction is very similar to the GOTO command used in the BASIC and Cprogramming languages or the JMP instruction used in the Assemblyprogramminglanguage.
CALL
args: label-----------This function is used to execute a sub-routine. The sub-routine must bedefined with the specified label somewhere in the current module. When aRETURN function is executed in the sub-routine, control flow will returnto thenext line following the CALL function that started the sub-routine. TheCALLfunction is very similar to the GOSUB command used in the BASICprogramminglangauge or the CALL instruction used in the Assembly programminglanguage. Atleast one RETURN function must exist in the sub-routine. Sub-routines
shouldnot use a GOTO function to "jump out" of the sub-routine.
RETURN------This function is used to exit a sub-routine and return to the point inthecode from which it was called with the CALL function. If a RETURNfunction is executed without a prior CALL, then the shell or module isimmediately terminated. If a shell is terminated with a user online, theyare immediately logged off. If a module is terminated, execution controlreturns to the shell or module that loaded it.
SETLOGIC args: logic
-------------------------------------------This function is used to set the current logic state to TRUE (same asEQUAL), FALSE (same as NOT_EQUAL), GREATER, or LESS. The logic state isset bymany functions, and tested by the IF_... functions to control the flow ofexecution.
COMPARE args: var cmp
------------------------------------------
This function compares any two variables, or a variable and a constant.If the cmp argument is an integer variable or integer constant and the
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
63/230
var variable is a string variable, then cmp is converted to a stringrepresentation of the cmp variable before the comparison is made. If thecmpargument is a string variable or string constant and the var variable isan integer variable, then cmp is converted to an integer before thecomparison
is made. The current logic state is set to the result of the comparion:TRUE (same as EQUAL), FALSE (as an NOT_EQUAL), GREATER, or LESS.
_______________________________________________________________________________Synchronet 32 Logic/Control FlowFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
64/230
IF_TRUE-------If the current logic state is set to TRUE, then following block of code(ending in an END_IF or ELSE function) will be executed. Otherwise,
the interpreter will skip the code until an ELSE or END_IF function isfoundand resume execution from that point. This function is the same asIF_EQUAL.
IF_FALSE--------This function is identical to the IF_TRUE function except that it worksin theopposite manor in regards to the current logic state. This function isthesame as IF_NOT_EQUAL.
IF_GREATER----------If the current logic state is set to GREATER by a subsequent COMPAREfunction,the following IF_... block will be executed.
IF_GREATER_OR_EQUAL-------------------If the current logic state is set to GREATER or EQUAL, the followingIF_...block will be executed. This function is the same as IF_EQUAL_OR_GREATER.
IF_LESS-------If the current logic state is set to LESS by a subsequent COMPAREfunction,the following block will be executed.
IF_LESS_OR_EQUAL----------------If the current logic state is set to LESS or EQUAL, the following codeblockwill be executed. This function is the same as IF_EQUAL_OR_LESS.
ELSE----This function marks the end of an IF_... block of code and begins analternateblock of code to be executed if the condition is not met for the IF_...function. The block of code is terminated with an END_IF function.
END_IF------This function is used to terminate an IF_... or ELSE code block. EveryIF_...function must be followed by an ELSE or END_IF instuction, and every ELSEfunction must be followed by an END_IF.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
65/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
66/230
SWITCH ----------------CASE --------
END_CASE--------DEFAULT-------END_SWITCH----------The SWITCH function is used in conjunction with the CASE, DEFAULT,END_CASE,and END_SWITCH functions to replace multiple COMPARE/IF_.../ELSEstatements.
Example:
INT IRANDOM I 3COMPARE I 0IF_EQUAL
PRINT "Zero"ELSE
COMPARE I 1IF_EQUAL
PRINT "One"ELSE
COMPARE I 2IF_EQUAL
PRINT "Two"END_IF
END_IFEND_IF
Could be replaced with:
INT IRANDOM I 3SWITCH I
CASE 0PRINT "Zero"
END_CASECASE 1PRINT "One"END_CASE
CASE 2PRINT "Two"END_CASE
DEFAULTPRINTF "Random returned %ld" IEND_CASE
END_SWITCH
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
67/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
68/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
69/230
_______________________________________________________________________________Synchronet 35 Logic/Control Flow
Functions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
70/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
71/230
the current logic state to TRUE or FALSE accordingly. The comparison isnotcase sensitive. This function is the Baja equivalent to the standard Cstricmp() function.
_______________________________________________________________________________Synchronet 36 Logic/Control FlowFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
72/230
COMPARE_WORD args: string
---------------------This function is identical to the COMPARE_STR function with the
exception that the current command string must only match the stringargumentfor as many characters as included in the string argument.
If for example, the current command string is "OPEN BLACKJACK" then theline:
COMPARE_WORD "OPEN"
would set the current logic state to TRUE since the first 4 characters ofeach string match, but the line:
COMPARE_STR "OPEN"
would set the current logic state to FALSE since the strings do notentirelymatch.
COMPARE_ARS args: ars
-----------------This function compares the requirement string argument ars against theinformation on the current user and sets the current logic state toeitherTRUE or FALSE based on the result of the comparison. See the ARS chapter
ofthe Synchronet sysop manual for details on the syntax of ARS.
Example:COMPARE_ARS LEVEL 60IF_TRUE
PRINT "You have level 60 or higher.\r\n"END_IF
COMPARE_STRN args: num str1 str2
-----------------------------------------------
This function is used to compare the first num characters of strings str1and str2. This function is the Baja equivalent of the standard Cstrnicmp()function. If the two strings are the same (ignoring case) for the thefirstnum characters, the current logic state is set to TRUE, otherwise it issetto FALSE.
COMPARE_SUBSTR args: str1 str2
--------------------------------------------This function is used to check if str2 is contained in str1 (case
sensitive).This function is the Baja equivalent of the standard C strstr() function.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
73/230
If str2 is located in str1, the current logic state is set to TRUE,otherwiseit is set to FALSE. This following example would set the current logicstateto TRUE:
SETSTR "This is a test"COMPARE_SUBSTR STR "test"
_______________________________________________________________________________Synchronet 37 Logic/Control FlowFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
74/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
75/230
_______________________________________________________________________________Synchronet 38 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
76/230
PRINTF [any_var] [...]args: format variables
-------------------------------This function is similar to print, except that defined variables can be
placed(formatted) into to displayed text output. This function is the Bajaequivalent of the standard C printf() function. The format argument is aC typestring with C printf() % specifiers for variable formatting.
The valid specifiers are:
%% Percent symbol%s String variable%#s String variable, minimum # chars wide, right justified%-#s String variable, minimum # chars wide, left justified
%.#s String variable, maximum # chars wide%#.#s String variable, min and max width specified, rightjustified
%-#.#s String variable, min and max width specified, leftjustified
%ld Integer variable, decimal - use lx for hexadecimal(lX=caps)
%#ld Integer variable minimum # chars wide right justified%-#ld Integer variable minimum # chars wide left justified%0#ld Integer variable minimum # digits wide zero padded
Multiple variable names may be specified after the str argument, but eachvariable MUST be properly represented in the str argument with the
correctPRINTF specifier (either %ld, %lx, or %s).
Example:STR sSET s "hello, world"PRINTF "~%s~\r\n" sPRINTF "~%10s~\r\n" sPRINTF "~%.10s~\r\n" sPRINTF "~%-10s~\r\n" sPRINTF "~%.15s~\r\n" sPRINTF "~%-15s~\r\n" s
PRINTF "~%15.10s~\r\n" sPRINTF "~%-15.10s~\r\n" s
Would produce the following display:
~hello, world~~hello, world~~hello, wor~~hello, world~~hello, world ~~ hello, wor~~hello, wor ~
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
77/230
_________________________________________________________________________
______Synchronet 39 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
78/230
And:INT iSET i 1234
PRINTF "~%ld~\r\n" i
PRINTF "~%3ld~\r\n" iPRINTF "~%6ld~\r\n" iPRINTF "~%-6ld~\r\n iPRINTF "~%06ld~\r\n" iPRINTF "~%06lx~\r\n" iPRINTF "~%06lX~\r\n" i
Would produce the following display:
~1234~~1234~~ 1234~
~1234 ~~001234~~0004d2~~0004D2~
PRINT_LOCAL args: string
--------------------This function works identical to the PRINT function with the exceptionthatthe output is only displayed locally (on the BBS console). Ctrl-A codesand @-codes are not supported.
PRINT_REMOTE args: string
---------------------This function works identical to the PRINT function with the exceptionthatthe output is only displayed remotely (on the user's terminal). If thecurrentuser is not logged on remotely, then no output is performed. Ctrl-A codesand @-codes are not supported.
PRINTSTR--------
This function works identical to the PRINT function with the exceptionthatthis function does not accept a string argument, and instead uses thecurrentcommand string (set with SETSTR, GETSTR, or similar function) as thecharacterstring to print.
Example:SETSTR "hello, world\r\n"PRINTSTR
PRINTKEY
--------
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
79/230
This function displays the current command key. The command key isnormallyobtained with the GETKEY, GETCMD, or similar function.
_______________________________________________________________________________Synchronet 40 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
80/230
MNEMONICS args: string
------------------This function works identical to the PRINT function with the exception
thatthe output is automatically colorized and characters following a tilde(~)are considered a mnemonic command character (hot key) and are high-lightedor placed in parentheses if the user's terminal does not support ANSI. IfCtrl-A codes are included in the str argument, then the automaticcolorizationand high-lighting is not used.
Example:mnemonics "Select: ~Good, ~Bad, or ~Indifferent: "
CLS---This function clears the current text screen.
CRLF----This function displays a carriage return/line feed (new line). It isequivalentto PRINT "\r\n", but requires less memory and executes faster.
PRINTFILE [#]SBBSDEFS.INC
args: file mode----------------------------------Displays the contents of the file to the user (both locally and remotely,ifapplicable).
Valid mode parameters:
P_NOABORT Disallows abortion of display with Ctrl-CP_SAVEATR Retain attributes (colors) after displayP_NOATCODES Don't expand @-code variables/actionsP_OPENCLOSE Open and close immediately (before display)
Multiple mode parameters can be specified by joining them together withtheOR (|) symbol.
Example:!INCLUDE SBBSDEFS.INCPRINTFILE "C:\TEXT\HELP.TXT" P_NOABORT|P_OPENCLOSE
PRINTTAIL SBBSDEFS.INCargs: file mode x
-----------------------------Displays the last x number of lines of file. The valid mode parameters
are the
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
81/230
same as those shown for the PRINTFILE function. If you don't want any ofthemode values, use 0 for the mode.
PRINTFILE_STR-------------
This function is indentical to the PRINTFILE function, with the exceptionthatthere is no argument, the current command string is used for the path andfilename instead.
_______________________________________________________________________________Synchronet 41 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
82/230
PRINTFILE_LOCAL args: file
-----------------------
This function works identical to the PRINTFILE function, with theexceptionthat the contents are only displayed locally.
PRINTFILE_REMOTE args: file
----------------------This function works identical to the PRINTFILE function, with theexceptionthat the contents are only displayed remotely. If the user is not loggedonremotely, then no output is performed.
LIST_TEXT_FILE--------------This function works similar to the PRINTFILE function, with the exceptionthat the system password is required when run remotely and the user ispromptedto enter the path and name of the file to list.
EDIT_TEXT_FILE--------------This function is generally for sysop use only. It will automaticallypromptthe user (if remote) for the system password, and then prompt them for
thepath and name of the file to edit.
PAUSE-----This function produces a "[Hit a key]" prompt and waits for the user tohit akey.
MENU args: file----------
This function is similar to the PRINTFILE function with the exceptionthat theTEXT\MENU directory is assumed to be the root path for the file and thefile'sextension (.ASC, .ANS, .MON, or .RIP) should not be specified. Thisfunctionwill automatically display the correct file based on the what the user'sterminal supports and which menu files are available. To display a menufilein a different directory, a sub-directory can be specified before thefilename.For example, do display the MAIN.* menu file in the TEXT\MENU\SIMPLEdirectory,
you would use the following:
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
83/230
MENU "SIMPLE\MAIN"
To display the MAIN.* menu file in the TEXT\MENU directory, you would usethefollowing:
MENU "MAIN"
You can also change the default menu directory with the SET_MENU_DIRfunction.Using the SET_MENU_FILE function, you can override the location andfilenamefor MENUs that are displayed from within core functions of Synchronet.
_______________________________________________________________________________Synchronet 42 Display
Functions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
84/230
NODELIST_ALL------------This function displays the current status of all nodes.
NODELIST_USERS--------------This function displays the current status of all nodes that are in use.
USERLIST_SUB------------This function displays all users that have access to the current messagesub-board.
USERLIST_DIR------------This function displays all users that have access to the current file
directory.
USERLIST_ALL------------This function displays all users that have active accounts on the BBS.
USERLIST_LOGONS---------------This function displays a list of the users who have logged on today.
YES_NO args: question
----------------
This function displays the question argument with automatic colorizationfollowed by the text " (Y/n) ? " and waits for the user to hit 'Y', 'N'or CR.If CR (enter) is hit, then 'Y' is assumed. If the answer to the prompt is'Y',then the current logic state is set to TRUE, otherwise it is set toFALSE.
Example:YES_NO "Logoff Now"IF_TRUE
LOGOFF
END_IF
NO_YES args: question
----------------This function is identical to the YES_NO function with the exception thatthestring is followed by text " (y/N) ? " and if CR is hit, then 'N' isassumed.If the answer to the prompt is 'N', then the current logic state is settoTRUE, otherwise it is set to FALSE.
Example:NO_YES "Logoff Now"
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
85/230
IF_FALSELOGOFFEND_IF
_________________________________________________________________________
______Synchronet 43 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
86/230
READ_SIF args: file
--------------This function displays the contents of a SIF questionnaire data file
(path andfilename specified in the current command command string). The data isreadfrom the SIF data file and displayed through the SIF questionnaire file:"TEXT\file.SIF".
The original SIF data file is created with the CREATE_SIF function. TheSIF file used to create and display the data file do not have to be thesameSIF file, but should have the same order and format of data types.
See the Synchronet Sysop Manual for details on the SIF file format.
SAVELINE--------This function saves the current line of text on the console to aninternalSynchronet buffer for later re-display with the RESTORELINE function.
RESTORELINE-----------This function re-displays a previously saved line of text to the localandremote console (if applicable).
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
87/230
_______________________________________________________________________________
Synchronet 44 DisplayFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
88/230
Input Functions===============
Input functions are used to obtain input data from the user (most often
fromthe user's keyboard).
INKEY-----Checks to see if the user has hit a key. If the user has hit a key, thecurrent command key is set to the hit key and the current logic state isset to TRUE, otherwise the logic state is set to FALSE. This functiondoesnot wait for a user to hit a key.
GETKEY
------Waits for a single key from the user. The key is converted to upper case(ifa letter) and becomes the current command key for functions such asCMDKEY,COMPARE_KEY, etc. The key is not echoed (displayed). Use the PRINTKEYfunctionto display a key accepted with this function.
GETKEYE-------This function is identical to the GETKEY function with the exception that"slash commands" are allowed. That is, if the user hits the slash (/)
key,then the slash is echoed and the system waits for another key from theuser.The second key is converted to upper case (if a letter) and the slash/keycombination becomes the current command key for functions such as CMDKEY,COMPARE_KEY, etc. The second key is not echoed (displayed). Use thePRINTKEYfunction to display a key accepted with this function.
GETCMD args: keys
---------------
This function is very similar to the GETKEY function, except that the'keys'argument specifies the only valid key to be accepted. The keys argumentsisa C style string, so carriage return (ENTER) is specified with a \r. If,forexample, you wanted to allow the user to hit A, B, C or ENTER, then youwoulduse the following:
GETCMD "ABC\r"
When an allowed key is hit, the key is converted to upper case (if a
letter)
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
89/230
and echoed (displayed) followed by a CRLF automatically. The key thenbecomesthe current command key for functions such as CMDKEY, COMPARE_KEY, etc.
Ctrl-C will always be allowed, in which case the command key becomes ^C.
_______________________________________________________________________________Synchronet 45 InputFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
90/230
GETSTR [str_var] [#] [#] SBBSDEFS.INCargs: string max mode
---------------------------This function ("Get String"), is used to accept a string of characters
fromthe user. The 'max' argument specifies the maximum length allowed for thestring (in characters). 'max' should not exceed 79 characters for mostuses.This function allows the user to enter any valid ASCII characters to formcommand words, sentences, etc. Control will not return to the moduleuntil theuser either hits CR (ENTER), Ctrl-C, or Ctrl-V or is disconnected. Theresultant string can then be used in functions such as CMDSTR,COMPARE_STR,COMPARE, SHIFT_STR, XTRN_EXEC, FILE_DOWNLOAD, etc.
If string is not specified, the current command string is written to. Ifmax is not specified, the value 128 is used.
The valid mode parameters (defined in SBBSDEFS.INC) are:
Mode Description~~~~ ~~~~~~~~~~~K_UPPER Converts all letters to upper caseK_UPRLWR Upper/Lower case automaticallyK_NUMBER Allow numbers onlyK_WRAP Allows word wrapK_MSG Allows Ctrl-A codes and Ctrl-G (beep)K_SPIN Spinning cursor
K_LINE Input line (inverse color)K_EDIT Edit string passedK_NOCRLF Don't print CRLF after string inputK_ALPHA Only allow alphabetic charactersK_LOWPRIO low priority inputK_NOEXASC No extended ASCII allowedK_E71DETECT Detect E-7-1 terminal typeK_AUTODEL Auto-delete text (used with EDIT)K_NOECHO Don't echo input to local or remote console
Multiple mode parameters can be used by ORing them together with the |symbol.
Example:
GETSTR STR 25 K_UPRLWR|K_EDIT|K_AUTODEL
GETLINE [str_var] [#]args: string max
--------------------------This function is identical to GETSTR with the exception that an inverselineis displayed to the user (if the user has an ANSI terminal) to show themaximumlength of the input string.
GETSTRUPR [str_var] [#]args: string max
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
91/230
------------------------This function ("Get String Upper") is identical to GETSTR with theexceptionthat the string is automatically converted to uppercase as the usertypes.
_______________________________________________________________________________Synchronet 46 InputFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
92/230
GETNAME [str_var] [#]args: string max
----------------------This function is identical to GETSTR with the exception that the string
isautomatically converted to "Capitalized" words (as in a proper noun) astheuser types.
GETFILESPEC-----------This function is specifically used to accept a file specification (nameand/orwildcard characters) from the user. It will automatically display apromptsimilar to:
Filespec [*.*]:
before waiting for the user to input the file specification. If the userhitsCR, *.* is assumed to be the file specification. If a period is notincludedin the string, a ".*" is automatically appended (so CR, "*" and "*.*" allresult in the same string: "*.*"). If the user enters "A*", the stringbecomes"A*.*". If the user enters "A*." the string remains unchanged. If theuserhits Ctrl-C, the current logic state is set to FALSE. Otherwise, the
logicstate is set to TRUE.
Example:
GETFILESPECIF_TRUE
FILE_DOWNLOADEND_IF
GETLINES--------
This function only has an effect if the user is logged on remotely, hasANSI terminal capability and their screen lines set to "Auto-detect". Itsends an ANSI sequence to detect the number of screen lines in the textwindowof the remote terminal and waits for a response.
GETNUM [any_var] args: dest max
---------------------This function is similar to GETSTR with the exception that it onlyexceptsnumbers as input and automatically stops accepting input if the numberbeing
input would exceed max (maximum of 32767). The dest variable (current
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
93/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
94/230
GET_TEMPLATE ------------------This function is much line GETLINE except that an input template ispassed
as an argument to this function. The template is useful when requiringtheuser to input a string of a fixed format, like a date, for example. Thecharacters in the template have special meaning: N indicates only anumber maybe used in this position, A indicates only an alphabetic character, and !indicates any character may be used in that position. Characters otherthanN, A, or ! are automatically displayed and used in the current commandstringin those positions. The first character of the template must be either N,A, or
!. An example (date format):
GET_TEMPLATE "NN/NN/NN"
would require the user to input two numbers, then automatically skip theslash character, two more numbers, skip the slash, then two more numbers.
Another example (Canadian postal code):
GET_TEMPLATE "ANA NAN"
would require the user to input a letter, then a number, another letter,automatically skip the space, another number, another letter, and one
morenumber. No other characters (symbols or otherwise) would be allowed inthestring using the above template example.
CHKSYSPASS----------This function ("Check System Password") displays an SY: prompt to theuserand waits for the user to input the system password (with no echo). Ifthepassword is correct, the current logic state is set to TRUE, otherwise it
is set to FALSE.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
95/230
_______________________________________________________________________________Synchronet 48 InputFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
96/230
CREATE_SIF args: file
----------------This function is used to present the user with a SIF questionnaire and
storetheir answers in a data file. The str argument is the filename of a .SIFfile(without the .SIF extension) located in your Synchronet TEXT directory.Theuser's answers are stored in a data file whose path and filename arespecifiedin the current command string. The data file should be specified with theuser's number to ensure unique data filenames. Example:
SETSTR "C:\\SBBS\\USER%4.DAT"CREATE_SIF "NEWUSER"
This would read the file TEXT\NEWUSER.SIF and the user would fill-out thequestionnaire with all answers being stored in the fileC:\SBBS\USER####.DAT(where #### would be the user's number padded with zeros to four digits).The questionnaire could then be read back with the answers filled in.Example:
SETSTR "C:\\SBBS\\USER%4.DAT"READ_SIF "NEWUSER"
See the Synchronet Sysop Manual for details on the SIF questionnaireformat.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
97/230
_________________________________________________________________________
______Synchronet 49 InputFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
98/230
Miscellaneous Functions=======================
ONLINE
------Assume online execution (default mode), auto-return from module if userisdisconnected or logged off.
OFFLINE-------Assume offline execution, no carrier and no one online locally. If used(for OFFLINE modules), must be the FIRST executed function of the module.
LOGIN args: pwprompt
---------------Process login attempt using the current command string as the username/numberand pwprompt for the password prompt. This function may also prompt forthesystem password with the SY: prompt if the user has level 90 or higher.
LOGON-----Logon the currently logged-in user. This function must be called beforetheLOGIN module terminates if the user is to be allowed online. Thisfunction,
in turn, executs the LOGON module, if one is configured in SCFG.
LOGOFF------This function prompts the user if they really wish to log off. If theyanswer Yes, then any logoff events are executed and the LOGOFF menu fileis displayed before they are disconnected.
LOGOFF_FAST-----------This function immediately drops carrier and logs the user off. It differsfrom the HANGUP function in that it performs a SYNC function, then it
immediately drops carrier, as opposed to the HANGUP function wich doesnotperform a SYNC operation and has a buffer flush delay before actuallydropping carrier.
LOGOUT------Logout the currently logged-on user. This function is used solely forre-logging-in an already connected user.
NEWUSER-------Begins the new user application process.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
99/230
_________________________________________________________________________
______Synchronet 50 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
100/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
101/230
Force flush (write) of current node information (who's online, etc) todisk.
PAUSE_RESET-----------This function resets the line counter used for the automatic screen pause
feature.
_______________________________________________________________________________Synchronet 51 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
102/230
CLEAR_ABORT-----------This function clears the abort (Ctrl-C) status flag.
UNGETKEY--------This function puts the current command key into the input buffer to bethenext key retrieved with GETKEY, GETCMD, GETSTR, or similar functions.
UNGETSTR--------This function puts the entire contents of the current command string intotheinput buffer.
HANGUP------This function immediately disconnects and logs the user off.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
103/230
_______________________________________________________________________________Synchronet 52 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
104/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
105/230
---------------This function executes the online external program specified by it'sinternalcode with the 'code' argument. If an online external program is not foundwitha matching internal code or the user does not have access to that
program, thisfunction does nothing.
_______________________________________________________________________________Synchronet 53 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
106/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
107/230
_______________________________________________________________________________
Synchronet 54 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
108/230
NODE_ACTION NODEDEFS.INCargs: action
-------------------This function is used to set the current node action. The valid action
parameter (defined in NODEDEFS.INC) are:
Action Description~~~~~~ ~~~~~~~~~~~NODE_MAIN Main PromptNODE_RMSG Reading MessagesNODE_RMAL Reading MailNODE_SMAL Sending MailNODE_RTXT Reading G-FilesNODE_RSML Reading Sent MailNODE_PMSG Posting MessageNODE_AMSG Auto-message
NODE_XTRN Running External ProgramNODE_DFLT Main Defaults SectionNODE_XFER File Transfer PromptNODE_DLNG Downloading FileNODE_ULNG Uploading FileNODE_BXFR Bidirectional TransferNODE_LFIL Listing FilesNODE_LOGN Logging onNODE_LCHT In Local Chat with SysopNODE_MCHT In Multi-Chat with Other NodesNODE_GCHT In Local Chat with GuruNODE_CHAT In Chat SectionNODE_SYSP Sysop Activity
NODE_TQWK Transferring QWK packetNODE_PCHT In Private ChatNODE_PAGE Paging another node for Private ChatNODE_RFSD Retrieving file from seq dev (node.aux=dev)
Only one action parameter may be used.
INC_MAIN_CMDS-------------This function increments the "main menu command" counter that can be usedinARS comparisons.
INC_FILE_CMDS-------------This function increments the "file menu command" counter that can be usedinARS comparisons.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
109/230
_______________________________________________________________________________Synchronet 55 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
110/230
COMPARE_USER_MISC USERDEFS.INCargs: attrs
------------------------This function is used to compare the current user's miscellaneous
attributessto the attrs argument specified. If all the attrs specified are ENABLEDfor thecurrent user, then the current logic state is set to TRUE, otherwise itis setto FALSE. One or more of the following attributess (defined inUSERDEFS.INC)can be specified:
Attribute Description~~~~~~~~~ ~~~~~~~~~~~UM_EXPERT Expert menu mode
UM_DELETED Deleted userUM_INACTIVE Inactive userUM_AUTOTERM Automatic terminal type detectionUM_ANSI ANSI terminalUM_COLOR Color terminal (ANSI)UM_RIP RIP compatible terminalUM_WIP WIP compatible terminalUM_NO_EXASCII Extended ASCII not supportedUM_UPAUSE Automatic screen pauseUM_SPIN Spinning cursorUM_ANFSCAN Automatic new file scanUM_CLRSCRN Clear screen between messagesUM_QUIET Default to quiet mode (if 'Q' exempt)
UM_BATCHFLAG Batch flagging mode enabledUM_NETMAIL Forward E-mail to NetMailUM_CURSUB Remember current sub-board and directoryUM_ASK_NSCAN Ask for new-scans at logonUM_ASK_SSCAN Ask for your message scan at logonUM_COLDKEYS Cold keys (CR required - opposite of Hot Keys)UM_EXTDESC Extended file descriptions in listings
Multiple attributes can be specified by ORing them together with the OR(|)symbol. Example:
COMPARE_USER_MISC UM_ANSI|UM_COLOR
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
111/230
_______________________________________________________________________________
Synchronet 56 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
112/230
COMPARE_USER_CHAT USERDEFS.INC
args: attrs------------------------
This function is used to compare the current user's chat attributes totheattrs argument specified. If all the attrs specified are ENABLED for thecurrent user, then the current logic state is set to TRUE, otherwise itis setto FALSE. One or more of the following attributes (defined inUSERDEFS.INC) canbe specified:
Attribute Description~~~~~~~~~ ~~~~~~~~~~~CHAT_ECHO Echo users input in multinode chat
CHAT_ACTION Action commands enabled in multinode chatCHAT_NOPAGE This user can't be paged by other usersCHAT_NOACT This user will not receive node activity (logon/off)alertsCHAT_SPLITP This user prefers split-screen private node-to-node chat
Multiple attributes may be specified by ORing them together with the OR(|)symbol. Example:
COMPARE_USER_CHAT CHAT_NOACT|CHAT_NOPAGE
COMPARE_USER_QWK USERDEFS.INC
args: attrs-----------------------This function is used to compare the current user's QWK attributes to theattrsargument specified. If all the attrs specified are ENABLED for thecurrentuser, then the current logic state is set to TRUE, otherwise it is set toFALSE. One or more of the following attrs (defined in USERDEFS.INC) canbespecified:
Attribute Description
~~~~~~~~~ ~~~~~~~~~~~QWK_FILES Include new files list in QWK packetQWK_EMAIL Include unread e-mail/netmail messages in QWK packetQWK_ALLMAIL Include all mail in QWK packetQWK_DELMAIL Automatically delete packed e-mail after downloadQWK_BYSELF Include messages in QWK packet from selfQWK_EXPCTLA Expand Ctrl-A codes in messages to ANSIQWK_RETCTLA Retain (keep) Ctrl-A codes in messagesQWK_ATTACH Include file attachments in QWK packetQWK_NOINDEX Do not include .NDX files in QWK packetQWK_TZ Include time zone (@TZ) in messagesQWK_VIA Include message path (@VIA) in messagesQWK_NOCTRL Do not include control files (DOOR.ID, CONTROL.DAT, etc)
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
113/230
Multiple attributes may be specified by ORing them together with the OR(|)symbol. Example:
COMAPARE_USER_QWK QWK_TZ|QWK_VIA
_______________________________________________________________________________Synchronet 57 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
114/230
COMPARE_NODE_MISC NODEDEFS.INCargs: attrs
------------------------This function is used to compare the current node's misc attributes to
theattrs argument specified. If all the attrs specified are ENABLED for thecurrent node, then the current logic state is set to TRUE, otherwise itis setto FALSE. The valid attributes (defined in NODEDEFS.INC) are:
Attribute Description~~~~~~~~~ ~~~~~~~~~~~NODE_ANON Anonymous nodeNODE_LOCK Locked node (sysop's and N exempt users only)NODE_INTR Interrupted node (log user off ASAP)NODE_MSGW Short message waiting for this node
NODE_POFF Not available for pagingNODE_AOFF No node activity alertsNODE_UDAT User data has been updated by another nodeNODE_RRUN Re-run this node after user logs offNODE_EVENT Run node daily event after user logs offNODE_DOWN Down this node after user logs offNODE_NMSG Node message waiting for this nodeNODE_EXT Extended status information available for this node
Multiple attributes may be specified by ORing them together with the OR(|)symbol. Example:
COMPARE_NODE_MISC NODE_DOWN|NODE_INTR
TOGGLE_USER_MISC USERDEFS.INCargs: attrs
-----------------------This function is used to toggle specific attributes on or off for thecurrentuser. The valid attrs for the argument are identical to those used fortheCOMPARE_USER_MISC function.You cannot specify if you want the attribute turned ON or OFF with this
command. Use in combination with the COMPARE_USER_MISC function tospecificallyenable or disable a user's attribute. Example to turn the NETMAIL miscattr OFFfor the current user:
!INCLUDE USERDEFS.INCCOMPARE_USER_MISC UM_NETMAIL
IF_TRUETOGGLE_USER_MISC UM_NETMAIL
END_IF
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
115/230
_______________________________________________________________________________Synchronet 58 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
116/230
TOGGLE_USER_CHAT USERDEFS.INCargs: attrs
-----------------------This function is used to toggle specific chat attributes on or off for
thecurrent user. The valid attrs for the argument are identical tothose used for the COMPARE_USER_CHAT function.
You cannot specify if you want the attribute turned ON or OFF with thiscommand. Use in combination with the COMPARE_USER_CHAT function tospecificallyenable or disable a chat attribute. Example to turn the Split ScreenPrivateChat (CHAT_SPLITP) attribute OFF for the current user:
COMPARE_USER_CHAT CHAT_SPLITP
IF_TRUETOGGLE_USER_CHAT CHAT_SPLITPEND_IF
TOGGLE_USER_QWK USERDEFS.INCargs: attrs
----------------------This function is used to toggle specific QWK attributes on or off for thecurrent user. The valid attrs for the argument are identical to thoseused forthe COMPARE_USER_QWK function.
You cannot specify if you want the attr turned ON or OFF with this
command. Usein combination with the COMPARE_USER_QWK function to specifically enableordisable a QWK attribute.
TOGGLE_NODE_MISC NODEDEFS.INCargs: attrs
-----------------------This function is used to toggle the miscellaneous attributes associatedwiththe current node. The valid attrs for the argument are identical to thoseused
for the COMPARE_NODE_MISC function.
TOGGLE_USER_FLAG args: set flag
-----------------------------This function is used to toggle the state of one of the current user'sflags.The first argument is a single character indicating the flag set. Validflag sets are 1, 2, 3, 4, or E for exemption, or R for restriction. Thesecond argument is the actual flag character to toggle (A through Z).
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
117/230
_______________________________________________________________________________Synchronet 59 MiscellaneousFunctions
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
118/230
ADJUST_USER_CREDITS args: adj
------------------------This function is used to add or subtract credits from the current user.
The'adj' argument must be either a positive or negative number (inKilobytes).Example, to subtract 100K in credits from the current user:
ADJUST_USER_CREDITS -100
ADJUST_USER_MINUTES args: adj
------------------------This function is used to add or subtract minutes from the current user'sminute bank. The 'adj' argument must be either a positive or negative
number.Example, to subtract 60 minutes from the current user:
ADJUST_USER_MINUTES -60
SET_USER_LEVEL args: level
---------------------This function changes the current user's security level to the numberpassedas the argument.
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
119/230
-
8/14/2019 Baja Version 2.10 Shell/Module Compiler for Synchronet
120/230
SET_USER_STRING USERDEFS.INCargs: user_string
----------------------------This fucntion changes one of the current user's text string fields to the
value of the current command string. The u