View Single Post
Visual77
Veteran Member
Join Date: Jan 2009
Old 01-06-2018 , 05:16   Re: [L4D2] sv_steamgroup fixer
Reply With Quote #11

Well then, I have only one other idea. Delete sv_steamgroup_fixer.smx from your server and compile a new .smx file with this code only.

Code:
#include <sourcemod>

#pragma semicolon 1
#pragma newdecls required

ConVar g_hSteamGroupCvar;

public void OnPluginStart()
{
	g_hSteamGroupCvar = FindConVar("sv_steamgroup");
}

public void OnConfigsExecuted()
{
	char stringValue[128];
	g_hSteamGroupCvar.GetString(stringValue, sizeof(stringValue));
	
	int intValue = StringToInt(stringValue);
	
	LogMessage("Setting sv_steamgroup %d", intValue);

	g_hSteamGroupCvar.SetInt(intValue);
}
Visual77 is offline