All pastes #295177 Raw Edit

Someone

public text v1 · immutable
#295177 ·published 2006-12-29 04:10 UTC
rendered paste body
################################
## Custom Server Colors:  (( standard mirc color codes ))
## Color settings for items below can be set in 2 ways:
## 1) one number:  like "06" : for text in purple
## 2) 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 c(0) "12"  ;# Logo color
set c(1) "02"  ;# Text color
set c(2) "03"  ;# Highlight
set c(3) "04"  ;# Triggers
set c(4) "14"  ;# Dividers
set c(5) "12"  ;# Pack descriptions

###############################
## Set Directory Path
## Example: set p0 "home/lamer/eggdrop/warez/music"
set p0 "/home/poppabear/eggefnet/warez/music"

#############################
## Set admins nick here
## Nick for contact reasons
set admin "poppabear"

############################
## Set File Type
## Example: set ftype "Music" or "Movies" or "Games"
set ftype "Music"


### Binds ###
bind dcc n|n start start:proc
bind dcc n|n stop stop:proc
bind pub -|- !list list:proc
bind pub -|- !getfile get:proc

setudef flag servplus

proc utime:proc {chan} {

}

proc list:proc {nick host hand chan {arg}} {
global c p0 ftype

foreach chan [channels] { if [channel get $chan servplus] {
set mdir [pwd]
cd $p0
set fi [glob *]
set data [split $fi]

        foreach e $data {
        putserv "PRIVMSG $nick :\002Use:\003$c(3) !getfile \003\003$c(2)\<FileName>\003\002"
        putserv "PRIVMSG $nick :\002 Do Not Include The File Size \002"
        putserv "PRIVMSG $nick :\002\003$c(5)\All Your Favorite $ftype\003\002"
        putserv "PRIVMSG $nick :\002\003$c(2)\FileName:\003 $e\002 (Size: [file size $e]-Bytes)"
        }

  }
 }
cd $mdir
}

proc get:proc {nick host hand chan arg} {
global admin p0
if {$arg == ""} {
putserv "NOTICE $nick :Syntax is:\002 !getfile <file> \002"
putserv "NOTICE $nick :!list in channel for list of files and triggers"
return
}

set a [dccsend $p0/$arg $nick]

 if {$a == "3"} {
      putserv "NOTICE $nick :File doesn't exist. Please report broken files to $admin"
} elseif {$a == "1"} {
      putserv "NOTICE $nick :The dcc table is full (too many connections)"
} elseif {$a == "2"} {
      putserv "NOTICE $nick :Can't open a socket for the transfer. Please report this to $admin"
} elseif {$a == "4"} {
      putserv "NOTICE $nick :The file was queued for later transfer"
} elseif {$a == "0"} {
putserv "NOTICE $nick :Successfully sent $arg"
 }
}

putlog "servplus script loaded"