Bazaar developer reference

LuaSupport::CallTestAll(ICvEngineScriptSystem1 *, const char *, ICvEngineScriptSystemArgs1 *, bool &)

Defined in
Lua/CvLuaSupport.cpp, line 85
Hook name
CivHooks::LuaSupport_CallTestAll

Hooks

static bool BeforeLuaSupport_CallTestAll(ICvEngineScriptSystem1* pkScriptSystem, const char* szName, ICvEngineScriptSystemArgs1* args, bool& value, bool& result);static void AfterLuaSupport_CallTestAll(ICvEngineScriptSystem1* pkScriptSystem, const char* szName, ICvEngineScriptSystemArgs1* args, bool& value, bool& result);static bool ReplaceLuaSupport_CallTestAll(bool (*original)(ICvEngineScriptSystem1*, const char*, ICvEngineScriptSystemArgs1*, bool&), ICvEngineScriptSystem1* pkScriptSystem, const char* szName, ICvEngineScriptSystemArgs1* args, bool& value);CivRegisterBefore<CivHooks::LuaSupport_CallTestAll>(host, &BeforeLuaSupport_CallTestAll);CivRegisterAfter<CivHooks::LuaSupport_CallTestAll>(host, &AfterLuaSupport_CallTestAll);CivRegisterReplace<CivHooks::LuaSupport_CallTestAll>(host, &ReplaceLuaSupport_CallTestAll);

Code

85bool LuaSupport::CallTestAll(ICvEngineScriptSystem1* pkScriptSystem, const char* szName, ICvEngineScriptSystemArgs1* args, bool& value)86{87	// Must release our lock so that if the main thread has the Lua lock and is waiting for the Game Core lock, we don't freeze88	bool bHadLock = gDLL->HasGameCoreLock();89	if(bHadLock)90		gDLL->ReleaseGameCoreLock();91	bool bResult = pkScriptSystem->CallTestAll(szName, args, value);92	if(bHadLock)93		gDLL->GetGameCoreLock();94	return bResult;95}

Calls

Called by

35 functions in 14 files