]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_setidle.cpp
Socket engine tweaks to fix a glitch, and improvements to new m_ident
[user/henk/code/inspircd.git] / src / modules / m_setidle.cpp
index e16369aa4b30e60afe4f17a4160dffcf9eb875f1..a676eedb4f99835a8e819600c6010e3b4ee950d4 100644 (file)
  */
 
 #include "inspircd.h"
-#include "users.h"
-#include "channels.h"
-#include "modules.h"
 
 /* $ModDesc: Allows opers to set their idle time */
 
 /** Handle /SETIDLE
  */
-class cmd_setidle : public command_t
+class cmd_setidle : public Command
 {
  public:
-       cmd_setidle (InspIRCd* Instance) : command_t(Instance,"SETIDLE", 'o', 1)
+       cmd_setidle (InspIRCd* Instance) : Command(Instance,"SETIDLE", 'o', 1)
        {
                this->source = "m_setidle.so";
                syntax = "<duration>";
+               TRANSLATE2(TR_TEXT, TR_END);
        }
 
-       CmdResult Handle (const char** parameters, int pcnt, userrec *user)
+       CmdResult Handle (const char** parameters, int pcnt, User *user)
        {
                time_t idle = ServerInstance->Duration(parameters[0]);
                if (idle < 1)
@@ -67,7 +65,7 @@ class ModuleSetIdle : public Module
        
        virtual Version GetVersion()
        {
-               return Version(1,1,0,1,VF_VENDOR,API_VERSION);
+               return Version(1, 1, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION);
        }
 };