put player in car problem
#1

Hello,
I have Been Trying to create a cmd thats create car and after i left car i wan't to go back to the car with out opening the door
Reply
#2

https://sampwiki.blast.hk/wiki/PutPlayerInVehicle
Reply
#3

Yeah I Try it but i need to get the id of the vehicle to put me on it right ?
soo how can i get the id of the car without getplayervehicleID ?
Reply
#4

PHP код:
new thevehicle;//Where the vehicle id will be stored.

//UNDER SOME CALLBACK
thevehicle CreateVehicle(422....///ETC);



//UNDER ANOTHER CALLBACK
PutPlayerInVehicle(thevehicle, ...//ETC); 
Reply
#5

Use this on your command exept CreateVehicle(...

PHP код:
    SetPVarInt(playerid,"SpawnedCar",CreateVehicle(411,...)); 
Then use this when you want to put player in it
PHP код:
    PutPlayerInVehicle(playerid,GetPVarInt(playerid,"SpawnedCar"),0); 
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)