From 9956da18e3186591b5347e63081756390f4f35d5 Mon Sep 17 00:00:00 2001 From: Adam Date: Sat, 1 Jun 2013 21:51:00 -0400 Subject: Move OnJoinChannel event to trigger after the user has completely joined and document it more about what you should and shouldnt do in it --- include/channels.h | 3 ++- include/modules.h | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/channels.h b/include/channels.h index 15b66e928..bdc273415 100644 --- a/include/channels.h +++ b/include/channels.h @@ -102,9 +102,10 @@ class CoreExport Channel : public Base, public Extensible /** Join a user internally to the channel * @param u The user + * @param status The status to give the user, if any * @return The UserContainer for the user */ - ChanUserContainer* JoinUser(User *u); + ChanUserContainer* JoinUser(User *u, const ChannelStatus *status); /** Remove a user internally from the channel * @param u The user diff --git a/include/modules.h b/include/modules.h index 286ba5246..c430767db 100644 --- a/include/modules.h +++ b/include/modules.h @@ -462,7 +462,10 @@ class CoreExport Module : public Extensible */ virtual void OnLeaveChannel(User *u, Channel *c) { throw NotImplementedException(); } - /** Called when a user joins a channel + /** Called after a user joins a channel + * If this event triggers the user is allowed to be in the channel, and will + * not be kicked for restricted/akick/forbidden, etc. If you want to kick the user, + * use the CheckKick event instead. * @param u The user * @param channel The channel */ -- cgit