New MPL vars recompile MPL (mplc -all)

This commit is contained in:
g00r00 2013-10-03 21:37:13 -04:00
parent aa10b93c6a
commit d3313c38f2
7 changed files with 56 additions and 22 deletions

View File

@ -66,8 +66,9 @@ Function IsThisUser (U: RecUser; Str: String) : Boolean;
// ECHOMAIL
Function GetFTNBundleExt (IncOnly: Boolean; Str: String) : String;
Function GetNodeByAddress (Addr: String; Var TempNode: RecEchoMailNode) : Boolean;
Function GetFTNBundleExt (IncOnly: Boolean; Str: String) : String;
Function SaveEchoMailNode (Var TempNode: RecEchoMailNode) : Boolean;
Implementation
@ -694,6 +695,33 @@ Begin
Until False;
End;
Function SaveEchoMailNode (Var TempNode: RecEchoMailNode) : Boolean;
Var
F : File;
TN : RecEchoMailNode;
Begin
Result := False;
Assign (F, bbsCfg.DataPath + 'echonode.dat');
If Not ioReset(F, SizeOf(RecEchoMailNode), fmRWDN) Then Exit;
While Not Eof(F) Do Begin
ioRead(F, TN);
If TempNode.Index = TN.Index Then Begin
Seek (F, FilePos(F) - 1);
ioWrite (F, TempNode);
Result := True;
Break;
End;
End;
Close (F);
End;
Initialization
bbsCfgStatus := GetBaseConfiguration(True, bbsCfg);

View File

@ -418,6 +418,8 @@ Begin
AddStr ({$IFDEF MPLPARSER} 'mbasepacs', {$ENDIF} iString, 30);
AddStr ({$IFDEF MPLPARSER} 'mbasesacs', {$ENDIF} iString, 30);
AddVar ({$IFDEF MPLPARSER} 'mbasenetaddr', {$ENDIF} iByte);
AddVar ({$IFDEF MPLPARSER} 'mbasenettype', {$ENDIF} iByte);
AddVar ({$IFDEF MPLPARSER} 'mbaseflags', {$ENDIF} iLongInt);
End;
4 : Begin
{$IFNDEF MPLPARSER} TInterpEngine(S).IdxVarMGroup := X + 1; {$ENDIF}

View File

@ -297,6 +297,8 @@ Begin
Move (M.PostACS, VarData[IdxVarMBase + 4 ]^.Data^, SizeOf(M.PostACS));
Move (M.SysopACS, VarData[IdxVarMBase + 5 ]^.Data^, SizeOf(M.SysopACS));
Move (M.NetAddr, VarData[IdxVarMBase + 6 ]^.Data^, SizeOf(M.NetAddr));
Move (M.NetType, VarData[IdxVarMBase + 7 ]^.Data^, SizeOf(M.NetType));
Move (M.Flags, VarData[IdxVarMBase + 8 ]^.Data^, SizeOf(M.Flags));
End;
Function TInterpEngine.GetMBaseStats (Num: LongInt; SkipFrom, SkipRead: Boolean; Var Total, New, Yours: LongInt) : Boolean;

View File

@ -77,7 +77,7 @@ Type
);
Const
mplVer = '11Y';
mplVer = '11S';
mplVersion = '[MPX ' + mplVer +']' + #26;
mplVerLength = 10;
mplExtSource = '.mps';

View File

@ -66,6 +66,7 @@ Var
Temp : String;
FLOName : String;
OrigAddr : RecEchoMailAddr;
CheckInc : Boolean;
Begin
FindFirst (TempPath + '*', AnyFile, DirInfo);
@ -88,32 +89,29 @@ Begin
OrigAddr.Node := PH.OrigNode;
BundlePath := GetFTNOutPath(EchoNode);
CheckInc := False;
DirCreate (BundlePath);
If Not (EchoNode.LPKTPtr in [48..57, 97..122]) Then
EchoNode.LPKTPtr := 48;
If EchoNode.LPKTDay <> DayOfWeek(CurDateDos) Then Begin
EchoNode.LPKTDay := DayOfWeek(CurDateDos);
EchoNode.LPKTPtr := 48;
End Else
CheckInc := True;
FLOName := BundlePath + GetFTNFlowName(EchoNode.Address);
BundleName := BundlePath + GetFTNArchiveName(OrigAddr, EchoNode.Address) + '.' + strLower(DayString[DayOfWeek(CurDateDos)]);
BundleName := BundlePath + GetFTNArchiveName(OrigAddr, EchoNode.Address) + '.' + Copy(strLower(DayString[DayOfWeek(CurDateDos)]), 1, 2) + Char(EchoNode.LPKTPtr);
BundleName[Length(BundleName)] := '0';
If CheckInc And Not FileExist(BundleName) Then Begin
BundleName := GetFTNBundleExt(True, BundleName);
(*
BundleName := BundlePath + GetFTNBundleExt(False, GetFTNArchiveName(OrigAddr, EchoNode.Address) + '.' + Copy(strLower(DayString[DayOfWeek(CurDateDos)]), 1, 2) + '0');
EchoNode.LPKTPtr := Byte(BundleName[Length(BundleName)]);
End;
BundleName := BundlePath + GetFTNArchiveName(OrigAddr, EchoNode.Address) + '.' + Copy(strLower(DayString[DayOfWeek(CurDateDos)]), 1, 2) + '0';
Temp := BundleName;
Repeat
BundleSize := FileByteSize(BundleName);
If (BundleSize > 0) and ((BundleSize DIV 1024) >= 250) Then Begin
BundleName := GetFTNBundleExt(True, BundleName);
If BundleName = Temp Then
Break;
End Else
Break;
Until False;
*)
SaveEchoMailNode(EchoNode);
Case EchoNode.MailType of
0 : FLOName := FLOName + '.flo';

View File

@ -132,7 +132,9 @@ Type
AreaFixPass : String[20];
DirInDir : String[60];
DirOutDir : String[60];
Res : Array[1..219] of Byte;
LPKTDay : Byte;
LPKTPtr : Byte;
Res : Array[1..217] of Byte;
End;
RecQwkNetwork = Record

View File

@ -60,6 +60,8 @@ BUGS AND POSSIBLE ISSUES
FUTURE / IDEAS / WORK IN PROGRESS / NOTES
=========================================
- Need to add MCI code for Default Protocol
- Make function get protocol by Key
- Make point mail bundles based off of their uplink (your address)?
- MIS escape confirmation
- Prompts for CONFIG editors