Dealership Vehicles. - 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)
+--- Thread: Dealership Vehicles. (
/showthread.php?tid=499312)
Dealership Vehicles. -
VerticalGaming - 07.03.2014
Hello there..
When a player selects a vehicle, It will create an vehicle as show model.
For example the freeway:
Код:
DLCar[11] = CreateVehicle(463,347.5634,2935.0889,1046.5648,90.6536,0,0, 2000); //
When he cancels it, even if he buys it.. the show model will be killed. (That correct)
Now the problem is, If 2 players are selecting cars, it will not show that vehicle for the desired player.
Somebody knows a way, so i can show them for both?
I was thinking about DLCar[11] changing the ''11" to the playerID + 1000.
But their might be a bether way tho'.
Can somebody help me out?
Edit; everyone is in a different VW, when selecting cars.. and they might select different models.
Respuesta: Dealership Vehicles. -
[CG]Milito - 07.03.2014
Create a variable for all the players
DLCar[MAX_PLAYERS]
Re: Dealership Vehicles. -
VerticalGaming - 07.03.2014
I did.. But how do i use it now with Createvehicle & Destroy vehicle etc?
Re: Dealership Vehicles. -
VerticalGaming - 07.03.2014
?
Re: Dealership Vehicles. -
Abagail - 07.03.2014
You can do it like this if you wanna be creative:
new DLCar1;
DLCar1 = ...
DLCar[playerid] = DLCar1;
Or something like that... Basically your making a variable to place into the player's variable. What DLCar[playerid] should be is the modelID if done correctly... And such...