SDKHooks_TakeDamage Function

Applies damage to an entity

void SDKHooks_TakeDamage(int entity, int inflictor, int attacker, float damage, int damageType, int weapon, const float damageForce[3], const float damagePosition[3])


int entity

Entity index taking damage

int inflictor

Inflictor entity index

int attacker

Attacker entity index

float damage

Amount of damage

int damageType

Bitfield of damage types

int weapon

Weapon index (orangebox and later) or -1 for unspecified

const float[3] damageForce

Velocity of damage force

const float[3] damagePosition

Origin of damage


Force application is dependent on game and damage type(s)