aboutsummaryrefslogtreecommitdiff
path: root/NorthstarDLL/hoststate.cpp
diff options
context:
space:
mode:
authorBobTheBob9 <for.oliver.kirkham@gmail.com>2022-07-12 14:05:02 +0100
committerBobTheBob9 <for.oliver.kirkham@gmail.com>2022-07-12 14:05:02 +0100
commit6ae30c9b15fcc200c7b642016e7adbfdf9b979f4 (patch)
treef645afba242a092e1e920582f37ae396e35b5e06 /NorthstarDLL/hoststate.cpp
parent1068b3daeb95322461e69a2d8f0203309bd22830 (diff)
downloadNorthstarLauncher-6ae30c9b15fcc200c7b642016e7adbfdf9b979f4.tar.gz
NorthstarLauncher-6ae30c9b15fcc200c7b642016e7adbfdf9b979f4.zip
move exploit prevention and limits code out of serverauthentication, and have actual defs for CBasePlayer
Diffstat (limited to 'NorthstarDLL/hoststate.cpp')
-rw-r--r--NorthstarDLL/hoststate.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/NorthstarDLL/hoststate.cpp b/NorthstarDLL/hoststate.cpp
index 248f7259..aabfbe7b 100644
--- a/NorthstarDLL/hoststate.cpp
+++ b/NorthstarDLL/hoststate.cpp
@@ -25,7 +25,7 @@ void,, (CHostState* hostState))
Cbuf_Execute();
// need to do this to ensure we don't go to private match
- if (g_pServerAuthenticationManager->m_bNeedLocalAuthForNewgame)
+ if (g_pServerAuthentication->m_bNeedLocalAuthForNewgame)
SetCurrentPlaylist("tdm");
// net_data_block_enabled is required for sp, force it if we're on an sp map
@@ -45,17 +45,17 @@ void,, (CHostState* hostState))
// Copy new server name cvar to source
Cvar_hostname->SetValue(Cvar_ns_server_name->GetString());
- g_MasterServerManager->AddSelfToServerList(
+ g_pMasterServerManager->AddSelfToServerList(
Cvar_hostport->GetInt(),
- Cvar_ns_player_auth_port->GetInt(),
+ g_pServerAuthentication->Cvar_ns_player_auth_port->GetInt(),
Cvar_ns_server_name->GetString(),
Cvar_ns_server_desc->GetString(),
hostState->m_levelName,
GetCurrentPlaylistName(),
maxPlayers,
Cvar_ns_server_password->GetString());
- g_pServerAuthenticationManager->StartPlayerAuthServer();
- g_pServerAuthenticationManager->m_bNeedLocalAuthForNewgame = false;
+ g_pServerAuthentication->StartPlayerAuthServer();
+ g_pServerAuthentication->m_bNeedLocalAuthForNewgame = false;
}
AUTOHOOK(CHostState__State_ChangeLevelMP, engine.dll + 0x16E520,
@@ -73,7 +73,7 @@ void,, (CHostState* hostState))
if (!strncmp(g_pHostState->m_levelName, "sp_", 3))
g_pCVar->FindVar("net_data_block_enabled")->SetValue(true);
- g_MasterServerManager->UpdateServerMapAndPlaylist(hostState->m_levelName, GetCurrentPlaylistName(), maxPlayers);
+ g_pMasterServerManager->UpdateServerMapAndPlaylist(hostState->m_levelName, GetCurrentPlaylistName(), maxPlayers);
double dStartTime = Tier0::Plat_FloatTime();
CHostState__State_ChangeLevelMP(hostState);
@@ -85,8 +85,8 @@ void,, (CHostState* hostState))
{
spdlog::info("HostState: GameShutdown");
- g_MasterServerManager->RemoveSelfFromServerList();
- g_pServerAuthenticationManager->StopPlayerAuthServer();
+ g_pMasterServerManager->RemoveSelfFromServerList();
+ g_pServerAuthentication->StopPlayerAuthServer();
CHostState__State_GameShutdown(hostState);
}