home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
ftp.wwiv.com
/
ftp.wwiv.com.zip
/
ftp.wwiv.com
/
pub
/
BBS
/
CEL141.ZIP
/
CEL141C.ZIP
/
TOOLKIT.ZIP
/
RECORDS.PAS
< prev
next >
Wrap
Pascal/Delphi Source File
|
1992-08-14
|
16KB
|
470 lines
const ver='1.41'; {Version number}
Mailer='CelMail v1.1';
NetVer='1.5'; {Network Version}
MailVer=1;
maxconf=5; {Number of conferences}
mailversion=1; {CelerityNet Mail Version}
postversion=1; {CelerityNet Bulletin Version}
maxbatch=30; {Maximum number of files to batch}
maxmessagesize=100; {Maxiumum # of lines in a post}
maxlastcallers=250; {Length of last caller list}
sectorsize=512;
numsectors=20000;
maxcatalogsize=100;
maxgroupsize=50;
maxsyslogsize=1000;
type anystr=string[128];
lstr=string[80];
mstr=string[30];
sstr=string[15];
cstr=string[45];
accesstype=(bylevel,keepout,letin,invalid); {Post access}
availtype=(available,bytime,notavailable); {Sysop available}
configtype=(linefeeds,postprompts,moreprompts,asciigraphics,
fudsysop,fbulletinsysop,fvotingsysop,femailsysop,fdoorsysop,fmainsysop,
fdatabasesysop,fNewUserSysop,fgfsysop );
boardorder=array [0..255,1..maxconf] of byte; {Order of subs}
filelisttype=(ffname,ffext,fffulnam,ffofwhat,ffsize,ffpoints,ffuploader,
ffuploaded,ffdown,ffdescript); {Configurable file listings}
NuvSet=set of 1..255;
type userrec=record {Version 1.40}
UserID:longint; {User identification number}
handle:mstr; {User's handle}
realname:mstr; {User's real first/last name}
InterNetName:sstr; {name for internet mail}
Signature:lstr; {User's signature}
Address:array[1..2] of mstr; {Street Address}
macro:array[1..3] of mstr; {Macros}
note:mstr; {User note: 'Sysop of XXX' etc.}
PrivNote:lstr; {Sysop note}
password:sstr; {Password}
phonenum:string[12]; {Phone #. If blank, user will be prompted}
laston:longint; {Last time on in PackTime format}
NumCalls, {Number of calls to system}
temp1:integer;
totaltime:real; {Total time spent on board}
udlevel, {Xfer section access level}
level, {Main BBS access level -5 through 100}
HelpLevel:integer; {Novice / Expert Mode}
udpoints:longint; {Current file points}
Access:Longint; {Access flags} {for next ver}
SpareLongs:array[1..8] of longint; {unused}
AutoChatCall:boolean; {Call chat upon login}
infoforms:array[1..5] of integer;
{Location values for Infoforms. Set to -1}
regularcolor, {User's color values. Setting to 0 will}
promptcolor, {cause system to remap them to the current}
statcolor, {defaults, as set in config.}
inputcolor,
fifthcolor,
sixthcolor,
seventhcolor,
eighthcolor,
displaylen:byte; {User's display length. 20-50 lines.}
lastmessages, {Used for determining "how many new posts"}
lastups:integer; {'' "new uploads"}
SingleKey:boolean; {use single key input}
defproto:char; {Default xfer protocol. Character.}
hack:byte; {Hack attempts since last call. If >5, ask for phone #}
config:set of configtype;
{Certain configuration options for user/access}
newscanconfig, {User subboard newscan data}
access1, {User access flags for subs}
access2:set of byte; {Second access flag set for subs}
lastread:array [0..40,1..maxconf] of word;
{Last post read on each sub}
confaccess: array [0..maxconf] of boolean;
{Conference access flags}
XferConfAccess:array[0..maxconf] of boolean;
XferScan:array[0..50,0..maxconf] of boolean; {xfer scan flags}
lastcps, {Average cps rate for downloading}
cpstimes:word; {Times counted for average}
filelister:array[1..3] of set of filelisttype;
{File listing configuration}
CurList:byte; {Which list currently in use?}
commpoints, {Points gained via commission since last call}
valpoints:integer; {Points gained from validation since last call}
ScanNet:boolean; {Flag to scan CelerityNet subs or not}
quikconf:array[1..maxconf] of boolean;
{Quickscan conferences flags}
QuikXferConf:array[1..maxconf] of boolean;
{Quickscan xfer conferences}
userpcr, {Individual post/call ratio. 0=use default}
userudr, {Individual upload/download ratio. 0=default}
usergenr, {General ratio}
age:byte; {User's age. 6-89. If less than 0, user will
be prompted for both age and sex}
usersex:boolean; {True=female. Approved by Deanna Elizalda, Feminist}
Expiration, {Date of account expiration}
birthdate:longint; {date of birth}
voteyes, {Number of votes cast for validation in NUV}
voteno:byte; {Number against user in NUV}
timeperday:byte; {Individual user's time per day. 0=default by lvl}
Posts_Month,
Posts_all,
Uploads_Month,
Uploads_All,
Dnloads_Month,
Dnloads_all:integer;
UpBytes_Month,
UpBytes_All,
DnBytes_Month,
DnBytes_All:longint;
PBytes_All,
PBytes_Month:longint;
KperDay,
KToday:Word;
NoNet:boolean; {Deny net access}
Exempt:array[1..5] of boolean;
{1-pcr, 2=udr, 3=genr, 4=, 5=xfer}
SpecialAccess:boolean;
AutoQwk:boolean; {Auto-create QWK Packet}
QwkUpdate:boolean; {Update Pointers in QWK packet}
QwkPacker:char; {code for QWK packer}
UseYesNo,
UseFloatPrompt,
UseColor:boolean;
UseSignature:boolean;
UseFSE:boolean;
PermitPaging:boolean;
SkipTopTen:boolean;{unused}
TermEmul:byte; {0=none, 1=vt52, 2=vt52 Atari, 3=vt100, 4=ANSI,
5=Avatar level 0}
SysopFlags:longint; {sysop flags #1 to 32}
AreaAccess:longint;
VoteData:array[1..8] of byte; {vote data - nybbles}
TimeCredit:longint; {Time credit remaining today}
temp4,
temp5,
temp6:longint;
end;
newBBSrec=record
name:string[24];
Descript:string[60];
Number:string[20];
DeviceType:byte; {0=bbs, 1=VMB, 2=NUA}
software:string[8];
megs:word;
maxbaud:string[4];
lines:byte;
mnp:boolean;
HST:boolean;
V32:boolean;
V42:boolean;
V42bis:boolean;
V32bis:boolean;
Allow24k:boolean;
Allow2200:boolean;
Allow1920:boolean;
Allow1680:boolean;
Allow1440:boolean;
Allow9600:boolean;
Allow2400:boolean;
Allow1200:boolean;
leftby:mstr;
when:longint;
end;
TopTenRec=record
name:mstr;
kup,kdn:longint;
numup,numdn:word;
posts:word;
code:byte;
end;
NewUserVoteRec=record
handle:mstr;
usernum:integer;
voteyes,voteno:NuvSet;
Comment:array[1..10] of string[84];
end;
userspecsrec=record {quick-lookup user file}
name:mstr;
minlevel,maxlevel,minlaston,maxlaston:integer;
minpcr,maxpcr:real
end;
boardrec=record {Description of sub-board}
boardname :mstr; {Name of sub}
sponsor :mstr; {Name of sub-sysop}
entrypw :mstr; {Unused}
netidnum :word; {Network ID number}
netpwd :sstr;
level :integer; {Level required for access}
autodel :integer; {Maximum posts on sub}
anonymous :boolean; {Allow anonymous posts}
RealNames :boolean; {Require real names rather than handles}
AllowANSI :boolean; {unused.}
shortname :sstr; {Access code for sub. Usually numeric}
fidopath :lstr; {Fido pathname. Not currently used.}
DataName :lstr; {Date file pathname. Not used.}
OriginLine:lstr; {Individual sub origin line}
Zone,
Net,
Node,
Point:word; {For Fido path}
AreaName :lstr; {MercuryNet}
MercNode :string[12]; {MercuryNet Node #}
end;
bulrec=record {Post data}
leftby, {Author of post}
leftto:mstr; {Addressed to..}
title, {Title of post}
status:mstr; {User's note}
when:longint; {When posted. Packtime format.}
where:lstr; {First net origin line}
where2:lstr; {Second net origin line}
version:byte; {Network version}
anon, {Anonymous post}
recieved:boolean; {Received by recipient}
line, {Lines in post}
plevel:integer; {Access level of poster}
id:word; {Data file address}
cnet, {All unused flags}
fidonet,
flag3,
flag4,
flag5,
flag6,
flag7,
flag8:boolean;
realname:mstr; {Real name of poster}
end;
message=record
text:array [1..maxmessagesize] of lstr;
leftto:mstr;
title:lstr;
anon:boolean;
numlines:integer
end;
NetPostRec=record {Record for networked posts}
NetIdNum: byte;
BulletinRec: bulrec;
MessageRec: message;
end;
nodelistrec=record {Node list record}
nodenum:string[7];
nodepass:string[15];
bbsname:string[30];
bbsnumber:string[12];
firstdate:longint;
lastdate:longint;
numconnects:word;
end;
MailIndexRec=record
offset : longint;
size : word;
deleted : boolean; {indication if record has been deleted}
version : byte;
Title : mstr;
LeftTo : mstr;
LeftAddr : word; {Node to be sent to}
Sender : mstr;
SenderAddr : sstr; {User address mail sent from}
ForwardBy : mstr; {was forwarded by}
When : longint;
Where1,
Where2 : lstr;
return, {Send a return receipt}
anon,
read : boolean; {Anonymous / has read mail}
filename : string[12]; {Attached file}
end;
NetSubRec=record
NetIdNum:byte;
Conference:lstr;
Comment:lstr;
end;
Newsrec=Record {record for news}
Location:Integer;
Level:Integer;
From:mstr;
where:lstr;
When:longint;
Title:String[28];
MaxLevel:Integer;
End;
lastrec=record {last callers}
name:mstr;
callnum:longint;
when:longint;
speed:mstr;
end;
XferListRec=record
Username:mstr;
Filename:mstr;
Size:longint;
When:longint;
cps:word;
end;
buffer=array [1..sectorsize] of char;
parsedentry=array [1..maxcats] of anystr;
udrec=record
sentby:mstr; { Who uploaded the file}
when, { When was it uploaded}
whenrated:longint; { When was it validated}
filename, { DOS filename}
dlpw:sstr; { Password to download it}
path:string[50]; { Full pathname pointing to location}
points:integer; { Cost to download}
filesize:longint; { Size (in bytes)}
descrip:lstr; { 44 character description}
downloaded:integer; { Number of times downloaded}
newfile, { Unvalidated file}
specialfile:boolean; { Special request}
progname:string[20]; { This is the full name of the program}
ofwhat1,ofwhat2:byte; { These are for "disk x of y"}
ptsgiven:integer; { How many validation points awarded}
private:mstr; { Who is a private file for}
end;
arearec=record {Transfer Area}
name, { Name of xfer volume}
xmodemdir:lstr; { Pathname of xfer section}
sponsor, { Cosysop for xfer section}
areapw:mstr; { Password to enter area. Unused.}
slowdrive:boolean; { If "Slow drive", like a WORM, the system
wont check for existance of file when
listing files}
level:integer; { Level required to enter section}
upload, { Allow uploads to section}
download:boolean; { Allow downloads from section}
dataname:lstr; { A path for the data file, to facilitate
multiple conference access to the area}
end;
OneLinerRec=record
author:mstr;
origin:mstr;
when :longint;
Line :lstr;
end;
ArtRecord=record
author:mstr;
origin:mstr;
when:longint;
filename:sstr;
Descript:lstr;
end;
doorRecord=record
name:mstr;
level:byte;
numused:word;
Commandline:lstr;
doortype:byte;
{0=Celerity, 1=Door.sys, 2=dorinfo.def, 3=chain.txt}
Collapse:boolean;
end;
logrec=record {Sysop log}
menu,subcommand:integer;
param:string[41];
when:longint
end;
syslogdatrec=record
menu,subcommand:integer;
text:mstr
end;
ModemLogRec=record
ConnectString:lstr;
speed:word;
result:byte;
end;
protorec=record {Protocol choice record}
letter:char;
desc:string[30];
progname:string[12];
commfmt:string[60];
end;
SystemHistoryRec=record
calls,posts,feedback,email,newusers,uploads,downloads,daynumber:integer;
netmaid:boolean;
date:sstr;
temp1,temp2,temp3,temp4,temp5:integer;
end;
NodeIDRec=record
Username:sstr;
ChatAvail:boolean;
ChatRequest:byte;
Activity:byte;
Update:longint;
end;
{Activities in NodeIDRec:
0:nothing
1:down
2:waiting for call
3:in login shell
4:main menu
5:in newscan
6:in xfers
7:xfering files
8:multinode chat
9:sysop chat
10:new user applying
11:qwk processor
12:using a door
13:in login sequence
}
(*
These are the basic pascal record types used for Celerity v1.40. Most data
files are random-access files consisting of equal records, and described
below. If you are writing in another language, you can read these files
but will need to know some of the details:
A "string" is an array of characters as large as the definition (string[20]
would mean 20 characters) preceded by a length byte. This byte tells how
many of those characters are in use. A length byte of value $04 would mean
that the first four characters hold valid data, and the rest of the array
is to be ignored.
An "integer" is a signed 16-bit integer number (-32768 to 32767).
A "longint" is a signed 32-bit integer
A "word" is an unsigned 16-bit integer (0 to 65535).
*)