29.08.2015, 00:10
There you go:
pawn Код:
new VehicleLastDriver[MAX_VEHICLES]; //put this at the top of the script
public OnPlayerStateChange(playerid, newstate, oldstate)
{
if(newstate == PLAYER_STATE_DRIVER)
{
if(GetPlayerVehicleID(playerid) != 0)
{
VehicleLastDriver[GetPlayerVehicleID(playerid)] = playerid;
}
}
return 1;
}