init.lua

changeset 18
d7cd7ce93132
parent 17
9fe723988f3c
child 24
330643a82a1d
equal deleted inserted replaced
17:9fe723988f3c 18:d7cd7ce93132
63 return self.stream:hook("bot/"..name, ...); 63 return self.stream:hook("bot/"..name, ...);
64 end 64 end
65 65
66 function riddim_mt:send_message(to, type, text) 66 function riddim_mt:send_message(to, type, text)
67 self:send(st.message({ to = to, type = type }):tag("body"):text(text)); 67 self:send(st.message({ to = to, type = type }):tag("body"):text(text));
68 end
69
70 function riddim_mt:send_presence(to, type)
71 self:send(st.presence({ to = to, type = type }));
68 end 72 end
69 73
70 function riddim_mt:add_plugin(name) 74 function riddim_mt:add_plugin(name)
71 if not self.plugins[name] then 75 if not self.plugins[name] then
72 self.plugins[name] = require("riddim.plugins."..name); 76 self.plugins[name] = require("riddim.plugins."..name);

mercurial