06.09.2013, 16:04
I want when player spawn a car and when he dissconect, his car dissapear
public OnPlayerSpawn(playerid)
{
new veh;
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
veh = CreateVehicle(451, x,y,z,0,1,1,0); //This will spawn turismo
PutPlayerInVehicle(playerid,veh,0);
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
new veh;
veh = GetPlayerVehicleID(playerid);
DestroyVehicle(veh);
return 1;
}