From 990c308a959a376335e91014bcaeb0081693947b Mon Sep 17 00:00:00 2001 From: brain Date: Mon, 25 Sep 2006 17:43:28 +0000 Subject: Whoops, patch git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5324 e03df62e-2008-0410-955e-edbf42e46eb7 --- include/channels.h | 2 +- include/modules.h | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/channels.h b/include/channels.h index 6c92f0801..648723b09 100644 --- a/include/channels.h +++ b/include/channels.h @@ -150,7 +150,7 @@ class chanrec : public Extensible /** Connect a chanrec to a userrec */ - static chanrec* ForceChan(InspIRCd* Instance, chanrec* Ptr,ucrec *a,userrec* user, int created); + static chanrec* ForceChan(InspIRCd* Instance, chanrec* Ptr,ucrec *a,userrec* user, const std::string &privs); prefixlist prefixes; diff --git a/include/modules.h b/include/modules.h index 95dbd764e..3f6ddb8d0 100644 --- a/include/modules.h +++ b/include/modules.h @@ -488,10 +488,13 @@ class Module : public Extensible * processing on the actual channel record at this point, however the channel NAME will still be passed in * char* cname, so that you could for example implement a channel blacklist or whitelist, etc. * @param user The user joining the channel - * @param cname The channel name being joined + * @param chan If the channel is a new channel, this will be NULL, otherwise it will be a pointer to the channel being joined + * @param cname The channel name being joined. For new channels this is valid where chan is not. + * @param privs A string containing the users privilages when joining the channel. For new channels this will contain "@". + * You may alter this string to alter the user's modes on the channel. * @return 1 To prevent the join, 0 to allow it. */ - virtual int OnUserPreJoin(userrec* user, chanrec* chan, const char* cname); + virtual int OnUserPreJoin(userrec* user, chanrec* chan, const char* cname, std::string &privs); /** Called whenever a user is about to be kicked. * Returning a value of 1 from this function stops the process immediately, causing no -- cgit v1.2.3