diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-04-10 12:11:00 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-04-10 12:11:00 +0000 |
commit | 4dd8228ede0167110a201ab5f3ca6ef8a9faf750 (patch) | |
tree | 67b1265090c9e3e9f86fc66454805906434ad779 /include/mode.h | |
parent | b01e94da8f5b58da0343d04c9d387da0c663083a (diff) |
Extra allowance for modes which have different number of params when being set to being unset (read as: jro smoking craq)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3858 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include/mode.h')
-rw-r--r-- | include/mode.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/include/mode.h b/include/mode.h index 70c02a503..381145319 100644 --- a/include/mode.h +++ b/include/mode.h @@ -48,19 +48,20 @@ enum ModeAction { class ModeHandler { char mode; - int n_params; + int n_params_on; + int n_params_off; bool list; ModeType m_type; bool oper; public: - ModeHandler(char modeletter, int parameters, bool listmode, ModeType type, bool operonly); + ModeHandler(char modeletter, int parameters_on, int parameters_off, bool listmode, ModeType type, bool operonly); virtual ~ModeHandler(); bool IsListMode(); ModeType GetModeType(); bool NeedsOper(); - int GetNumParams(); + int GetNumParams(bool adding); char GetModeChar(); virtual ModeAction OnModeChange(userrec* source, userrec* dest, chanrec* channel, std::string ¶meter, bool adding); /* Can change the mode parameter as its a ref */ |