home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Equalizer BBS
/
equalizer-bbs-collection_2004.zip
/
equalizer-bbs-collection
/
BBS-PCBOARD-STUFF
/
AGSMC10.ZIP
/
MCUTILS.PPE
(
.txt
)
< prev
next >
Wrap
PCBoard Programming Language Executable
|
1995-02-27
|
7KB
|
570 lines
;------------------------------------------------------------------------------
; .ss.
; `²²'
; .,sS$Ss,,s$ .,sS$$$Ss. .,sS$Ss,,s$ .ss. .sSs.
; .d$$²^°²$$$$'.d$P²°^^²$P'.d$$²^°²$$$$'.$$$' .$$$²Sb,.
; $$$' .$$$' $$$²Sçsµ²' .$$$' .$$$'.$$$' .$$$' `$$b.
; $$$b,,d$$$' ,$$$b,....,s$$$$b,,d$$$'.$$$;.,$$$' ;$$$
; `²S$$S²²S$$S²°²S$$$$S²°°²S$$$$$$',$$S²°²S$S'.sS$$$P²'
; .sS²°$$$²²°"' d²°'
; .$$² .$$'
; $$$.,d$$'
; `²S$$S²'
;------------------------------------------------------------------------------
; P.P.L.X. 2.OO (C)1996 - Lone Runner / AEGiS CoRP'96
;------------------------------------------------------------------------------
; PPE 3.O1 (Encryption type I) - Analysis ON - Postprocessing ON
;------------------------------------------------------------------------------
Boolean BOOLEAN001
Boolean BOOLEAN002
Boolean BOOLEAN003
DWord DWORD001
Integer INTEGER001
String STRING001
String STRING002
String STRING003
String STRING004
String STRING005
String STRING006
String STRING007
String STRING010
String STRING011
Word WORD001
Word WORD002
Word WORD003
Word TWORD004(9)
Word WORD005
Word WORD006
Word WORD007
Word WORD008
Word WORD009
Word WORD010
Word WORD011
Word WORD012
Word WORD014
Declare Function FUNCTION001(String STRING009) String
Declare Function FUNCTION002() String
Declare Function FUNCTION003() Word
Declare Procedure PROC001()
Declare Procedure PROC002(String STRING008, Word WORD013)
Declare Procedure PROC005()
Declare Procedure PROC006(Word WORD016)
Declare Procedure PROC007(Word WORD015)
Declare Procedure PROC008()
Declare Procedure PROC009()
;------------------------------------------------------------------------------
STRING007 = PPEPath() + "GROUP.LOG"
GetUser
StartDisp 1
Print "@POFF@"
STRING001 = PPEPath() + "WORK\ORG.DAT"
If (Exist(STRING001)) Goto LABEL001
PROC008()
End
:LABEL001
DispFile PPEPath() + "MCUTILS", 0 + 4
DWORD001 = Crc32(1, STRING001)
WORD010 = 1
AnsiPos 28, 7 + WORD010
Print "@X09■"
INTEGER001 = Time()
AnsiPos 1, 23
WORD005 = FileInf(STRING001, 4) / 2
PROC001()
For WORD002 = 1 To WORD005
AnsiPos 25, 7 + WORD002
If (WORD002 < 10) Then
Print "@X0F", WORD002
Else
Print "@X0F" + "0"
Endif
AnsiPos 29, 7 + WORD002
If (TWORD004(WORD002 - 1) <> 0) Then
RdUNet TWORD004(WORD002 - 1)
Print FUNCTION001(UN_Name())
Continue
Endif
Print "-"
Next
WORD009 = 1
Gosub LABEL013
While (1) Do
PROC009()
STRING003 = Inkey()
If (STRING003 == "RIGHT") Then
Gosub LABEL012
If (WORD009 < 4) Then
Inc WORD009
Goto LABEL002
Endif
WORD009 = 1
:LABEL002
Gosub LABEL013
AnsiPos 1, 23
Continue
Endif
If (STRING003 == "LEFT") Then
Gosub LABEL012
If (WORD009 > 1) Then
Dec WORD009
Goto LABEL003
Endif
WORD009 = 4
:LABEL003
Gosub LABEL013
AnsiPos 1, 23
Continue
Endif
If (STRING003 == Chr(13)) Then
If (WORD009 == 1) Then
PROC005()
End
Endif
If (WORD009 == 2) Then
STRING005 = FUNCTION002()
If (BOOLEAN002) Goto LABEL004
PrintLn
STRING005 = "/" + U_Name() + " : " + STRING005
WORD002 = FUNCTION003()
If (WORD002 <> 0) Then
PROC002(STRING005, WORD002)
FAppend 7, STRING007, 1, 0
FPutLn 7, " -*- SYSOP -------------------*> (MCUTILS.PPE) - PRIVATE TO #" + String(WORD002) + " :"
FPutLn 7, STRING005
FClose 7
STRING002 = ScrText(27, 7, 5, 1)
AnsiPos 27, 7
Print "@X8FSeNT!"
AnsiPos 1, 23
Delay 18
AnsiPos 1, 22
ClrEol
AnsiPos 27, 7
Print STRING002
Goto LABEL005
Endif
:LABEL004
AnsiPos 1, 22
ClrEol
:LABEL005
AnsiPos 1, 23
Endif
If (WORD009 == 3) Then
If (BOOLEAN003) Goto LABEL006
FOpen 1, PPEPath() + "WORK\LOCKED.SEM", 1, 0
FPutLn 1, "Chat is locked !"
FClose 1
STRING002 = "Chat has been locked by the sysop!"
FAppend 7, STRING007, 1, 0
FPutLn 7, " -*- SYSOP -------------------*> (MCUTILS.PPE) LOCK THE CHAT"
FClose 7
For WORD002 = 1 To WORD005
If (TWORD004(WORD002 - 1)) PROC002(STRING002, WORD002)
Next
Goto LABEL007
:LABEL006
Delete PPEPath() + "WORK\LOCKED.SEM"
STRING002 = "Chat has been unlocked by the sysop!"
FAppend 7, STRING007, 1, 0
FPutLn 7, " -*- SYSOP -------------------*> (MCUTILS.PPE) UNLOCK THE CHAT"
FClose 7
For WORD002 = 1 To WORD005
If (TWORD004(WORD002 - 1)) PROC002(STRING002, WORD002)
Next
Endif
:LABEL007
If (WORD009 == 4) Then
WORD002 = FUNCTION003()
If (WORD002 == 0) Continue
If (WORD002 == 10) WORD002 = 0
FAppend 7, STRING007, 1, 0
FPutLn 7, " -*- SYSOP -------------------*> (MCUTILS.PPE) EJECT #" + String(WORD002)
FClose 7
FOpen 1, PPEPath() + "WORK\EJECT." + String(WORD002), 1, 0
FPutLn 1, "Go away !"
FClose 1
Endif
Continue
Endif
If (STRING003 == Chr(27)) Then
PROC005()
End
Endif
EndWhile
End
;------------------------------------------------------------------------------
Procedure PROC001()
WORD008 = 0
FOpen 1, STRING001, 0, 3
FSeek 1, 0, 0
For WORD003 = 1 To WORD005
FRead 1, WORD002, 2
If (WORD002 <> 0) Then
Inc WORD008
If (WORD002 == PcbNode()) WORD001 = WORD003
TWORD004(WORD003 - 1) = WORD002
Continue
Endif
TWORD004(WORD003 - 1) = 0
Next
FClose 1
EndProc
;------------------------------------------------------------------------------
Procedure PROC002(String STRING008, Word WORD013)
WORD007 = WORD013
If (WORD007 == 10) WORD007 = 0
FCreate 1, PPEPath() + "WORK\PVT." + String(WORD007), 1, 0
FPutLn 1, Left(STRING008, 80)
FClose 1
EndProc
;------------------------------------------------------------------------------
Function FUNCTION001(String STRING009) String
STRING002 = Upper(STRING009)
STRING002 = Replace(STRING002, "A", "a")
STRING002 = Replace(STRING002, "E", "e")
STRING002 = Replace(STRING002, "I", "i")
STRING002 = Replace(STRING002, "O", "o")
STRING002 = Replace(STRING002, "U", "u")
FUNCTION001 = STRING002
EndFunc
;------------------------------------------------------------------------------
Procedure PROC005()
Color 15
Cls
AnsiPos 33, 11
Color 8
Gosub LABEL008
Color 7
Gosub LABEL008
Color 15
Gosub LABEL008
Color 7
Gosub LABEL008
Color 8
Gosub LABEL008
Color 15
Print " "
Goto LABEL009
:LABEL008
Print "<┤EGiS CoRP'94"
Delay 2
Backup 14
Return
:LABEL009
EndProc
;------------------------------------------------------------------------------
Function FUNCTION002() String
Word WORD014
BOOLEAN002 = 0
AnsiPos 1, 22
Print "@X0F"
Print "@X09MeSSaGE )> "
STRING004 = ""
:LABEL010
PROC009()
STRING003 = Inkey()
If (STRING003 <> "") Then
If (Len(STRING003) < 2) Then
If (STRING003 == Chr(27)) Then
BOOLEAN002 = 1
STRING003 = Chr(13)
Goto LABEL011
Endif
If (STRING003 == Chr(13)) Then
Goto LABEL011
Endif
If ((Asc(STRING003) > 31) && (Len(STRING004) < 50)) Then
Color 15
Print STRING003
STRING004 = STRING004 + STRING003
Endif
If (STRING003 == Chr(8)) Then
If (Len(STRING004) > 0) Then
Backup 1
Print "@X07 "
Backup 1
STRING004 = Mid(STRING004, 1, Len(STRING004) - 1)
Endif
Endif
Endif
Endif
Goto LABEL010
:LABEL011
FUNCTION002 = STRING004
EndFunc
;------------------------------------------------------------------------------
Function FUNCTION003() Word
Word WORD015
WORD006 = 1
PROC006(1)
While (1) Do
PROC009()
If (BOOLEAN001) Then
PROC006(WORD006)
BOOLEAN001 = 0
Endif
STRING003 = Inkey()
If (STRING003 == "DOWN") Then
PROC007(WORD006)
Inc WORD006
If (WORD006 > WORD005) WORD006 = 1
PROC006(WORD006)
Continue
Endif
If (STRING003 == "UP") Then
PROC007(WORD006)
Dec WORD006
If (WORD006 == 0) WORD006 = WORD005
PROC006(WORD006)
Continue
Endif
If (STRING003 == Chr(13)) Then
If (TWORD004(WORD006 - 1)) Then
PROC007(WORD006)
FUNCTION003 = WORD006
Break
Endif
Continue
Endif
If (STRING003 == Chr(27)) Then
PROC007(WORD006)
FUNCTION003 = 0
Break
Endif
EndWhile
EndFunc
;------------------------------------------------------------------------------
Procedure PROC007(Word WORD015)
AnsiPos 29, 7 + WORD015
Print "@X0F" + ScrText(29, 7 + WORD015, 25, 0)
AnsiPos 1, 23
EndProc
;------------------------------------------------------------------------------
Procedure PROC006(Word WORD016)
AnsiPos 29, 7 + WORD016
Print "@X1F" + ScrText(29, 7 + WORD016, 25, 0)
AnsiPos 1, 23
EndProc
;------------------------------------------------------------------------------
Procedure PROC008()
Cls
DispFile PPEPath() + "NOBODY", 0 + 4
EndProc
:LABEL012
AnsiPos 11 + (WORD009 - 1) * 14, 19
Print "@X0F" + ScrText(11 + (WORD009 - 1) * 14, 19, 14, 0)
Return
:LABEL013
AnsiPos 11 + (WORD009 - 1) * 14, 19
Print "@X1F" + ScrText(11 + (WORD009 - 1) * 14, 19, 14, 0)
Return
End
;------------------------------------------------------------------------------
Procedure PROC009()
If (Exist(STRING001)) Goto LABEL014
PROC008()
End
:LABEL014
If (Exist(PPEPath() + "WORK\LOCKED.SEM")) Then
If (BOOLEAN003) Goto LABEL015
BOOLEAN003 = 1
STRING006 = ScrText(35, 7, 6, 1)
AnsiPos 36, 7
Print "@X0FLoCKeD"
AnsiPos 1, 23
:LABEL015
ElseIf (BOOLEAN003) Then
BOOLEAN003 = 0
AnsiPos 36, 7
Print STRING006
AnsiPos 1, 23
Endif
If (Exist(STRING001)) Then
If (Crc32(1, STRING001) <> DWORD001) Then
WORD011 = GetX()
WORD012 = GetY()
DWORD001 = Crc32(1, STRING001)
WORD005 = FileInf(STRING001, 4) / 2
PROC001()
BOOLEAN001 = 1
For WORD002 = 1 To WORD005
AnsiPos 25, 7 + WORD002
If (WORD002 < 10) Then
Print "@X0F", WORD002
Goto LABEL016
Endif
Print "@X0F" + "0"
:LABEL016
AnsiPos 29, 7 + WORD002
If (TWORD004(WORD002 - 1) <> 0) Then
RdUNet TWORD004(WORD002 - 1)
Print FUNCTION001(UN_Name())
Continue
Endif
Print "- "
Next
AnsiPos WORD011, WORD012
Goto LABEL017
Endif
If (INTEGER001 + 1 < Time()) Then
WORD011 = GetX()
WORD012 = GetY()
AnsiPos 28, 7 + WORD010
Print "@X0F "
Inc WORD010
If (WORD010 > WORD005) WORD010 = 1
AnsiPos 28, 7 + WORD010
Print "@X09■"
INTEGER001 = Time()
AnsiPos WORD011, WORD012
Endif
Endif
:LABEL017
EndProc
;------------------------------------------------------------------------------
;
; Usage report (before postprocessing)
;
; ■ Statements used :
;
; 6 End
; 2 Cls
; 2 ClrEol
; 8 Color
; 77 Goto
; 68 Let
; 26 Print
; 1 PrintLn
; 55 If
; 2 DispFile
; 1 FCreate
; 3 FOpen
; 4 FAppend
; 8 FClose
; 8 FPutLn
; 1 StartDisp
; 1 GetUser
; 1 Delete
; 10 Gosub
; 3 Return
; 2 Delay
; 4 Inc
; 2 Dec
; 2 RdUNet
; 30 AnsiPos
; 3 Backup
; 1 FSeek
; 1 FRead
; 7 EndProc
; 3 EndFunc
;
;
; ■ Functions used :
;
; 4 *
; 2 /
; 47 +
; 14 -
; 20 ==
; 6 <>
; 11 <
; 5 <=
; 5 >
; 10 >=
; 45 !
; 11 &&
; 5 ||
; 4 Len(
; 1 Upper()
; 1 Mid()
; 1 Left()
; 8 Chr()
; 1 Asc()
; 3 Time()
; 1 U_Name()
; 5 Replace()
; 3 Inkey()
; 4 String()
; 9 PPEPath()
; 1 PcbNode()
; 2 UN_Name()
; 4 Exist()
; 2 GetX()
; 2 GetY()
; 2 FileInf()
; 6 ScrText()
; 3 Crc32()
;
;------------------------------------------------------------------------------
;
; Analysis flags : No flag
;
;------------------------------------------------------------------------------
;
; Postprocessing report
;
; 5 For/Next
; 2 While/EndWhile
; 34 If/Then or If/Then/Else
; 0 Select Case
;
;------------------------------------------------------------------------------
; AEGiS Corp - Break the routines, code against the machines!
;------------------------------------------------------------------------------