diff options
author | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-09-30 21:46:08 +0100 |
---|---|---|
committer | BobTheBob <32057864+BobTheBob9@users.noreply.github.com> | 2021-09-30 21:46:08 +0100 |
commit | 1ff8e068e62d095775ef2ae54d3685d89238f28c (patch) | |
tree | 5aedcc16f144c2225d7398dd1f19b4f11cd467c1 /NorthstarDedicatedTest/serverauthentication.cpp | |
parent | 8b93a09f5b12ce7967df5824794ed24b3ff31cdc (diff) | |
download | NorthstarLauncher-1ff8e068e62d095775ef2ae54d3685d89238f28c.tar.gz NorthstarLauncher-1ff8e068e62d095775ef2ae54d3685d89238f28c.zip |
small modmanager refactors
Diffstat (limited to 'NorthstarDedicatedTest/serverauthentication.cpp')
-rw-r--r-- | NorthstarDedicatedTest/serverauthentication.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/NorthstarDedicatedTest/serverauthentication.cpp b/NorthstarDedicatedTest/serverauthentication.cpp index fed4eb82..48ae1cf2 100644 --- a/NorthstarDedicatedTest/serverauthentication.cpp +++ b/NorthstarDedicatedTest/serverauthentication.cpp @@ -29,7 +29,7 @@ typedef char(*CGameClient__ExecuteStringCommandType)(void* self, uint32_t unknow CGameClient__ExecuteStringCommandType CGameClient__ExecuteStringCommand; // global vars -ServerAuthenticationManager* g_ServerAuthenticationManager; +std::unique_ptr<ServerAuthenticationManager> g_ServerAuthenticationManager; ConVar* Cvar_ns_player_auth_port; ConVar* Cvar_ns_erase_auth_info; @@ -299,7 +299,7 @@ char CGameClient__ExecuteStringCommandHook(void* self, uint32_t unknown, const c void InitialiseServerAuthentication(HMODULE baseAddress) { - g_ServerAuthenticationManager = new ServerAuthenticationManager; + g_ServerAuthenticationManager = std::make_unique<ServerAuthenticationManager>(); Cvar_ns_erase_auth_info = RegisterConVar("ns_erase_auth_info", "1", FCVAR_GAMEDLL, "Whether auth info should be erased from this server on disconnect or crash"); CVar_ns_auth_allow_insecure = RegisterConVar("ns_auth_allow_insecure", "0", FCVAR_GAMEDLL, "Whether this server will allow unauthenicated players to connect"); |