1 2005-07-06 Clinton Ebadi <clinton@unknownlamer.org>
3 * bobot++.texinfo (Misc Scripting Stuff): Documented bot:who and
6 * source/Interp.C (interp_init_helper): Add bot:who and bot:whois
9 * source/ScriptCommands.C (Who): Implemented Who method
10 Removed IQUEUE macro (no longer needed)
11 (Whois): Implemented Whois method
13 * source/ScriptCommands.H: Added Who and Whois methods
15 * source/Commands.C (Who): Implemented Who
16 (Whois): Implemented Whois
18 * source/Commands.H: Add Who and Whois tethods
20 * source/Interp.C: Updated copyright notice
21 (interp_init_helper): Remove send from CTCP/CTCPReply method names
23 * source/Interp.H: Updated copyright notice
25 * source/ScriptCommands.C (CTCP): Renamed from sendCTCP
26 (CTCPReply): Renamed from sendCTCPReply
28 2005-07-05 Clinton Ebadi <clinton@unknownlamer.org>
30 * bobot++.texinfo (Low Level Message Functions): Updated docs to
31 reflect new names for ctcp functions
33 * source/Interp.C (interp_init_helper): Register
34 ScriptCommands::Notice instead of sendNotice
35 (interp_init_helper): Renamed bot:send-ctcp to bot:ctcp
36 (interp_init_helper): Renamed bot:send-ctcp-reply to bot:ctcp-reply
38 * source/ScriptCommands.C (Notice): Renamed from sentNotice
40 * source/ScriptCommands.H: Renamed sendNotice to Notice
42 * bobot++.texinfo (Hook Types): Spelling fix
44 2005-07-04 Clinton Ebadi <clinton@unknownlamer.org>
46 * scripts/bobot-utils.scm (_deprecated-fun): Set
47 current-error-port to bot:logport while calling
48 issue-deprecation-warning
50 * bobot++.texinfo: Grammar fixes on the title page
51 (Configuration): Added more info on config files.
52 (bot.conf): Added xrefs for server syntax and channel syntax
53 (server syntax): Added more detail and moved a paragraph
54 (channel syntax): Added more details, revised the examples, and
55 moved some text around
56 (User Levels): Clarified
57 (Protection): Cleaned up
58 (Automatic Op): Improved substantially
60 * source/DCCManager.C (checkInput): Call hooks/dcc/chat-end if the
63 * scripts/bobot-utils.scm (bot:log): Updated to use bot:logport
64 instead of bot-logport
66 * source/Interp.C (interp_init_helper): Add hooks/dcc/chat-end
69 * bobot++.texinfo (DCC CHAT Hooks): Document hooks/dcc/chat-end
71 * source/BotInterp.H: Add DCC_CHAT_END to enum
73 * source/DCCManager.C (checkStale): Run hooks/dcc/chat-end when
74 deleting a stale connection.
76 2005-07-03 Clinton Ebadi <clinton@unknownlamer.org>
78 * bobot++.texinfo (Hook Types): Documented all hooks
80 * source/ServerQueue.C (sendPrivmsg): Changed SEND_MESSAGE hook to
81 match dest and pass dest to send hook
83 * bobot++.texinfo (Hook Types): Changed language of
84 hooks/dcc/chat-* hook documention
85 (Received Message Hooks): Added subsub section of Hook Types
86 (Sent Message Hooks): Added subsub section of Hook Types
87 (DCC CHAT Hooks): Added subsub section of Hook Types
88 (Miscellaneous Hooks): Added subsub section of Hook Types
90 * source/Parser.C (parseScriptFunction): Changed
91 lazy_apply_wrapper to Interp::LazyApplyWrapper
92 (parseScriptFunction): Changed empty_handler to Interp::EmptyHandler
93 (parsePart): Grammar fix in log (Leaved => Left)
95 * source/Interp.H (Interp): Added LazyHandler method
97 * source/BotInterp.C (RunHooks): changed lazy_apply_wrapper to
98 Interp::LazyApplyWrapper
99 (RunTimers): Changed empty_handler to Interp::EmptyHandler
100 (RunHooks): Changed empty_handler to Interp::EmptyHandler
101 (RunTimers): Changed lazy_apply_wrapper to Interp::LazyApplyWrapper
103 * source/Interp.C (LazyHandler): Renamed from lazy_handler
104 (ScmApplyWrapper): Renamed from scm_apply_wrapper
105 (EmptyHandler): Renamed from empty_handler
107 * source/Interp.H (Interp): Removed ErrorHandler method
108 (Interp): Added LazyApplyWrapper method
109 (Interp): Added EmptyHandler method
110 (Interp): Added ScmApplyWrapper method
112 * scripts/bobot-utils.scm: Added hooks/leave as an alias for hooks/part
113 Added begin-deprecated around deprecated definitions
114 (_deprecated-fun): Added macro to define an alias for a function
115 and issue a deprecation warning when used
116 Converted all bot- aliases to use _deprecated-fun
118 * source/Interp.C (interp_init_helper): Changed Hook::LEAVE to
120 (interp_init_helper): Removed definition of hooks/leave
122 * bobot++.texinfo (Hook Types): Removed stub for hooks/leave, only
123 document hooks/part name (hooks/leave still exists, but will not
124 be documented as it is the same as hooks/part)
126 * source/Parser.C (parsePart): Use Hook::PART instead of Hook::LEAVE
128 * source/BotInterp.H: Removed Hook::LEAVE, added Hook::PART
130 * bobot++.texinfo (Scripting): Added note about most arguments
133 * source/Commands.C (NextServer): Call hooks/disconnect
135 * source/Bot.C (run): Pass extra argument to Hook::DISCONNECT
137 * bobot++.texinfo (Creating a Hook): Reformatted the bot:addhook
138 section to make it more readable
139 (Hook Types): Reformatted hooks/action
140 (Hook Types): Changed grammar of hooks/nickname (their => his)
141 (Hook Types): Documented hooks/signoff
143 2005-06-29 Clinton Ebadi <clinton@unknownlamer.org>
145 * bobot++.texinfo: Updated copyright years, changed "applies to
148 * source/Socket.C (readLine): return buf.substr (0, pos) instead
149 of using the String char * constructor (this should be faster,
150 especially for long strings since a simple copy is used instead of
151 going over each char until nul is encountered)
153 * configure.ac: Release 2.1.8
154 Change version to 2.1.9CVS
156 * source/Parser.C: Include Commands.H (fixes --disable-scripting build)
158 * source/Bot.C (Bot): Fix to make a --disable-scripting build work
160 * bobot++.texinfo (Configuration): Swapped order of config file
161 placement and config files
162 (User Levels): users not found in the user list *can* execute
163 commands as bot:user-none now.
164 (Low Level Message Functions): Changed a few @code{}s to @var{}s
166 2005-06-28 Clinton Ebadi <clinton@unknownlamer.org>
168 * bobot++.texinfo: @vskip Opt... => @vskip 0pt...
170 * source/Main.C (namespace): Added debug-scripts option
172 * source/Parser.C (parseCTCP): Hook::ACTION is now passed
173 from->getNick () instead of from->getAddress () (consistency fix)
175 * source/Main.C: Merged error handling patch from dsmith
177 * source/Parser.C: Merged error handling
180 * source/Interp.H: Merged error handling patch from dsmith
182 * source/Interp.C (lazy_handler): Merged error handling patch from
185 * source/BotInterp.H: Merged error handling patch from dsmith
187 * source/BotInterp.C: Merged error handling patch from dsmith
189 * bobot++.texinfo (Low Level Message Functions): Documented
192 * source/Parser.C (parseCTCP): Converted to use Commands::CTCPReply
194 * source/Interp.C (interp_init_helper): Bound bot:send-ctcp-reply
197 * bobot++.texinfo (Low Level Message Functions):
198 s/bot:send-CTCP/bot:send-ctcp/
200 * source/Interp.C (interp_init_helper): Renamed bot:send-CTCP to
203 * source/ScriptCommands.H: Uncommented sendCTCPReply prototype
205 * source/ScriptCommands.C (sendCTCP): Convert to use Commands::CTCP
206 (sendCTCPReply): Added
208 * source/Parser.C (parseJoin): Convert to use Commands::CTCP
210 * source/Commands.C (CTCP): Implemented
211 (CTCPReply): Implemented
212 (Action): Convert to use Commands::CTCP
214 * source/Commands.H: Added CTCP (bot, target, command, message)
215 Added CTCPReply (bot, target, command, message)
217 2005-06-27 Clinton Ebadi <clinton@unknownlamer.org>
219 * examples/bot.conf (maxnicklength): Update example config
221 * source/Utils.C (valid_nickname_p): Use b->MAX_NICKLENGTH
223 * source/Bot.C (readConfig): Look for MAXNICKLENGTH parameter
225 * source/Bot.H: Added MAX_NICKLENGTH member
227 * source/Utils.H (valid_nickname_p): Now takes Bot* as first argument
229 * source/Commands.C (Msg): Send multiple PRIVMSGs when a message
232 * source/UserCommands.C (SetVersion): Convert to use Commands::Notice
234 * source/Commands.C (Notice): Send multiple NOTICEs when a message
237 2005-06-25 Clinton Ebadi <clinton@unknownlamer.org>
239 * source/Main.C (real_main): Enable Guile debugging mode when
242 * source/Interp.C (interp_post_startup_helper): Return
243 SCM_UNSPECIFIED instead of 0
245 2005-06-24 Clinton Ebadi <clinton@unknownlamer.org>
247 * All: Updated FSF street address
249 * source/Commands.C (Msg): Move body of Say to an if inside of this
252 * source/ScriptCommands.C (sendNotice): Returns error code instead
255 * source/Commands.C (Say): Check to make sure target is a channel
256 (Msg): Extended to send messages to channels
258 2005-06-23 Clinton Ebadi <clinton@unknownlamer.org>
260 * scripts/bot.scm: Added file ((bobotpp bot) module for other
261 modules to gain access to bobot++ interface)
263 * source/Commands.C (Notice): Commented out check/abort if target
264 is a channel (there doesn't seem to be a reason for this to not work)
266 * source/Interp.C (interp_init_helper): Register bot:notice with scheme
268 * bobot++.texinfo (High Level Message Functions): Document bot:notice
270 * source/Message.H: Added operator== to Message (tests for error
273 * source/Commands.C: Removed message type macros
275 * source/Message.H: Moved message type macros to Message.H
277 * source/ScriptCommands.C (sendNotice): Implemented sendNotice
279 * source/ScriptCommands.H: Uncomment sendNotice
281 * source/Bot.C (waitForInput): Use %02d when formatting
282 Hooks::TIMER argument instead of %2d, and switch to snprintf to
285 * bobot++.texinfo (Hooks): Clarified intro text about hooks (order
288 * source/Bot.C (run): Added call to Hooks::DISCONNECT
289 (hooks/disconnect) when the bot is disconnected from the server
291 * bobot++.texinfo: Applied documentation patch from Dale P. Smith
292 (Hook Types): Added hooks/disconnect argument
294 2005-06-06 Clinton Ebadi <clinton@unknownlamer.org>
296 * bobot++.texinfo: Change @vskip 0 to @vskip 0pt to make this work
297 again (thanks dsmith)
299 2005-06-01 Clinton Ebadi <clinton@unknownlamer.org>
301 * source/Interp.C (interp_init_helper): Added
302 bot:protection/[none|ban|kick|deop] constants to Scheme
303 (interp_init_helper): Added bot:aop/[yes|no] constants
305 2005-05-31 Clinton Ebadi <clinton@unknownlamer.org>
307 * configure.ac: Release Bobot++ 2.1.7
308 Changed version to 2.18.CVS
310 * source/UserList.C (save): Remove workaround for BUG #2
312 * source/Parser.C (parse001): make realNick lowercase when doing
313 the comparison to bot->nickName to prevent pushing a second copy
314 of the bot onto the userlist (closes BUG #2)
316 * source/Bot.C (Bot): cleaned up constructor
317 (waitForInput): replaced gh_list with scm_list_n
319 * source/UserList.C: Cleaned up some formatting
321 * source/Main.C: Formatted code more cleanly
322 (real_main): changed a few Strings to std::strings
324 * source/String.C (operator): Made index signed again, it's not
325 worth fixing this warning
327 * source/Bot.C: Add casts to make this compile with unsigned int
328 as operator[] in String
330 * source/String.C (operator): Made index unsigned
332 * source/Utils.C: Made a few things unsigned to kill warnings
334 * source/Socket.C (readLine): Made pos unsigned
336 * source/Bot.C (Bot): Fixed initializer list order to kill warnings
338 * source/BotInterp.C (RunTimers): Removed unused variable (Timer *t)
340 * source/StringTokenizer.C (count_tokens): Changed return type to
342 (more_tokens_p): Made counter unsigned
344 * source/StringTokenizer.H (class StringTokenizer): Made pos
345 std::string::size_type instead of int
347 * source/Commands.C (TBan): Returns Ok is the ban is done instead
348 of falling off the end (oops)
350 * source/BotInterp.H: Add general catch case (false)
352 2005-03-11 Clinton Ebadi <clinton@unknownlamer.org>
354 * configure.ac: Release 2.1.6
355 Changed version to 2.1.7CVS
357 2005-02-28 Clinton Ebadi <clinton@unknownlamer.org>
359 * source/Parser.C (parseLine): use map<>::find and an iterator to
360 find the IRC command instead of map<>::operator[] to avoid a
363 * source/Bot.C (waitForInput): Removed commented out code
365 * source/Socket.C (readLine): return String (buf.c_str ()) instead
366 of String (buf) so that only the buffer up to the first null is returned
367 (readLine): Added a comment explaining the usage of buf
368 (readLine): Changed type of length (std::string::size_type instead
371 * source/String.C: Reimplemented String on top of std::string to
372 fix a few bugs and potential memory leaks
373 (toLower): use Utils::to_lower
374 (toUpper): Use Utils::to_upper
375 (trim): Use Utils::trim_str
377 * source/String.H: removed srep, replaced it with a std::string (my_string)
379 * source/Utils.C (to_upper): Applied patch from Jos Hulzink
381 (trim_str): Appled patch from Jos Hulzink <josh@stack.nl> (fixes
382 counters and substr call)
384 * source/StringTokenizer.C (next_token): Applied patch from Jos
385 Hulzink <josh@stack.nl> (fixes substr call)
386 (rest): Applied patch from Jos Hulzink <josh@stack.nl> (fixes
389 2005-02-27 Clinton Ebadi <clinton@unknownlamer.org>
391 * source/Bot.H (COPYRIGHT_STRING): Remove Michael Wilson because
392 he is a lazy bum and never submitted the String replacing patch
394 2005-01-23 Clinton Ebadi <clinton@unknownlamer.org>
396 * configure.ac: Remove CC++ test
397 Changed version to 2.1.6CVS (2.1.5 released)
399 * bobot++.texinfo: Updated copyright
401 2005-01-16 Clinton Ebadi <clinton@unknownlamer.org>
403 * TODO (General): Added TODO items
404 (2.2): Moved a few items here from 2.4
406 * README (NOTE): Mention boost requirement
408 2005-01-13 Clinton Ebadi <clinton@unknownlamer.org>
410 * ChangeLog Updated copryight
412 * source/User.H: Removed forward declaration of Utils
414 * source/Bot.H: Removed forward declaration of Utils
416 * source/ChannelList.H: Removed forward declaration of Utils
418 * source/UserListItem.H: Removed forward declaration of Utils
420 * source/Utils.H: Removed class Utils, replaced with a namspace
421 (it only contained static methods)
423 * source/Bot.H (COPYRIGHT_STRING): Added 2005 and Michael Wilson
424 (he is replacing String)
426 2005-01-12 Clinton Ebadi <clinton@unknownlamer.org>
428 * source/BotConfig.C (set_option_value): Put watcher calling
429 inside of if (cf_iter != end()) to fix a segfault (if the cf_iter
430 = end then there are no watchers since this is a new value and
431 references cf_iter->second segfaults)
433 * source/Utils.C (trim_str): Fixed bug (last non-space character
436 * source/BotConfig.C (read_config): Made to use set_option_value
437 instead of manipulating options_db directly
439 * source/BotConfig.H (class BotConfig): Add set_option_value that
440 takes a t_value instead of t_value_list (most uss of
441 set_option_value will be to add a single value so this is very useful)
443 * source/BotConfig.C (set_option_value): Implemented
445 * source/UserList.C: Made to work with new Utils/StringTokenizer names
447 * source/UserCommands.C: Made to work with new
448 Utils/StringTokenizer names
450 * source/ShitList.C: Uses Utils.H now (Utils::trim_str & friends)
452 2005-01-11 Clinton Ebadi <clinton@unknownlamer.org>
454 * source/ShitList.C: Made to work with new StringTokenizer names
456 * source/ServerQueueItem.C: Made to work with new StringTokenizer names
458 * source/ServerQueue.C: Made to work with new Utils names
460 * source/ScriptCommands.C: Made work with new Utils names
462 * source/Person.C (getNick): Made work with new Utils names
464 * source/String.H: Added substr prototypes
466 * source/String.C (substr): Added substr as an alias of subString
467 (for compat with std::string before the transition)
469 * source/Parser.C: Made to work with new Utils/StringTokenizer names
471 * source/DCCParser.C: Made to work with new Utils names
473 * source/DCCChatConnection.C: Made to work new Utils names
475 * source/Commands.C: Made to work with new Utils names
477 * source/Channel.C: Made to work with new Utils names
479 * source/BotInterp.C: Made to work with new Utils
481 * source/Bot.C: Made to work with new Utils/StringTokenizer names
483 * source/String.C (operator=): Unremoved operator=(std::string)
485 * source/String.H: Unremoved operator=(std::string)
487 * source/BotConfig.C (read_config): Use Utils::trim_str
489 * source/String.C (trim): Fixed bug (p->s[i] == '\r', s/i/j/)
491 * source/Utils.C (trim_str): Implemented
493 * source/Utils.H: Added tim_str (replaces String::trim)
495 * source/BotConfig.C: Made everything work with new
496 StringTokenizer and Utils names
498 * source/Utils.H: Added to_lower
501 * source/StringTokenizer.C (rest): uses std::isspace instead of
502 checking st[pos] against ' ' and '\t'
504 * source/StringTokenizer.H: Removed CamelCasing
505 Renamed hasMoreTokens to more_tokens_p
507 * source/StringTokenizer.C: Converted to use std::string
509 * source/StringTokenizer.H: Converted to use std::string
511 * source/String.C: Removed operator=(std::string)
513 * source/String.H: Removed operator=(std::string)
515 * source/Utils.C: Added copyright
516 Reformatted to match GNU coding standard more closely
517 Converted everything to use std::string
518 (get_nick): Renamed from getNick
519 (get_userhost): Renamed from getUserHost
520 (get_key): Renamed from getKey
521 (IP_p): Renamed from isIP
522 (make_wildcard): Renamed from makeWildcard
523 (channel_p): Renamed from isChannel
524 (wildcard_p): Renamed from isWildcard
525 (valid_channel_name_p): Renamed from isValidChannelName
526 (valid_nickname_p): Renamed from isValidNickName
527 (get_level): Renamed from getLevel
528 (str2time): Renamed from strToTime
529 (str2time): Fixed potential buffer overflow (num[512] => std::string)
530 (level2str): Renamed from levelToStr
531 (prot2str): Renamed from protToStr
532 (bool2str): Renamed from boolToStr
533 (long2str): Implemented
534 (scm2str): Renamed from scm2String
535 (str2scm): Renamed from string2SCM
537 * source/BotConfig.C: Reformatted to fit GNU coding style more closely
539 * source/Utils.H: Added long2str (long int -> std::string)
541 * source/String.H: Added 2003 copyright (the year I last modified
544 * source/String.C: Added 2002 copyright (the year I last modified
547 * source/Utils.H: Updated Copyright
548 s/String/std::string/g
549 Removed camel casing and is* = *_p
552 * source/BotConfig.C: Updated Copyright
554 * source/BotConfig.H: Updated copyright
556 2005-01-08 Clinton Ebadi <clinton@unknownlamer.org>
558 * source/BotConfig.C (set_option_value): Take care of the case
559 where key is not already in the db
560 (add_watcher): Implemented
561 (read_config): Removed ',' token parsing (not needed)
563 * configure.ac: Add AC_LANG([C++]) so we can check for C++ libs
564 AC_CHECK_LIB ccgnu2 (CommonC++2)
566 * README: Updated README (reformatted, adding info, etc.)
568 2005-01-07 Clinton Ebadi <clinton@unknownlamer.org>
570 * source/BotConfig.C (set_option_value): call watcher list
571 (run_fun_): Added to support watcher list calling
573 2005-01-06 Clinton Ebadi <clinton@unknownlamer.org>
575 * source/BotConfig.C (set_option_value): Fuck you STL
576 (push_back_): Reimplemented so that it doesn't need std::bind1st
577 because the STL is being stupid
579 2004-12-26 Clinton Ebadi <clinton@unknownlamer.org>
581 * source/BotConfig.C (read_config): Implemented properly
582 (get_option_values): Implemented properly
583 (set_config_file): Fixed
585 2004-07-10 Clinton Ebadi <clinton@unknownlamer.org>
587 * bobot++.texinfo (Built-In Commands): Added empty stubs to the
590 2004-06-22 Clinton Ebadi <clinton@unknownlamer.org>
592 * source/BotConfig.C: New file (implementation of configuration database)
594 * source/BotConfig.H: New File (semi-generic configuration database)
596 2004-06-17 Clinton Ebadi <clinton@unknownlamer.org>
598 * bobot++.texinfo (Starting the Bot): New section
600 2004-06-14 Clinton Ebadi <clinton@unknownlamer.org>
602 * bobot++.texinfo (Protection): Added Section
603 (User Levels): Rewrote section to be useful
604 (bot.users): Added section
606 2004-06-12 Clinton Ebadi <clinton@unknownlamer.org>
608 * source/DCCChatConnection.C (connect): Checks to make sure the
609 person initiating a DCC CHAT with the bot is at least a FRIEND of
612 * README: Fixed a typo
614 * scripts/bobot-utils.scm (ctcp-quote): Implemented ctcp-quote
615 (bot:ctcp-quote): Renamed ctcp-quote to bot:ctcp-quite (whoops)
617 2004-05-28 Clinton Ebadi <clinton@unknownlamer.org>
619 * bobot++.texinfo (bot.conf): Finished section
620 (server syntax): New section, documents the bot.conf SERVER syntax
621 (channel syntax): New section, documentes the bot.conf CHANNEL syntax
623 2004-05-13 Clinton Ebadi <clinton@unknownlamer.org>
625 * source/Main.C (real_main): std::exit instead of exit
627 2004-05-12 Clinton Ebadi <clinton@unknownlamer.org>
629 * source/DCCConnection.C (DCCConnection): Intialized `nuh' in the
630 constructor with `n' This should fix the segfaulting.
632 2004-01-28 Clinton Ebadi <clinton@unknownlamer.org>
634 * ChangeLog: Updated copyright notice
636 2004-01-09 Clinton Ebadi <clinton@unknownlamer.org>
638 * source/Interp.C (interp_init_helper): Register
639 bot:change-command-level
641 * source/ScriptCommands.C (ChangeCommandLevel): Added
642 ChangeCommandLevel to change the level a user needs to be to run a
645 * source/ScriptCommands.H: Added ChangeCommandLevel
647 2003-10-12 Clinton Ebadi <clinton@unknownlamer.org>
649 * source/String.H: Changed #define STRING_H to BSTRING_H
651 2003-08-04 Clinton Ebadi <clinton@unknownlamer.org>
653 * scripts/bobot-utils.scm (bot:sent-to-me?): New procedure, used
654 to see if a message was sent to the bot (this is better than
655 bot:match-to-me because the hook isn't invalidated when the bot's
658 * source/DCCConnection.H: Added `nuh' back and added an
660 Added setter `set_autoRemove(bool)'
662 * source/DCCConnection.H: Removed all friends
663 Added accessors (get_bot, get_lastSpoken, get_autoRemove; get_bot
664 reveals the pointer to the bot [PRIVATE POINTER] which probably
665 isn't so nice, but there isn't much to be done about it with the
666 current design of the bot)
668 * source/DCCChatConnection.H: Removed all friends
670 * source/DCCConnection.H: DCCConnection is now a pure virtual
671 class with the subclass DCCChatConnection
673 2003-07-29 Clinton Ebadi <clinton@unknownlamer.org>
675 * source/Socket.C (connect): log errors to the bot log instead of
678 2003-07-23 Clinton Ebadi <clinton@unknownlamer.org>
680 * source/Parser.C (parseMessage): use the find method of std::map
681 to find the command to call instead of [] and then extract the
682 pointer to the userFunction from that if it exists. This appears
683 to fix the crash when one uses an undefined command followed by
686 2003-04-09 Clinton Ebadi <clinton@unknownlamer.org>
688 * source/Interp.C (interp_init_helper): Bind bot:setfloodrate to
689 ScriptCommands::SetFloodRate
691 * source/ScriptCommands.C (SetFloodRate): New Method: SetFloodRate
693 * source/Bot.C (init_user_functions): Make SETFLOODRATE available
696 * source/Bot.H: Made MAX_MESSAGES writeable
698 * source/UserCommands.H: New method: SetFloodRate
700 * source/Commands.H: New method: SetFloodRate
702 2003-04-03 Clinton Ebadi <clinton@unknownlamer.org>
704 * configure.ac: Merged all AC_OUTPUTs at the end
706 2003-04-02 Clinton Ebadi <clinton@unknownlamer.org>
708 * scripts/bobot-utils.scm: Make exported symbols from
709 the-bot-module available in the guile-user module so that scripts
710 loaded with Interp::Load function.
712 2003-03-30 Clinton Ebadi <clinton@unknownlamer.org>
714 * scripts/bobot-utils.scm (bot:load-module): Loads a file from the
715 %bot:loadpath into its own module and returns that (unnamed) module
716 (bot:use-module): Calls bot:load-module and then adds the newly
717 loaded module to the (current-module)'s use-list
719 * source/Interp.C (interp_init_helper): New procedure to initialize
720 the-bot-module (this is the old Interp::Startup verbatim)
721 (interp_post_startup_helper): New procedure to export
722 the-bot-module from bot_module
723 (Startup): Now calls interp_init_helper and
724 interp_post_startup_helper to initalize the bot module system
726 * source/Interp.H: Added private variable bot_module to Interp
728 2002-11-04 Clinton Ebadi <clinton@unknownlamer.org>
730 * scripts/bobot-utils.scm: Added bot: to regex functions (yes,
731 this breaks existing scripts, this is the unstable tree after all)
733 2002-11-03 Clinton Ebadi <clinton@unknownlamer.org>
735 * source/Mask.C (match): Made Mask::match case insensitive
737 2002-09-23 Clinton Ebadi <clinton@unknownlamer.org>
739 * source/Interp.C (scm_apply_wrapper): turned off locking of
740 Interp::mutex to see if this makes the bot work again...and it
743 2002-09-07 Clinton Ebadi <clinton@unknownlamer.org>
745 * configure.ac: Removed arguments to AM_INIT_AUTOMAKE and updated
746 everything to use aclocal/automake 1.6
748 2002-08-27 Clinton Ebadi <clinton@unknownlamer.org>
750 * source/DCCPerson.H (class DCCPerson): Added
751 UserCommands::DCCList as a friend (friends are better than the old
752 DCC() function at least).
754 * source/DCCManager.H (class DCCManager): Added
755 UserCommands::DCCList as a friend
757 * source/Interp.H (class Interp): Made function scm_apply_wrapper
758 a friend so it can lock Interp::mutex
760 * source/Interp.C (scm_apply_wrapper): Lock Interp::mutex if
761 MULTITHREAD is defined (it is always defined when scripting is
762 enabled) so that Sockets can be made multithreaded using
765 * source/DCCPerson.H: Removed DCC method and made Bot a friend
766 Made DCCManager a friend
768 * source/DCCManager.H (class DCCManager): Removed MAP() method
769 and made Bot a friend of DCCManager
771 2002-08-18 Clinton Ebadi <clinton@unknownlamer.org>
773 * source/Interp.C (Startup): Renamed bot:DCC-chat-send to
776 * bobot++.texinfo (Hook Types): Fixed a typo (I wrote
777 user!nick@host instead of the correct nick!user@host).
779 * source/Interp.C (Startup): Register bot:DCC-chat-send
781 * source/ScriptCommands.C (sendDCCChatMessage): Added method again
783 2002-08-08 Clinton Ebadi <clinton@unknownlamer.org>
785 * source/String.C (String): The std::string copy constructor now
786 extracts the c_str of the std::string and then takes the strlen of
787 that before copying it. This fixes a bug with DCC where if you did
788 e.g. "!help" the bot would reply with "No TOPIC PRIVMSG FOUND" or
789 something like that, depending on what the last message was
790 because Socket will insert a \0 into its semi-static buffer, so
791 the len of the String will not equal the strlen of its char*.
793 2002-08-07 Clinton Ebadi <clinton@unknownlamer.org>
795 * source/DCCPerson.H: Removed destructor (I = idiot)
797 * source/DCCConnection.H: DCCManager is now a friend of
798 DCCConnection (ugh, the bot has way too many friends).
800 * source/DCCPerson.H: Added DCC member that returns a const
801 DCCConnection* (the dcc connection). This isn't saved anywhere
802 because when a DCCPerson is destroyed, its connection is also
805 * source/Bot.H: dccConnections is now a DCCManager
807 * source/DCCPerson.H: Added destructor
808 Added handleInput method
810 * source/DCCManager.C: New file
811 (addConnection): Wrote method, add a DCCConection to the manager
813 * source/DCCManager.H: New file
815 * source/Interp.C (Startup): Register bot:DCC-chat-send
816 (Startup): Removed sendDCCChatMessage stuff
818 * source/ScriptCommands.C (sendDCCChatMessage): New method:
819 sendDCCChatMessage (to, message) sends message to to.
821 * source/DCCConnection.C (connect): Run DCC_CHAT_BEGIN hook with
822 one arg: from (user!nick@host).
824 * source/DCCParser.C (parseLine): Runs DCC_CHAT_MESSAGE hook with
825 two args: from (user!nick@host) and line
827 2002-08-06 Clinton Ebadi <clinton@unknownlamer.org>
829 * source/Interp.C (Startup): Two new Scheme values:
830 hooks/dcc/chat-begin and hooks/dcc/chat-message for the
831 DCC_CHAT_BEGIN and DCC_CHAT_MESSAGE hooks.
833 * source/BotInterp.H: Added two new enum values to Hook:
834 DCC_CHAT_BEGIN and DCC_CHAT_MESSAGE for the DCC chat start and DCC
837 2002-08-05 Clinton Ebadi <clinton@unknownlamer.org>
839 * source/Parser.C (parseCTCP): Removed call to htonl and fixed
840 DCC! Ack, sockets take their arguments in network byte order so
841 there is no need to convert to host...now DCC _sort of_ works.
843 2002-08-04 Clinton Ebadi <clinton@unknownlamer.org>
845 * source/UserList.C (save): Increment iterator twice to get around
848 * source/ServerQueue.C: Now sends SEND_* hooks instead of
849 triggered general hooks.
851 * source/Interp.C (Startup): New scheme side defines: hooks/send/*
852 (* = the new SEND_ hooks, but lowercase).
854 * source/BotInterp.H: New hook types (SEND_..., ... = ACTION,
855 CTCP, PUBLIC, MESSAGE). These are triggered on send messages.
857 2002-08-01 Clinton Ebadi <clinton@unknownlamer.org>
859 * source/Bot.C (set_log_file): Oops! Fixed logging. Now the bot
862 * source/Socket.C (readLine): Now uses a static std::string that
863 starts out with 512 chars. This will never need to be resized for
864 usualy IRC messages, but might be for DCC messages
866 2002-07-31 Clinton Ebadi <clinton@unknownlamer.org>
868 * scripts/bobot-utils.scm (not-from-me): New syntax.
870 * source/ScriptCommands.C (AddHook): Now takes another optional
871 arg--name that will name the hook (see the hooks section in the
872 manual for what this does).
874 * source/BotInterp.H: Added name field to Hook
876 2002-07-29 Clinton Ebadi <clinton@unknownlamer.org>
878 * source/ServerQueue.C (sendPrivmsg): Now calls hooks on own
879 PRIVMSGes because the IRC server doesn't echo them back to the
880 bot. This could be useful for something (e.g. log script).
882 2002-07-27 Clinton Ebadi <clinton@unknownlamer.org>
884 * source/Interp.C (Shutdown): Runs bot:exit-hook hooks
885 (Startup): New var for Scheme: bot:exit-hook. Calls the thunks
886 associated with the hook when Interp::Shutdown is called (bot exit).
888 2002-07-23 Clinton Ebadi <clinton@unknownlamer.org>
890 * source/BotInterp.H (Hook<): Changed behavior of Hook's <. If a
891 hook is greater than or less than the other hook, only the
892 priority is considered. However, if both hooks have the same
893 priority, then the fallthru-ness is considered, with fallthru
894 hooks being greater than non-fallthru hooks.
896 * source/BotInterp.C (hptr_lt): Added this static function to be
897 used to sort the hooks list (now hooks should be sorted using
898 Hook's operator < instead of using pointer comparision, meaning
899 the new hook system will work correctly)
901 * scripts/bobot-utils.scm: Make bot:log use for-each instead of
902 map because we don't need the result of the displays (this would
903 just be a list of #<undefined> values and is a waste of memory).
905 2002-07-13 Clinton Ebadi <clinton@unknownlamer.org>
907 * source/Bot.C (Bot): userFunctions is now a map for efficiency
908 (worst case search is now NlogN instead of N). This improvement is
909 not as drastic as the one gained by making the Parser functions
910 list a map (because we don't scan this map for every message), but
911 it helps to clean up the code
913 2002-07-12 Clinton Ebadi <clinton@unknownlamer.org>
915 * source/Parser.H: Removed userFunctionsStruct
917 * source/Interp.C (Startup): ScriptCommands::sendCTCP registered
918 as bot:send-CTCP for Scheme
920 * source/ScriptCommands.C (sendCTCP): Wrote sendCTCP
922 2002-07-11 Clinton Ebadi <clinton@unknownlamer.org>
924 * source/ServerQueue.C (sendUser): Changed . . in USER command to
925 0 * (which is the Right Way to because <mode> must be a number...)
927 * source/Parser.C (init): New method of Parse. This initalizes the
928 functions map. functions replaces the old functions array, and
929 should yield better performance (since the functions array had to
930 be scanned for every incoming message)
932 * source/Parser.H: New member, functions (private)
934 2002-07-10 Clinton Ebadi <clinton@unknownlamer.org>
936 * source/Interp.C (Startup): New symbols: bot:user-*
937 [none|user|trusted|friend|master] are defined in Scheme as the
938 different levels of the users.
939 (Startup): All bot-* variables are now bot:*
941 2002-07-09 Clinton Ebadi <clinton@unknownlamer.org>
943 * source/Bot.H: Made some variables private because they shouldn't
944 be changed at runtime
946 * source/Parser.C (parseCTCP): Reneabled DCC CHAT (I want to test
947 this out to see if it works and make it work)
949 * source/Bot.C (Bot::Bot): New var: logs_dir. Set to the log file
952 * scripts/bobot-utils.scm: Fixed a typo (I forgot the / after
953 scripts in the user scripts dir) that made bobot++ not able to
954 load scripts from the user scripts dir
956 2002-07-08 Clinton Ebadi <clinton@unknownlamer.org>
958 * source/BotInterp.C (RunHooks): Changed iterators to
959 reverse_iterators because the hooks list is sorted in ascending
960 order--higher priority and fallthrough hooks appear _after_ the
961 lower priority and non-fallthrough hooks.
963 * source/Main.C (print_long_help): Added function
964 (print_short_help): Renamed from printUsage
965 (namespace): Most stuff in here is now defined in an anonymouse
966 namespace so it doesn't have external linkage
967 (real_main): Uses getopt_long instead of getopt. Added several
968 command line arguments (bobotpp --help for a full list).
970 * scripts/bobot-utils.scm (bot-load): Function moved from
973 * source/Interp.C (Startup): Autoloads
974 PREFIX/bobotpp/scripts/bobot-utils.scm now
975 (Startup): New Scheme variable: bot-sys-scripts-dir (system
978 * source/bobot-scheme.scm.in: Removed
980 * source/Makefile.am: Removed bobot-scheme.scm compiliation
982 * configure.ac (PREFIX): configure.ac defined prefix now
984 * source/Main.C (real_main): Default configuration is now read
985 from /etc/bobotpp/default
986 * source/bobot-scheme.scm.in: Added file. This defines the
987 'bot-load' procedure which will load a file from
988 $HOME/.bobotpp/scripts/ or @datadir@/bobotpp/scripts/ if the
989 script doesn't exist in the user script dir.
991 2002-07-01 Clinton Ebadi <clinton@unknownlamer.org>
993 * bobot++.texinfo: Started docs (just a skeleton right now)
995 * source/ScriptCommands.C (AddHook): Now takes pri and fall opt
996 args to set a hooks priority and whether or not it will
997 fallthrough. These args are optional.
999 * source/Interp.C (Startup): addhook now takes 3 req and 2 opt args
1001 * source/BotInterp.C (AddHook): Now uses priority and fallthrough
1002 (RunHooks): exec fallthrough hooks first.
1004 * source/BotInterp.H: Changed Hooks to have priority
1005 Added fhooksMap to BotInterp (fallthrough)
1007 * source/UserCommands.C (AddShit): Converted to use Commands
1009 2002-06-21 Clinton Ebadi <clinton@unknownlamer.org>
1011 * source/Commands.C (AddUser): Fixed a one-off (function call was
1012 before a brace instead of after one) that caused a segfault when
1013 the user mask was a wildcard
1015 2002-06-20 Clinton Ebadi <clinton@unknownlamer.org>
1017 * all files: Updated address of the FSF
1019 * source/UserCommands.C (AddUser): Uses Commands now instead of
1020 manipulating the bot directly
1022 2002-06-18 Clinton Ebadi <clinton@unknownlamer.org>
1024 * source/ScriptCommands.C (AddShit): Filled in function.
1026 * source/Interp.C (Startup): Bind bot-adduser to
1027 ScriptCommands::AddUser instead of Action
1028 (Startup): Bind bot-addshit to ScriptCommands::AddShit
1030 * source/ScriptCommands.C (AddUser): Filled in function
1032 * source/ServerList.C (delServer): Changed (n - 1) to n...n-1
1033 would have caused problems if you used more than one server
1035 * source/Parser.H: Changed const char* to String in userFunctionStruct
1037 * source/String.H: Added std::string compatibility members
1039 * configure.ac: You can now disable Crypt and scripting
1041 * source/*: Added #include "config.h" where needed
1043 * configure.ac: Added AM_CONFIG_HEADER
1045 * config.h.in: added file
1047 * source/Queue.C: Didn't notice iostream.h here! Fixed
1050 Copyright 2002,2003,2004,2005 Clinton Ebadi
1051 Copying and distribution of this file, with or without modification, are
1052 permitted provided the copyright notice and this notice are preserved.