Player hurt

From EventScripts Community Encyclopedia

Description

player_hurt executes EVERY TIME A PLAYER IS HURT, and also executes on EVERY PLAYER THAT IS HURT

Variables

Variables Specific to player_hurt That Are Expanded:

     event_var(userid)
           The userid of the person that was attacked (the victim)
     event_var(attacker)
           The userid of the attacker
     event_var(weapon)
           The weapon name the attacker used to hurt the player
     event_var(health)
           The remaining health of the victim
     event_var(dmg_health) // for DOD:S event_var(damage)
           How much damage was done to the victim (per hit)
     event_var(armor)
           The remaining armor value of the victim after being damaged
     event_var(dmg_armor)  // not working at DOD:S
           How much damage was done to the armor of the victim (per hit)
     event_var(hitgroup)
           Which limb was damaged on the victim

For the values of event_var(hitgroup), see Hit_Groups.

Variables Specific to the "victim":

     event_var(es_username)
           The name of the person that was attacked
     event_var(es_steamid)
           The steamid of the person that was attacked
     event_var(es_userteam)
           The team # of the person that was attacked
     event_var(es_userhealth)
           The health of the person that was attacked
     event_var(es_userarmor)
           The armor of the person that was attacked
     event_var(es_userdeaths)
           The number of deaths of the person that was attacked
     event_var(es_userkills)
           The number of kills of the person that was attacked
     event_var(es_userweapon)
           The name of the victim's weapon
     event_var(es_userdead)
           "0" if the victim is alive and "1" if the victim is dead


Variables Specific to the "attacker":

     event_var(es_attackername)
           The name of the person that attacked the victim
     event_var(es_attackersteamid)
           The steamid of the person that was attacking
     event_var(es_attackerteam)
           The team # of the person that was attacking
     event_var(es_attackerhealth)
           The health of the person that was attacking
     event_var(es_attackerarmor)
           The armor of the person that was attacking
     event_var(es_attackerdeaths)
           The number of deaths of the person that was attacking
     event_var(es_attackerkills)
           The number of kills of the person that was attacking
     event_var(es_attackerweapon)
           The name of the attacker's weapon
     event_var(es_attackerdead)
           "0" if the attacker is alive and "1" if the attacker is dead
blog comments powered by Disqus