Changed: Try to load Steam DLL without path if fails
--HG-- branch : compatibility-develop
This commit is contained in:
parent
833976be5b
commit
264e8be1a2
1 changed files with 9 additions and 3 deletions
|
@ -302,14 +302,20 @@ bool CSteamClient::init()
|
||||||
filename = "libsteam_api.so";
|
filename = "libsteam_api.so";
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// try to load library
|
// try to load library with absolute path
|
||||||
_Handle = NLMISC::nlLoadLibrary(Args.getProgramPath() + filename);
|
_Handle = NLMISC::nlLoadLibrary(Args.getProgramPath() + filename);
|
||||||
|
|
||||||
|
if (!_Handle)
|
||||||
|
{
|
||||||
|
// try to load library with relative path (will search in system paths)
|
||||||
|
_Handle = NLMISC::nlLoadLibrary(filename);
|
||||||
|
|
||||||
if (!_Handle)
|
if (!_Handle)
|
||||||
{
|
{
|
||||||
nlwarning("Unable to load Steam client");
|
nlwarning("Unable to load Steam client");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// load Steam functions
|
// load Steam functions
|
||||||
NL_LOAD_SYMBOL(SteamAPI_Init);
|
NL_LOAD_SYMBOL(SteamAPI_Init);
|
||||||
|
|
Loading…
Reference in a new issue