mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-09 18:49:03 -04:00
Add an 005 token to let clients know that fakelag is enabled.
This commit is contained in:
parent
ccdf1d4975
commit
5ea0bfff6f
@ -62,6 +62,7 @@ struct ISupportAction final
|
|||||||
|
|
||||||
class CoreModInfo final
|
class CoreModInfo final
|
||||||
: public Module
|
: public Module
|
||||||
|
, public ISupport::EventListener
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
CommandAdmin cmdadmin;
|
CommandAdmin cmdadmin;
|
||||||
@ -111,6 +112,7 @@ private:
|
|||||||
public:
|
public:
|
||||||
CoreModInfo()
|
CoreModInfo()
|
||||||
: Module(VF_CORE | VF_VENDOR, "Provides the ADMIN, COMMANDS, INFO, MODULES, MOTD, TIME, SERVLIST, and VERSION commands")
|
: Module(VF_CORE | VF_VENDOR, "Provides the ADMIN, COMMANDS, INFO, MODULES, MOTD, TIME, SERVLIST, and VERSION commands")
|
||||||
|
, ISupport::EventListener(this)
|
||||||
, cmdadmin(this)
|
, cmdadmin(this)
|
||||||
, cmdcommands(this)
|
, cmdcommands(this)
|
||||||
, cmdinfo(this)
|
, cmdinfo(this)
|
||||||
@ -237,6 +239,12 @@ public:
|
|||||||
{
|
{
|
||||||
ServerInstance->Modules.SetPriority(this, I_OnUserConnect, PRIORITY_FIRST);
|
ServerInstance->Modules.SetPriority(this, I_OnUserConnect, PRIORITY_FIRST);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void OnBuildClassISupport(const std::shared_ptr<ConnectClass>& klass, ISupport::TokenMap& tokens) override
|
||||||
|
{
|
||||||
|
if (klass->fakelag)
|
||||||
|
tokens["FAKELAG"];
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
MODULE_INIT(CoreModInfo)
|
MODULE_INIT(CoreModInfo)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user