Teleporting vehicle to interior - player not synced
#1

Hi guys. So here's my problem: When I teleport a player in vehicle to an interior he is paused for other players. (Same problem as here). Player can move around but he is not synced with other players. When a player exits the vehicle he is synced for all players. This is on a GL gamemode with no filterscripts nor plugins loaded.

pawn Код:
//command
new vehicleid = GetPlayerVehicleID(playerid);
//RemovePlayerFromVehicle(playerid);
//ClearAnimations(playerid);
//SetTimerEx("TeleTimer", 3000, false, "dd", playerid, vehicleid);
LinkVehicleToInterior(vehicleid, 15);
SetVehiclePos(vehicleid, -1488.8818,950.7721,1036.4448);
SetPlayerInterior(playerid,15);
//PutPlayerInVehicle(playerid, vehicleid, 0);
return 1;
Image : /imageshack/img827/5907/32da.png
Reply
#2

Ha? what do you mean?
Reply
#3

Quote:
Originally Posted by Antonio144
Посмотреть сообщение
Hi guys. So here's my problem: When I teleport a player in vehicle to an interior he is paused for other players. (Same problem as here). Player can move around but he is not synced with other players. When a player exits the vehicle he is synced for all players. This is on a GL gamemode with no filterscripts nor plugins loaded.

pawn Код:
//command
new vehicleid = GetPlayerVehicleID(playerid);
//RemovePlayerFromVehicle(playerid);
//ClearAnimations(playerid);
//SetTimerEx("TeleTimer", 3000, false, "dd", playerid, vehicleid);
LinkVehicleToInterior(vehicleid, 15);
SetVehiclePos(vehicleid, -1488.8818,950.7721,1036.4448);
SetPlayerInterior(playerid,15);
//PutPlayerInVehicle(playerid, vehicleid, 0);
return 1;
Image : /imageshack/img827/5907/32da.png
- Don't forget to teleport the player into those cords aswell. && Why did you comment out the rest i.e ''PutPlayerInVehicle''.
Reply
#4

Added SetPlayerPos, uncommented, still the same.
Here's a video showing my problem: [ame]http://www.youtube.com/watch?v=8y2A1MIvh-M[/ame]
Reply
#5

Lemme guess, i think this will solve your problem.
pawn Код:
public OnPlayerInteriorChange(playerid,newinteriorid,oldinteriorid)
{
   //Do something here.
}
i dont experience this kind of situation.
Reply
#6

When I teleport back from that interior and use that command again, it works, which made me assume that the interior needs to load before putting player in vehicle. So this is the only way I could make it work:
pawn Код:
new vehicleid = GetPlayerVehicleID(playerid);
RemovePlayerFromVehicle(playerid);
SetPlayerInterior(playerid,15);
SetPlayerPos(playerid, -1488.8818,950.7721,1036.4448);
LinkVehicleToInterior(vehicleid, 15);
SetVehiclePos(vehicleid, -1488.8818,950.7721,1036.4448);
SetTimerEx("TeleTimer", 700, false, "dd", playerid, vehicleid);

forward TeleTimer(playerid, vehicleid);
public TeleTimer(playerid, vehicleid) return PutPlayerInVehicle(playerid, vehicleid, 0);
Does anybody know how to increase ping on a local network? Maybe spamming my network with useless packages?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)