summaryrefslogtreecommitdiff
path: root/src/modules/m_testcommand.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_testcommand.cpp')
-rw-r--r--src/modules/m_testcommand.cpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/modules/m_testcommand.cpp b/src/modules/m_testcommand.cpp
index 3b6b646a9..b65430c5a 100644
--- a/src/modules/m_testcommand.cpp
+++ b/src/modules/m_testcommand.cpp
@@ -55,7 +55,7 @@ class ModuleTestCommand : public Module
Srv->AddCommand("WOOT",handle_woot,0,1);
// Add a mode +Z for channels with no parameters
- Srv->AddExtendedMode('Z',MT_CHANNEL,false,0,0);
+ Srv->AddExtendedMode('Z',MT_CHANNEL,false,1,0);
}
virtual bool OnExtendedMode(userrec* user, chanrec* chan, char modechar, int type, bool mode_on, string_list &params)
@@ -80,6 +80,16 @@ class ModuleTestCommand : public Module
return 1;
}
+ virtual void OnUserJoin(userrec* user, chanrec* channel)
+ {
+ Srv->Log(DEBUG,"OnUserJoin triggered");
+ if (channel->IsCustomModeSet('Z'))
+ {
+ std::string param = channel->GetModeParameter('Z');
+ Srv->Log(DEBUG,"Custom mode is set on this channel! Parameter="+param);
+ }
+ }
+
virtual ~ModuleTestCommand()
{
delete Srv;