
   /*
   * AMX_FLUSH
   *  by Yitram
   */
   #include <amxmod>
   #include <amxmisc>
   public adminFlush(id,level, cid){
       if (!cmd_access(id,level,cid,2))
           return PLUGIN_HANDLED
       new time[5]
       read_argv(1,time,4)
       new Float:ftime = floatstr(time)
       set_task(ftime,"flushIt")
       return PLUGIN_HANDLED
   }
   public flushIt(){
       new argnum = read_argc()
       new ltags[4][32]
       new ltagsnum = 0
       for(new a=1;a<5;++a){
           if (a<argnum)
               read_argv(a,ltags[ltagsnum++],31)
           else
               ltags[ltagsnum++][0] = 0
       }
       new nick[32], ires, pnum = get_maxplayers() + 1, count = 0
       for(new b=1;b<pnum;++b){
           if (!is_user_connected(b)&&!is_user_connecting(b)) continue
           get_user_name(b,nick,31)
           if (get_user_flags(b)&ADMIN_IMMUNITY){
               continue
           }
           if (is_user_bot(b))
               server_cmd("kick #%d",get_user_userid(b))
           else
               client_cmd(b,"echo  *  You have been dropped because admin
   has left only specified group of clients;disconnect")
           count++
       }
       new authid[16],name[32]
       return PLUGIN_HANDLED
   }
   public plugin_init(){
       register_plugin("Server Flush","1.0","Yitram")
       register_concmd("amx_flush","adminFlush",ADMIN_RCON,"<time      in
   sec.>")
       return PLUGIN_CONTINUE
   }
