RE: [Request]: Send message on conversation start, repeat message on timer.
try this out:
code: var cmd = "/some command"; // your own command here (with slash)
var cwnd;
var delay = 60; // delay when to repeat message (in seconds)
function OnEvent_ChatWndCreated(ChatWnd){
ChatWnd.SendMessage(cmd);
cwnd = ChatWnd;
MsgPlus.CancelTimer("sendmsg");
MsgPlus.AddTimer("sendmsg", parseInt(delay) * 1000);
}
function OnEvent_Timer(i){
if(i == "sendmsg"){
cwnd.SendMessage(cmd);
}
}
This post was edited on 02-18-2008 at 08:29 AM by roflmao456.
[quote]
Ultimatess6: What a noob mod
|