Event: OnChanNotice(from,channel,message,handle)
Syntax: OnChanNotice(object from,string channel,string message,object handle);
Event arguments
from- the sender
channel- the channel on which the notice message was sent
message- the message
handle- the output handler
This even trigger when a person send a notice message to a channel.
Note: You can get the host and the user of the sender by using from.Host
and from.User. To edit the output text use ole.SetOutput(text,handle);. To delete
the output text use ole.DelOutput(handle);
Example:
function OnChanNotice(sender,channel,message,handle)
{
//If you are not the sender of the message ban and kick the sender.
if(sender!=ole.Me)
{
//ban the senders host
ole.Ban(channel,sender.Host);
//kick the sender and mention the reason
ole.Kick(channel,sender,"Notice messages are not allowed on the channel");
}
}