mirror of
https://github.com/alliedmodders/metamod-source.git
synced 2025-02-21 14:54:14 +01:00
Fixed bug where engine was being detected as OBV/ep2v on OB/ep2 listen servers (bug 4560, r=dvander).
This commit is contained in:
parent
6b9bd44ff1
commit
3de5678e45
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 sw=4 tw=99 noet :
|
* vim: set ts=4 sw=4 tw=99 noet :
|
||||||
* ======================================================
|
* ======================================================
|
||||||
* Metamod:Source
|
* Metamod:Source
|
||||||
* Copyright (C) 2004-2009 AlliedModders LLC and authors.
|
* Copyright (C) 2004-2010 AlliedModders LLC and authors.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
* ======================================================
|
* ======================================================
|
||||||
*
|
*
|
||||||
@ -183,12 +183,15 @@ mm_GetProcAddress(const char *name)
|
|||||||
#if defined _WIN32
|
#if defined _WIN32
|
||||||
#define TIER0_NAME "bin\\tier0.dll"
|
#define TIER0_NAME "bin\\tier0.dll"
|
||||||
#define VSTDLIB_NAME "bin\\vstdlib.dll"
|
#define VSTDLIB_NAME "bin\\vstdlib.dll"
|
||||||
|
#define STEAM_API_NAME "bin\\steam_api.dll"
|
||||||
#elif defined __APPLE__
|
#elif defined __APPLE__
|
||||||
#define TIER0_NAME "bin/libtier0.dylib"
|
#define TIER0_NAME "bin/libtier0.dylib"
|
||||||
#define VSTDLIB_NAME "bin/libvstdlib.dylib"
|
#define VSTDLIB_NAME "bin/libvstdlib.dylib"
|
||||||
|
#define STEAM_API_NAME "bin/libsteam_api.dylib"
|
||||||
#elif defined __linux__
|
#elif defined __linux__
|
||||||
#define TIER0_NAME "bin/" LIB_PREFIX "tier0" LIB_SUFFIX
|
#define TIER0_NAME "bin/" LIB_PREFIX "tier0" LIB_SUFFIX
|
||||||
#define VSTDLIB_NAME "bin/" LIB_PREFIX "vstdlib" LIB_SUFFIX
|
#define VSTDLIB_NAME "bin/" LIB_PREFIX "vstdlib" LIB_SUFFIX
|
||||||
|
#define STEAM_API_NAME "bin/" LIB_PREFIX "steam_api" LIB_SUFFIX
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
const char *
|
const char *
|
||||||
@ -284,12 +287,12 @@ mm_DetermineBackend(QueryValveInterface engineFactory, const char *game_name)
|
|||||||
char lib_path[PLATFORM_MAX_PATH];
|
char lib_path[PLATFORM_MAX_PATH];
|
||||||
|
|
||||||
/* These would have failed already if they were going to? */
|
/* These would have failed already if they were going to? */
|
||||||
mm_ResolvePath(TIER0_NAME, lib_path, sizeof(lib_path));
|
mm_ResolvePath(STEAM_API_NAME, lib_path, sizeof(lib_path));
|
||||||
void *lib = mm_LoadLibrary(lib_path, NULL, 0);
|
void *lib = mm_LoadLibrary(lib_path, NULL, 0);
|
||||||
void *tier0_ctime = mm_GetLibAddress(lib, "Plat_ctime");
|
void *steamapi_breakpad = mm_GetLibAddress(lib, "SteamAPI_SetBreakpadAppID");
|
||||||
mm_UnloadLibrary(lib);
|
mm_UnloadLibrary(lib);
|
||||||
|
|
||||||
if (tier0_ctime != NULL)
|
if (steamapi_breakpad != NULL)
|
||||||
{
|
{
|
||||||
return MMBackend_Episode2Valve;
|
return MMBackend_Episode2Valve;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user