/////////////////////////////////////////////////////////////////////
| 18 | |
| 19 | ////////////////////////////////////////////////////////////////////////// |
| 20 | void CDynamicResponseProxy::Initialize(SComponentInitializer const& init) |
| 21 | { |
| 22 | const char* szEntityName = init.m_pEntity->GetName(); |
| 23 | m_pResponseActor = gEnv->pDynamicResponseSystem->GetResponseActor(szEntityName); |
| 24 | if (m_pResponseActor) |
| 25 | { |
| 26 | CryWarning(VALIDATOR_MODULE_DRS, VALIDATOR_ERROR_DBGBRK, "DrsActor with name '%s' already exists. Actors need to have unique names to be referenced correctly", szEntityName); |
| 27 | } |
| 28 | else |
| 29 | { |
| 30 | m_pResponseActor = gEnv->pDynamicResponseSystem->CreateResponseActor(szEntityName, init.m_pEntity->GetId()); |
| 31 | } |
| 32 | SET_DRS_USER_SCOPED("DrsProxy Initialize"); |
| 33 | m_pResponseActor->GetLocalVariables()->SetVariableValue("Name", CHashedString(szEntityName)); |
| 34 | } |
| 35 | |
| 36 | ////////////////////////////////////////////////////////////////////////// |
| 37 | void CDynamicResponseProxy::Reload(IEntity* pEntity, SEntitySpawnParams& params) |
nothing calls this directly
no test coverage detected