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

Method SendHitAllowed

ogsr_engine/xrGame/ShootingObject.cpp:395–410  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

393}
394
395bool CShootingObject::SendHitAllowed(CObject* pUser)
396{
397 if (Game().IsServerControlHits())
398 return true;
399
400 {
401 if (pUser->CLS_ID == CLSID_OBJECT_ACTOR)
402 {
403 if (Level().CurrentControlEntity() != pUser)
404 {
405 return false;
406 }
407 }
408 return true;
409 }
410};
411
412void CShootingObject::FireBullet(const Fvector& pos, const Fvector& shot_dir, float fire_disp, const CCartridge& cartridge, u16 parent_id, u16 weapon_id, bool send_hit)
413{

Callers

nothing calls this directly

Calls 2

CurrentControlEntityMethod · 0.80
IsServerControlHitsMethod · 0.45

Tested by

no test coverage detected