openmultiplayer / open.mp

Open Multiplayer, a multiplayer mod fully backwards compatible with SA-MP
https://open.mp
Mozilla Public License 2.0
450 stars 90 forks source link

[Behavioural difference] `Move(Player)Object` rotation #749

Closed xunder-matth closed 10 months ago

xunder-matth commented 10 months ago

The rotation parameters for Move(Player)Object functions are optional and are set to -1000.0 by default. In SA-MP server, any default value given is internally converted to the actual object rotation, and then the server sends the MoveObject RPC to the client with the correct rotation values. In open.mp server, the -1000.0 value is not changed to the real object rotation value, resulting in the client receiving an RPC with incorrect rotation parameters.

AmyrAhmady commented 10 months ago

I can't find it anywhere in samp server where it filters out rotation values and send real object rotation to client

xunder-matth commented 10 months ago

Incoming RPC from open.mp server:

wObjectID=31, x=283.862609, y=3017.552490, z=8.143922, target_X=286.371429, target_Y=3015.671386, target_Z=8.143922, speed=2.000000, target_rX=-1000.000000, target_rY=134.166275, target_rZ=-58.566345

Incoming RPC from SA-MP server:

wObjectID=31, x=283.862609, y=3017.552490, z=8.143922, target_X=286.371429, target_Y=3015.671386, target_Z=8.143922, speed=2.000000, target_rX=90.000000, target_rY=134.166275, target_rZ=-58.566345

The original rotation of the object on the X-axis was 90.0 deg.

AmyrAhmady commented 10 months ago

Fixed in next release and nightly