#include "inspircd.h"
-/* $ModDesc: Provides support for unreal-style channel mode +c */
+/* $ModDesc: Provides channel mode +c to block color */
/** Handles the +c channel mode
*/
class ModuleBlockColor : public Module
{
- bool AllowChanOps;
BlockColor bc;
public:
ModuleBlockColor() : bc(this)
{
- if (!ServerInstance->Modes->AddMode(&bc))
- throw ModuleException("Could not add new modes!");
+ }
+
+ void init()
+ {
+ ServerInstance->Modules->AddService(bc);
Implementation eventlist[] = { I_OnUserPreMessage, I_OnUserPreNotice, I_On005Numeric };
- ServerInstance->Modules->Attach(eventlist, this, 3);
+ ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
}
virtual void On005Numeric(std::string &output)
virtual Version GetVersion()
{
- return Version("Provides support for unreal-style channel mode +c",VF_VENDOR);
+ return Version("Provides channel mode +c to block color",VF_VENDOR);
}
};