]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_showwhois.cpp
Wahhhhhhhhhhhh bwahahaha. Mass commit to tidy up tons of messy include lists
[user/henk/code/inspircd.git] / src / modules / m_showwhois.cpp
index 9b51e6204628e94377011623c2fe6d5c3be8db53..0719a93f83a7641843e5d8b68e60e3ad143ef863 100644 (file)
@@ -6,14 +6,17 @@ using namespace std;
 #include "users.h"
 #include "channels.h"
 #include "modules.h"
-#include "helperfuncs.h"
+
+#include "inspircd.h"
 
 /* $ModDesc: Allows opers to set +W to see when a user uses WHOIS on them */
 
+
+
 class SeeWhois : public ModeHandler
 {
  public:
-       SeeWhois() : ModeHandler('W', 0, 0, false, MODETYPE_CHANNEL, false) { }
+       SeeWhois(InspIRCd* Instance) : ModeHandler(Instance, 'W', 0, 0, false, MODETYPE_CHANNEL, false) { }
 
        ModeAction OnModeChange(userrec* source, userrec* dest, chanrec* channel, std::string &parameter, bool adding)
        {
@@ -44,16 +47,16 @@ class SeeWhois : public ModeHandler
 
 class ModuleShowwhois : public Module
 {
-       Server* Srv;
+       
        SeeWhois* sw;
 
  public:
 
-       ModuleShowwhois(Server* Me) : Module::Module(Me)
+       ModuleShowwhois(InspIRCd* Me) : Module::Module(Me)
        {
-               Srv = Me;
-               sw = new SeeWhois();
-               Srv->AddMode(sw, 'W');
+               
+               sw = new SeeWhois(ServerInstance);
+               ServerInstance->AddMode(sw, 'W');
        }
 
        ~ModuleShowwhois()
@@ -92,7 +95,7 @@ class ModuleShowwhoisFactory : public ModuleFactory
                {
                }
 
-               virtual Module* CreateModule(Server* Me)
+               virtual Module* CreateModule(InspIRCd* Me)
                {
                        return new ModuleShowwhois(Me);
                }