16.07.2013, 21:59
pawn Код:
if(newstate == PLAYER_STATE_DRIVER)
{
new pname[MAX_PLAYER_NAME];
GetPlayerName(playerid, pname, sizeof(pname));
new v = GetPlayerVehicleID(playerid);
if(v == name1car || v == Name2)
{
if(!strcmp(pname, "Name1", true) || !strcmp(pname, "Name2", true))
{
SendClientMessage(playerid, COLOR_RED, "Welcome to your car");
}
else
{
SendClientMessage(playerid, COLOR_RED, "This car is private.");
RemovePlayerFromVehicle(playerid);
}
}
return 1;
}