20.03.2011, 10:33
596 is the modelid not the vehicleid.
pawn Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
if(GetVehicleModel(vehicleid) == 596) // If the model of the vehicleid is 596 (LA police)
{
if(PlayerInfo[playerid][pFaction] != 1)
{
new Float:X, Float:Y, Float:Z;
GetPlayerPos(playerid, X, Y, Z);
SetPlayerPos(playerid, X, Y, Z);
SendClientMessage(playerid, COLOR_GREY, "YOU DONT HAVE THE KEYS");
}
}
}