SendInCarSyncData

From NPC for VCMP 0.4 Servers
Revision as of 14:21, 4 January 2023 by Habi (talk | contribs) (Created page with "{{Welcome| desc=This will send an in-car sync packet to server which is filled by the following parameters.| params=<syntaxhighlight lang="lua">( keys, health, armour, weapon,...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


Description:
This will send an in-car sync packet to server which is filled by the following parameters.


Parameters:

( keys, health, armour, weapon, ammo, carhealth, cardamage, x, y, z, rotx, roty, rotz, rotw, speedx, speedy, speedz, turretx, turrety )

keys : The npc's Game Keys to hold.
health : The npc's health.( in subsequent packets, it can be decreased but do not increase )
armour  : The npc's armour.
weapon  : The weapon of npc.
ammo : The weapon's ammo.
carhealth : Health of the vehicle in which npc is driver. (0-1000.0)
damage : The vehicle's damage.
x : The x co-ordinate of the vehicle.
y : The y co-ordinate of the vehicle.
z : The z co-ordinate of the vehicle.
rotx : The x co-ordinate of the quaternion rotation of the vehicle.
roty : The y co-ordinate of the quaternion rotation of the vehicle.
rotz : The z co-ordinate of the quaternion rotation of the vehicle.
rotw : The w co-ordinate of the quaternion rotation of the vehicle.
speedx : The vehicle's speed x co-ordinate.
speedy : The vehicle's speed y co-ordinate.
speedz : The vehicle's speed z co-ordinate.
turretx : The float value turretx
turrety : The float value turrety


Return Values:
This function does not return any specific values.

Important Note:
This was added in v1.6

Example

Related Functions

The following functions may be helpful as they relate to this function in one way or another.