function
hitPlayer (server-side)
Available since version: 0.3.0
Note
attacker and victim must be in stream range (spawned), otherwise damage action won't perform.
This function is used to simulate hit between attacker and victim. It will only work with if killer or victim is a real player. The victim will receive damage calculated damage by the game.
Declaration
bool hitPlayer(int attackerId, int victimId)
Parameters
int
attackerId: the attacker id.int
victimId: the victim id.
Returns bool
true
if hit was successfully simulated, otherwise false
.