blob: 5a57055626e928ca897e3f2e6d1d8f689e04c9fa (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
var commands = {}
commands.say = function (settings, params) {
var sendObj = {
method: 'say',
params: { msg: params },
};
settings.sock.send(JSON.stringify(sendObj))
}
commands.nick = function (settings, params) {
var sendObj = {
method: 'nick',
params: { nick: params },
}
settings.sock.send(JSON.stringify(sendObj))
}
commands.badcommand = function (settings, params) {
console.log("error");
chatboxAppend( '<span class="from_system">error</span>', 'command not found' )
}
|