# *************************************************************************************************** # Schubaal's Basic Auth Mod # # Description: # - read's Steam ID's from Mani Admin's clients.txt # - enters them into basic_auth's variable # # # Installation: # 1. Install Mattie's Eventscripts 2.0+ # http://www.mattie.info/cs # # 2. Install Mani's Admin Plugin v1.2+ # http://www.mani-admin-plugin.com/ # # 2. Place [schubaal_auth.py] in [/cstrike/addons/eventscripts/schubaal_auth/] directory # # 3. Add the following line to the beginning of [autoexec.cfg]: # es_load schubaal_auth # # # Coming Soon: # - creating a better system to replace basic_auth (as basic_auth is an all-or-nothing admin auth) # # *************************************************************************************************** import es import keyvalues def load(): if not es.exists('script', 'examples/auth/basic_auth'): es.load("examples/auth/basic_auth") _temp_admin_list = "STEAM_ID_LAN" _list = keyvalues.getKeyGroup("clients.txt/players") for k in _list: _temp_admin_list = _temp_admin_list + "," + k.getString("steam") es.set("BASIC_AUTH_ADMIN_LIST", _temp_admin_list) es.unload("schubaal_auth")