MCPcopy Create free account
hub / github.com/StrongPC123/Far-Cry-1-Source-Full / GetEntity

Method GetEntity

CrySystem/ScriptObjectSystem.cpp:678–694  ·  view source on GitHub ↗

///////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////// int CScriptObjectSystem::PostMessage(IFunctionHandler *pH) { CHECK_PARAMETERS(1); const char *sParam; IProcess *pProcess = m_pSystem->GetIProcess(); pH->GetParam(1, sParam); m_pGame->SendMessage(sParam); return pH->EndFunction();

Source from the content-addressed store, hash-verified

676 @param nID the entity id
677*/
678int CScriptObjectSystem::GetEntity(IFunctionHandler *pH)
679{
680 CHECK_PARAMETERS(1);
681 IEntity *pEntity;
682 IScriptObject *pObject;
683 int nID;
684 pH->GetParam(1,nID);
685 pEntity=m_pEntitySystem->GetEntity(nID);
686 if(pEntity){
687 pObject=pEntity->GetScriptObject();
688 return pH->EndFunction(pObject);
689 }
690 else
691 {
692 return pH->EndFunctionNull();
693 }
694}
695/////////////////////////////////////////////////////////////////////////////////
696/////////////////////////////////////////////////////////////////////////////////
697/*!return a all entities currently present in the level

Callers 14

CreateDecalMethod · 0.45
AttachMethod · 0.45
DetachMethod · 0.45
GetEntityByNameMethod · 0.45
SetGrasshopperCGFMethod · 0.45
ActivatePortalMethod · 0.45
RayWorldIntersectionMethod · 0.45
RayTraceCheckMethod · 0.45
CreateSoftEntityMethod · 0.45
SetEntityPhysicParamsMethod · 0.45
SetAnimationEventMethod · 0.45
DisableAnimationEventMethod · 0.45

Calls 4

EndFunctionMethod · 0.80
EndFunctionNullMethod · 0.80
GetParamMethod · 0.45
GetScriptObjectMethod · 0.45

Tested by

no test coverage detected