CommandSwhois(Module* Creator) : Command(Creator,"SWHOIS", 2,2), swhois("swhois", Creator)
{
flags_needed = 'o'; syntax = "<nick> :<swhois>";
- ServerInstance->Extensions.Register(&swhois);
TRANSLATE3(TR_NICK, TR_TEXT, TR_END);
}
public:
ModuleSWhois() : cmd(this)
{
- ServerInstance->AddCommand(&cmd);
+ }
+
+ void init()
+ {
+ ServerInstance->Modules->AddService(cmd);
+ ServerInstance->Modules->AddService(cmd.swhois);
Implementation eventlist[] = { I_OnWhoisLine, I_OnPostOper };
- ServerInstance->Modules->Attach(eventlist, this, 2);
+ ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation));
}
// :kenny.chatspike.net 320 Brain Azhrarn :is getting paid to play games.