mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Flip 'sv_rcon_sendlogs' if netcon is not input only
This commit is contained in:
parent
5e4ea7d25a
commit
759d8d6d2e
@ -322,7 +322,7 @@ void ConVar_StaticInit(void)
|
||||
sv_simulateBots = ConVar::StaticCreate("sv_simulateBots", "1", FCVAR_RELEASE, "Simulate user commands for bots on the server.", true, 0.f, false, 0.f, nullptr, nullptr);
|
||||
|
||||
sv_rcon_debug = ConVar::StaticCreate("sv_rcon_debug" , "0" , FCVAR_RELEASE, "Show rcon debug information ( !slower! ).", false, 0.f, false, 0.f, nullptr, nullptr);
|
||||
sv_rcon_sendlogs = ConVar::StaticCreate("sv_rcon_sendlogs" , "1" , FCVAR_RELEASE, "Network console logs to connected and authenticated sockets.", false, 0.f, false, 0.f, nullptr, nullptr);
|
||||
sv_rcon_sendlogs = ConVar::StaticCreate("sv_rcon_sendlogs" , "0" , FCVAR_RELEASE, "Network console logs to connected and authenticated sockets.", false, 0.f, false, 0.f, nullptr, nullptr);
|
||||
sv_rcon_banpenalty = ConVar::StaticCreate("sv_rcon_banpenalty" , "10", FCVAR_RELEASE, "Number of minutes to ban users who fail rcon authentication.", false, 0.f, false, 0.f, nullptr, nullptr);
|
||||
sv_rcon_maxfailures = ConVar::StaticCreate("sv_rcon_maxfailures", "10", FCVAR_RELEASE, "Max number of times an user can fail rcon authentication before being banned.", true, 1.f, false, 0.f, nullptr, nullptr);
|
||||
sv_rcon_maxignores = ConVar::StaticCreate("sv_rcon_maxignores" , "15", FCVAR_RELEASE, "Max number of times an user can ignore the instruction message before being banned.", true, 1.f, false, 0.f, nullptr, nullptr);
|
||||
|
@ -426,8 +426,16 @@ bool CRConServer::ProcessMessage(const char* pMsgBuf, const int nMsgLen)
|
||||
{
|
||||
if (data.m_bAuthorized)
|
||||
{
|
||||
// "0" means the netconsole is input only.
|
||||
data.m_bInputOnly = !atoi(request.requestval().c_str());
|
||||
// request value "0" means the netconsole is input only.
|
||||
const bool bWantLog = atoi(request.requestval().c_str()) != NULL;
|
||||
|
||||
data.m_bInputOnly = !bWantLog;
|
||||
if (bWantLog && !sv_rcon_sendlogs->GetBool())
|
||||
{
|
||||
// Toggle it on since there's at least 1 netconsole that
|
||||
// wants to receive logs.
|
||||
sv_rcon_sendlogs->SetValue(bWantLog);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user