Author
Topic: Requesting "!seen" script (Read 33546 times)

My scripting skills are woefully inadequate, else I'd be able to deal with this myself, or adapt some other product's script successfully. I believe it's the lack of full documentation of IC7 scripting functionality that prevents me from puzzling it out anyway in this case.

Is there a chance that some worthy person has or can port a common "!seen" script to be usable in IC7?

A "seen" script keeps a database of at least joins/parts in a channel, often also nickchanges, and replies upon prompting (usually with "!seen <nick>") by giving the elapsed time since the nick in question was last used in the channel. Often, the quit/part message will also be given. The user is also commonly listed as "present in the channel as <nick>" if there's a related nickchange.

One useful thing that I also usually find in previous examples, is the ability to have the script only act on particular channels of the list that a user may be joined at a given time.

A "seen" script keeps a database of at least joins/parts in a channel, often also nickchanges, and replies upon prompting (usually with "!seen <nick>") by giving the elapsed time since the nick in question was last used in the channel. Often, the quit/part message will also be given. The user is also commonly listed as "present in the channel as <nick>" if there's a related nickchange.

One useful thing that I also usually find in previous examples, is the ability to have the script only act on particular channels of the list that a user may be joined at a given time.

Anything else?

Hmm, I could do this, I think.

The problem I run into is when we hit the part about the time. I know there is a datediff function in Visual Basic i'm just not sure how to do it in Icechat, For I have never used it. I'll look into this right now.

Hi, i dnot know if anyone is interested still in this, but... Here is a seen script for the most popular IRC bot "eggdrop" its written in tcl, my question is can it be somehow changed to work/rewritten for IceChat? (don't mind the polish texts those are just replys from bot and not script variables). Sorry for double post, but it wont fit in one post.

#bs(no_pub) is a list of channels you *don't* want the bot to post public # replies to (public queries ignored). Enter in lower case, eg: #lamerset bs(no_pub) ""

#bs(quiet_chan) is a list of channels you want replies to requests sent # to the person who made the query via notice. (The bot replies to # public queries via notice.) Enter in lower case.set bs(quiet_chan) ""

#bs(no_log) is a list of channels you *don't* want the bot to log# data on. Enter chans in lower case.set bs(no_log) ""

#bs(log_only) is a list of channels you *only* want the bot to log# data on. This is the opposite of bs(no_log). Set it to "" if you # want to log new channels the bot joins. Enter chans in lower case.set bs(log_only) ""

#bs(cmdchar) is what command character should be used for making public # queries. The default is "!". Setting it to "" is a valid option.set bs(cmdchar) "!"

#bs(flood) is used for flood protection, in the form x:y. Any queries# beyond x in y seconds is considered a flood and ignored.set bs(flood) 4:15#bs(ignore) is used as a switch for ignoring flooders (1=on)set bs(ignore) 1#bs(ignore_time) is used to define the amount of time a flooder is # ignored (minutes). This is meaningless if bs(ignore) is 0.set bs(ignore_time) 2

#bs(smartsearch) is a master enable/disable for SmartSearch. SmartSearch ensures that# the most accurate and current results are returned for nick queries. (1=on)set bs(smartsearch) 1

#bs(logqueries) is used to log DCC/MSG/PUB queriesset bs(logqueries) 1

#bs(path) is used to indicate what path to save the database and backup to. # Setting to "" will cause the script to be saved in the same path as the eggdrop executable# If you set it, use the full path, and make sure you terminate w/ a "/". # eg: set bs(path) "/usr/home/mydir/blah/"set bs(path) ""

Yeah i know its big, but then again there's a lot of things needed to be set. I pasted whole script cause maybe somebody knows how to rewrite TCL into IceChat. I really look forward to Morio's script, my last IRC client had this function and i will be gratefull if the one he wrote will work.

If Len(When) > 0 then SendCommand "/msg " & Channel & " " & Who & " is in this channel right now",ServerNumber End If

If Len(When) = 0 then When = getinifile("seen.ini",Channel,"part:" & Who,"") If Len(When) > 0 then SendCommand "/msg " & Channel & " " & Who & " was last seen on " & When,ServerNumber End If If Len(When) = 0 then SendCommand "/msg " & Channel & " " & Who & " has never been seen on this channel",ServerNumber End If End If

/scan:/! scan $1Load the script and type '/scan'this will scan through all your channels and create an ini file with all the nicknames in those channels, note that this can take a while if you are on many/big channels, and it might seem that icechat has crashed because it won't respond while it is scanning, but it will come back to life when it's done. If icechat says that it's taking longer than expected to execute, just keep hitting continue every time you get the popup.

You should run the scan command every time you start icechat, but note that it must be run after you are connected and have joined all your channels.when/if you join a new channel you need to do '/scan #channelname' to scan that channel and add the info to the ini.

The script won't work perfectly with multiple networks if there are channels or persons with the same name on both networks.

to use the script people simply have to type !seen nickname, this currently only work for other people, not for yourself, but I will be adding that functionality sometime soon.

If you have any problems wih the script, contact me, and I'll try to help you out.

And last but not least, a big big thank you to DarkStar, he created most of the code needed for quits and nick changes.

Logged

"I don't know what World War 3 will be fought with, but I know World War 4 with be fought with sticks and stones." - Albert Einstein