ModuleTimedBans()
: cmd(this)
{
- ServerInstance->AddCommand(&cmd);
- TimedBanList.clear();
- Implementation eventlist[] = { I_OnDelBan, I_OnBackgroundTimer };
- ServerInstance->Modules->Attach(eventlist, this, 2);
}
- virtual ~ModuleTimedBans()
+ void init()
{
- TimedBanList.clear();
+ ServerInstance->Modules->AddService(cmd);
+ Implementation eventlist[] = { I_OnDelBan, I_OnBackgroundTimer };
+ ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
}
virtual ModResult OnDelBan(User* source, Channel* chan, const std::string &banmask)