MCPcopy Create free account
hub / github.com/OGSR/OGSR-Engine / SpawnCopy

Method SpawnCopy

ogsr_engine/xrGame/PHSkeleton.cpp:332–351  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

330}
331
332void CPHSkeleton::SpawnCopy()
333{
334 if (PPhysicsShellHolder()->Local())
335 {
336 CSE_Abstract* D = F_entity_Create("ph_skeleton_object"); //*cNameSect()
337 R_ASSERT(D);
338 /////////////////////////////////////////////////////////////////////////////////////////////
339 CSE_ALifePHSkeletonObject* l_tpALifePhysicObject = smart_cast<CSE_ALifePHSkeletonObject*>(D);
340 R_ASSERT(l_tpALifePhysicObject);
341 l_tpALifePhysicObject->_flags.set(CSE_PHSkeleton::flSpawnCopy, 1);
342 /////////////////////////////////////////////////////////////////////////////////////////////
343 InitServerObject(D);
344 // Send
345 NET_Packet P;
346 D->Spawn_Write(P, TRUE);
347 Level().Send(P, net_flags(TRUE));
348 // Destroy
349 F_entity_Destroy(D);
350 }
351}
352
353PHSHELL_PAIR_VECTOR new_shells;
354

Callers

nothing calls this directly

Calls 7

F_entity_CreateFunction · 0.85
net_flagsFunction · 0.85
F_entity_DestroyFunction · 0.85
Spawn_WriteMethod · 0.80
PPhysicsShellHolderFunction · 0.70
setMethod · 0.45
SendMethod · 0.45

Tested by

no test coverage detected