diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/modules.h | 7 | ||||
-rw-r--r-- | include/users.h | 10 |
2 files changed, 14 insertions, 3 deletions
diff --git a/include/modules.h b/include/modules.h index 97529e313..16495dad6 100644 --- a/include/modules.h +++ b/include/modules.h @@ -75,7 +75,7 @@ enum MessageType { * ipv4 servers, so this value will be ten times as * high on ipv6 servers. */ -#define NATIVE_API_VERSION 11017 +#define NATIVE_API_VERSION 11018 #ifdef IPV6 #define API_VERSION (NATIVE_API_VERSION * 10) #else @@ -471,9 +471,10 @@ class Module : public Extensible * This event is only called when the user is fully registered when they quit. To catch * raw disconnections, use the OnUserDisconnect method. * @param user The user who is quitting - * @param message The user's quit message + * @param message The user's quit message (as seen by non-opers) + * @param oper_message The user's quit message (as seen by opers) */ - virtual void OnUserQuit(userrec* user, const std::string &message); + virtual void OnUserQuit(userrec* user, const std::string &message, const std::string &oper_message); /** Called whenever a user's socket is closed. * The details of the exiting user are available to you in the parameter userrec *user diff --git a/include/users.h b/include/users.h index 8da80d62f..d9a5168cc 100644 --- a/include/users.h +++ b/include/users.h @@ -283,6 +283,9 @@ class userrec : public connection * mode characters this user is making use of. */ void DecrementModes(); + + char* operquit; + public: /** Resolvers for looking up this users IP address * This will occur if and when res_reverse completes. @@ -895,6 +898,13 @@ class userrec : public connection */ void ShowRULES(); + /** Set oper-specific quit message shown to opers only when the user quits + * (overrides any sent by QuitUser) + */ + void SetOperQuit(const std::string &oquit); + + const char* GetOperQuit(); + /** Handle socket event. * From EventHandler class. * @param et Event type |