Restructure of filebase list data files
This commit is contained in:
parent
47810eeefc
commit
85f02a78bf
|
@ -6,11 +6,24 @@ Program UP110;
|
||||||
|
|
||||||
Uses
|
Uses
|
||||||
CRT,
|
CRT,
|
||||||
m_Strings;
|
DOS,
|
||||||
|
m_Strings,
|
||||||
|
m_FileIO;
|
||||||
|
|
||||||
{$I RECORDS.PAS}
|
{$I RECORDS.PAS}
|
||||||
|
|
||||||
Type
|
Type
|
||||||
|
OldFDirRec = Record { *.DIR }
|
||||||
|
FileName : String[70]; { File name }
|
||||||
|
Size : LongInt; { File size (in bytes) }
|
||||||
|
DateTime : LongInt; { Date and time of upload }
|
||||||
|
Uploader : String[30]; { User name who uploaded the file }
|
||||||
|
Flags : Byte; { Set of FDIRFLAGS (see above) }
|
||||||
|
Pointer : LongInt; { Pointer to file description }
|
||||||
|
Lines : Byte; { Number of description lines }
|
||||||
|
DLs : Word; { # of times this file was downloaded}
|
||||||
|
End;
|
||||||
|
|
||||||
ExtAddrType = Record
|
ExtAddrType = Record
|
||||||
Zone,
|
Zone,
|
||||||
Net,
|
Net,
|
||||||
|
@ -955,20 +968,71 @@ Begin
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
|
Procedure ConvertFileLists;
|
||||||
|
Var
|
||||||
|
DirInfo : SearchRec;
|
||||||
|
OldList : OlDFDirRec;
|
||||||
|
OldFile : File of OldFDirRec;
|
||||||
|
List : RecFileList;
|
||||||
|
ListFile : File of RecFileList;
|
||||||
|
FN : String;
|
||||||
|
Begin
|
||||||
|
WriteLn ('[-] Updating file listings...');
|
||||||
|
|
||||||
|
FindFirst (Config.DataPath + '*.dir', AnyFile, DirInfo);
|
||||||
|
|
||||||
|
While DosError = 0 Do Begin
|
||||||
|
FN := Config.DataPath + JustFile(DirInfo.Name) + '.old';
|
||||||
|
|
||||||
|
RenameFile (Config.DataPath + DirInfo.Name, FN);
|
||||||
|
|
||||||
|
Assign (OldFile, FN);
|
||||||
|
Reset (OldFile);
|
||||||
|
|
||||||
|
Assign (ListFile, Config.DataPath + DirInfo.Name);
|
||||||
|
ReWrite (ListFile);
|
||||||
|
|
||||||
|
While Not Eof(OldFile) Do Begin
|
||||||
|
Read (OldFile, OldList);
|
||||||
|
|
||||||
|
List.FileName := OldList.FileName;
|
||||||
|
List.Size := OldList.Size;
|
||||||
|
List.DateTime := OldList.DateTime;
|
||||||
|
List.Uploader := OldList.Uploader;
|
||||||
|
List.Flags := OldList.Flags;
|
||||||
|
List.Downloads := OldList.DLs;
|
||||||
|
List.Rating := 0;
|
||||||
|
List.DescPtr := OldList.Pointer;
|
||||||
|
List.DescLines := OldList.Lines;
|
||||||
|
|
||||||
|
Write (ListFile, List);
|
||||||
|
End;
|
||||||
|
|
||||||
|
Close (OldFile);
|
||||||
|
Close (ListFile);
|
||||||
|
|
||||||
|
DeleteFile (FN);
|
||||||
|
FindNext (DirInfo);
|
||||||
|
End;
|
||||||
|
|
||||||
|
FindClose(DirInfo);
|
||||||
|
End;
|
||||||
|
|
||||||
Var
|
Var
|
||||||
ConfigFile : File of RecConfig;
|
ConfigFile : File of RecConfig;
|
||||||
Begin
|
Begin
|
||||||
WarningDisplay;
|
WarningDisplay;
|
||||||
|
|
||||||
// comment this out ONLY IF config needs converting
|
// COMMENT this out if mystic.dat is being converted:
|
||||||
// Assign (ConfigFile, 'mystic.dat');
|
Assign (ConfigFile, 'mystic.dat');
|
||||||
// Reset (ConfigFile);
|
Reset (ConfigFile);
|
||||||
// Read (ConfigFile, Config);
|
Read (ConfigFile, Config);
|
||||||
// Close (ConfigFile);
|
Close (ConfigFile);
|
||||||
|
|
||||||
ConvertConfig; //1.10a11
|
// ConvertConfig; //1.10a11
|
||||||
// ConvertUsers; //1.10a11
|
// ConvertUsers; //1.10a11
|
||||||
//ConvertSecurity; //1.10a11
|
//ConvertSecurity; //1.10a11
|
||||||
|
ConvertFileLists; //1.10a11
|
||||||
|
|
||||||
// ConvertArchives; //1.10a1
|
// ConvertArchives; //1.10a1
|
||||||
// ConvertGroups; //1.10a1
|
// ConvertGroups; //1.10a1
|
||||||
|
|
|
@ -24,7 +24,7 @@ Type
|
||||||
|
|
||||||
TFileBase = Class
|
TFileBase = Class
|
||||||
FBaseFile : File of FBaseRec;
|
FBaseFile : File of FBaseRec;
|
||||||
FDirFile : File of FDirRec;
|
FDirFile : File of RecFileList;
|
||||||
FScanFile : File of FScanRec;
|
FScanFile : File of FScanRec;
|
||||||
ProtocolFile : File of RecProtocol;
|
ProtocolFile : File of RecProtocol;
|
||||||
FGroupFile : File of RecGroup;
|
FGroupFile : File of RecGroup;
|
||||||
|
@ -32,7 +32,7 @@ Type
|
||||||
FBase : FBaseRec;
|
FBase : FBaseRec;
|
||||||
FGroup : RecGroup;
|
FGroup : RecGroup;
|
||||||
FScan : FScanRec;
|
FScan : FScanRec;
|
||||||
FDir : FDirRec;
|
FDir : RecFileList;
|
||||||
Arc : RecArchive;
|
Arc : RecArchive;
|
||||||
Protocol : RecProtocol;
|
Protocol : RecProtocol;
|
||||||
BatchNum : Byte;
|
BatchNum : Byte;
|
||||||
|
@ -261,12 +261,12 @@ Function TFileBase.ImportDIZ (FN: String) : Boolean;
|
||||||
Var
|
Var
|
||||||
A : Byte;
|
A : Byte;
|
||||||
Begin
|
Begin
|
||||||
For A := Num To FDir.Lines - 1 Do
|
For A := Num To FDir.DescLines - 1 Do
|
||||||
Session.Msgs.Msgtext[A] := Session.Msgs.MsgText[A + 1];
|
Session.Msgs.Msgtext[A] := Session.Msgs.MsgText[A + 1];
|
||||||
|
|
||||||
Session.Msgs.MsgText[FDir.Lines] := '';
|
Session.Msgs.MsgText[FDir.DescLines] := '';
|
||||||
|
|
||||||
Dec (FDir.Lines);
|
Dec (FDir.DescLines);
|
||||||
End;
|
End;
|
||||||
|
|
||||||
Var
|
Var
|
||||||
|
@ -281,25 +281,25 @@ Begin
|
||||||
|
|
||||||
If IoResult = 0 Then Begin
|
If IoResult = 0 Then Begin
|
||||||
Result := True;
|
Result := True;
|
||||||
FDir.Lines := 0;
|
FDir.DescLines := 0;
|
||||||
|
|
||||||
While Not Eof(tFile) Do Begin
|
While Not Eof(tFile) Do Begin
|
||||||
Inc (FDir.Lines);
|
Inc (FDir.DescLines);
|
||||||
ReadLn (tFile, Session.Msgs.MsgText[FDir.Lines]);
|
ReadLn (tFile, Session.Msgs.MsgText[FDir.DescLines]);
|
||||||
Session.Msgs.MsgText[FDir.Lines] := strStripLOW(Session.Msgs.MsgText[FDir.Lines]);
|
Session.Msgs.MsgText[FDir.DescLines] := strStripLOW(Session.Msgs.MsgText[FDir.DescLines]);
|
||||||
If Length(Session.Msgs.MsgText[FDir.Lines]) > mysMaxFileDescLen Then Session.Msgs.MsgText[FDir.Lines][0] := Chr(mysMaxFileDescLen);
|
If Length(Session.Msgs.MsgText[FDir.DescLines]) > mysMaxFileDescLen Then Session.Msgs.MsgText[FDir.DescLines][0] := Chr(mysMaxFileDescLen);
|
||||||
If FDir.Lines = Config.MaxFileDesc Then Break;
|
If FDir.DescLines = Config.MaxFileDesc Then Break;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
Close (tFile);
|
Close (tFile);
|
||||||
|
|
||||||
FileErase(Session.TempPath + 'file_id.diz');
|
FileErase(Session.TempPath + 'file_id.diz');
|
||||||
|
|
||||||
While (Session.Msgs.MsgText[1] = '') and (FDir.Lines > 0) Do
|
While (Session.Msgs.MsgText[1] = '') and (FDir.DescLines > 0) Do
|
||||||
RemoveLine(1);
|
RemoveLine(1);
|
||||||
|
|
||||||
While (Session.Msgs.MsgText[FDir.Lines] = '') And (FDir.Lines > 0) Do
|
While (Session.Msgs.MsgText[FDir.DescLines] = '') And (FDir.DescLines > 0) Do
|
||||||
Dec (FDir.Lines);
|
Dec (FDir.DescLines);
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
|
@ -510,8 +510,8 @@ Begin
|
||||||
WriteLn (TF, FDir.FileName);
|
WriteLn (TF, FDir.FileName);
|
||||||
Write (TF, ' `- ' + strPadL(strComma(FDir.Size), 11, ' ') + ' ' + DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType) + ' ');
|
Write (TF, ' `- ' + strPadL(strComma(FDir.Size), 11, ' ') + ' ' + DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType) + ' ');
|
||||||
|
|
||||||
Seek (DF, FDir.Pointer);
|
Seek (DF, FDir.DescPtr);
|
||||||
For A := 1 to FDir.Lines Do Begin
|
For A := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DF, Temp[0], 1);
|
BlockRead (DF, Temp[0], 1);
|
||||||
BlockRead (DF, Temp[1], Ord(Temp[0]));
|
BlockRead (DF, Temp[1], Ord(Temp[0]));
|
||||||
If A = 1 Then WriteLn (TF, Temp) Else WriteLn (TF, strRep(' ', 27) + Temp);
|
If A = 1 Then WriteLn (TF, Temp) Else WriteLn (TF, strRep(' ', 27) + Temp);
|
||||||
|
@ -1349,7 +1349,7 @@ Function TFileBase.ListFileAreas (Compress: Boolean) : Integer;
|
||||||
Var
|
Var
|
||||||
Total : Word = 0;
|
Total : Word = 0;
|
||||||
Listed : Word = 0;
|
Listed : Word = 0;
|
||||||
tDirFile : File of FDirRec;
|
tDirFile : File of RecFileList;
|
||||||
Begin
|
Begin
|
||||||
Reset (FBaseFile);
|
Reset (FBaseFile);
|
||||||
|
|
||||||
|
@ -1588,8 +1588,8 @@ Var
|
||||||
3 : Begin
|
3 : Begin
|
||||||
T2 := Bool_Search(Data, FDir.FileName);
|
T2 := Bool_Search(Data, FDir.FileName);
|
||||||
If Not T2 Then Begin
|
If Not T2 Then Begin
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
For A := 1 to FDir.Lines Do Begin
|
For A := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DataFile, Temp[0], 1);
|
BlockRead (DataFile, Temp[0], 1);
|
||||||
BlockRead (DataFile, Temp[1], Length(Temp));
|
BlockRead (DataFile, Temp[1], Length(Temp));
|
||||||
If Bool_Search(Data, Temp) Then Begin
|
If Bool_Search(Data, Temp) Then Begin
|
||||||
|
@ -1696,11 +1696,11 @@ Var
|
||||||
If Not OkFile Then Continue;
|
If Not OkFile Then Continue;
|
||||||
|
|
||||||
If TopDesc > 0 Then Begin
|
If TopDesc > 0 Then Begin
|
||||||
Inc (Count, FDir.Lines - (FDir.Lines - TopDesc + 1) + 1);
|
Inc (Count, FDir.DescLines - (FDir.DescLines - TopDesc + 1) + 1);
|
||||||
If TopDesc = FDir.Lines + 2 Then Dec(Count);
|
If TopDesc = FDir.DescLines + 2 Then Dec(Count);
|
||||||
TopDesc := 0;
|
TopDesc := 0;
|
||||||
End Else Begin
|
End Else Begin
|
||||||
Inc (Count, FDir.Lines + 1);
|
Inc (Count, FDir.DescLines + 1);
|
||||||
If FBase.ShowUL Then Inc(Count);
|
If FBase.ShowUL Then Inc(Count);
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
@ -1838,7 +1838,7 @@ Var
|
||||||
Session.io.PromptInfo[3] := ' ';
|
Session.io.PromptInfo[3] := ' ';
|
||||||
Session.io.PromptInfo[4] := GetFileListSize;
|
Session.io.PromptInfo[4] := GetFileListSize;
|
||||||
Session.io.PromptInfo[5] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
Session.io.PromptInfo[5] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
||||||
Session.io.PromptInfo[6] := strI2S(FDir.DLs);
|
Session.io.PromptInfo[6] := strI2S(FDir.Downloads);
|
||||||
|
|
||||||
List[ListSize + 1].Batch := False;
|
List[ListSize + 1].Batch := False;
|
||||||
|
|
||||||
|
@ -1864,10 +1864,10 @@ Var
|
||||||
End Else
|
End Else
|
||||||
HeaderCheck;
|
HeaderCheck;
|
||||||
|
|
||||||
If BotDesc <= FDir.Lines + 2 Then Begin { skip if 1st line is uler }
|
If BotDesc <= FDir.DescLines + 2 Then Begin { skip if 1st line is uler }
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
|
|
||||||
For A := 1 to FDir.Lines Do Begin
|
For A := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DataFile, Str[0], 1);
|
BlockRead (DataFile, Str[0], 1);
|
||||||
BlockRead (DataFile, Str[1], Ord(Str[0]));
|
BlockRead (DataFile, Str[1], Ord(Str[0]));
|
||||||
|
|
||||||
|
@ -1878,7 +1878,7 @@ Var
|
||||||
If A = 1 Then Begin
|
If A = 1 Then Begin
|
||||||
Session.io.PromptInfo[1] := GetFileListSize;
|
Session.io.PromptInfo[1] := GetFileListSize;
|
||||||
Session.io.PromptInfo[2] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
Session.io.PromptInfo[2] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
||||||
Session.io.PromptInfo[3] := strI2S(FDir.DLs);
|
Session.io.PromptInfo[3] := strI2S(FDir.Downloads);
|
||||||
Session.io.PromptInfo[4] := Str;
|
Session.io.PromptInfo[4] := Str;
|
||||||
Session.io.PromptInfo[5] := FDir.Uploader;
|
Session.io.PromptInfo[5] := FDir.Uploader;
|
||||||
OK := ShowText(strDesc);
|
OK := ShowText(strDesc);
|
||||||
|
@ -1891,7 +1891,7 @@ Var
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
If BotDesc > FDir.Lines Then Begin
|
If BotDesc > FDir.DescLines Then Begin
|
||||||
If FBase.ShowUL Then Begin
|
If FBase.ShowUL Then Begin
|
||||||
OK := ShowText(strUploader);
|
OK := ShowText(strUploader);
|
||||||
If OK Then
|
If OK Then
|
||||||
|
@ -2334,8 +2334,8 @@ Var
|
||||||
|
|
||||||
Procedure Check_Area;
|
Procedure Check_Area;
|
||||||
Var
|
Var
|
||||||
TempFile : File of FDirRec;
|
TempFile : File of RecFileList;
|
||||||
Temp : FDirRec;
|
Temp : RecFileList;
|
||||||
Begin
|
Begin
|
||||||
Assign (TempFile, Config.DataPath + FBase.FileName + '.dir');
|
Assign (TempFile, Config.DataPath + FBase.FileName + '.dir');
|
||||||
{$I-} Reset (TempFile); {$I+}
|
{$I-} Reset (TempFile); {$I+}
|
||||||
|
@ -2382,21 +2382,21 @@ Begin
|
||||||
|
|
||||||
Session.io.OutFullLn (Session.GetPrompt(72));
|
Session.io.OutFullLn (Session.GetPrompt(72));
|
||||||
|
|
||||||
FDir.Lines := Config.MaxFileDesc;
|
FDir.DescLines := Config.MaxFileDesc;
|
||||||
|
|
||||||
For A := 1 to Config.MaxFileDesc Do Begin
|
For A := 1 to Config.MaxFileDesc Do Begin
|
||||||
Session.io.PromptInfo[1] := strZero(A);
|
Session.io.PromptInfo[1] := strZero(A);
|
||||||
Session.io.OutFull (Session.GetPrompt(207));
|
Session.io.OutFull (Session.GetPrompt(207));
|
||||||
Session.Msgs.MsgText[A] := Session.io.GetInput(mysMaxFileDescLen, mysMaxFileDescLen, 11, '');
|
Session.Msgs.MsgText[A] := Session.io.GetInput(mysMaxFileDescLen, mysMaxFileDescLen, 11, '');
|
||||||
If Session.Msgs.MsgText[A] = '' Then Begin
|
If Session.Msgs.MsgText[A] = '' Then Begin
|
||||||
FDir.Lines := Pred(A);
|
FDir.DescLines := Pred(A);
|
||||||
Break;
|
Break;
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
If FDir.Lines = 0 Then Begin
|
If FDir.DescLines = 0 Then Begin
|
||||||
Session.Msgs.MsgText[1] := Session.GetPrompt(208);
|
Session.Msgs.MsgText[1] := Session.GetPrompt(208);
|
||||||
FDir.Lines := 1;
|
FDir.DescLines := 1;
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
|
@ -2537,7 +2537,8 @@ Begin
|
||||||
FDir.DateTime := CurDateDos;
|
FDir.DateTime := CurDateDos;
|
||||||
FDir.Uploader := Session.User.ThisUser.Handle;
|
FDir.Uploader := Session.User.ThisUser.Handle;
|
||||||
FDir.Flags := 0;
|
FDir.Flags := 0;
|
||||||
FDir.DLs := 0;
|
FDir.Downloads := 0;
|
||||||
|
FDir.Rating := 0;
|
||||||
|
|
||||||
If Config.FDupeScan > 0 Then Begin
|
If Config.FDupeScan > 0 Then Begin
|
||||||
Session.io.OutFull (Session.GetPrompt(377));
|
Session.io.OutFull (Session.GetPrompt(377));
|
||||||
|
@ -2592,9 +2593,9 @@ Begin
|
||||||
End Else
|
End Else
|
||||||
GetFileDescription(FileName);
|
GetFileDescription(FileName);
|
||||||
|
|
||||||
FDir.Pointer := FileSize(DataFile);
|
FDir.DescPtr := FileSize(DataFile);
|
||||||
|
|
||||||
For A := 1 to FDir.Lines Do
|
For A := 1 to FDir.DescLines Do
|
||||||
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
||||||
|
|
||||||
Assign (TempFile, FBase.Path + FileName);
|
Assign (TempFile, FBase.Path + FileName);
|
||||||
|
@ -2705,7 +2706,7 @@ Begin
|
||||||
Session.io.PromptInfo[2] := strComma(FDir.Size);
|
Session.io.PromptInfo[2] := strComma(FDir.Size);
|
||||||
Session.io.PromptInfo[3] := FDir.Uploader;
|
Session.io.PromptInfo[3] := FDir.Uploader;
|
||||||
Session.io.PromptInfo[4] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
Session.io.PromptInfo[4] := DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType);
|
||||||
Session.io.PromptInfo[5] := strI2S(FDir.DLs);
|
Session.io.PromptInfo[5] := strI2S(FDir.Downloads);
|
||||||
|
|
||||||
GetTransferTime (FDir.Size, Min, Sec);
|
GetTransferTime (FDir.Size, Min, Sec);
|
||||||
|
|
||||||
|
@ -2726,7 +2727,7 @@ Begin
|
||||||
Inc (Session.User.ThisUser.DLsToday);
|
Inc (Session.User.ThisUser.DLsToday);
|
||||||
Inc (Session.User.ThisUser.DLk, FDir.Size DIV 1024);
|
Inc (Session.User.ThisUser.DLk, FDir.Size DIV 1024);
|
||||||
Inc (Session.User.ThisUser.DLkToday, FDir.Size DIV 1024);
|
Inc (Session.User.ThisUser.DLkToday, FDir.Size DIV 1024);
|
||||||
Inc (FDir.DLs);
|
Inc (FDir.Downloads);
|
||||||
Inc (Session.HistoryDLs);
|
Inc (Session.HistoryDLs);
|
||||||
Inc (Session.HistoryDLKB, FDir.Size DIV 1024);
|
Inc (Session.HistoryDLKB, FDir.Size DIV 1024);
|
||||||
|
|
||||||
|
@ -2827,7 +2828,7 @@ Begin
|
||||||
Read (FDirFile, FDir);
|
Read (FDirFile, FDir);
|
||||||
|
|
||||||
If (FDir.FileName = Batch[A].FileName) And (FDir.Flags And FDirDeleted = 0) Then Begin
|
If (FDir.FileName = Batch[A].FileName) And (FDir.Flags And FDirDeleted = 0) Then Begin
|
||||||
Inc (FDir.DLs);
|
Inc (FDir.Downloads);
|
||||||
Seek (FDirFile, FilePos(FDirFile) - 1);
|
Seek (FDirFile, FilePos(FDirFile) - 1);
|
||||||
Write (FDirFile, FDir);
|
Write (FDirFile, FDir);
|
||||||
Break;
|
Break;
|
||||||
|
@ -3011,7 +3012,7 @@ Procedure TFileBase.DirectoryEditor (Edit : Boolean; Mask: String);
|
||||||
|
|
||||||
Function Get_Next_File (Back: Boolean): Boolean;
|
Function Get_Next_File (Back: Boolean): Boolean;
|
||||||
Var
|
Var
|
||||||
Old : FDirRec;
|
Old : RecFileList;
|
||||||
Pos : LongInt;
|
Pos : LongInt;
|
||||||
Begin
|
Begin
|
||||||
Old := FDir;
|
Old := FDir;
|
||||||
|
@ -3091,7 +3092,7 @@ Begin
|
||||||
'|033) Uploader : |11' + FDir.Uploader);
|
'|033) Uploader : |11' + FDir.Uploader);
|
||||||
|
|
||||||
Session.io.OutFullLn ('|034) File Date : |11' + strPadR(DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType), 19, ' ') +
|
Session.io.OutFullLn ('|034) File Date : |11' + strPadR(DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType), 19, ' ') +
|
||||||
'|035) Downloads : |11' + strI2S(FDir.DLs));
|
'|035) Downloads : |11' + strI2S(FDir.Downloads));
|
||||||
|
|
||||||
Session.io.OutFull ('|036) Status : |11');
|
Session.io.OutFull ('|036) Status : |11');
|
||||||
|
|
||||||
|
@ -3110,11 +3111,11 @@ Begin
|
||||||
Session.io.OutFullLn (Temp);
|
Session.io.OutFullLn (Temp);
|
||||||
Session.io.OutFullLn ('|08|$D79Ä');
|
Session.io.OutFullLn ('|08|$D79Ä');
|
||||||
|
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
|
|
||||||
For A := 1 to 11 Do Begin
|
For A := 1 to 11 Do Begin
|
||||||
Temp := '';
|
Temp := '';
|
||||||
If A <= FDir.Lines Then Begin
|
If A <= FDir.DescLines Then Begin
|
||||||
BlockRead (DataFile, Temp[0], 1);
|
BlockRead (DataFile, Temp[0], 1);
|
||||||
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
||||||
End;
|
End;
|
||||||
|
@ -3158,9 +3159,9 @@ Begin
|
||||||
'I' : Begin
|
'I' : Begin
|
||||||
Session.io.OutFullLn ('|CR|14Importing file_id.diz...');
|
Session.io.OutFullLn ('|CR|14Importing file_id.diz...');
|
||||||
If ImportDIZ(FDir.FileName) Then Begin
|
If ImportDIZ(FDir.FileName) Then Begin
|
||||||
FDir.Pointer := FileSize(DataFile);
|
FDir.DescPtr := FileSize(DataFile);
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
For A := 1 to FDir.Lines Do
|
For A := 1 to FDir.DescLines Do
|
||||||
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
@ -3203,11 +3204,11 @@ Begin
|
||||||
{$I-} Reset (DataFile2, 1); {$I+}
|
{$I-} Reset (DataFile2, 1); {$I+}
|
||||||
If IoResult <> 0 Then ReWrite (DataFile2, 1);
|
If IoResult <> 0 Then ReWrite (DataFile2, 1);
|
||||||
|
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
FDir.Pointer := FileSize(DataFile2);
|
FDir.DescPtr := FileSize(DataFile2);
|
||||||
Seek (DataFile2, FDir.Pointer);
|
Seek (DataFile2, FDir.DescPtr);
|
||||||
|
|
||||||
For B := 1 to FDir.Lines Do Begin
|
For B := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DataFile, Temp[0], 1);
|
BlockRead (DataFile, Temp[0], 1);
|
||||||
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
||||||
BlockWrite (DataFile2, Temp[0], Length(Temp) + 1);
|
BlockWrite (DataFile2, Temp[0], Length(Temp) + 1);
|
||||||
|
@ -3245,9 +3246,9 @@ Begin
|
||||||
|
|
||||||
Assign (TF, Session.TempPath + 'file_id.diz');
|
Assign (TF, Session.TempPath + 'file_id.diz');
|
||||||
ReWrite (TF);
|
ReWrite (TF);
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
|
|
||||||
For B := 1 to FDir.Lines Do Begin
|
For B := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DataFile, Temp[0], 1);
|
BlockRead (DataFile, Temp[0], 1);
|
||||||
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
BlockRead (DataFile, Temp[1], Ord(Temp[0]));
|
||||||
WriteLn (TF, Temp);
|
WriteLn (TF, Temp);
|
||||||
|
@ -3273,22 +3274,24 @@ Begin
|
||||||
Get_Next_File(False);
|
Get_Next_File(False);
|
||||||
End;
|
End;
|
||||||
'!' : Begin
|
'!' : Begin
|
||||||
Seek (DataFile, FDir.Pointer);
|
Seek (DataFile, FDir.DescPtr);
|
||||||
If FDir.Lines > Config.MaxFileDesc Then FDir.Lines := Config.MaxFileDesc;
|
If FDir.DescLines > Config.MaxFileDesc Then FDir.DescLines := Config.MaxFileDesc;
|
||||||
|
|
||||||
For A := 1 to FDir.Lines Do Begin
|
For A := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (DataFile, Session.Msgs.MsgText[A][0], 1);
|
BlockRead (DataFile, Session.Msgs.MsgText[A][0], 1);
|
||||||
BlockRead (DataFile, Session.Msgs.MsgText[A][1], Ord(Session.Msgs.MsgText[A][0]));
|
BlockRead (DataFile, Session.Msgs.MsgText[A][1], Ord(Session.Msgs.MsgText[A][0]));
|
||||||
End;
|
End;
|
||||||
|
|
||||||
Temp := 'Description Editor';
|
Temp := 'Description Editor';
|
||||||
B := FDir.Lines;
|
B := FDir.DescLines;
|
||||||
|
|
||||||
If Editor(B, mysMaxFileDescLen, Config.MaxFileDesc, True, False, Temp) Then Begin
|
If Editor(B, mysMaxFileDescLen, Config.MaxFileDesc, True, False, Temp) Then Begin
|
||||||
FDir.Lines := B;
|
FDir.DescLines := B;
|
||||||
FDir.Pointer := FileSize(DataFile);
|
FDir.DescPtr := FileSize(DataFile);
|
||||||
Seek (DataFile, FDir.Pointer);
|
|
||||||
For A := 1 to FDir.Lines Do
|
Seek (DataFile, FDir.DescPtr);
|
||||||
|
|
||||||
|
For A := 1 to FDir.DescLines Do
|
||||||
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
||||||
End;
|
End;
|
||||||
End;
|
End;
|
||||||
|
@ -3298,7 +3301,7 @@ Begin
|
||||||
End;
|
End;
|
||||||
'4' : FDir.DateTime := DateStr2Dos(Session.io.InXY(16, 6, 8, 8, 15, DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType)));
|
'4' : FDir.DateTime := DateStr2Dos(Session.io.InXY(16, 6, 8, 8, 15, DateDos2Str(FDir.DateTime, Session.User.ThisUser.DateType)));
|
||||||
'3' : FDir.Uploader := Session.io.InXY(50, 5, 30, 30, 18, FDir.Uploader);
|
'3' : FDir.Uploader := Session.io.InXY(50, 5, 30, 30, 18, FDir.Uploader);
|
||||||
'5' : FDir.DLs := strS2I(Session.io.InXY(50, 6, 4, 4, 12, strI2S(FDir.DLs)));
|
'5' : FDir.Downloads := strS2I(Session.io.InXY(50, 6, 4, 4, 12, strI2S(FDir.Downloads)));
|
||||||
'6' : Begin
|
'6' : Begin
|
||||||
Session.io.OutFull('|CRFlags: F(a)iled, (F)ree, (O)ffline, (U)nvalidated, (Q)uit: ');
|
Session.io.OutFull('|CRFlags: F(a)iled, (F)ree, (O)ffline, (U)nvalidated, (Q)uit: ');
|
||||||
Case Session.io.OneKey('AFOUQ', True) of
|
Case Session.io.OneKey('AFOUQ', True) of
|
||||||
|
@ -3385,23 +3388,24 @@ Var
|
||||||
FDir.Size := DirInfo.Size;
|
FDir.Size := DirInfo.Size;
|
||||||
FDir.DateTime := CurDateDos;
|
FDir.DateTime := CurDateDos;
|
||||||
FDir.Uploader := Session.User.ThisUser.Handle;
|
FDir.Uploader := Session.User.ThisUser.Handle;
|
||||||
FDir.DLs := 0;
|
FDir.Downloads := 0;
|
||||||
FDir.Flags := 0;
|
FDir.Flags := 0;
|
||||||
FDir.Lines := 0;
|
FDir.DescLines := 0;
|
||||||
|
FDir.Rating := 0;
|
||||||
|
|
||||||
If Config.ImportDIZ Then
|
If Config.ImportDIZ Then
|
||||||
If Not ImportDIZ(DirInfo.Name) Then
|
If Not ImportDIZ(DirInfo.Name) Then
|
||||||
If Not AutoArea Then
|
If Not AutoArea Then
|
||||||
GetFileDescription(DirInfo.Name);
|
GetFileDescription(DirInfo.Name);
|
||||||
|
|
||||||
If FDir.Lines = 0 Then Begin
|
If FDir.DescLines = 0 Then Begin
|
||||||
Session.Msgs.MsgText[1] := Session.GetPrompt(208);
|
Session.Msgs.MsgText[1] := Session.GetPrompt(208);
|
||||||
FDir.Lines := 1;
|
FDir.DescLines := 1;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
FDir.Pointer := FileSize(DataFile);
|
FDir.DescPtr := FileSize(DataFile);
|
||||||
|
|
||||||
For A := 1 to FDir.Lines Do
|
For A := 1 to FDir.DescLines Do
|
||||||
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
BlockWrite (DataFile, Session.Msgs.MsgText[A][0], Length(Session.Msgs.MsgText[A]) + 1);
|
||||||
|
|
||||||
If Config.TestUploads and (Config.TestCmdLine <> '') Then Begin
|
If Config.TestUploads and (Config.TestCmdLine <> '') Then Begin
|
||||||
|
|
|
@ -133,9 +133,9 @@ Var
|
||||||
SortList : TQuickSort;
|
SortList : TQuickSort;
|
||||||
FBaseFile : File of FBaseRec;
|
FBaseFile : File of FBaseRec;
|
||||||
FBase : FBaseRec;
|
FBase : FBaseRec;
|
||||||
FDirFile : File of FDirRec;
|
FDirFile : File of RecFileList;
|
||||||
TFDirFile : File of FDirRec;
|
TFDirFile : File of RecFileList;
|
||||||
FDir : FDirRec;
|
FDir : RecFileList;
|
||||||
A : Word;
|
A : Word;
|
||||||
Begin
|
Begin
|
||||||
Write ('Sorting File Bases : ');
|
Write ('Sorting File Bases : ');
|
||||||
|
@ -194,9 +194,9 @@ Procedure Pack_File_Bases;
|
||||||
Var
|
Var
|
||||||
A : Byte;
|
A : Byte;
|
||||||
Temp : String[50];
|
Temp : String[50];
|
||||||
FDirFile : File of FDirRec;
|
FDirFile : File of RecFileList;
|
||||||
TFDirFile : File of FDirRec;
|
TFDirFile : File of RecFileList;
|
||||||
FDir : FDirRec;
|
FDir : RecFileList;
|
||||||
DataFile : File;
|
DataFile : File;
|
||||||
TDataFile : File;
|
TDataFile : File;
|
||||||
FBaseFile : File of FBaseRec;
|
FBaseFile : File of FBaseRec;
|
||||||
|
@ -232,11 +232,11 @@ Begin
|
||||||
While Not Eof(FDirFile) Do Begin
|
While Not Eof(FDirFile) Do Begin
|
||||||
Read (FDirFile, FDir);
|
Read (FDirFile, FDir);
|
||||||
If FDir.Flags AND FDirDeleted = 0 Then Begin
|
If FDir.Flags AND FDirDeleted = 0 Then Begin
|
||||||
Seek (TDataFile, FDir.Pointer);
|
Seek (TDataFile, FDir.DescPtr);
|
||||||
|
|
||||||
FDir.Pointer := FilePos(DataFile);
|
FDir.DescPtr := FilePos(DataFile);
|
||||||
|
|
||||||
For A := 1 to FDir.Lines Do Begin
|
For A := 1 to FDir.DescLines Do Begin
|
||||||
BlockRead (TDataFile, Temp[0], 1);
|
BlockRead (TDataFile, Temp[0], 1);
|
||||||
BlockRead (TDataFile, Temp[1], Ord(Temp[0]));
|
BlockRead (TDataFile, Temp[1], Ord(Temp[0]));
|
||||||
|
|
||||||
|
@ -267,9 +267,9 @@ Procedure Check_File_Bases;
|
||||||
Var
|
Var
|
||||||
FBaseFile : File of FBaseRec;
|
FBaseFile : File of FBaseRec;
|
||||||
FBase : FBaseRec;
|
FBase : FBaseRec;
|
||||||
FDirFile : File of FDirRec;
|
FDirFile : File of RecFileList;
|
||||||
FDir : FDirRec;
|
FDir : RecFileList;
|
||||||
TFDirFile : File of FDirRec;
|
TFDirFile : File of RecFileList;
|
||||||
DF : File of Byte;
|
DF : File of Byte;
|
||||||
Begin
|
Begin
|
||||||
Write ('Checking File Bases : ');
|
Write ('Checking File Bases : ');
|
||||||
|
|
|
@ -46,8 +46,8 @@ Type
|
||||||
Destructor Destroy; Override;
|
Destructor Destroy; Override;
|
||||||
|
|
||||||
Procedure ResetSession;
|
Procedure ResetSession;
|
||||||
Procedure UpdateUserStats (TFBase: FBaseRec; FDir: FDirRec; DirPos: LongInt);
|
Procedure UpdateUserStats (TFBase: FBaseRec; FDir: RecFileList; DirPos: LongInt);
|
||||||
Function CheckFileLimits (TempFBase: FBaseRec; FDir: FDirRec) : Byte;
|
Function CheckFileLimits (TempFBase: FBaseRec; FDir: RecFileList) : Byte;
|
||||||
Function OpenDataSession : Boolean;
|
Function OpenDataSession : Boolean;
|
||||||
Procedure CloseDataSession;
|
Procedure CloseDataSession;
|
||||||
Function ValidDirectory (TempBase: FBaseRec) : Boolean;
|
Function ValidDirectory (TempBase: FBaseRec) : Boolean;
|
||||||
|
@ -129,14 +129,14 @@ Begin
|
||||||
InTransfer := False;
|
InTransfer := False;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
Procedure TFTPServer.UpdateUserStats (TFBase: FBaseRec; FDir: FDirRec; DirPos: LongInt);
|
Procedure TFTPServer.UpdateUserStats (TFBase: FBaseRec; FDir: RecFileList; DirPos: LongInt);
|
||||||
Var
|
Var
|
||||||
HistFile: File of HistoryRec;
|
HistFile: File of HistoryRec;
|
||||||
History : HistoryRec;
|
History : HistoryRec;
|
||||||
FDirFile: File of FDirRec;
|
FDirFile: File of RecFileList;
|
||||||
UserFile: File of RecUser;
|
UserFile: File of RecUser;
|
||||||
Begin
|
Begin
|
||||||
Inc (FDir.DLs);
|
Inc (FDir.Downloads);
|
||||||
|
|
||||||
Assign (UserFile, bbsConfig.DataPath + 'users.dat');
|
Assign (UserFile, bbsConfig.DataPath + 'users.dat');
|
||||||
ioReset (UserFile, SizeOf(RecUser), fmReadWrite + fmDenyWrite);
|
ioReset (UserFile, SizeOf(RecUser), fmReadWrite + fmDenyWrite);
|
||||||
|
@ -162,7 +162,7 @@ Begin
|
||||||
Close (UserFile);
|
Close (UserFile);
|
||||||
|
|
||||||
Assign (FDirFile, bbsConfig.DataPath + TFBase.FileName + '.dir');
|
Assign (FDirFile, bbsConfig.DataPath + TFBase.FileName + '.dir');
|
||||||
ioReset (FDirFile, SizeOf(FDirRec), fmReadWrite + fmDenyWrite);
|
ioReset (FDirFile, SizeOf(RecFileList), fmReadWrite + fmDenyWrite);
|
||||||
ioSeek (FDirFile, DirPos - 1);
|
ioSeek (FDirFile, DirPos - 1);
|
||||||
ioWrite (FDirFile, FDir);
|
ioWrite (FDirFile, FDir);
|
||||||
Close (FDirFile);
|
Close (FDirFile);
|
||||||
|
@ -195,7 +195,7 @@ Begin
|
||||||
Close (HistFile);
|
Close (HistFile);
|
||||||
End;
|
End;
|
||||||
|
|
||||||
Function TFTPServer.CheckFileLimits (TempFBase: FBaseRec; FDir: FDirRec) : Byte;
|
Function TFTPServer.CheckFileLimits (TempFBase: FBaseRec; FDir: RecFileList) : Byte;
|
||||||
{ 0 = OK to download }
|
{ 0 = OK to download }
|
||||||
{ 1 = Offline or Invalid or Failed or NO ACCESS or no file (prompt 224)}
|
{ 1 = Offline or Invalid or Failed or NO ACCESS or no file (prompt 224)}
|
||||||
{ 2 = DL per day limit exceeded (prompt 58) }
|
{ 2 = DL per day limit exceeded (prompt 58) }
|
||||||
|
@ -479,7 +479,7 @@ Var
|
||||||
TempBase : FBaseRec;
|
TempBase : FBaseRec;
|
||||||
TempPos : LongInt;
|
TempPos : LongInt;
|
||||||
DirFile : TBufFile;
|
DirFile : TBufFile;
|
||||||
Dir : FDirRec;
|
Dir : RecFileList;
|
||||||
Begin
|
Begin
|
||||||
If LoggedIn Then Begin
|
If LoggedIn Then Begin
|
||||||
TempPos := FindDirectory(TempBase);
|
TempPos := FindDirectory(TempBase);
|
||||||
|
@ -495,7 +495,7 @@ Begin
|
||||||
|
|
||||||
DirFile := TBufFile.Create(FileBufSize);
|
DirFile := TBufFile.Create(FileBufSize);
|
||||||
|
|
||||||
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(FDirRec)) Then Begin
|
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(RecFileList)) Then Begin
|
||||||
While Not DirFile.EOF Do Begin
|
While Not DirFile.EOF Do Begin
|
||||||
DirFile.Read(Dir);
|
DirFile.Read(Dir);
|
||||||
|
|
||||||
|
@ -532,7 +532,7 @@ Var
|
||||||
TempPos : LongInt;
|
TempPos : LongInt;
|
||||||
FBaseFile : TBufFile;
|
FBaseFile : TBufFile;
|
||||||
DirFile : TBufFile;
|
DirFile : TBufFile;
|
||||||
Dir : FDirRec;
|
Dir : RecFileList;
|
||||||
Begin
|
Begin
|
||||||
If LoggedIn Then Begin
|
If LoggedIn Then Begin
|
||||||
TempPos := FindDirectory(TempBase);
|
TempPos := FindDirectory(TempBase);
|
||||||
|
@ -562,7 +562,7 @@ Begin
|
||||||
|
|
||||||
DirFile := TBufFile.Create(FileBufSize);
|
DirFile := TBufFile.Create(FileBufSize);
|
||||||
|
|
||||||
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(FDirRec)) Then Begin
|
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(RecFileList)) Then Begin
|
||||||
While Not DirFile.EOF Do Begin
|
While Not DirFile.EOF Do Begin
|
||||||
DirFile.Read(Dir);
|
DirFile.Read(Dir);
|
||||||
|
|
||||||
|
@ -587,7 +587,7 @@ Var
|
||||||
TempPos : LongInt;
|
TempPos : LongInt;
|
||||||
TempBase : FBaseRec;
|
TempBase : FBaseRec;
|
||||||
DirFile : TBufFile;
|
DirFile : TBufFile;
|
||||||
Dir : FDirRec;
|
Dir : RecFileList;
|
||||||
Found : LongInt;
|
Found : LongInt;
|
||||||
F : File;
|
F : File;
|
||||||
Buf : Array[1..4096] of Byte;
|
Buf : Array[1..4096] of Byte;
|
||||||
|
@ -605,7 +605,7 @@ Begin
|
||||||
DirFile := TBufFile.Create(FileBufSize);
|
DirFile := TBufFile.Create(FileBufSize);
|
||||||
Found := -1;
|
Found := -1;
|
||||||
|
|
||||||
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(FDirRec)) Then Begin
|
If DirFile.Open(bbsConfig.DataPath + TempBase.FileName + '.dir', fmOpenCreate, fmRWDN, SizeOf(RecFileList)) Then Begin
|
||||||
While Not DirFile.EOF Do Begin
|
While Not DirFile.EOF Do Begin
|
||||||
DirFile.Read(Dir);
|
DirFile.Read(Dir);
|
||||||
|
|
||||||
|
|
|
@ -481,21 +481,23 @@ Const
|
||||||
FDirFree = $10;
|
FDirFree = $10;
|
||||||
|
|
||||||
Type
|
Type
|
||||||
FDirRec = Record { *.DIR }
|
RecFileList = Record
|
||||||
FileName : String[70]; { File name }
|
FileName : String[70];
|
||||||
Size : LongInt; { File size (in bytes) }
|
Size : LongInt;
|
||||||
DateTime : LongInt; { Date and time of upload }
|
DateTime : LongInt;
|
||||||
Uploader : String[30]; { User name who uploaded the file }
|
Uploader : String[30];
|
||||||
Flags : Byte; { Set of FDIRFLAGS (see above) }
|
Flags : Byte;
|
||||||
Pointer : LongInt; { Pointer to file description }
|
Downloads : LongInt;
|
||||||
Lines : Byte; { Number of description lines }
|
Rating : Byte;
|
||||||
DLs : Word; { # of times this file was downloaded}
|
DescPtr : LongInt;
|
||||||
|
DescLines : Byte;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
FDirCommentRec = Record { .FCI and .FCT in DATA directory }
|
RecFileComment = Record { .FCI and .FCT in DATA directory }
|
||||||
UserName : String[30];
|
UserName : String[30];
|
||||||
Rating : Byte;
|
Rating : Byte;
|
||||||
Date : LongInt;
|
Date : LongInt;
|
||||||
|
Pointer : LongInt;
|
||||||
Lines : Word;
|
Lines : Word;
|
||||||
End;
|
End;
|
||||||
|
|
||||||
|
|
101
mystic/todo.pas
101
mystic/todo.pas
|
@ -2,7 +2,8 @@ This file showcases the direction of where this software wants to go as it
|
||||||
continues to expand. Some things that will probably be mentioned will be
|
continues to expand. Some things that will probably be mentioned will be
|
||||||
vague, and serve mostly to remind me of my own ideas.
|
vague, and serve mostly to remind me of my own ideas.
|
||||||
|
|
||||||
The scope of this file is to document bugs and future enhancements/ideas.
|
The scope of this file is to document bugs, future enhancements/ideas and
|
||||||
|
design elements/issues.
|
||||||
|
|
||||||
BUGS AND POSSIBLE ISSUES
|
BUGS AND POSSIBLE ISSUES
|
||||||
========================
|
========================
|
||||||
|
@ -84,9 +85,107 @@ FUTURE / IDEAS / WORK IN PROGRESS / NOTES
|
||||||
- MIDE version using the Lazaurs GUI editor [Spec]. Maybe he would be
|
- MIDE version using the Lazaurs GUI editor [Spec]. Maybe he would be
|
||||||
interested in working on that?
|
interested in working on that?
|
||||||
- PCBoard-style "quickscan"? Yes? No?
|
- PCBoard-style "quickscan"? Yes? No?
|
||||||
|
- This line intentionally means nothing.
|
||||||
- Filebase allow anonymous flag for FTP or just use FreeFiles
|
- Filebase allow anonymous flag for FTP or just use FreeFiles
|
||||||
- Build in "telnetd" STDIO redirection into MIS in Linux/OSX
|
- Build in "telnetd" STDIO redirection into MIS in Linux/OSX
|
||||||
- Template system similar to Mystic 2 (ansiedit.ans ansiedit.ans.cfg)
|
- Template system similar to Mystic 2 (ansiedit.ans ansiedit.ans.cfg)
|
||||||
- Rename Template filenames to allow more than 8 characters (for clarity)
|
- Rename Template filenames to allow more than 8 characters (for clarity)
|
||||||
- Does anyone use Version 7 compiled nodelists? Worth supporting?
|
- Does anyone use Version 7 compiled nodelists? Worth supporting?
|
||||||
- Ignore user inactivity flag per user
|
- Ignore user inactivity flag per user
|
||||||
|
- HOME and END keys added to lightbar file listings
|
||||||
|
|
||||||
|
RANDOM DRUNKEN BRAINDUMP AKA DESIGN DETAILS
|
||||||
|
===========================================
|
||||||
|
|
||||||
|
-------------------------------------------------------------------------
|
||||||
|
Disconnect while posting design:
|
||||||
|
|
||||||
|
1. Before msg post or msg reply Session.Msgs.Posting is set to that bases
|
||||||
|
Index.
|
||||||
|
2. All editors reset this value on any save/abort
|
||||||
|
3. Any disconnect checks that value.
|
||||||
|
4. If disconnect while value is set:
|
||||||
|
a. Save MSGTMP from node's TEMP dir into DATA as msg_<UID>.tmp
|
||||||
|
overwrite if exists
|
||||||
|
b. Save MsgText into DATA as msg_<UID>.txt with format:
|
||||||
|
Line 1: Base perm index
|
||||||
|
Line 2: Msg From
|
||||||
|
Line 3: Msg To
|
||||||
|
Line 4: Msg Subj
|
||||||
|
Line 5: Network address (or blank if none)
|
||||||
|
Line 6: MsgText
|
||||||
|
overwrite if exists
|
||||||
|
5. During LOGIN, check for msg_<UID>.txt
|
||||||
|
6. If exists, process and prompt user:
|
||||||
|
|
||||||
|
You were recently disconnected while posting a message:
|
||||||
|
|
||||||
|
Base: Clever Message Base Name
|
||||||
|
To: MOM JOKEZ R FUNNY LOLZ
|
||||||
|
Subj: I eat hot coal.
|
||||||
|
|
||||||
|
(R)esume post, (D)elete, or (A)sk me later?
|
||||||
|
|
||||||
|
7. Case result:
|
||||||
|
Resume:
|
||||||
|
Copy msg_UID.tmp if exists to MSGTMP in temp node directory
|
||||||
|
Populate MsgText and execute editor with the other values
|
||||||
|
Execute editor
|
||||||
|
If save... save... this will be the hard part. :(
|
||||||
|
If abort... delete msg_UID* since they aborted?
|
||||||
|
What happens if they disconnect while continuing? lol
|
||||||
|
make sure this is handled appropriately.
|
||||||
|
Delete:
|
||||||
|
Delete msg_UID* in data.
|
||||||
|
Ask later:
|
||||||
|
Do nothing. Keep files so Mystic asks on next login.
|
||||||
|
|
||||||
|
PROBLEM: When we localize MsgText for the ANSI viewer integration...
|
||||||
|
how will this work? I am not sure it really can work without it being
|
||||||
|
global. We cannot save what we do not have access to from a class.
|
||||||
|
|
||||||
|
SOLUTION: Actual MsgText should be separate from Attributes in the msg
|
||||||
|
base ANSI class. Memory requirements almost double though for MsgText
|
||||||
|
storage if it remains global = 1000 lines x 80. 80,000 bytes memory per
|
||||||
|
node. But attributes are only really required while READING. So maybe
|
||||||
|
somehow it can be separated so attributes are specific to reading and
|
||||||
|
the entire class is "unused" until then?
|
||||||
|
|
||||||
|
-----------------------------------------------------------------------
|
||||||
|
|
||||||
|
CHANGE to support 50 line mode
|
||||||
|
|
||||||
|
1. terminal "screen length" is no longer an option of lines but a
|
||||||
|
selection:
|
||||||
|
|
||||||
|
80x25
|
||||||
|
80x50
|
||||||
|
132x50
|
||||||
|
|
||||||
|
2. all display files and templates will have this logic added:
|
||||||
|
|
||||||
|
if 132 mode .132.ans is the extention
|
||||||
|
if 50 mode .50.ans is the extention
|
||||||
|
if 25 mode then .ans is the extention
|
||||||
|
|
||||||
|
-----------------------------------------------------------------------
|
||||||
|
|
||||||
|
NEW TEMPLATE system
|
||||||
|
|
||||||
|
templates will be .cfg files with various things defined within them
|
||||||
|
based on the template. no more "injecting" screeninfo codes (|!X) into
|
||||||
|
files. Extentions for random ANSI templates:
|
||||||
|
|
||||||
|
ansiflst.ans = ansiflist.ans.cfg
|
||||||
|
ansiflst.an1 = ansiflist.an1.cfg
|
||||||
|
|
||||||
|
50 line mode template examples with random selected templates
|
||||||
|
|
||||||
|
ansiflst.50.ans = ansiflist.50.ans.cfg
|
||||||
|
ansiflst.50.an1 = ansiflist.50.an1.cfg
|
||||||
|
|
||||||
|
-----------------------------------------------------------------------
|
||||||
|
|
||||||
|
FILE rating system
|
||||||
|
|
||||||
|
-----------------------------------------------------------------------
|
||||||
|
|
Loading…
Reference in New Issue