Category : BBS Programs+Doors
Archive   : FREETIME.ZIP
Filename : FREETIME.PAS

 
Output of file : FREETIME.PAS contained in archive : FREETIME.ZIP
PROGRAM FreeTime (Input, Output);
USES DOS;

TYPE FlagType= Array [001..004] OF Byte;

SysInfoRecord= {* SYSINFO.BBS *}
RECORD
CallCount: LongInt;
LastCaller: String [35];
ExtraSpace: Array [001..128] OF Byte
END;

TimeLogRecord= {* TIMELOG.BBS *}
RECORD
StartDate: String [8];
BusyPerHour: Array [000..023] OF Integer;
BusyPerDay: Array [000..006] OF Integer
END;

EventRecord=
RECORD
Status: Byte; { 0=Deleted 1=Enabled 2=Disabled }
RunTime: String [5];
ErrorLevel: Byte;
Days: Byte;
Forced: Boolean;
LastTimeRun: String [8]
END;

UserRecord= {* USERS.BBS *}
RECORD
Name: String [35];
City: String [25];
Pwd: String [15];
DataPhone,
HomePhone: String [12];
LastTime: String [5];
LastDate: String [8];
Attrib: Byte;
Flags: FlagType;
Credit,
Pending,
TimesPosted,
HighMsgRead,
SecLvl,
Times,
Ups,
Downs,
UpK,
DownK,
TodayK,
Elapsed,
Len: Integer;
ExtraSpace: Array [1..8] of Byte
END;

ExitRecord= {* EXITINFO.BBS *}
RECORD
BaudRate: Integer;
SysInfo: SysInfoRecord;
TimeLogInfo: TimeLogRecord;
UserInfo: UserRecord;
EventInfo: EventRecord;
NetMailEntered: Boolean;
EchoMailEntered: Boolean;
LoginTime: String [5];
LoginDate: String [8];
TmLimit: Integer;
LoginSec: LongInt;
Credit: LongInt;
UserRecNum: Integer;
ReadThru: Integer;
PageTimes: Integer;
DownLimit: Integer
END;

VAR TimeFile: TEXT;
ExitFile: FILE OF ExitRecord;
ExitRec: ExitRecord;
Option: String [1];

Hour, Min, Sec, Sec100, eMin, eSec: WORD;
FileT: LongInt; FTime: DateTime;

BEGIN
WriteLn ;
WriteLn ( 'FreeTime ³ v2.00.20.05.89 ³ Fidonet 1:141/234.0 ³ (203) 834-0367' );
WriteLn ;

IF ParamCount = 0
THEN BEGIN WriteLn ( 'Syntax: FREETIME [SAVE³LOAD]' ); Halt END;

Assign ( ExitFile, 'EXITINFO.BBS' );
Assign ( TimeFile, 'FREETIME.DAT' );

Option := ParamStr ( 1 ); Option[ 1 ] := UpCase ( Option[1] );

IF ( Option[1]='S' )
THEN BEGIN

GetTime ( Hour, Min, Sec, Sec100 );
ReWrite ( TimeFile ); Close ( TimeFile );
WriteLn ( 'FreeTime³SAVE ',Hour,'.',Min )

END ELSE
IF ( Option[1]='L' )
THEN BEGIN

{$I-} Reset ( TimeFile ); {$I+}

IF ( IOresult<>0 )
THEN BEGIN WriteLn ( 'FreeTime³MISSING' ); Halt END;

GetFTime ( TimeFile, FileT ); UnpackTime ( FileT, FTime );
Close ( TimeFile ); Erase ( TimeFile );

GetTime ( Hour, Min, Sec, Sec100 );
IF ( Min IF ( Sec
eMin := Min-FTime.Min; eSec := Sec-FTime.Sec;

IF ( eMin>0 ) OR ( eSec>0 )
THEN WITH ExitRec
DO BEGIN

{$I-} Reset ( ExitFile ); {$I+}
IF ( IOresult<>0 )
THEN BEGIN WriteLn ( 'ExitInfo³MISSING' ); Halt END;

Read ( ExitFile, ExitRec );

LoginSec := ( LoginSec+LongInt (eMin*60) );
LoginSec := ( LoginSec+LongInt (eSec ) );

IF ( LoginSec>86400 )
THEN Dec ( LoginSec, 86400 );

ReWrite ( ExitFile ); Write ( ExitFile, ExitRec );
Close ( ExitFile );

WriteLn ;
WriteLn ( 'FreeTime³LOAD ',eMin,'.',eSec )
END
END
END.


  3 Responses to “Category : BBS Programs+Doors
Archive   : FREETIME.ZIP
Filename : FREETIME.PAS

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/