X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=lib%2Frbot%2Fircbot.rb;h=ab4c2cf1298390ab60d160ab0269a6c362f7b3e7;hb=63785bdaded80af35574add65958aa0df2bd5c41;hp=f74b1530cd51f8d1a1d4fcd0f525cad7b2eed8f5;hpb=d642da9348926e418655685b92f0b68c11b710f1;p=user%2Fhenk%2Fcode%2Fruby%2Frbot.git diff --git a/lib/rbot/ircbot.rb b/lib/rbot/ircbot.rb index f74b1530..ab4c2cf1 100644 --- a/lib/rbot/ircbot.rb +++ b/lib/rbot/ircbot.rb @@ -163,7 +163,7 @@ module Irc # Main bot class, which manages the various components, receives messages, # handles them or passes them to plugins, and contains core functionality. class Bot - COPYRIGHT_NOTICE = "(c) Tom Gilbert and the rbot development team" + COPYRIGHT_NOTICE = "(c) Giuseppe Bilotta and the rbot development team" SOURCE_URL = "http://ruby-rbot.org" # the bot's Auth data attr_reader :auth @@ -202,6 +202,8 @@ class Bot # loads and opens new registry databases, used by the plugins attr_accessor :registry_factory + attr_accessor :webservice + # server we are connected to # TODO multiserver def server @@ -1395,20 +1397,26 @@ class Bot end end - # call the save method for all of the botmodules - def save + # call the save method for all or the specified botmodule + # + # :botmodule :: + # optional botmodule to save + def save(botmodule=nil) @save_mutex.synchronize do - @plugins.save + @plugins.save(botmodule) end end - # call the rescan method for all of the botmodules - def rescan + # call the rescan method for all or just the specified botmodule + # + # :botmodule :: + # instance of the botmodule to rescan + def rescan(botmodule=nil) debug "\tstopping timer..." @timer.stop @save_mutex.synchronize do - @lang.rescan - @plugins.rescan + # @lang.rescan + @plugins.rescan(botmodule) end @timer.start end