Hello everyone!
I made a small plugin, and I have a small problem with
RegConsoleCmd
Code:
#include <sourcemod>
#include <sdktools>
#include <tf2>
#include <tf2_stocks>
#include <sdkhooks>
bool bMimic = false;
public void OnPluginStar()
{
RegConsoleCmd("sm_toggle_mimic", Command_Mimic);
}
public Action Command_Mimic(int iClient, int iArgs)
{
if (bMimic)
bMimic = false;
else
bMimic = true;
return Plugin_Handled;
}
The client/server console, always says unknown command, I renamed the command, made a new plugin, upgraded sourcemod downgraded sourcemod, nothing, any help?
Ps: the variable (bMimic) is never changed when I use the command.
Soluce:Welp I feel dumb found my mistake, I wrote OnPluginStar I should have written OnPluginStart xd
I should reread my work slowly next time
__________________