bard / purplebridge

bard (author)
Sun Aug 10 07:05:06 -0700 2008
purplebridge / main.lua
100644 32 lines (24 sloc) 0.683 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
require('server')
 
function debug(msg)
   print('** (lua): DEBUG: ' .. msg)
   print()
end
 
function on_client_connection(conn)
   debug('Client connected')
   --sessions[conn] = session_create(conn)
   sess = Session:new(conn)
end
 
function on_client_activity(conn, data)
   --session_receive(sessions[con])
   sess:receive(data)
end
 
function on_client_disconnection(conn)
   --session_close(sessions[conn])
   sess:close()
end
 
-- local protocols = {}
-- for i,name in ipairs(purple.get_protocols()) do
-- table.insert(protocols, name)
-- end
-- debug('found protocol plugins: ' .. table.concat(protocols, ', '))
 
--purple.signon('prpl-msn', 'milly.tom@hotmail.it', 'potina')