SendOnFootSyncData: Difference between revisions
No edit summary |
mNo edit summary |
||
Line 2: | Line 2: | ||
desc=This will send a packet to server which is filled by the following parameters.| | desc=This will send a packet to server which is filled by the following parameters.| | ||
params=<syntaxhighlight lang="lua">(keys, posX, posY, posZ, angle, health, armour, weapon, speedX, speedY, speedZ, aimPosX, aimPosY, aimPosZ, aimDirX, aimDirY, aimDirZ)</syntaxhighlight> | params=<syntaxhighlight lang="lua">(keys, posX, posY, posZ, angle, health, armour, weapon, speedX, speedY, speedZ, aimPosX, aimPosY, aimPosZ, aimDirX, aimDirY, aimDirZ)</syntaxhighlight> | ||
<poem>::keys[integer] : The players Game Keys to hold. | <poem>::keys [integer] : The players Game Keys to hold. | ||
::posX[float] : The npc's position x co-ordinate. | ::posX [float] : The npc's position x co-ordinate. | ||
::posY[float] : The npc's position y co-ordinate. | ::posY [float] : The npc's position y co-ordinate. | ||
::posZ[float] : The npc's position z co-ordinate. | ::posZ [float] : The npc's position z co-ordinate. | ||
::angle[float] : The npc's facing angle in radians.(-PI to PI ). | ::angle [float] : The npc's facing angle in radians.(-PI to PI ). | ||
::health[integer] : Health of the npc. | ::health [integer] : Health of the npc. | ||
::armour[integer] : Armour of the npc. | ::armour [integer] : Armour of the npc. | ||
::weapon[integer] : Weapon of the npc. | ::weapon [integer] : Weapon of the npc. | ||
::speedX[float] : The npc's speed in x direction (supposed to be same as player.Speed.x on serverside ) | ::speedX [float] : The npc's speed in x direction (supposed to be same as player.Speed.x on serverside ) | ||
::speedY[float] : The npc's speed in y direction ( " ) | ::speedY [float] : The npc's speed in y direction ( " ) | ||
::speedZ[float] : The npc's speed in z direction ( " ) | ::speedZ [float] : The npc's speed in z direction ( " ) | ||
::aimPosX[float] : The x co-ordinate of aim position of NPC ( can be determined using server using player.AimPos or can be calculated artificially). | ::aimPosX [float] : The x co-ordinate of aim position of NPC ( can be determined using server using player.AimPos or can be calculated artificially). | ||
::aimPosY[float] : The y co-ordinate of aim position of NPC | ::aimPosY [float] : The y co-ordinate of aim position of NPC | ||
::aimPosZ[float] : The z co-ordinate of aim position of NPC | ::aimPosZ [float] : The z co-ordinate of aim position of NPC | ||
::aimDirX[float] : The x value given by player.AimDir. (It is mostly 0 or PI ) | ::aimDirX [float] : The x value given by player.AimDir. (It is mostly 0 or PI ) | ||
::aimDirY[float] : The y value given by player.AimDir. | ::aimDirY [float] : The y value given by player.AimDir. | ||
::aimDirZ[float] : The z value given by player.AimDir. (usually ranges from -PI/2 to PI/2) | ::aimDirZ [float] : The z value given by player.AimDir. (usually ranges from -PI/2 to PI/2) | ||
</poem>| | </poem>| | ||
note=This was added in v2.0 and will not work in previous builds.| | note=This was added in v2.0 and will not work in previous builds.| | ||
}} | }} |
Revision as of 09:48, 13 November 2022
Description:
This will send a packet to server which is filled by the following parameters.
Parameters:
(keys, posX, posY, posZ, angle, health, armour, weapon, speedX, speedY, speedZ, aimPosX, aimPosY, aimPosZ, aimDirX, aimDirY, aimDirZ)
keys [integer] : The players Game Keys to hold.
posX [float] : The npc's position x co-ordinate.
posY [float] : The npc's position y co-ordinate.
posZ [float] : The npc's position z co-ordinate.
angle [float] : The npc's facing angle in radians.(-PI to PI ).
health [integer] : Health of the npc.
armour [integer] : Armour of the npc.
weapon [integer] : Weapon of the npc.
speedX [float] : The npc's speed in x direction (supposed to be same as player.Speed.x on serverside )
speedY [float] : The npc's speed in y direction ( " )
speedZ [float] : The npc's speed in z direction ( " )
aimPosX [float] : The x co-ordinate of aim position of NPC ( can be determined using server using player.AimPos or can be calculated artificially).
aimPosY [float] : The y co-ordinate of aim position of NPC
aimPosZ [float] : The z co-ordinate of aim position of NPC
aimDirX [float] : The x value given by player.AimDir. (It is mostly 0 or PI )
aimDirY [float] : The y value given by player.AimDir.
aimDirZ [float] : The z value given by player.AimDir. (usually ranges from -PI/2 to PI/2)
Return Values:
This function does not return any specific values.
Important Note:
This was added in v2.0 and will not work in previous builds.