04.03.2009, 09:33
This is what i have:
I get this error:
error 035: argument type mismatch (argument 2)
on this line:
SetVehicleNumberPlate(vehid, plate);
Can anyone help me?
pawn Код:
else if(strcmp(x_nr,"plates",true) == 0)
{
if(PlayerInfo[playerid][pPcarkey] == 999 && PlayerInfo[playerid][pPcarkey2] == 999 && PlayerInfo[playerid][pPcarkey3] == 999)
{
SendClientMessage(playerid, COLOR_GREY," You don't have a vehicle to buy new plates for.");
return 1;
}
if(GetPlayerMoney(playerid) < 4999)
{
SendClientMessage(playerid, COLOR_GREY," You don't have enough money to buy new plates.");
return 1;
}
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_WHITE, "USAGE: /v plates [Numberplate]");
return 1;
}
new plate;
plate = strval(tmp);
new vehid;
if(GetPlayerVehicleID(playerid) == PlayerInfo[playerid][pPcarkey]) { vehid = PlayerInfo[playerid][pPcarkey]; }
else if(GetPlayerVehicleID(playerid) == PlayerInfo[playerid][pPcarkey2]) { vehid = PlayerInfo[playerid][pPcarkey2]; }
else if(GetPlayerVehicleID(playerid) == PlayerInfo[playerid][pPcarkey3]) { vehid = PlayerInfo[playerid][pPcarkey3]; }
else { return 1; }
if(IsPlayerInVehicle(playerid, vehid))
{
SetVehicleNumberPlate(vehid, plate);
CarInfo[vehid][cLicense] = plate;
SafeGivePlayerMoney(playerid, -5000);
GameTextForPlayer(playerid, "~w~Bill for New Plates~n~~r~-$5000", 5000, 1);
OnPropUpdate();
OnPlayerUpdate(playerid);
return 1;
}
else
{
SendClientMessage(playerid, COLOR_GREY," You are not in your vehicle.");
return 1;
}
}
else
{
SendClientMessage(playerid, COLOR_WHITE, "HINT: (/v)ehicle [name]");
SendClientMessage(playerid, COLOR_WHITE, "Available names: park, lock(1-3), sell, sellto, color");
return 1;
}
}
return 1;
}
error 035: argument type mismatch (argument 2)
on this line:
SetVehicleNumberPlate(vehid, plate);
Can anyone help me?