################################
## Custom Server Colors: (( standard mirc color codes ))
## Color settings for items below can be set in 3 ways:
## 1) one number: like "06" : for text in purple
## 2) two numbers: like "04,12" : for red text, blue background (1st# = text, 2nd# = background)
## 3) no numbers: like "" : no color code for this item.. text will be user default colors.
#------------------------------------------------------------------------------------#
# 00=white 01=black 02=dkblue 03=green 04=red 05=brown 06=purple 07=orange 08=yellow #
# 09=lightgreen 10=darkgreen 11=bluegreen 12=blue 13=pink 14=darkgrey 15=lightgrey #
#------------------------------------------------------------------------------------#
set c0 "12" ;# Logo color
set c1 "02" ;# Text color
set c2 "03" ;# Highlight
set c3 "04" ;# Triggers
set c4 "14" ;# Dividers
set c5 "12" ;# Pack descriptions
###############################
## Set Directory Paths
## Example: set p0 "./music/" ;# Music Directory
set p0 "warez/music/" ;# Music Directory
set p1 "warez/movies/" ;# Movies Directory
set p2 "warez/apps/" ;# Apps Directory
set p3 "warez/games/" ;# Games Directory
set p4 "warez/porn/" ;# Porn Directory
set p5 "warez/misc/" ;# Misc Directory
##############################
## Set Path To Database Files
set d0 "db/music.ini" ;# Music DataBase
set d1 "db/movies.ini" ;# Movies DataBase
set d2 "db/apps.ini" ;# Apps DataBase
set d3 "db/games.ini" ;# Games DataBase
set d4 "db/porn.ini" ;# Porn DataBase
set d5 "db/misc.ini" ;# Misc DataBase
### Binds ###
bind dcc n|n add add:proc
bind dcc n|n del del:proc
bind dcc n|n start start:proc
bind dcc n|n stop stop:proc
bind pub -|- !list list:proc
# bind time - "00 * * * *" time:proc
# bind time - "30 * * * *" time:proc
setudef flag servplus
proc add:proc {hand idx text} {
global p0 p1 p2 p3 p4 p5 d0 d1 d2 d3 d4 d5 c0 c1 c2 c3 c4 c5
set type [lindex [split $text] 0]
set file [lindex [split $text] 1]
set desc [lrange $text 2 end]
switch -- $type {
music {
set a [open $d0 a+]
puts $a "\003$c5$desc\003"
puts $a "Trigger: \003$c3!getfile $p0$file\003"
puts $a "Filename: \003$c2$file\003"
puts $a " "
close $a
}
movie {
set a [open $d1 a+]
puts $a "$p1$file"
close $a
}
app {
set a [open $d2 a+]
puts $a "$p2$file"
close $a
}
game {
set a [open $d3 a+]
puts $a "$p3$file"
close $a
}
porn {
set a [open $d4 a+]
puts $a "$p4$file"
close $a
}
misc {
set a [open $d5 a+]
puts $a "$p5$file"
close $a
}
default {putlog "Syntax is \002 .add <type> <file>\002"}
}
}
# proc time:proc {mins hours days months years} {
proc list:proc {nick host hand chan {arg}} {
global c0 c1 c2 c3 c4 c5 d0 d1 d2 d3 d4 d5
foreach chan [channels] { if [channel get $chan servplus] {
set list "$d0 $d1 $d2 $d3 $d4 $d5"
foreach {c} $list {
set spl [split $c]
set fi [open $spl r]
set data [read $fi]
foreach {c} [split $data \n] {
putserv "PRIVMSG $nick :\002$c\002"
}
}
close $fi
}
}
}
putlog "servplus script loaded"