summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorgumi <mekolat@users.noreply.github.com>2017-06-24 09:13:50 -0400
committergumi <mekolat@users.noreply.github.com>2017-06-24 09:27:14 -0400
commitd382ab002074b76315bc9980bd8550fb778f51fb (patch)
tree6b6dbf7d4f0786e1462f39f8b52edbc5c45cdf1d /src
parentacdde91ef9675a44ecd9a02d7f543814a75f0093 (diff)
downloadhercules-d382ab002074b76315bc9980bd8550fb778f51fb.tar.gz
hercules-d382ab002074b76315bc9980bd8550fb778f51fb.tar.bz2
hercules-d382ab002074b76315bc9980bd8550fb778f51fb.tar.xz
hercules-d382ab002074b76315bc9980bd8550fb778f51fb.zip
allow addchannelhandler to be called with attached rid
Diffstat (limited to 'src')
-rw-r--r--src/map/script.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/map/script.c b/src/map/script.c
index ea8b03450..e0bdecd47 100644
--- a/src/map/script.c
+++ b/src/map/script.c
@@ -23057,9 +23057,10 @@ BUILDIN(channelmes)
BUILDIN(addchannelhandler)
{
int i;
+ struct map_session_data *sd = map->id2sd(st->rid);
const char *channelname = script_getstr(st, 2);
const char *eventname = script_getstr(st, 3);
- struct channel_data *chan = channel->search(channelname, NULL);
+ struct channel_data *chan = channel->search(channelname, sd);
if (!chan) {
script_pushint(st, 0);