diff --git a/dlls/tripmine.cpp b/dlls/tripmine.cpp index 3a585412..a8390b88 100644 --- a/dlls/tripmine.cpp +++ b/dlls/tripmine.cpp @@ -267,9 +267,16 @@ void CTripmineGrenade::BeamBreakThink() // respawn detect. if (!m_pBeam) { + // Use the same trace parameters as the original trace above so the right entity is hit. + TraceResult tr2; + UTIL_TraceLine(pev->origin + m_vecDir * 8, pev->origin - m_vecDir * 32, dont_ignore_monsters, ENT(pev), &tr2); MakeBeam(); - if (tr.pHit) - m_hOwner = CBaseEntity::Instance(tr.pHit); // reset owner too + if (tr2.pHit) + { + // reset owner too + pev->owner = tr2.pHit; + m_hOwner = CBaseEntity::Instance(tr2.pHit); + } } if (fabs(m_flBeamLength - tr.flFraction) > 0.001)