aboutsummaryrefslogtreecommitdiff
path: root/primedev
diff options
context:
space:
mode:
Diffstat (limited to 'primedev')
-rw-r--r--primedev/core/convar/convar.cpp5
-rw-r--r--primedev/core/convar/cvar.cpp1
-rw-r--r--primedev/core/convar/cvar.h1
3 files changed, 2 insertions, 5 deletions
diff --git a/primedev/core/convar/convar.cpp b/primedev/core/convar/convar.cpp
index 87a1e159..802c088d 100644
--- a/primedev/core/convar/convar.cpp
+++ b/primedev/core/convar/convar.cpp
@@ -1,7 +1,7 @@
#include "bits.h"
#include "cvar.h"
#include "convar.h"
-#include "core/sourceinterface.h"
+#include "core/tier1.h"
#include <float.h>
@@ -35,8 +35,7 @@ ON_DLL_LOAD("engine.dll", ConVar, (CModule module))
g_pConVar_Vtable = module.Offset(0x67FD28);
g_pIConVar_Vtable = module.Offset(0x67FDC8);
- g_pCVarInterface = new SourceInterface<CCvar>("vstdlib.dll", "VEngineCvar007");
- g_pCVar = *g_pCVarInterface;
+ g_pCVar = Sys_GetFactoryPtr("vstdlib.dll", "VEngineCvar007").RCast<CCvar*>();
}
//-----------------------------------------------------------------------------
diff --git a/primedev/core/convar/cvar.cpp b/primedev/core/convar/cvar.cpp
index aa5f0365..78da1ad2 100644
--- a/primedev/core/convar/cvar.cpp
+++ b/primedev/core/convar/cvar.cpp
@@ -22,5 +22,4 @@ std::unordered_map<std::string, ConCommandBase*> CCvar::DumpToMap()
return allConVars;
}
-SourceInterface<CCvar>* g_pCVarInterface;
CCvar* g_pCVar;
diff --git a/primedev/core/convar/cvar.h b/primedev/core/convar/cvar.h
index beaa84f4..024f2b87 100644
--- a/primedev/core/convar/cvar.h
+++ b/primedev/core/convar/cvar.h
@@ -34,5 +34,4 @@ public:
std::unordered_map<std::string, ConCommandBase*> DumpToMap();
};
-extern SourceInterface<CCvar>* g_pCVarInterface;
extern CCvar* g_pCVar;