home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Carsten's PPE Collection
/
Carstens_PPE_Collection_2007.zip
/
T
/
TVIEW33.ZIP
/
TV.PPE
(
.txt
)
< prev
next >
Wrap
PCBoard Programming Language Executable
|
1994-06-19
|
8KB
|
488 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
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 STRING017
String STRING018
String STRING019
String STRING020
String STRING021
String STRING022
String STRING023
String STRING024
String STRING025
String STRING026
String STRING027
String STRING028
String STRING029
String STRING030
String STRING031
String STRING032
String STRING033
String STRING034
String STRING035
String STRING036
;------------------------------------------------------------------------------
STRING021 = "@X0BTextView v3.3 (c) Joseph Sheppard, The Ledge PCBoard (818) 896-4015"
Newline
GetToken STRING001
STRING001 = PPEPath() + STRING001
If (Exist(STRING001)) Then
Gosub LABEL001
If (STRING029 == "") STRING029 = STRING003 + "\TVMENU"
If (STRING030 == "") STRING030 = STRING003 + "\TVHELLO"
If (STRING031 == "") STRING031 = STRING003 + "\TVBYE"
Log "Executed TextView to Display " + STRING008, 0
If (Upper(Left(STRING009, 1)) == "Y") Gosub LABEL002
If (Exist(PPEPath() + "TV.KEY")) Gosub LABEL003
If (!BOOLEAN001) Gosub LABEL004
INTEGER004 = MinLeft()
If (Exist(STRING030)) DispFile STRING030, 2 + 1 + 4
If (Exist(STRING030)) Wait
GetUser
If (U_Sec == INTEGER002) Gosub LABEL005
Gosub LABEL007
Goto LABEL029
:LABEL001
FOpen 1, STRING001, 0, 0
FGet 1, STRING002
FGet 1, STRING003
FGet 1, INTEGER001
FGet 1, INTEGER002
FGet 1, INTEGER003
FGet 1, STRING004
FGet 1, STRING005
FGet 1, STRING006
FGet 1, STRING007
FGet 1, STRING008
FGet 1, STRING009
FGet 1, STRING010
FGet 1, STRING011
FGet 1, STRING029
FGet 1, STRING030
FGet 1, STRING031
FClose 1
STRING032 = INTEGER001
Return
Endif
Beep
Beep
Newline
PrintLn "@X0CThe Configuration File is Missing! Please Notify the Sysop!"
PrintLn STRING001
Newline
End
:LABEL002
PrintLn Chr(7) + "@X0E" + Mid(STRING009, 3, Len(STRING009) - 2)
InputStr "@X0A[@X0FY@X0A]es, [@X0FN@X0A]o, [@X0FG@X0A]oodbye", STRING012, 7, 1, Mask_Ascii(), 0
If (Upper(STRING012) == "Y") Return
If (Upper(STRING012) == "G") Goto LABEL028
End
:LABEL003
FOpen 1, PPEPath() + "TV.KEY", 0, 0
FGet 1, STRING013
FGet 1, STRING014
FGet 1, STRING015
FGet 1, STRING016
FClose 1
STRING017 = Mid(STRING013, 4, 1)
STRING017 = String(Asc(STRING017) + 9)
STRING018 = Mid(STRING014, 2, 1)
STRING018 = String(Asc(STRING018) * 4)
STRING019 = Mid(STRING015, 3, 1)
STRING019 = String(Asc(STRING019) + 2)
STRING020 = STRING017 + STRING018 + STRING019
If (STRING020 == STRING016) BOOLEAN001 = 1
If (STRING020 <> STRING016) BOOLEAN001 = 0
Return
:LABEL004
STRING022 = ""
Newline
PrintLn STRING021
If (BOOLEAN001) Newline
If (BOOLEAN001) PrintLn "@X0ERegistered to:@X0F " + STRING013 + " on " + STRING015
If (BOOLEAN001) PrintLn "@X0E Sysop: @X0F" + STRING014
If (!BOOLEAN001) PrintLn "@X0F[UNREGISTERED EVALUATION COPY]"
If (!BOOLEAN001) Newline
If (!BOOLEAN001) Delay 30
If (!BOOLEAN001) Wait
Newline
Return
:LABEL005
If (EvtTimeAdj()) Return
AdjTime INTEGER003
Newline
INTEGER008 = MinLeft()
PrintLn "@X0F" + String(INTEGER003) + " minutes have been added to your time while visiting " + STRING008
Newline
Return
:LABEL006
If (!EvtTimeAdj()) AdjTime -INTEGER003
Return
:LABEL007
While (STRING022 <> "Q") Do
GetToken STRING022
DefColor
Newline
PrintLn "@POFF@"
DispFile STRING029, 2 + 1 + 4
Newline
Print "@X0E(@X0C" + String(MinLeft()) + "@X0E min. left) "
Print "(1-" + STRING032 + ") "
If (Upper(STRING004) <> "N") Print "(D)ownload "
PrintLn "(S)earch (A)bout (Q)uit (G)oodbye "
InputStr "@X0FCommand", STRING022, 7, 100, Mask_Ascii(), 256
Tokenize STRING022
Gosub LABEL008
EndWhile
Return
:LABEL008
While (Len(STRING022) > 0) Do
GetToken STRING022
If (STRING022 == "Q") Goto LABEL029
If (STRING022 == "QUIT") Goto LABEL029
If (STRING022 == "QU") Goto LABEL029
If (STRING022 == "G") Goto LABEL028
If (STRING022 == "GOODBYE") Goto LABEL028
If (STRING022 == "BYE") Goto LABEL028
If (STRING022 == "D") Gosub LABEL009
If (STRING022 == "S") Gosub LABEL015
If (STRING022 == STRING011) Gosub LABEL024
If (STRING022 == "NS") STRING022 = " "
If (STRING022 == "A") Gosub LABEL004
If (STRING022 <> " ") Gosub LABEL027
EndWhile
Return
:LABEL009
STRING022 = ""
If (Upper(STRING004) == "N") Return
STRING022 = " "
If (STRING004 == "S") Goto LABEL013
Gosub LABEL010
InputStr "@X0FFile to Download ", STRING027, 7, 100, Mask_Ascii(), 256
If (STRING027 == "") Return
Gosub LABEL014
If (STRING027 == " ") Return
Download ""
Return
:LABEL010
FOpen 2, STRING003 + "\TVDIR", 0, 0
FGet 2, STRING028
PrintLn "@X06" + STRING028
FGet 2, STRING028
PrintLn "@X06" + STRING028
FGet 2, STRING028
PrintLn "@X06" + STRING028
:LABEL011
If (Ferr(2)) Goto LABEL012
FGet 2, STRING028
If (InStr(STRING028, "|") > 0) PrintLn "@X03" + Space(33) + Mid(STRING028, 34, 45)
If (Abort()) FClose 2
If (Abort()) Return
STRING033 = Mid(STRING028, 1, 12)
STRING034 = Mid(STRING028, 16, 7)
STRING035 = Mid(STRING028, 24, 8)
STRING036 = Mid(STRING028, 34, 45)
If (InStr(STRING028, "|") == 0) PrintLn "@X0E" + STRING033 + " @X0A" + STRING034 + " @X0C" + STRING035 + " @X0B" + STRING036
Goto LABEL011
:LABEL012
FClose 2
Return
:LABEL013
Flag STRING005
Download STRING005
Return
:LABEL014
If (Exist(STRING005 + "\" + STRING027)) Flag STRING005 + "\" + STRING027
If (!Exist(STRING005 + "\" + STRING027)) PrintLn "@X0C" + STRING027 + " Not Found!"
If (!Exist(STRING005 + "\" + STRING027)) STRING027 = " "
Return
:LABEL015
STRING022 = ""
STRING023 = ""
Newline
If (BOOLEAN001) Then
InputStr "@X0BEnter the Text to Scan for, (Enter) to Exit ", STRING025, 7, 100, Mask_Ascii(), 256
If (Len(STRING025) < 1) Return
Newline
InputStr "@X0BMenu item to search? (1-" + STRING032 + "), (A)ll, (Enter) to Exit ", STRING022, 7, Len(STRING032), Mask_Ascii(), 256
Tokenize STRING022
GetToken STRING022
If (STRING022 == "A") Gosub LABEL016
If (STRING022 == "") Return
If (STRING022 < 0) Goto LABEL025
If (STRING022 > INTEGER001) Goto LABEL025
Gosub LABEL026
Gosub LABEL017
STRING022 = ""
STRING022 = ""
Return
Endif
PrintLn "@X0CSorry, the SEARCH feature available in registered copies only."
Return
:LABEL016
INTEGER009 = 1
STRING022 = INTEGER009
While (INTEGER009 < INTEGER001 + 1) Do
STRING022 = INTEGER009
Gosub LABEL026
Gosub LABEL017
Inc INTEGER009
STRING022 = INTEGER009
If (INTEGER009 == INTEGER001) Return
EndWhile
Return
:LABEL017
BOOLEAN002 = 0
FOpen 1, STRING023, 0, 0
Newline
PrintLn "@X0ESearching menu item #", INTEGER006, "....."
Newline
FGet 1, STRING026
:LABEL018
If (Ferr(1)) Goto LABEL019
If (Abort()) FClose 1
If (Abort()) Return
If (InStr(Upper(STRING026), Upper(STRING025)) > 0) Gosub LABEL020
FGet 1, STRING026
Goto LABEL018
:LABEL019
FClose 1
If (!BOOLEAN002) PrintLn "@X0CThe requested text was not found in Menu Item #", INTEGER006, "@X07"
STRING022 = ""
STRING023 = ""
Return
:LABEL020
DefColor
FClose 1
Newline
BOOLEAN002 = 1
Print "@X0BThe Requested text has been found in Menu Item #", INTEGER006, ":"
DefColor
Newline
FOpen 1, STRING023, 0, 0
FGet 1, STRING026
:LABEL021
If (Ferr(1)) Goto LABEL022
INTEGER007 = 0
INTEGER007 = InStr(Upper(STRING026), Upper(STRING025))
If (InStr(Upper(STRING026), Upper(STRING025)) > 0) Gosub LABEL023
If (InStr(Upper(STRING026), Upper(STRING025)) < 1) PrintLn StripAtx(STRING026)
FGet 1, STRING026
Goto LABEL021
:LABEL022
FClose 1
STRING023 = ""
STRING022 = ""
Return
:LABEL023
Print StripAtx(Left(STRING026, INTEGER007 - 1))
Print "@X70" + Upper(STRING025)
DefColor
INTEGER010 = INTEGER007 + Len(STRING025)
INTEGER011 = Len(STRING026) - STRING025
PrintLn StripAtx(Mid(STRING026, INTEGER010, INTEGER011))
Return
:LABEL024
If (STRING011 == "NONE") Return
STRING011 = PPEPath() + STRING011
Shell 1, INTEGER005, STRING011, ""
If (!OnLocal()) Log "Shelled to " + STRING011, 1
STRING022 = " "
Return
:LABEL025
If (STRING022 == " ") Goto LABEL007
If (Len(STRING022) < 1) Goto LABEL007
Newline
Log STRING022 + " is an invalid command", 0
Beep
PrintLn Chr(7) + "@X0C[" + STRING022 + "] is an invalid command @FIRST@"
STRING022 = ""
Goto LABEL007
:LABEL026
If (Len(STRING022) < 1) Return
If (STRING022 == " ") Return
If (STRING007 == "DEFAULT") STRING023 = STRING003 + "\TV" + STRING022
If (STRING007 == "DEFAULT") Return
If (!BOOLEAN001) STRING023 = STRING003 + "\TV" + STRING022
If (!BOOLEAN001) Return
FOpen 1, STRING007, 0, 0
INTEGER006 = 0
While (STRING022 <> INTEGER006) Do
Inc INTEGER006
FGet 1, STRING023
EndWhile
FClose 1
Return
:LABEL027
If (STRING022 < 1) Goto LABEL025
If (STRING022 > INTEGER001) Goto LABEL025
STRING024 = TokenStr()
Tokenize STRING024
Gosub LABEL026
If (Len(STRING022) < 1) Return
If (STRING022 == " ") Return
PrintLn "@PON@"
If (InStr(STRING024, "NS")) PrintLn "@POFF@"
DispFile STRING023, 2 + 1 + 4
Wait
Log "Read File: " + STRING023, 0
STRING023 = " "
Return
:LABEL028
If (U_Sec == INTEGER002) Gosub LABEL006
If (Exist(STRING031)) DispFile STRING031, 2 + 1 + 4
Goodbye
End
:LABEL029
If (U_Sec == INTEGER002) Gosub LABEL006
Newline
If (Exist(STRING003 + "\TVBYE")) DispFile STRING003 + "\TVBYE", 2 + 1 + 4
End
;------------------------------------------------------------------------------
;
; Usage report (before postprocessing)
;
; ■ Statements used :
;
; 4 End
; 3 Wait
; 32 Goto
; 52 Let
; 6 Print
; 24 PrintLn
; 86 If
; 5 DispFile
; 6 FOpen
; 9 FClose
; 29 FGet
; 1 GetUser
; 4 DefColor
; 2 AdjTime
; 4 Log
; 5 InputStr
; 24 Gosub
; 37 Return
; 1 Delay
; 2 Inc
; 19 Newline
; 3 Tokenize
; 4 GetToken
; 1 Shell
; 3 Beep
; 1 Goodbye
; 2 Flag
; 2 Download
;
;
; ■ Functions used :
;
; 1 -
; 1 *
; 75 +
; 3 -
; 35 ==
; 5 <>
; 8 <
; 6 >
; 21 !
; 9 Len(
; 14 Upper()
; 10 Mid()
; 2 Left()
; 1 Space()
; 3 Ferr()
; 2 Chr()
; 3 Asc()
; 7 InStr()
; 4 Abort()
; 3 StripAtx()
; 5 String()
; 5 Mask_Ascii()
; 4 PPEPath()
; 1 OnLocal()
; 3 MinLeft()
; 9 Exist()
; 1 TokenStr()
; 2 EvtTimeAdj()
;
;------------------------------------------------------------------------------
;
; Analysis flags : ASf
;
; A - Adjust online time remaining ■ 5
; Program modify the amount of online time remaining, this may
; be a way to bypass time limits
; ■ Search for : ADJTIME
;
; S - Shell to DOS ■ 5
; This may be normal if the PPE need to execute an external command,
; but may be actually anything... nasty (formating HD, rebooting,...)
; or usefull (sorting, maintenance,...). Check!
; ■ Search for : SHELL
;
; f - Flag files for download ■ 3
; This may be normal if a PPE needs to send some files, but since
; this statement allows flagging of any file on the hard disk, you
; have to be carefull. Check!
; ■ Search for : FLAG
;
;------------------------------------------------------------------------------
;
; Postprocessing report
;
; 0 For/Next
; 4 While/EndWhile
; 2 If/Then or If/Then/Else
; 0 Select Case
;
;------------------------------------------------------------------------------
; AEGiS Corp - Break the routines, code against the machines!
;------------------------------------------------------------------------------