
   /* AMXMOD script.
   *
   * (c) Copyright 2000-2002, RAV
   * This file is provided as is (no warranties).
   *
   *
   * Required: ADMIN_LEVEL_A to use this command
   *
   * Changelog
   *
   * Version 1.00 - Initial Build
   *
   * Command amx_armor < part of nick > < amount >
   */
   #include <amxmod>
   public admin_armor(id)
   {
       if (!(get_user_flags(id)&ADMIN_LEVEL_A)){
           client_print(id,print_console,"[AMX]  You  have  no  access to
   that command")
           return PLUGIN_HANDLED
       }
       if (read_argc() <2) {
           client_print(id,print_console,"[AMX]  Usage:  amx_armor < part
   of nick > < amount > ")
           return PLUGIN_HANDLED
       }
       new name[32]
       new amount[33]
       read_argv(1,name,32)
       read_argv(2,amount,32)
       new toarmor = find_player("bl",name)
       if (toarmor)    {
           if (get_user_flags(toarmor)&ADMIN_IMMUNITY){
           client_print(id,print_console,"[AMX] The player has immunity")
           return PLUGIN_HANDLED
           }
           if (is_user_alive(toarmor)==0)    {
           client_print(id,print_console,"[AMX]  Client  ^"%s^"  is dead,
   armor is useless",name)
           return PLUGIN_HANDLED
           }
           if (str_to_num(amount) > 100){
           client_print(id,print_console,"[AMX]  Clients  cannot be given
   more than 100 armor!")
           return PLUGIN_HANDLED
           }
       set_user_armor(toarmor,str_to_num(amount))
       return PLUGIN_HANDLED
       }
       else {
           client_print(id,print_console,"[AMX]  Client with that part of
   nick not found")
           return PLUGIN_HANDLED
       }
       return PLUGIN_CONTINUE
   }
   public plugin_init()
   {
       register_plugin("Admin armor","1.00","Rav")
       register_clcmd("amx_armor","admin_armor",ADMIN_LEVEL_A,"amx_armor
   < part of nick > < amount >")
       register_cvar(".RVS_AdminArmor", "1.3",FCVAR_SERVER)
       return PLUGIN_CONTINUE

   }
