diff options
author | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-01-01 18:34:23 +0100 |
---|---|---|
committer | Matthias Schiffer <mschiffer@universe-factory.net> | 2013-01-01 18:34:23 +0100 |
commit | 9d1555604557b7ca385869a6fcebaf4dc0665059 (patch) | |
tree | 6269c57f48331f1704907b633d7a3660b3a647a1 /bot.rb | |
parent | 0b95e32f2f9f21ad288bc53f2423c135532b933e (diff) | |
download | lain-9d1555604557b7ca385869a6fcebaf4dc0665059.tar lain-9d1555604557b7ca385869a6fcebaf4dc0665059.zip |
Add credits module, more core improvements
Diffstat (limited to 'bot.rb')
-rw-r--r-- | bot.rb | 15 |
1 files changed, 9 insertions, 6 deletions
@@ -6,17 +6,13 @@ require_relative 'sasl' require_relative 'config' module Lain + Version = '0.1' + class Bot - Version = '0.1' def initialize $stderr.puts "Lain #{Version} starting..." - @cl = Jabber::Client.new(Jabber::JID.new(Config::JID)) - @cl.connect - @cl.auth(Config::Password) - @cl.send(Jabber::Presence.new) - @modules = {} $stderr.puts 'Loading modules...' @@ -26,6 +22,13 @@ module Lain @modules[mod] = Modules.const_get(mod).new self } + $stderr.puts 'Connecting...' + + @cl = Jabber::Client.new(Jabber::JID.new(Config::JID)) + @cl.connect + @cl.auth(Config::Password) + @cl.send(Jabber::Presence.new) + @mucs = {} Config::Rooms.each { |r| |