home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Crawly Crypt Collection 1
/
crawlyvol1.bin
/
bbs
/
asn151
/
assassin.scr
< prev
next >
Wrap
Text File
|
1991-10-05
|
6KB
|
207 lines
SCRIPT
; Assassin.SCR v1.0
; Change and setup to match your BBS and tastes.
abort off
SETUP:
clear variables
;! Change the following to fit your system
define noplay = 10 ; minutes left after which play is not allowed
define bbs_log = 'f:\rcacall.log' ;or pathname (c:\bbs\callers.log)
define bbs_path = 'f:\' ;path BBS is run from
define game_menu = 'f:\menus_80\games.hlp' ;pathname of main game menu
; All your Assassin files should be in one folder (Assassin_path)
; The folder containing the files MUST be on the same drive as BBS!
define Assassin_path = 'F:\Assassin\' ;Assassin folder
define Assnprg = 'Assassin.Tos' ;program name
define Assndoc = 'Assassin.ins' ;doc file
define Assnnews = 'Asnnews.log' ;news file
define %0 ; 1 key input for user selection
define pause ; Dummy input, used to pause display
define user_log ; For log print routine LOGPRINT
define docfile ; For file printer routine DOCPRINT
define fc ; Variable for file copy
integer cd ; Variable for directory changes
define prompt ; prompt for command routine
define option ; where command routine looks for choice
define time_used_call ; for time limit routine
define time_left_call ;
define time_used_day ;
define time_left_day ;
define time_on ;
define time_ok ;
define time_per_call = '&13' ;
define time_per_day = '&14' ;
define time_before = '&15' ;
user_log = 'Enters Assassin menu' ;if you want to know when callers
gosub logprint ;enter Assassin menu
TOP:
prompt = '\r\i Assassin \o\b\v\{12-DGX?\}: ' ;Add G if you exec a game menu
option = 'Assassin'
goto menuAss
COMMAND:
abort off
margin (2)
printe
print '(&32 min) [prompt]' ; Hold the cursor on this line
if time_exceeded ;check time limit every time game prompt prints
printe ;blank line between game and BBS prompt
exit ;let BBS log them off
endif
get_key %0 ;get callers choice
goto [option] ;goto the if/ef choice routine
LOGPRINT:
open '[bbs_log]', append ;logs callers activity
fprinte ' &23 [user_log]'
close
return
DOCPRINT:
printe
printe ' < Control-S to Pause,\vControl-X to Abort >'
printe
view '[docfile]' ;formats text output
return
INVALID:
printe 'Enter ? For Menu...' ; what happens upon invalid command
goto command ; choice
Assassin:
if %0 = '?' ;choices for Assassin
printe 'Help!'
goto menuAss
ef %0 = 1
print 'Play Assassin? \{y,N\}: '
goto playAss
ef %0 = 2
printe 'Assassin News'
docfile = '[Assassin_path][Assnnews]'
gosub docprint
goto command
ef %0 = D
printe 'Assassin Doc\"s'
docfile = '[Assassin_path][Assndoc]'
gosub docprint
goto command
ef %0 = G
cd= file_chgdir '[BBS_Path]'
printe 'Exit To Game Menu...'
execute [game_menu]
ef %0 = X
cd= file_chgdir '[BBS_Path]'
printe 'Exit to BBS..'
exit
endif
goto invalid
PLAYAss:
abort off
get_key %0
if %0 # Y
printe 'No'
goto command
else
printe 'Yes'
endif
gosub timelimit
if time_ok = N
user_log = '-->Attempts Assassin after time limit!'
gosub logprint
goto command
endif
printe
printe ' Loading Assassin'
printe
open 'F:\Assassin\Dorinfo1.def', output ; Forem2.2
fprinte 'Rubber City BBS' ;
fprinte 'Don' ;
fprinte 'Crano' ;
fprinte ;
fprinte ;
fprinte '&01' ;
fprinte '&01' ;
fprinte ;
%0 = '0' ;don't know why this is needed, but it is...
fprinte '0' ;
fprinte '0' ;
fprinte '30' ;
fprinte ;
close ;
user_log = 'Plays Assassin'
gosub logprint
close
printe
GEM '[Assassin_path][Assnprg]' ;! Assassin prg filename
abort off
user_log= 'Quits Assassin'
cd = file_chgdir '[bbs_path]'
gosub logprint
close
printe
goto command
TIMELIMIT:
increase noplay
if &29 = 300 ;if 300 baud, cut them off
noplay = [noplay] + 5 ;5 minutes sooner
endif
time_ok = Y
time_on = &32
time_left_call = [time_per_call] - [time_on] ;time left for this call
if time_left_call < noplay
printe '\n Sorry, you don\"t have enough time\vduring this call to play.'
time_ok = N
endif
time_used_day = [time_before] + [time_on]
time_left_day = [time_per_day] - [time_used_day] ;time left for today
if time_left_day < noplay
printe '\n Sorry, you don\"t have enough time\vleft for today to play.'
time_ok = N
endif
return
MENUAss:
clear screen
if &11= '80' then
margin (20)
endif
printe ' \r '
printe ' \i \o'
printe ' \i Rubber City Presents \o' ; Your BBS name goes here
printe ' \i -------------------- \o'
printe ' \i Assassin \o'
printe ' \i \o'
printe ' \b '
printe ' \r\{1\}\b Play Assassin '
printe ' \r\{2\}\b Assassin News '
printe
printe ' \r\{D\}\b Documentation'
printe ' \r\{G\}\b Exit to Game Menu' ;if you execute a game menu
printe ' \r\{X\}\b Exit to BBS'
printe ' \r\{?\}\b This Menu'
printe
goto command