31.01.2010, 09:11
This will work for car with model 402(buffalo).
The player will lose control as they enter the vehicle.
I assume that is what has happened now.
There are two options for locking a car,
Either
There is also a physical door lock system in samp using:
https://sampwiki.blast.hk/wiki/SetVehicleParamsForPlayer
https://sampwiki.blast.hk/wiki/OnVehicleStreamIn
The player will lose control as they enter the vehicle.
I assume that is what has happened now.
There are two options for locking a car,
Either
Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER)
{
new vehicleid = GetPlayerVehicleID(playerid);
switch(GetVehicleModel(vehicleid))
{
case 402:
{
SendClientMessage(playerid, 0x33AA33AA, "Vehicle locked!");
RemovePlayerFromVehicle(playerid);
}
}
}
return 1;
}
https://sampwiki.blast.hk/wiki/SetVehicleParamsForPlayer
https://sampwiki.blast.hk/wiki/OnVehicleStreamIn

