Vice City Multiplayer

VC:MP => mIRC/pawn Scripting => ShowRoom (pawn) => Topic started by: Robd on January 27, 2011, 11:43:33 PM

Title: SetVehiclePos?!?!
Post by: Robd on January 27, 2011, 11:43:33 PM
This function doesnt seem to be working in any of my scripts  :S
Can someone help me?
Title: Re: SetVehiclePos?!?!
Post by: aXXo on January 29, 2011, 01:47:58 PM
It is a lil bit bugged.
It only works if you didnt enter a car.

If you enter a car once, SetVehiclePos wont work for that car....until you restart the server.

Also GetVehiclePos coordinates are desynced. It doesnt update the Vehicle coordinates when someone drives it.
Example: If you drove a car from its spawnloc to some other place...the GetVehiclePos still displays its spawn loc.

Though, the vehicle coordinates can be manually synced using a timer, or from OnPlayerEnter/ExitVehicle() functions.
Title: Re: SetVehiclePos?!?!
Post by: Robd on January 30, 2011, 02:03:49 AM
hmm, is there anyway around this?
something like maybe deleting the car and making an identical one

I've tried doing something like that but almost all car create functions appear to be bugged, any help appreciated, ty
Title: Re: SetVehiclePos?!?!
Post by: [GCK]KoFFe on January 30, 2011, 04:47:47 PM
its works when some one drives your car if you are owner you type !getcar bla bla id the server take u that car with driver on it  [mIRC/Pawn]  SetVehiclePos works i tryed it SO don't be noob
Title: Re: SetVehiclePos?!?!
Post by: sseebbyy on April 21, 2011, 09:41:40 AM
This is Solution  ;D

Credits: By Tato


SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
SetVehicleToRespawn(GetPlayerVehicleID(playerid));
RemovePlayerFromVehicle(playerid);
SetVehiclePos(SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
Title: Re: SetVehiclePos?!?!
Post by: stormeus on April 21, 2011, 09:25:53 PM
Nice bump; this thread hasn't been replied to in months. ::)
Also:
Quote from: sseebbyy on April 21, 2011, 09:41:40 AM
This is Solution  ;D

Credits: By Tato


SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
SetVehiclePos(SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);


He said SetVehiclePos doesn't work, so this code wouldn't work anyways.
Title: Re: SetVehiclePos?!?!
Post by: sseebbyy on April 21, 2011, 11:13:43 PM
Have you even tried?

And for your information, setvehiclepos works only once!

But with this command whenever you want go !
Title: Re: SetVehiclePos?!?!
Post by: tato on April 22, 2011, 04:48:08 AM
Quote from: sseebbyy on April 21, 2011, 09:41:40 AM
This is Solution  ;D

Credits: By Tato


SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
SetVehicleToRespawn(GetPlayerVehicleID(playerid));
RemovePlayerFromVehicle(playerid);
SetVehiclePos(SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);

:O i made that XD?! :D
Title: Re: SetVehiclePos?!?!
Post by: yazeen on April 22, 2011, 05:49:16 AM
Quote from: [GCK]KoFFe on January 30, 2011, 04:47:47 PM
its works when some one drives your car if you are owner you type !getcar bla bla id the server take u that car with driver on it  [mIRC/Pawn]  SetVehiclePos works i tryed it SO don't be noob

Maybe SetVehiclePos(id,GetPlayerPos(playerid);but SetVehiclePos(id,GetPlayerPos(playerid)x+3,y+3; Dosent work Got it i cant explain! But i got it
Title: Re: SetVehiclePos?!?!
Post by: tato on April 22, 2011, 08:14:26 AM
try this
SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
SetVehicleToRespawn(GetPlayerVehicleID(playerid));
RemovePlayerFromVehicle(playerid);
SetVehicleToRespawn(vehicleid);
SetVehiclePos(SetVehiclePos(GetPlayerVehicleID(playerid),X,Y,Z,Angle);
Title: Re: SetVehiclePos?!?!
Post by: sseebbyy on April 22, 2011, 09:20:10 AM
need 2 respawns ?  ???
Title: Re: SetVehiclePos?!?!
Post by: BaSSMaN on April 22, 2011, 03:27:20 PM
Lol? It works well for me without edits, so this topic is kinda useless :/.
Title: Re: SetVehiclePos?!?!
Post by: yazeen on April 22, 2011, 04:26:45 PM
Quote from: BaSSMaN on April 22, 2011, 03:27:20 PM
Lol? It works well for me without edits, so this topic is kinda useless :/.

WTF!? u mean More than 2 times like SetVehiclePos(id,blblablalba); Once the car is spawned u can spawn it again?
Title: Re: SetVehiclePos?!?!
Post by: BaSSMaN on April 22, 2011, 09:38:37 PM
Oops, it works one time yeah xD.
Fail sorry lol.
But who on earth would use /c addveh? I just add vehicles into dini..
Title: Re: SetVehiclePos?!?!
Post by: stormeus on April 22, 2011, 09:55:15 PM
I think we're starting to go a little off topic here. The topic creator hasn't been in this topic for three months, so it's safe to lock it.
Title: Re: SetVehiclePos?!?!
Post by: tato on April 22, 2011, 11:55:32 PM
Quote from: stormeus on April 22, 2011, 09:55:15 PM
I think we're starting to go a little off topic here. The topic creator hasn't been in this topic for three months, so it's safe to lock it.
i know huh XD i think my function works i don't know
Title: Re: SetVehiclePos?!?!
Post by: Morphine on April 23, 2011, 04:05:02 AM
Just one more thing - the car can spawn at it's original coordinates when it gets totaled, too, if that hasn't been stated yet.