[Dedicated] Add com_logFilter dvar
This commit is contained in:
parent
ef3fb631d5
commit
0aaf8b8730
@ -16,12 +16,14 @@ This is the first public Beta version, it mostly consists of bug fixes.
|
||||
|
||||
### Added
|
||||
|
||||
- Add peacekeeper
|
||||
- Add peacekeeper.
|
||||
- Add com_logFilter dvar.
|
||||
|
||||
### Changed
|
||||
|
||||
- Optimize fastfiles, they are now a lot smaller.
|
||||
- Improve security by modifying guids to allow 64 bit certificate fingerprints.
|
||||
- Improve node synchronization handling.
|
||||
|
||||
### Fixed
|
||||
|
||||
|
@ -28,6 +28,12 @@ namespace Components
|
||||
std::memcpy(reinterpret_cast<void*>(0x66E1CB0), &fastfiles, sizeof(fastfiles));
|
||||
Game::R_LoadGraphicsAssets();
|
||||
|
||||
if (Dvar::Var("com_logFilter").get<bool>())
|
||||
{
|
||||
Utils::Hook::Nop(0x647466, 5); // 'dvar set' lines
|
||||
Utils::Hook::Nop(0x5DF4F2, 5); // 'sending splash open' lines
|
||||
}
|
||||
|
||||
Utils::Hook::Call<void()>(0x4F84C0)();
|
||||
}
|
||||
|
||||
@ -272,6 +278,7 @@ namespace Components
|
||||
// Map rotation
|
||||
Utils::Hook::Set(0x4152E8, Dedicated::MapRotate);
|
||||
Dvar::Register<bool>("sv_dontrotate", false, Game::dvar_flag::DVAR_FLAG_CHEAT, "");
|
||||
Dvar::Register<bool>("com_logFilter", true, Game::dvar_flag::DVAR_FLAG_LATCHED, "Removes ~95% of unneeded lines from the log");
|
||||
|
||||
if (Dedicated::IsEnabled() || ZoneBuilder::IsEnabled()) // Run zonebuilder as dedi :P
|
||||
{
|
||||
|
@ -337,8 +337,12 @@ namespace Components
|
||||
Utils::Hook::Nop(0x4CA1FA, 6);
|
||||
|
||||
// Filter log (initially com_logFilter, but I don't see why that dvar is needed)
|
||||
Utils::Hook::Nop(0x647466, 5); // 'dvar set' lines
|
||||
Utils::Hook::Nop(0x5DF4F2, 5); // 'sending splash open' lines
|
||||
// Seems like it's needed for B3, so there is a separate handling for dedicated servers in Dedicated.cpp
|
||||
if (!Dedicated::IsEnabled())
|
||||
{
|
||||
Utils::Hook::Nop(0x647466, 5); // 'dvar set' lines
|
||||
Utils::Hook::Nop(0x5DF4F2, 5); // 'sending splash open' lines
|
||||
}
|
||||
|
||||
// intro stuff
|
||||
Utils::Hook::Nop(0x60BEE9, 5); // Don't show legals
|
||||
|
Loading…
Reference in New Issue
Block a user