OnSniperRifleFired: Difference between revisions
(Created page with "{{Welcome| desc=This function is called when a player fires a sniper rifle. This function is not called if the npc itself is firing the sniper rifle using FireSniperRifle....") |
No edit summary |
||
Line 12: | Line 12: | ||
::dz : The z component of the normalized direction vector multiplied by 16.0 | ::dz : The z component of the normalized direction vector multiplied by 16.0 | ||
</poem>| | </poem>| | ||
retvals= | retvals=event| | ||
}} | }} |
Revision as of 11:41, 27 November 2022
Description:
This function is called when a player fires a sniper rifle. This function is not called if the npc itself is firing the sniper rifle using FireSniperRifle. If more than one npc is there, this function gets called when other npcs fire sniper rifle using FireSniperRifle.
Parameters:
( playerid, weaponid, x, y, z, dx, dy, dz ) )
playerId : The ID of the player who fired
weaponid: The ID of the weapon fired. ( Usually 28 or 29 )
x : The source x co-ordinate of the firing.
y : The source y co-ordinate of the firing.
z : The source z co-ordinate of the firing
dx : The x component of the normalized direction vector multiplied by 16.0
dy : The y component of the normalized direction vector multiplied by 16.0
dz : The z component of the normalized direction vector multiplied by 16.0