
   /* AMX Mod script.
   *
   * (c) Copyright 2003
   * This file is provided as is (no warranties).
   *
   */
   #include <amxmod>
   new blockjoining[6]
   public admin_lockt() {
   blockjoining[ 0 ] = PLUGIN_HANDLED
   return PLUGIN_HANDLED
   }
   public admin_unlockt() {
   blockjoining[ 0 ] = PLUGIN_CONTINUE
   return PLUGIN_HANDLED
   }
   public admin_lockct() {
   blockjoining[ 1 ] = PLUGIN_HANDLED
   return PLUGIN_HANDLED
   }
   public admin_unlockct() {
   blockjoining[ 1 ] = PLUGIN_CONTINUE
   return PLUGIN_HANDLED
   }
   public admin_lockauto() {
   blockjoining[ 4 ] = PLUGIN_HANDLED
   return PLUGIN_HANDLED
   }
   public admin_unlockauto() {
   blockjoining[ 4 ] = PLUGIN_CONTINUE
   return PLUGIN_HANDLED
   }
   public admin_lockspec() {
   blockjoining[ 5 ] = PLUGIN_HANDLED
   return PLUGIN_HANDLED
   }
   public admin_unlockspec() {
   blockjoining[ 5 ] = PLUGIN_CONTINUE
   return PLUGIN_HANDLED
   }
   public team_select(id, key){
       if ( blockjoining[ key ] == PLUGIN_HANDLED ){
           engclient_cmd(id,"chooseteam")
           return PLUGIN_HANDLED
       }
       return PLUGIN_CONTINUE
   }
   public plugin_init() {
       register_plugin("Team Locker","0.1","bardelot")
       register_menucmd(register_menuid("Team_Select"),(1<<0)|(1<<1)|(1<<
   4)|(1<<5),"team_select")
       register_menucmd(-2,(1<<0)|(1<<1)|(1<<4)|(1<<5),"team_select")
       register_clcmd("amx_lockt","admin_lockt",ADMIN_SLAY,"locks       T
   Team")
       register_clcmd("amx_unlockt","admin_unlockt",ADMIN_SLAY,"unlocks T
   Team")
       register_clcmd("amx_lockct","admin_lockct",ADMIN_SLAY,"locks    CT
   Team")
       register_clcmd("amx_unlockct","admin_unlockct",ADMIN_SLAY,"unlocks
   CT Team")
       register_clcmd("amx_lockauto","admin_lockauto",ADMIN_SLAY,"locks
   Auto Team")
       register_clcmd("amx_unlockauto","admin_unlockauto",ADMIN_SLAY,"unl
   ocks Auto Team")
       register_clcmd("amx_lockspec","admin_lockspec",ADMIN_SLAY,"locks
   Spec Team")
       register_clcmd("amx_unlockspec","admin_unlockspec",ADMIN_SLAY,"unl
   ocks Spec Team")
       return PLUGIN_CONTINUE
       }
