MCPcopy Create free account
hub / github.com/MergHQ/CRYENGINE / BeginCall

Method BeginCall

Code/CryEngine/CryScriptSystem/ScriptSystem.cpp:1321–1342  ·  view source on GitHub ↗

///////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

1319//////////////////////////////////////////////////////////////////////
1320//////////////////////////////////////////////////////////////////////
1321int CScriptSystem::BeginCall(HSCRIPTFUNCTION hFunc)
1322{
1323 assert(hFunc != 0);
1324 if (!hFunc)
1325 return 0;
1326
1327 lua_getref(L, (int)(INT_PTR)hFunc);
1328 if (!lua_isfunction(L, -1))
1329 {
1330#if defined(__GNUC__)
1331 ScriptWarning("[CScriptSystem::BeginCall] Function Ptr:%d not found", (int)(INT_PTR)hFunc);
1332#else
1333 ScriptWarning("[CScriptSystem::BeginCall] Function Ptr:%d not found", hFunc);
1334#endif
1335 m_nTempArg = -1;
1336 lua_pop(L, 1);
1337 return 0;
1338 }
1339 m_nTempArg = 0;
1340
1341 return 1;
1342}
1343
1344//////////////////////////////////////////////////////////////////////
1345//////////////////////////////////////////////////////////////////////

Callers 15

ReloadMethod · 0.80
ResetCharacterMethod · 0.80
SetCharacterMethod · 0.80
CallScriptMethod · 0.80
CompleteInitMethod · 0.80
ReleaseScriptBindsMethod · 0.80
CreateItemTableMethod · 0.80
OnInputEventMethod · 0.80
CallScriptMethod · 0.80

Calls 1

ScriptWarningFunction · 0.85

Tested by

no test coverage detected