class CommandSetname : public Command
{
public:
- CommandSetname (InspIRCd* Instance) : Command(Instance,"SETNAME", 0, 1, 1)
+ CommandSetname (InspIRCd* Instance, Module* Creator) : Command(Instance, Creator,"SETNAME", 0, 1, 1)
{
- this->source = "m_setname.so";
syntax = "<new-gecos>";
TRANSLATE2(TR_TEXT, TR_END);
}
class ModuleSetName : public Module
{
- CommandSetname* mycommand;
+ CommandSetname cmd;
public:
ModuleSetName(InspIRCd* Me)
- : Module(Me)
+ : Module(Me), cmd(Me, this)
{
-
- mycommand = new CommandSetname(ServerInstance);
- ServerInstance->AddCommand(mycommand);
-
+ ServerInstance->AddCommand(&cmd);
}
virtual ~ModuleSetName()