SA-MP Forums Archive
[BUG] Vehicle Position/Roation Sync - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [BUG] Vehicle Position/Roation Sync (/showthread.php?tid=198279)



[BUG] Vehicle Position/Roation Sync - [NeS]Justin - 11.12.2010

Hello,

i found out some vehicle synchronisation problems since the new streaming system in 0.3a...

some explanation:

Код:
public UpdateVehicleAfterNumberplateChange(vehicleid)
{
	new Float:x, Float:y, Float:z, Float:rot;
	GetVehiclePos(vehicleid, x, y, z);
 	GetVehicleZAngle(vehicleid, rot);
 	SetVehicleToRespawn(vehicleid);
 	SetVehiclePos(vehicleid, x,y,z);
 	SetVehicleZAngle(vehicleid, rot);
	return 1;
}
When i use this function. Affected vehicles wont sync properly to players who werent streamed in to the vehicle when it respawned. (position and rotation)

>> Explanation 2:
-player x exits the vehicle and enters an interior
-change vehicle numberplate and respawn it (using function above) while player is in Interior
-player x exits interior and see the vehicle with wrong ZAngle and some Coordinates near the original one

Sorry if someone else already reported this bug!
I hope this "bug" could be fixed in the upcoming release 0.3c and sry for my noobish english


Re: [BUG] Vehicle Position/Roation Sync - Finn - 11.12.2010

Yeah, I've noticed this happening since 0.3 came out.

After respawn cars are spawned in correct positions, but rotations are all f*ckd up.


Re: [BUG] Vehicle Position/Roation Sync - [NeS]Justin - 11.12.2010

In this case positions are bugged too


AW: [BUG] Vehicle Position/Roation Sync - [Nino] - 11.12.2010

Noticed it since 0.3a too..^^


Re: [BUG] Vehicle Position/Roation Sync - WillyP - 11.12.2010

I havn't seen this before. :S


Re: [BUG] Vehicle Position/Roation Sync - [NeS]Justin - 11.12.2010

you can use my code snippet and test it by yourself ^^


Re: [BUG] Vehicle Position/Roation Sync - WillyP - 11.12.2010

Quote:
Originally Posted by JayTea
Посмотреть сообщение
you can use my code snippet and test it by yourself ^^
Nah, I'm finalizing my TDM atm.


Re: [BUG] Vehicle Position/Roation Sync - Ash. - 11.12.2010

Quote:
Originally Posted by JayTea
Посмотреть сообщение
Hello,

i found out some vehicle synchronisation problems since the new streaming system in 0.3a...

some explanation:

Код:
public UpdateVehicleAfterNumberplateChange(vehicleid)
{
	new Float:x, Float:y, Float:z, Float:rot;
	GetVehiclePos(vehicleid, x, y, z);
 	GetVehicleZAngle(vehicleid, rot);
 	SetVehicleToRespawn(vehicleid);
 	SetVehiclePos(vehicleid, x,y,z);
 	SetVehicleZAngle(vehicleid, rot);
	return 1;
}
When i use this function. Affected vehicles wont sync properly to players who werent streamed in to the vehicle when it respawned. (position and rotation)

>> Explanation 2:
-player x exits the vehicle and enters an interior
-change vehicle numberplate and respawn it (using function above) while player is in Interior
-player x exits interior and see the vehicle with wrong ZAngle and some Coordinates near the original one

Sorry if someone else already reported this bug!
I hope this "bug" could be fixed in the upcoming release 0.3c and sry for my noobish english
I agree with this, but normally the rotations arent VERY different, its only a couple of degrees... - Which makes me think it could just be the way they land after respawn (they drop about 0.1 meters to reach floor usually)


Re: [BUG] Vehicle Position/Roation Sync - Redirect Left - 11.12.2010

I've had this since 0.3a too. Although the rotations are usually off by very miniscule amounts (around 5 either way) so doesn't make too much difference.


Re: [BUG] Vehicle Position/Roation Sync - [NeS]Justin - 11.12.2010

ye i hope they could find the bug soon ^^