CTakeDamageInfo:GetInflictor
Description
Returns the inflictor of the damage. This is not necessarily a weapon.
For hitscan weapons this is the weapon.
For projectile weapons this is the projectile.
For a more reliable method of getting the weapon that damaged an entity, use GetAttacker with GetActiveWeapon.