*/
#include "inspircd.h"
-#include "users.h"
-#include "channels.h"
-#include "modules.h"
/* $ModDesc: /helpop Command, Works like Unreal helpop */
static std::map<irc::string, std::string> helpop_map;
irc::sepstream stream(value, '\n');
std::string token = "*";
- while ((token = stream.GetToken()) != "")
- {
+ while (stream.GetToken(token))
user->WriteServ("NOTICE %s :%s", user->nick, token.c_str());
- }
user->WriteServ("NOTICE %s :*** End of HELPOP", user->nick);
}
}
};
-class ModuleHelpopFactory : public ModuleFactory
-{
- public:
- ModuleHelpopFactory()
- {
- }
-
- ~ModuleHelpopFactory()
- {
- }
-
- virtual Module * CreateModule(InspIRCd* Me)
- {
- return new ModuleHelpop(Me);
- }
-
-};
-
-extern "C" DllExport void * init_module( void )
-{
- return new ModuleHelpopFactory;
-}
+MODULE_INIT(ModuleHelpop)