From 8669002016bc60019a317124ae088a8053a0238b Mon Sep 17 00:00:00 2001 From: gumi Date: Tue, 25 Apr 2017 23:48:59 -0400 Subject: add channel handler events --- doc/script_commands.txt | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'doc/script_commands.txt') diff --git a/doc/script_commands.txt b/doc/script_commands.txt index 5ba0aaa2e..0ba350ad1 100644 --- a/doc/script_commands.txt +++ b/doc/script_commands.txt @@ -7449,6 +7449,27 @@ If the channel doesn't exist (or, in the case of a character-specific channel, no RID is attached), false will be returned. In case of success, true is returned. +--------------------------------------- + +*addchannelhandler("<#channel>", "") + +This command will trigger the specified event every time a player +talks in the specified channel, with said player as attached rid. +It assigns the message to @channelmes$ + +OnChannelMessage: + channelmes("#chan", "Echo: " + @channelmes$); + end; + +OnInit: + addchannelhandler("#chan", "NPC::OnChannelMessage"); + +--------------------------------------- + +*removechannelhandler("<#channel>", "") + +Removes a channel handler added by addchannelhandler() + --------------------------------------- *rand({, }) -- cgit v1.2.3-60-g2f50