home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 15
/
CD_ASCQ_15_070894.iso
/
vrac
/
bcon110.zip
/
LOGOFF.PPE
(
.txt
)
< prev
next >
Wrap
PCBoard Programming Language Executable
|
1994-05-19
|
6KB
|
418 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 2.OO (plain) - Analysis ON - Postprocessing ON
;------------------------------------------------------------------------------
Boolean BOOLEAN001
Boolean BOOLEAN002
Integer INTEGER001
Integer INTEGER002
Integer INTEGER003
Integer INTEGER004
Integer INTEGER005
Integer INTEGER006
Integer INTEGER007
Integer INTEGER008
Integer INTEGER009
Integer INTEGER010
Integer INTEGER011
Integer INTEGER012
Integer INTEGER013
Integer INTEGER014
String STRING001
String STRING002
String STRING003
String STRING004
String STRING005
String STRING006
String STRING007
String STRING008
String STRING009
String STRING010
String STRING011
String STRING012
String STRING013
String STRING014
String STRING015
String STRING016
String TSTRING017(6)
String STRING018
String STRING019
Time TIME001
Time TIME002
Time TIME003
;------------------------------------------------------------------------------
INTEGER011 = 5
INTEGER013 = "@X1F"
STRING019 = INTEGER013
STRING009 = TokenStr()
GetUser
PutUser
BOOLEAN001 = 0
If (BOOLEAN001) Then
PrintLn "Cmdline = " + STRING009
Wait
Endif
STRING014 = PPEPath() + "\" + "logoff.cfg"
STRING013 = PPEPath() + "work\whotmp"
STRING015 = PPEPath() + "graph\offtext"
STRING011 = PPEPath() + "offmenus.cfg"
If (LangExt() <> "") Then
If (Exist(STRING015 + LangExt())) Then
STRING015 = STRING015 + LangExt()
Endif
Endif
INTEGER009 = ReadLine(STRING014, 1)
If (INTEGER009 > 0) Then
BOOLEAN002 = 1
Else
BOOLEAN002 = 0
Endif
INTEGER005 = ReadLine(STRING011, 1)
STRING003 = PPEPath() + "graph\off"
STRING018 = ReadLine(STRING014, 2)
INTEGER006 = ReadLine(STRING014, 3)
If (U_Sec < ToInteger(ReadLine(STRING014, 4))) Then
Bye
End
Endif
STRING007 = Upper(ReadLine(STRING014, 5))
STRING005 = ReadLine(STRING015, 1)
STRING001 = ReadLine(STRING015, 6)
TIME001 = Time()
TIME002 = ReadLine(PCBDat(), 189)
TIME003 = ReadLine(PCBDat(), 190)
STRING002 = Chr(13)
If (AnsiOn()) Goto LABEL001
PrintLn
PrintLn "Sorry but you have to have ansi capabilities to use the lightbar"
PrintLn "logoff matrix, please make sure you have ansi installed and call back"
End
:LABEL001
StartDisp 1
If (STRING007 == "LIGHTBAR") Then
Gosub LABEL002
Else
Gosub LABEL008
Endif
End
:LABEL002
Tokenize STRING009
STRING012 = ""
If (TokCount() >= 1) Then
If (BOOLEAN001) Then
PrintLn "tokcount == 1"
Endif
STRING008 = GetToken()
If (BOOLEAN001) Then
PrintLn "token = " + STRING008
Wait
Endif
If (Upper(STRING008) == "UPDATE") Then
End
Endif
If (((STRING008 >= "1") && (STRING008 <= String(INTEGER011))) || (Upper(STRING008) == "Y")) Then
If (BOOLEAN001) Then
PrintLn "token =", STRING008
Wait
Endif
STRING012 = STRING008
INTEGER012 = STRING008
If (Upper(STRING008) == "Y") Then
STRING012 = "1"
INTEGER012 = 1
Endif
Else
:LABEL003
INTEGER008 = Random(INTEGER005 - 1) + 1
DispFile STRING003 + String(INTEGER008), 1 + 4
STRING016 = ReadLine(STRING011, 1 + INTEGER008)
Tokenize STRING016
INTEGER003 = GetToken()
INTEGER004 = GetToken()
STRING010 = ""
STRING010 = GetToken()
INTEGER014 = STRING010
INTEGER007 = INTEGER004
TSTRING017(5) = ScrText(INTEGER003, INTEGER007, INTEGER014, 1)
TSTRING017(4) = ScrText(INTEGER003, INTEGER007 - 1, INTEGER014, 1)
TSTRING017(3) = ScrText(INTEGER003, INTEGER007 - 2, INTEGER014, 1)
TSTRING017(2) = ScrText(INTEGER003, INTEGER007 - 3, INTEGER014, 1)
TSTRING017(1) = ScrText(INTEGER003, INTEGER007 - 4, INTEGER014, 1)
STRING019 = GetToken()
INTEGER012 = 1
INTEGER001 = INTEGER003
INTEGER002 = INTEGER004
For INTEGER007 = INTEGER011 To 1 Step -1
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER007
Print TSTRING017(INTEGER007)
Next
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER012
Print STRING019, StripAtx(TSTRING017(INTEGER012))
:LABEL004
STRING012 = Inkey()
Endif
Endif
Select Case (STRING012)
Case "a", "UP", "LEFT"
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER012
Print TSTRING017(INTEGER012)
If (INTEGER012 == 1) Then
INTEGER012 = INTEGER011
Else
INTEGER012 = INTEGER012 - 1
Endif
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER012
Print STRING019, StripAtx(TSTRING017(INTEGER012))
Goto LABEL004
Case "z", "DOWN", "RIGHT"
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER012
Print "@X0F", TSTRING017(INTEGER012)
If (INTEGER012 == INTEGER011) Then
INTEGER012 = 1
Else
INTEGER012 = INTEGER012 + 1
Endif
AnsiPos INTEGER001, INTEGER002 - INTEGER011 - INTEGER012
Print STRING019, StripAtx(TSTRING017(INTEGER012))
Goto LABEL004
Case ||, "1", String(INTEGER011)
If (STRING012 <> STRING002) INTEGER012 = STRING012
Select Case (INTEGER012)
Case 1
Goto LABEL005
Case 2
DefColor
Cls
End
Case 3
Call STRING018
StartDisp 1
Case 4
Call PPEPath() + "feedback.ppe"
FClose -1
StartDisp 1
Case 5
Gosub LABEL006
End Select
Goto LABEL003
Case Else
If (BOOLEAN001) If (STRING012 <> "") PrintLn STRING012
Goto LABEL004
End Select
Goto LABEL003
:LABEL005
DefColor
Cls
PrintLn
PrintLn
PrintLn STRING005
If (BOOLEAN002) Then
INTEGER010 = Random(INTEGER009 - 1) + 1
DispFile PPEPath() + "graph\bye" + String(INTEGER010), 1 + 4
Endif
Bye
End
:LABEL006
DefColor
Cls
STRING006 = ReadLine(STRING015, 19)
PrintLn STRING006 + String(INTEGER006) + ReadLine(STRING015, 16)
STRING006 = ReadLine(STRING015, 15)
PrintLn STRING006 + U_Name()
FCreate 1, PPEPath() + "work\offtmp" + "." + String(PcbNode()), 1, 0
INTEGER007 = 0
STRING006 = ReadLine(STRING015, 17)
While (1) Do
If (INTEGER007 >= INTEGER006) Break
STRING004 = ""
InputStr STRING006 + "_", STRING004, 3, 79, Mask_Ascii(), 2 + 512
If (STRING004 == "") Break
FPutLn 1, STRING004
PrintLn
Inc INTEGER007
EndWhile
Newline
STRING012 = "S"
STRING006 = ReadLine(STRING015, 7)
InputStr STRING006, STRING012, 1, 1, "AaSsTt", 2
If (STRING012 == "") Then
FClose 1
Return
Else
Select Case (Upper(STRING012))
Case "A"
FClose 1
Goto LABEL007
Case "T"
FClose 1
Goto LABEL006
Endif
End Select
Newline
STRING012 = Upper(NoChar())
InputYN ReadLine(STRING015, 20), STRING012, 1
If (Upper(STRING012) == Upper(NoChar())) Then
FPutLn 1, ""
FPutLn 1, ReadLine(STRING015, 21) + U_Name()
Else
FPutLn 1, ""
FPutLn 1, ReadLine(STRING015, 21) + ReadLine(STRING015, 22)
Endif
FClose 1
Copy PPEPath() + "work\offtmp" + "." + String(PcbNode()), PPEPath() + "graph\msg"
Return
:LABEL007
Return
:LABEL008
STRING012 = YesChar()
Newline
InputYN ReadLine(STRING015, 23), STRING012, 1
If (Upper(STRING012) == Upper(NoChar())) Then
Return
ElseIf (Upper(STRING012) <> Upper(YesChar())) Then
Return
Endif
Newline
STRING012 = NoChar()
InputYN ReadLine(STRING015, 24), STRING012, 1
If (Upper(STRING012) == Upper(YesChar())) Then
Call PPEPath() + "feedback.ppe"
FClose -1
Endif
Newline
STRING012 = NoChar()
InputYN ReadLine(STRING015, 25), STRING012, 1
If (Upper(STRING012) == Upper(YesChar())) Then
Gosub LABEL006
Endif
PrintLn STRING005
If (BOOLEAN002) Then
INTEGER010 = Random(INTEGER009 - 1) + 1
Endif
DispFile PPEPath() + "graph\bye" + String(INTEGER010), 1 + 4
Bye
Return
;------------------------------------------------------------------------------
;
; Usage report (before postprocessing)
;
; ■ Statements used :
;
; 6 End
; 3 Cls
; 3 Wait
; 64 Goto
; 68 Let
; 6 Print
; 15 PrintLn
; 41 If
; 3 DispFile
; 1 FCreate
; 6 FClose
; 5 FPutLn
; 3 StartDisp
; 1 GetUser
; 1 PutUser
; 3 DefColor
; 2 InputStr
; 4 InputYN
; 4 Gosub
; 6 Return
; 1 Inc
; 5 Newline
; 2 Tokenize
; 3 Call
; 3 Bye
; 6 AnsiPos
; 1 Copy
;
;
; ■ Functions used :
;
; 5 -
; 40 +
; 20 -
; 26 ==
; 4 <>
; 2 <
; 3 <=
; 1 >
; 6 >=
; 36 !
; 4 &&
; 7 ||
; 17 Upper()
; 1 Chr()
; 3 Random()
; 1 Time()
; 2 U_Name()
; 5 NoChar()
; 4 YesChar()
; 3 StripAtx()
; 1 Inkey()
; 8 String()
; 1 Mask_Ascii()
; 2 PCBDat()
; 12 PPEPath()
; 2 PcbNode()
; 23 ReadLine()
; 5 GetToken()
; 1 Exist()
; 1 TokenStr()
; 3 LangExt()
; 1 AnsiOn()
; 1 TokCount()
; 5 ScrText()
; 1 ToInteger()
;
;------------------------------------------------------------------------------
;
; Analysis flags : WCd
;
; W - Write user ■ 5
; Program writes a user record. Although this may be normal for a
; User Editor, it may also be a way to modify an account level.
; ■ Search for : PUTUSER
;
; C - Call child PPE ■ 3
; This is usually normal, but may be a tricky way to launch some
; sysop-only commands.
; ■ Search for : CALL
;
; d - Access PCBOARD.DAT ■ 2
; Program gets the full pathname to PCBOARD.DAT, this may be usefull
; for many PPE so they can find various informations on the system
; (system paths, max number of lines in messages, ...) but it may also
; be a way to gather vital informations.
; ■ Search for : PCBDAT()
;
;------------------------------------------------------------------------------
;
; Postprocessing report
;
; 1 For/Next
; 1 While/EndWhile
; 23 If/Then or If/Then/Else
; 3 Select Case
;
;------------------------------------------------------------------------------
; AEGiS Corp - Break the routines, code against the machines!
;------------------------------------------------------------------------------