Revision Difference
CTakeDamageInfo:GetInflictor#563412
<function name="GetInflictor" parent="CTakeDamageInfo" type="classfunc">
<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 <page text="GetAttacker">CTakeDamageInfo:GetAttacker</page> with <page text="GetActiveWeapon">Player:GetActiveWeapon</page>.⤶
⤶
For projectile weapons this is the projectile.⤶
⤶
For a more reliable method of getting the weapon that damaged an entity, use <page>CTakeDamageInfo:GetWeapon</page> or <page text="GetAttacker">CTakeDamageInfo:GetAttacker</page> with <page text="GetActiveWeapon">Player:GetActiveWeapon</page>.
</description>
<realm>Shared</realm>
<rets>
<ret name="" type="Entity">The inflictor</ret>⤶
<ret name="" type="Entity">The inflictor entity.</ret>⤶
</rets>
</function>