r9k updates

After breaking my own silent promise not to touch r9k for the last week of 'holidays', I believe I have reached the point where I feel it ok not to edit the code now and then.

In fact so much that I shared it: http://randname.pastebin.com/f280b7151
(Sorry for bad formatting and weird obfuscation, it's one of my very bad habits)
Feel free to edit it as much as possible. If you can get it to be more like Moderator on #xkcd-signal, why not?

Changes include:
1) No more debug mode.
2) Sets channel to +m on activation, -m on leaving. Also announces to the chan
3) Mutes for configurable (default 5 seconds) time by -o pplz
4) either say "!r9k" or pm the bot "timeout" to get the current mute time
5) either say "!r9k form [nick]" or pm the bot "form [nick]" to find out how many times you have angered the bot. If nick is left out it defaults to you.
6) Password for remote toggling. Look for "password" in the code and change that.
7) Nick list accessible from @users and also $num_users after calling load_users();
8) Xchat::EAT_NONE; instead of printing again.
9) Order of stripping: Case, Multi-letters (>3), punctuation, Multi-whitespace.

Finally, a well deserved rest away from perl. But this means I need to rush the remaining homework. Kuso.

0 comments: