Add hack to not throw error on FEBC not found if not attempted to be found (nobug, r=asherkin).
authorNicholas Hastings <skamonkey@gmail.com>
Fri Mar 21 12:03:19 2014 -0400 (2014-03-21)
changeset 4286cdf909025f39
parent 4285 40a2c6a9e8c8
child 4287 95d818e1f496
Add hack to not throw error on FEBC not found if not attempted to be found (nobug, r=asherkin).
extensions/sdktools/vnatives.cpp
     1.1 --- a/extensions/sdktools/vnatives.cpp	Mon Mar 17 10:01:17 2014 -0400
     1.2 +++ b/extensions/sdktools/vnatives.cpp	Fri Mar 21 12:03:19 2014 -0400
     1.3 @@ -825,7 +825,15 @@
     1.4  			if (!bProbablyNoFEBC)
     1.5  			{
     1.6  				bProbablyNoFEBC = true;
     1.7 -				g_pSM->LogError(myself, "%s, falling back to IServerTools method.", error);
     1.8 +
     1.9 +				// CreateBaseCall above abstracts all of the gamedata logic, but we need to know if the key was even found.
    1.10 +				// We don't want to log an error if key isn't present (knowing falling back to native method), only throw
    1.11 +				// error if signature/symbol was not found.
    1.12 +				void *dummy;
    1.13 +				if (g_pGameConf->GetMemSig("FindEntityByClassname", &dummy))
    1.14 +				{
    1.15 +					g_pSM->LogError(myself, "%s, falling back to IServerTools method.", error);
    1.16 +				}
    1.17  			}
    1.18  			return NativeFindEntityByClassname(pContext, params);
    1.19  #else