I doubt I'll find someone with enough patience and time for this, but it never hurts to ask.
I worked on an mIRC bot for about 3 years and it took me quite a while to learn it all, especially the counting script. Now I would like to "convert" my mIRC script so that I could use it in an eggdrop but I'm having quite a bit of trouble with it.
My bot generally just writes something whenever someone in the channel types a key word (e.g. you write "brb", the bot will say "see you in a sec!").
For that, I wrote this in TCL:
Code: Select all
bind pub -|- "brb" brb
proc brb { nick host hand chan text } {
putserv "msg $nick/$chan :See you in a sec $nick"
}
I have absolutely no idea if that's correct and I couldn't find anything on Google where I could test it for free (i.e. without an eggdrop, I only want to buy it when I actually have the script). Any suggestions would be great.
Now it gets a bit harder... when someone joins or leaves a channel, the bot says something again (e.g. on join -> Hello $nick!). It gets a bit more complicated, when the bot has some restrictions. For example, my mIRC script says "Hello $nick" if the ($nick != BotNick) and ($chan != #CertainChannel).
That's most of what my bot does or rather what the eggdrop should do. I do have 2 very complicated scripts, however. That would be the "counting script".
Whenever someone types "!cookie", the bot will say "X gave cookie to Y" and will add the variable 1 to Y. The variable will always increase, depending on how many cookies Y received and when you type "?cookie Y", the bot would tell you how many cookies Y has -> "Y has X $variable" (e.g. "Y has 10 cookies"). Again with many if's and else (Y has 1 cookie, Y has 0 cookieS, Y has 10 cookieS, etc). All variables are bound to the nicknames that were given cookies to and are saved by the bot.
The bot also "steals" cookies, where the variable will be decreased from X by 1 and added to Y by 1. E.g. "!cookiesteal X" -> "Y stole a cookie from X" -> Y has now +1 $variable (cookie) and X has minus 1.
One last thing I have is a timer with quit and rejoin. The bot leaves the channel with a certain text when you write the trigger word, comes back after X seconds and writes another sentence.
Other than that, the only thing that changes is that sometimes the text the bot writes is written via query, sometimes directly in the channel and sometimes via notice.
I've tried to learn this, but I'll tell you straight away, I'm a "noob". I would like any help you can give me - no matter if it's rewriting my script for me (though I know that is a bit much to ask) or giving me examples of how to write the certain codes I want or just general tips and tricks.
Looking forward to your replies!