Skip to content

event onPlayerHit (client-side)

Available since version: 0.1.2

This event can be canceled


In case when other connected player damages any other player or npc, this event cannot be cancelled!


In case when user damages any other connected player and this event is cancelled, the server will not get notified!

This event is triggered when a player or npc is damaged.


int killerid, int playerid, int damage
  • int killerid: the id of the killer. If killerid is set to -1, it means that there was no killer. In this particular case damage source can be fall from a tall object or scripts.
  • int playerid: the id of the player who was damaged.
  • int damage: a value representing the amount of health the player lost.