mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-11 11:39:02 -04:00
All modules which implement simplemodes (no parameters, not a list mode) can now be UNLOADED O_o
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5102 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
5c3df6d82d
commit
40e990ed06
@ -94,20 +94,21 @@ public:
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
virtual int OnUserPreNotice(userrec* user,void* dest,int target_type, std::string &text, char status)
|
||||
{
|
||||
return OnUserPreMessage(user,dest,target_type,text,status);
|
||||
}
|
||||
|
||||
|
||||
virtual ~ModuleBlockCAPS()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(bc);
|
||||
DELETE(bc);
|
||||
}
|
||||
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -109,12 +109,13 @@ class ModuleBlockColour : public Module
|
||||
|
||||
virtual ~ModuleBlockColour()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(bc);
|
||||
DELETE(bc);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -81,12 +81,13 @@ class ModuleBotMode : public Module
|
||||
|
||||
virtual ~ModuleBotMode()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(bm);
|
||||
DELETE(bm);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
|
||||
virtual void OnWhois(userrec* src, userrec* dst)
|
||||
|
@ -137,10 +137,12 @@ class ModuleCensor : public Module
|
||||
|
||||
virtual ~ModuleCensor()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(cu);
|
||||
ServerInstance->Modes->DelMode(cc);
|
||||
DELETE(cu);
|
||||
DELETE(cc);
|
||||
}
|
||||
|
||||
|
||||
virtual void ReplaceLine(irc::string &text, irc::string pattern, irc::string replace)
|
||||
{
|
||||
if ((pattern != "") && (text != ""))
|
||||
@ -153,9 +155,8 @@ class ModuleCensor : public Module
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// format of a config entry is <badword text="shit" replace="poo">
|
||||
|
||||
virtual int OnUserPreMessage(userrec* user,void* dest,int target_type, std::string &text, char status)
|
||||
{
|
||||
bool active = false;
|
||||
@ -219,7 +220,7 @@ class ModuleCensor : public Module
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
// This is version 2 because version 1.x is the unreleased unrealircd module
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
|
||||
};
|
||||
|
@ -416,6 +416,7 @@ class ModuleCloaking : public Module
|
||||
|
||||
virtual ~ModuleCloaking()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(cu);
|
||||
DELETE(cu);
|
||||
}
|
||||
|
||||
@ -423,7 +424,7 @@ class ModuleCloaking : public Module
|
||||
{
|
||||
// returns the version number of the module to be
|
||||
// listed in /MODULES
|
||||
return Version(1,0,0,2,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,2,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
|
||||
virtual void OnRehash(const std::string ¶meter)
|
||||
|
@ -254,6 +254,7 @@ class ModuleHelpop : public Module
|
||||
|
||||
virtual ~ModuleHelpop()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(ho);
|
||||
DELETE(conf);
|
||||
DELETE(helpop);
|
||||
DELETE(ho);
|
||||
@ -261,7 +262,7 @@ class ModuleHelpop : public Module
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,1,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,1,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -123,12 +123,13 @@ class ModuleKnock : public Module
|
||||
|
||||
virtual ~ModuleKnock()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(kn);
|
||||
DELETE(kn);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,1,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,1,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -100,12 +100,13 @@ class ModuleNoCTCP : public Module
|
||||
|
||||
virtual ~ModuleNoCTCP()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(nc);
|
||||
DELETE(nc);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -79,12 +79,13 @@ class ModuleNoInvite : public Module
|
||||
|
||||
virtual ~ModuleNoInvite()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(ni);
|
||||
DELETE(ni);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -98,12 +98,13 @@ class ModuleNoKicks : public Module
|
||||
|
||||
virtual ~ModuleNoKicks()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(nk);
|
||||
DELETE(nk);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -67,12 +67,13 @@ class ModuleNoNickChange : public Module
|
||||
|
||||
virtual ~ModuleNoNickChange()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(nn);
|
||||
DELETE(nn);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,1,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,1,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
|
||||
void Implements(char* List)
|
||||
|
@ -94,12 +94,13 @@ class ModuleNoNotice : public Module
|
||||
|
||||
virtual ~ModuleNoNotice()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(nt);
|
||||
DELETE(nt);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -275,6 +275,12 @@ class ModuleServices : public Module
|
||||
|
||||
virtual ~ModuleServices()
|
||||
{
|
||||
kludgeme = true;
|
||||
ServerInstance->Modes->DelMode(m1);
|
||||
ServerInstance->Modes->DelMode(m2);
|
||||
ServerInstance->Modes->DelMode(m3);
|
||||
ServerInstance->Modes->DelMode(m4);
|
||||
ServerInstance->Modes->DelMode(m5);
|
||||
DELETE(m1);
|
||||
DELETE(m2);
|
||||
DELETE(m3);
|
||||
@ -284,7 +290,7 @@ class ModuleServices : public Module
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -305,6 +305,9 @@ class ModuleServicesAccount : public Module
|
||||
|
||||
virtual ~ModuleServicesAccount()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(m1);
|
||||
ServerInstance->Modes->DelMode(m2);
|
||||
ServerInstance->Modes->DelMode(m3);
|
||||
DELETE(m1);
|
||||
DELETE(m2);
|
||||
DELETE(m3);
|
||||
@ -312,7 +315,7 @@ class ModuleServicesAccount : public Module
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1,0,0,0,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -61,6 +61,7 @@ class ModuleShowwhois : public Module
|
||||
|
||||
~ModuleShowwhois()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(sw);
|
||||
DELETE(sw);
|
||||
}
|
||||
|
||||
@ -71,7 +72,7 @@ class ModuleShowwhois : public Module
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1,0,0,3,VF_STATIC);
|
||||
return Version(1,0,0,3,VF_COMMON|VF_VENDOR);
|
||||
}
|
||||
|
||||
virtual void OnWhois(userrec* source, userrec* dest)
|
||||
|
@ -109,12 +109,13 @@ class ModuleSSLModes : public Module
|
||||
|
||||
virtual ~ModuleSSLModes()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(sslm);
|
||||
DELETE(sslm);
|
||||
}
|
||||
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
return Version(1, 0, 0, 0, VF_STATIC | VF_VENDOR);
|
||||
return Version(1, 0, 0, 0, VF_COMMON | VF_VENDOR);
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -115,6 +115,8 @@ class ModuleStripColor : public Module
|
||||
|
||||
virtual ~ModuleStripColor()
|
||||
{
|
||||
ServerInstance->Modes->DelMode(usc);
|
||||
ServerInstance->Modes->DelMode(csc);
|
||||
DELETE(usc);
|
||||
DELETE(csc);
|
||||
}
|
||||
@ -202,7 +204,7 @@ class ModuleStripColor : public Module
|
||||
virtual Version GetVersion()
|
||||
{
|
||||
// This is version 2 because version 1.x is the unreleased unrealircd module
|
||||
return Version(1,0,0,0,VF_STATIC|VF_VENDOR);
|
||||
return Version(1, 0, 0, 0, VF_COMMON | VF_VENDOR);
|
||||
}
|
||||
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user