Really annoying problem -
SparkZ_ - 05.12.2010
Hi, well..
I'm having an annoying problem with vehicles...
Well, basically I have a skyroad and everytime I teleport to it, they fall threw there spawn point, it's really annoying, i tried raising the height of the vehicles in map editor, but it failed.
Any ideas, of how I can fix it ?
Re: Really annoying problem -
NewYorkRP - 05.12.2010
instead of spawning them, when they teleport to /skyroad, make it create a vehicle, and put them in it ..
thats one solution
Re: Really annoying problem -
SparkZ_ - 05.12.2010
Quote:
Originally Posted by NewYorkRP
instead of spawning them, when they teleport to /skyroad, make it create a vehicle, and put them in it ..
thats one solution
|
I'd rather keep the vehicles on the carpark, when the player teleports there:
Ehh, anyway I use this code:
pawn Код:
if (strcmp("/cj", cmdtext, true) == 0)
{ if(GetPlayerState(playerid) == PLAYER_STATE_PASSENGER)
{
SendClientMessage(playerid,red,"You must be the driver or on foot to use this command");
}
else if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT || PLAYER_STATE_DRIVER)
{
SendClientMessage(playerid,coloryellow,"You have teleported to (/cj)");
SendClientMessage(playerid,red,"Chilliad Jump");
new getv = GetPlayerVehicleID(playerid);
SetVehiclePos(getv,-3013.7920,-1590.9929,945.6582+3);
SetPlayerPos(playerid,-3013.7920,-1590.9929,945.6582+3);
PutPlayerInVehicle(playerid,getv,0);
}
return 1;
}
It teleports the players vehicle with him too.
Re: Really annoying problem -
SparkZ_ - 05.12.2010
Anymore suggestions

?
Re: Really annoying problem -
Sinner - 05.12.2010
I use incognito's streamer to pre-stream the objects before teleporting the player, so when the player teleports the objects are already there, this method never seems to fail.
Here's in a nutshell how it goes:
1. Get the teleport position (x, y, z)
2. Pre-stream the objects at the teleport position with Streamer_updateEx(x, y, z)
3. Teleport the player (optionally put in a timer to make the player wait a little to give the streamer a little time to stream the objects)
The method our server uses is a lot more complicated but it all comes down to that ^^
Re: Really annoying problem -
SparkZ_ - 05.12.2010
Quote:
Originally Posted by Sinner
I use incognito's streamer to pre-stream the objects before teleporting the player, so when the player teleports the objects are already there, this method never seems to fail.
Here's in a nutshell how it goes:
1. Get the teleport position (x, y, z)
2. Pre-stream the objects at the teleport position with Streamer_updateEx(x, y, z)
3. Teleport the player (optionally put in a timer to make the player wait a little to give the streamer a little time to stream the objects)
The method our server uses is a lot more complicated but it all comes down to that ^^
|
Thanks, I'll try it.
And anymore suggestions though ?