diff options
Diffstat (limited to 'src/core/ns_ghost.c')
-rw-r--r-- | src/core/ns_ghost.c | 41 |
1 files changed, 14 insertions, 27 deletions
diff --git a/src/core/ns_ghost.c b/src/core/ns_ghost.c index 689fd2aff..5a0da7a3a 100644 --- a/src/core/ns_ghost.c +++ b/src/core/ns_ghost.c @@ -18,36 +18,23 @@ int do_ghost(User * u); void myNickServHelp(User * u); -/** - * Create the command, and tell anope about it. - * @param argc Argument count - * @param argv Argument list - * @return MOD_CONT to allow the module, MOD_STOP to stop it - **/ -int AnopeInit(int argc, char **argv) +class NSGhost : public Module { - Command *c; - - moduleAddAuthor("Anope"); - moduleAddVersion("$Id$"); - moduleSetType(CORE); + public: + NSGhost(const std::string &creator) : Module(creator) + { + Command *c; - c = createCommand("GHOST", do_ghost, NULL, NICK_HELP_GHOST, -1, -1, -1, - -1); - moduleAddCommand(NICKSERV, c, MOD_UNIQUE); + moduleAddAuthor("Anope"); + moduleAddVersion("$Id$"); + moduleSetType(CORE); - moduleSetNickHelp(myNickServHelp); - - return MOD_CONT; -} + c = createCommand("GHOST", do_ghost, NULL, NICK_HELP_GHOST, -1, -1, -1, -1); + moduleAddCommand(NICKSERV, c, MOD_UNIQUE); -/** - * Unload the module - **/ -void AnopeFini(void) -{ - -} + moduleSetNickHelp(myNickServHelp); + } +}; @@ -121,4 +108,4 @@ int do_ghost(User * u) return MOD_CONT; } -MODULE_INIT("ns_ghost") +MODULE_INIT(NSGhost) |