summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2018-11-13 17:04:25 +0100
committerGitHub <noreply@github.com>2018-11-13 17:04:25 +0100
commit78db115b41d966daf26160abe224701f743f6df0 (patch)
treec10d9b013b5e6bff45cba86beac25f30a8f5699a /src/map
parent37340a9e36de30387c8e2b347fd4446cf786612e (diff)
parentcf2c2f8e243cc4d2792a05907a13d1d5c855c5b3 (diff)
downloadhercules-78db115b41d966daf26160abe224701f743f6df0.tar.gz
hercules-78db115b41d966daf26160abe224701f743f6df0.tar.bz2
hercules-78db115b41d966daf26160abe224701f743f6df0.tar.xz
hercules-78db115b41d966daf26160abe224701f743f6df0.zip
Merge pull request #2286 from EyesOfAHawk/channel_delay_msg
Change channel delay message to time left instead of generic message.
Diffstat (limited to 'src/map')
-rw-r--r--src/map/channel.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/map/channel.c b/src/map/channel.c
index f1946385d..eadd7367b 100644
--- a/src/map/channel.c
+++ b/src/map/channel.c
@@ -276,7 +276,9 @@ static void channel_send(struct channel_data *chan, struct map_session_data *sd,
if (sd && chan->msg_delay != 0
&& DIFF_TICK(sd->hchsysch_tick + chan->msg_delay*1000, timer->gettick()) > 0
&& !pc_has_permission(sd, PC_PERM_HCHSYS_ADMIN)) {
- clif->messagecolor_self(sd->fd, COLOR_RED, msg_sd(sd,1455));
+ char output[CHAT_SIZE_MAX];
+ sprintf(output, msg_sd(sd, 1455), DIFF_TICK(sd->hchsysch_tick + chan->msg_delay * 1000, timer->gettick()) / 1000); // "You cannot send a message to this channel for another %d seconds."
+ clif->messagecolor_self(sd->fd, COLOR_RED, output);
return;
} else if (sd) {
int i;