mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
convar for logger overlay, some colour changes
This commit is contained in:
parent
65ab3770e5
commit
3d770e087d
@ -412,6 +412,8 @@ namespace GameGlobals
|
||||
void* ReloadBanListConCommand = CreateCustomConCommand("reloadbanlist", "Reloads the ban list from disk.", 0, CustomCommandVariations::ReloadBanList_Callback, nullptr);
|
||||
void* BanConCommand = CreateCustomConCommand("ban", "Bans a client from the Server via name. | Usage: ban (name)", 0, CustomCommandVariations::Ban_Callback, nullptr);
|
||||
void* BanIDConCommand = CreateCustomConCommand("banid", "Bans a client from the Server via originID, userID or IP | Usage: banid (originID/ipAddress/userID)", 0, CustomCommandVariations::BanID_Callback, nullptr);
|
||||
|
||||
ConVar* DrawConsoleOverlayConVar = CreateCustomConVar("cl_drawconsoleoverlay", "0", 0, "Draw the console overlay at the top of the screen", false, 0.f, false, 0.f, nullptr, nullptr);
|
||||
}
|
||||
|
||||
void* CreateCustomConCommand(const char* name, const char* helpString, int flags, void* callback, void* callbackAfterExecution)
|
||||
|
@ -16,6 +16,9 @@ void LogSystem::Update()
|
||||
for (int i = 0; i < m_vLogs.size(); ++i) {
|
||||
if (m_vLogs[i].Ticks >= 0)
|
||||
{
|
||||
if (GameGlobals::Cvar->FindVar("cl_drawconsoleoverlay")->m_iValue < 1)
|
||||
return;
|
||||
|
||||
if (i < LOGSYSTEM_LINES_TO_SHOW) {
|
||||
|
||||
float fadepct = fminf(float(m_vLogs[i].Ticks) / 64.f, 1.0);
|
||||
@ -56,10 +59,10 @@ std::array<int, 3> LogSystem::GetLogColorForType(LogType_t type) {
|
||||
case LogType_t::NATIVE:
|
||||
return { 255, 255, 255 };
|
||||
case LogType_t::SCRIPT_SERVER:
|
||||
return { 163, 156, 213 };
|
||||
return { 190, 183, 240 };
|
||||
case LogType_t::SCRIPT_CLIENT:
|
||||
return { 117, 116, 139 };
|
||||
case LogType_t::SCRIPT_UI:
|
||||
return { 117, 99, 98 };
|
||||
return { 197, 160, 177 };
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user