aboutsummaryrefslogtreecommitdiff
path: root/NorthstarDLL/client
diff options
context:
space:
mode:
Diffstat (limited to 'NorthstarDLL/client')
-rw-r--r--NorthstarDLL/client/clientauthhooks.cpp4
-rw-r--r--NorthstarDLL/client/demofixes.cpp6
-rw-r--r--NorthstarDLL/client/languagehooks.cpp2
-rw-r--r--NorthstarDLL/client/r2client.cpp12
-rw-r--r--NorthstarDLL/client/r2client.h12
-rw-r--r--NorthstarDLL/client/rejectconnectionfixes.cpp2
6 files changed, 14 insertions, 24 deletions
diff --git a/NorthstarDLL/client/clientauthhooks.cpp b/NorthstarDLL/client/clientauthhooks.cpp
index adb2ab22..35ae3aa7 100644
--- a/NorthstarDLL/client/clientauthhooks.cpp
+++ b/NorthstarDLL/client/clientauthhooks.cpp
@@ -32,10 +32,10 @@ void, __fastcall, (void* a1))
// if player has agreed to send token and we aren't already authing, try to auth
if (Cvar_ns_has_agreed_to_send_token->GetInt() == AGREED_TO_SEND_TOKEN &&
!g_pMasterServerManager->m_bOriginAuthWithMasterServerInProgress)
- g_pMasterServerManager->AuthenticateOriginWithMasterServer(R2::g_pLocalPlayerUserID, R2::g_pLocalPlayerOriginToken);
+ g_pMasterServerManager->AuthenticateOriginWithMasterServer(g_pLocalPlayerUserID, g_pLocalPlayerOriginToken);
// invalidate key so auth will fail
- *R2::g_pLocalPlayerOriginToken = 0;
+ *g_pLocalPlayerOriginToken = 0;
}
AuthWithStryder(a1);
diff --git a/NorthstarDLL/client/demofixes.cpp b/NorthstarDLL/client/demofixes.cpp
index 65e48fc0..344764ba 100644
--- a/NorthstarDLL/client/demofixes.cpp
+++ b/NorthstarDLL/client/demofixes.cpp
@@ -11,15 +11,15 @@ ON_DLL_LOAD_CLIENT_RELIESON("client.dll", ClientDemoFixes, ConVar, (CModule modu
{
// change default values of demo cvars to enable them by default, but not autorecord
// this is before Host_Init, the setvalue calls here will get overwritten by custom cfgs/launch options
- ConVar* Cvar_demo_enableDemos = R2::g_pCVar->FindVar("demo_enabledemos");
+ ConVar* Cvar_demo_enableDemos = g_pCVar->FindVar("demo_enabledemos");
Cvar_demo_enableDemos->m_pszDefaultValue = "1";
Cvar_demo_enableDemos->SetValue(true);
- ConVar* Cvar_demo_writeLocalFile = R2::g_pCVar->FindVar("demo_writeLocalFile");
+ ConVar* Cvar_demo_writeLocalFile = g_pCVar->FindVar("demo_writeLocalFile");
Cvar_demo_writeLocalFile->m_pszDefaultValue = "1";
Cvar_demo_writeLocalFile->SetValue(true);
- ConVar* Cvar_demo_autoRecord = R2::g_pCVar->FindVar("demo_autoRecord");
+ ConVar* Cvar_demo_autoRecord = g_pCVar->FindVar("demo_autoRecord");
Cvar_demo_autoRecord->m_pszDefaultValue = "0";
Cvar_demo_autoRecord->SetValue(false);
}
diff --git a/NorthstarDLL/client/languagehooks.cpp b/NorthstarDLL/client/languagehooks.cpp
index 4251dbbd..35ca5659 100644
--- a/NorthstarDLL/client/languagehooks.cpp
+++ b/NorthstarDLL/client/languagehooks.cpp
@@ -57,7 +57,7 @@ char*, __fastcall, ())
bool& canOriginDictateLang = *(bool*)((char*)tier0Handle + 0xA9A90);
const char* forcedLanguage;
- if (Tier0::CommandLine()->CheckParm("-language", &forcedLanguage))
+ if (CommandLine()->CheckParm("-language", &forcedLanguage))
{
if (!CheckLangAudioExists((char*)forcedLanguage))
{
diff --git a/NorthstarDLL/client/r2client.cpp b/NorthstarDLL/client/r2client.cpp
index fea97d8e..c8e59d74 100644
--- a/NorthstarDLL/client/r2client.cpp
+++ b/NorthstarDLL/client/r2client.cpp
@@ -1,14 +1,8 @@
#include "r2client.h"
-using namespace R2;
-
-// use the R2 namespace for game funcs
-namespace R2
-{
- char* g_pLocalPlayerUserID;
- char* g_pLocalPlayerOriginToken;
- GetBaseLocalClientType GetBaseLocalClient;
-} // namespace R2
+char* g_pLocalPlayerUserID;
+char* g_pLocalPlayerOriginToken;
+GetBaseLocalClientType GetBaseLocalClient;
ON_DLL_LOAD("engine.dll", R2EngineClient, (CModule module))
{
diff --git a/NorthstarDLL/client/r2client.h b/NorthstarDLL/client/r2client.h
index 64ed6c61..ea263dbc 100644
--- a/NorthstarDLL/client/r2client.h
+++ b/NorthstarDLL/client/r2client.h
@@ -1,11 +1,7 @@
#pragma once
-// use the R2 namespace for game funcs
-namespace R2
-{
- extern char* g_pLocalPlayerUserID;
- extern char* g_pLocalPlayerOriginToken;
+extern char* g_pLocalPlayerUserID;
+extern char* g_pLocalPlayerOriginToken;
- typedef void* (*GetBaseLocalClientType)();
- extern GetBaseLocalClientType GetBaseLocalClient;
-} // namespace R2
+typedef void* (*GetBaseLocalClientType)();
+extern GetBaseLocalClientType GetBaseLocalClient;
diff --git a/NorthstarDLL/client/rejectconnectionfixes.cpp b/NorthstarDLL/client/rejectconnectionfixes.cpp
index 6adde8b6..1b326a3c 100644
--- a/NorthstarDLL/client/rejectconnectionfixes.cpp
+++ b/NorthstarDLL/client/rejectconnectionfixes.cpp
@@ -22,7 +22,7 @@ void,, (bool a1, const char* fmt, ...))
// not doing this gets our client in a pretty weird state so we need to shut it down manually here
// don't call Cbuf_Execute because we don't need this called immediately
- R2::Cbuf_AddText(R2::Cbuf_GetCurrentPlayer(), "disconnect", R2::cmd_source_t::kCommandSrcCode);
+ Cbuf_AddText(Cbuf_GetCurrentPlayer(), "disconnect", cmd_source_t::kCommandSrcCode);
}
return COM_ExplainDisconnection(a1, "%s", buf);