Garry's Mod Wiki

CTakeDamageInfo:SetWeapon

Recently Added

This was recently added in version (2025.01.15). It might only be available on the Dev Branch right now.

Description

Sets the damage-inflicting weapon of the damage event.

This should be a Weapon entity, not a projectile. See also CTakeDamageInfo:SetInflictor.

Arguments

1 Entity
The damage-inflicting weapon or NULL.