|
| Author |
Message |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Tue Dec 20, 2005 3:07 am Post subject: I would like some help, PLEASE! |
|
|
please keep in mind i am absolutely new to this!
I am confortable(ish) with Abyss Web Server and installing Perl etc.
I just want a chat bot that ppl can add themselves to and when the bot adds the new contact it will do something like
"welcome to info bot, please enter and of the following commands to get a reply, ^ip - gives you the bots ip ^time - gives you the time" and so on and so forth... this should be easy for you guys. cos MSN plus! can dish out the time and ip etc... can anyone reccomend a good bot for me?
I downloaded SDBA (from http://www.duncanlamb.com/sdba ) but haven't had a play yet..
can anyone help!!!
thanks, adam
ps: email is adamwis@gmail.com if you'd rather email |
|
| Back to top |
|
 |
JTW God Like

Joined: 07 Mar 2004 Posts: 579 Location: Maidstone
  votes: 4
|
Posted: Tue Dec 20, 2005 10:36 am Post subject: |
|
|
That is very easily done (well im not sure about the IP bit but im sure someone else can help) You could just use the echobot and set up subtyping to work as a welcome mesaage when a new conversation is opened. And then use sub message to process commands.
Or if you want to use a template i would recomend using a lite template.
I would be wiling to make the bot for you but it is proberly better that you get some basic knowledge of perl yourself so you get a basic idea on how to fix errors if they show up. _________________ "Help us, Help you" - BotDepot |
|
| Back to top |
|
 |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Tue Dec 20, 2005 3:08 pm Post subject: |
|
|
| JTW wrote: | That is very easily done (well im not sure about the IP bit but im sure someone else can help) You could just use the echobot and set up subtyping to work as a welcome mesaage when a new conversation is opened. And then use sub message to process commands.
Or if you want to use a template i would recomend using a lite template.
I would be wiling to make the bot for you but it is proberly better that you get some basic knowledge of perl yourself so you get a basic idea on how to fix errors if they show up. |
hey thanks for your prompt reply!!! i have installed Maya Bot to find it does not actually use MSN Messenger, meaning no MSN Plus!!! do any bots "plug in" to msn messenger? |
|
| Back to top |
|
 |
darkmonkey The Merovingian

Joined: 18 Apr 2004 Posts: 2557 Location: London, England
     votes: 7
|
|
| Back to top |
|
 |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Tue Dec 20, 2005 3:18 pm Post subject: |
|
|
| taa will read up |
|
| Back to top |
|
 |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Tue Dec 20, 2005 3:20 pm Post subject: |
|
|
from what i see that won't do the (!IP) command, because that is a command run on the "server" side. btw: chatbot is at saedravmer@hotmail.com - as unexciting as it is. |
|
| Back to top |
|
 |
Cer Upgraded Agent

Joined: 03 Feb 2004 Posts: 3776 Location: Michigan
  votes: 4
|
Posted: Tue Dec 20, 2005 6:24 pm Post subject: |
|
|
| AdamW wrote: | | from what i see that won't do the (!IP) command, because that is a command run on the "server" side. |
It's done on the sending user's client, not the server. You could have your bot send its IP if you can get it into a variable first.
| Code: | | $self->sendMessage ("My IP address is $ip"); |
Look into Sys::Hostname or just use LWP::Simple and grab a whatismyip.com kind of site.
edit, Sys::HostIP, not Sys::Hostname [both would work but SysIP is easier] _________________ Current Site (2008) http://www.cuvou.com/
Last edited by Cer on Tue Dec 20, 2005 6:29 pm; edited 1 time in total |
|
| Back to top |
|
 |
alienz Almost An Agent

Joined: 22 Mar 2004 Posts: 1436 Location: Mars
 
|
Posted: Tue Dec 20, 2005 6:27 pm Post subject: |
|
|
Why would you want to give the public your bot's IP? LOL _________________ Check out Botworld! A dev resource for things bot.
Downloads, articles, news, fourm and more.
http://botworld.marzopolis.com |
|
| Back to top |
|
 |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Wed Dec 21, 2005 4:48 am Post subject: |
|
|
so ppl can connect to my streaming radio (i have a dynamic ip) or the FTP client. (when i said server side i meant the chatbot as the server, not msn's servers)
thanks for your help... I will attempt to understand the interesting mix of characters above that are supposed to help me do this. |
|
| Back to top |
|
 |
alienz Almost An Agent

Joined: 22 Mar 2004 Posts: 1436 Location: Mars
 
|
Posted: Wed Dec 21, 2005 7:15 am Post subject: |
|
|
| AdamW wrote: | so ppl can connect to my streaming radio (i have a dynamic ip) or the FTP client. (when i said server side i meant the chatbot as the server, not msn's servers)
thanks for your help... I will attempt to understand the interesting mix of characters above that are supposed to help me do this. |
What Cer was explaining is that you can use a module like Sys::HostIP to do it. You can find most modules on CPAN at cpan.org
Using Modules - http://www.unix.org.ua/orelly/perl/prog3/ch11_01.htm
Using PPM to install Modules - http://aspn.activestate.com/ASPN/docs/ActivePerl/5.8/faq/ActivePerl-faq2.html
The Sys::HostIP manpage - http://search.cpan.org/~bluelines/Sys-HostIP-1.3.1/HostIP.pm
Or ...(Assuming your external IP is directly connected to the machine.)
| Code: |
#!/usr/bin/perl
# the interface is what your external IP is bound to- eth0 or ppp0, most likely
# if you're on ADSL/dialup, it's probably ppp0
$interface="ppp0";
# path to ifconfig
$ifconfig="/sbin/ifconfig";
@lines=qx|$ifconfig $interface| or die("Can't get info from ifconfig: ".$!);
foreach(@lines){
if(/inet addr:([\d.]+)/){
print "$1\n";
}
}
|
Muhahahah _________________ Check out Botworld! A dev resource for things bot.
Downloads, articles, news, fourm and more.
http://botworld.marzopolis.com |
|
| Back to top |
|
 |
AdamW Newbie

Joined: 20 Dec 2005 Posts: 12
    
|
Posted: Wed Dec 21, 2005 7:20 am Post subject: |
|
|
thanks for you help  |
|
| Back to top |
|
 |
|