24.07.2011, 15:16
PHP код:
public OnPlayerStateChange(playerid, newstate, oldstate)
{
new vehicleid = GetPlayerVehicleID(playerid);
new pname[MAX_PLAYER_NAME];
GetPlayerName(playerid, pname, sizeof pname);
if(newstate == PLAYER_STATE_DRIVER)
{
if(vehicleid == vehicle)
{
new mpp;
new carsid = mpp;
if(strcmp(pname, "%d", carsid, true) == 0)
{
return 1;
}
else
{
RemovePlayerFromVehicle(playerid);
new string[50];
format(string, sizeof(string), "~r~This car is private!");
GameTextForPlayer(playerid, string, 3000, 4);
}
}
}
return 1;
}
Quote:
C:\Users\mega\Desktop\1\gamemodes\grandlarc.pwn(65 5) : warning 213: tag mismatch |
PHP код:
if(strcmp(pname, "%d", carsid, true) == 0)