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

Method LoadAIState_PATCH_1

CryGame/XPlayer.cpp:7314–7334  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7312
7313
7314void CPlayer::LoadAIState_PATCH_1(CStream & stm)
7315{
7316
7317 if (!m_bIsAI)
7318 return;
7319
7320 IAIObject *pObject = m_pEntity->GetAI();
7321 pObject->Load_PATCH_1(stm);
7322
7323 int nGunOut=0;
7324 stm.Read(nGunOut);
7325 if (nGunOut)
7326 {
7327 SetWeaponPositionState(WEAPON_POS_HOLD);
7328 m_pEntity->GetScriptObject()->SetValue("AI_GunOut",1);
7329
7330 m_pScriptSystem->BeginCall("BasicAI","MakeAlerted");
7331 m_pScriptSystem->PushFuncParam(m_pEntity->GetScriptObject());
7332 m_pScriptSystem->EndCall();
7333 }
7334}
7335
7336
7337void CPlayer::OnEntityNetworkUpdate( const EntityId &idViewerEntity, const Vec3d &v3dViewer, uint32 &inoutPriority,

Callers 1

Calls 8

BeginCallMethod · 0.80
PushFuncParamMethod · 0.80
GetAIMethod · 0.45
Load_PATCH_1Method · 0.45
ReadMethod · 0.45
SetValueMethod · 0.45
GetScriptObjectMethod · 0.45
EndCallMethod · 0.45

Tested by

no test coverage detected