View Single Post
  #1  
Old 6th January 2011, 10:16
draconian draconian is offline
Senior Member
 
Join Date: Jun 2010
P2P
Posts: 39
Default [Tutorial] Setting up Eggdrop for TSSE
I was looking up why i couldnt get eggdrop to work with my TSSE5.6

Credit goes to Cyberlock. (http://www.bvlist.com/tsse/885-setti...s-channel.html)

EggDrop setup, here is a tutorial how : http://www.egghelp.org/setup.htm

Edit all text in red with your own information

Now lets get to the takeupload.php.
SEARCH
Code:
$size = mksize ($totallen);
ADD AFTER
Code:
$bot['ip'] = "IP ADRESSE FOR BOT SERVER"; // your bot ip
$bot['port'] = "PORT TO BOT USING"; // your script listen port
$bot['password'] = "PASSWORD"; // password which you have set in script
$bot['message'] = "7,1[New torrent was uploaded] 0,1-> 3,1Name: \002$torrent\002 .:. Category: \002$cat\002 0,1.:. 4,1URL: \002$BASEURL/details.php?id=$id"; // your message

$fp = fsockopen($bot['ip'], $bot['port'], $errno, $errstr, 40);

if($fp)
{
    fputs($fp, $bot['password'] . " " . $bot['message'] . "\n");
    sleep(15);
    fclose($fp);
}
//botmsg("New Torrent :: ($torrent) :: ($cat) :: ($s) :: ($BASEURL/details.php?id=$id)");
// Bot IRC end
Now we add the tcl script to EggDrop for the takeupload to connect.
I assume you are using a shell or a linux to install EggDrop since its only available on linux.

nano /whereyoueggdropfolderislocated/scripts/announce.tcl

ADD
Code:
# port for your script you want to listen on (you need to set same port in php script)
set botlisten(port) "SAME PORT AS TAKEUPLOAD"
# password (you need to set same password in php script)
set botlisten(password) "PASSWORD"
# channel you want to send output to
set botlisten(channel) "#IRCCHAN"
listen $botlisten(port) script botlisten
proc botlisten {idx} {
    control $idx botlisten2
}
proc botlisten2 {idx args} {
global botlisten newTorrentChannel
set args [join $args]
set botlisten(pass) [lindex [split $args] 0]
set botlisten(message) [join [lrange [split $args] 1 end]]
if {[string match $botlisten(pass) $botlisten(password)]} then {
   putquick "PRIVMSG $botlisten(channel) :$botlisten(message)"
 } else {
  putlog "Unauthorized person tried to connect to the bot"
  }
}
Next Open youeggdropconfig.conf
SEARCH
Code:
TCL Scripts
ADD
Code:
source scripts/announce.tcl
If you dont like the format the bot announces the uploads, you can edit "$bot['message']" in takeupload.php

P/S remember to login to setting panel and edit your irc settings.
Reply With Quote