This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Netbot relay chat

Old posts that have not been replied to for several years.
Locked
s
strex

Netbot relay chat

Post by strex »

Hi guys i have a script that makes echo of everything a specific user says on a channel to another channel in the same network using a bot. I liked to know if in netbots is possible to make the first bot echo for a second bot in other network, that should write in the channel

example:

user@chan1@network1: “hello world”

bot1@chan1@network1:(catch "hello world") - > send To - > bot 2@chan1@network2 that will write to the channel "hello world"

is there any chance to make this "send to" with netbots tcl?


Sorry my English :oops:

Thanks
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

I fail to see how this is related to netbots.

Are you planning to write it yourself? If not; many such scripts exists already.
s
strex

Post by strex »

user wrote:I fail to see how this is related to netbots.

Are you planning to write it yourself? If not; many such scripts exists already.
well, my idea it was to see if theres any command like netsay in netbots that i could include in the first tcl, to make the other bot echos to the other network.

I know that there are a script called netlink, thats relays all the chat in a channel to other in a diferent network... but i just want to echo a single user.

Do u know any script that could make me that? and that could echo precisly as the user write.. like with bolds.. etc... ?
User avatar
slennox
Owner
Posts: 593
Joined: Sat Sep 22, 2001 8:00 pm
Contact:

Post by slennox »

You would use a combination of commands for sending messages to other bots over the botnet (putbot, putallbots) and "bind bot" to trigger a proc on the bot that receives the command.

It would be possible to do it through netbots.tcl, but it is basically a more complex version of the above, so if you don't already have some experience writing scripts that send/receive things over the botnet, you probably don't want to try making your script through netbots.

Here is an example of using putbot and bind bot:

Code: Select all

proc strex_receive {frombot command text} {
  putlog "I received from $frombot the command '$command' with the argument '$text'"
  return 0
}

bind bot - testcmd strex_receive
Load that on one bot, and on another bot that is on the botnet make sure the .tcl command is enabled (check it's not being unbound in the config file) and type .tcl putbot <otherbot> "testcmd arguments go here". That is the best way to learn how it all works.

I'm not sure if the suninet tcl guide deals with this topic -- but have a look there too.
s
strex

Post by strex »

thx slennox, it works just fine now with your code and a few more.

bye :D
Locked