hook for chat msg

This commit is contained in:
John McLear 2013-03-19 02:21:53 +00:00
parent 07adb45503
commit 7741f762e2
1 changed files with 13 additions and 1 deletions

View File

@ -17,6 +17,7 @@
var padutils = require('./pad_utils').padutils;
var padcookie = require('./pad_cookie').padcookie;
var Tinycon = require('tinycon/tinycon');
var hooks = require('./pluginfw/hooks');
var chat = (function()
{
@ -162,7 +163,18 @@ var chat = (function()
time: '4000'
});
Tinycon.setBubble(count);
var msg = {
"authorName" : authorName,
"text" : text,
"sticky" : false,
"time" : timeStr
};
hooks.aCallAll("chatNewMessage", {
"authorName" : authorName,
"text" : text,
"sticky" : false,
"time" : timeStr
});
}
}
}