X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_opermodes.cpp;h=3f840f89445e3948f7b28ab647b15d26a57cf5c6;hb=1383dba43e463f292aea094d01f62f355946049d;hp=063e675fc52b6062b6c145ef637c5fdf647d86dc;hpb=ebd92418f89acb456207a05420b71a6f0f27c3f4;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_opermodes.cpp b/src/modules/m_opermodes.cpp index 063e675fc..3f840f894 100644 --- a/src/modules/m_opermodes.cpp +++ b/src/modules/m_opermodes.cpp @@ -2,7 +2,7 @@ * | Inspire Internet Relay Chat Daemon | * +------------------------------------+ * - * Inspire is copyright (C) 2002-2004 ChatSpike-Dev. + * InspIRCd is copyright (C) 2002-2006 ChatSpike-Dev. * E-mail: * * @@ -31,16 +31,21 @@ class ModuleModesOnOper : public Module ConfigReader *Conf; public: - ModuleModesOnOper() + ModuleModesOnOper(Server* Me) + : Module::Module(Me) { - Srv = new Server; + Srv = Me; Conf = new ConfigReader; } + + void Implements(char* List) + { + List[I_OnOper] = 1; + } virtual ~ModuleModesOnOper() { delete Conf; - delete Srv; } virtual Version GetVersion() @@ -48,7 +53,7 @@ class ModuleModesOnOper : public Module return Version(1,0,0,1,VF_VENDOR); } - virtual void OnOper(userrec* user) + virtual void OnOper(userrec* user, std::string opertype) { // whenever a user opers, go through the oper types, find their , // and if they have one apply their modes. The mode string can contain +modes @@ -85,9 +90,9 @@ class ModuleModesOnOperFactory : public ModuleFactory { } - virtual Module * CreateModule() + virtual Module * CreateModule(Server* Me) { - return new ModuleModesOnOper; + return new ModuleModesOnOper(Me); } };