I made a self-balancing via a config file based on the map.
I only want to know how to finish the plugin because I block, let me explain:
In addons / sourcemod / config I have a folder name test, this test file name includes the name of each map used by the server.
If the file does not exist, the plugin automatically created.
I want to know how to read my addons/sourcemod/test/de_dust2.cfg file.
And how an automatic swap T in CT if the number of T is greater to that defined in the config.
This is the beginning of the plugin:
PHP Code:
#include <sourcemod>
new String:g_sConfigFile[256];
public OnMapStart() { decl String:sPath[256]; BuildPath(Path_SM, sPath, sizeof(sPath), "configs/test");
if (!DirExists(sPath)) CreateDirectory(sPath, 511);
Je fait un équilibrage automatique via un fichier de config en fonction de la map.
Seulement je voudrais savoir comment terminer le plugin car je block, je m'explique :
Dans addons/sourcemod/config j'ai un dossier nommer test, ce dossier nommer test comporte le nom de chaque map utilisé par le serveur.
Si le fichier n'existe pas, le plugin le créé automatiquement.
Je voudrais savoir comment faire pour lire dans mon fichier addons/sourcemod/test/de_dust2.cfg.
Et comment faire un swap automatique de T en CT si le nombre de T est supérieur de se qui est défini dans la config.
Voilà le début du plugin :
PHP Code:
#include <sourcemod>
new String:g_sConfigFile[256];
public OnMapStart() { decl String:sPath[256]; BuildPath(Path_SM, sPath, sizeof(sPath), "configs/test");
if (!DirExists(sPath)) CreateDirectory(sPath, 511);