error 035: argument type mismatch (argument 1)
#1

So i have the same line with "playerid" instead of "giveplayer" and there is no error,only on this line:
Код:
GivePlayerMoney(giveplayer, RepairPrice[playerid]);
(error 035: argument type mismatch (argument 1))

Do you know what is problem?
So i know that giveplayer is string,but how can i add him money?

Код:
COMMAND:prihvatipopravku(playerid, params[])
{
    If(RepairOffer[playerid] < 999)
    {
            If(GetPlayerMoney(playerid) > RepairPrice[playerid])
	        {
	            If(IsPlayerInAnyVehicle(playerid))
       			{
					new sendername[MAX_PLAYER_NAME];
				 	new RepairCar[MAX_PLAYERS];
					new giveplayer[MAX_PLAYER_NAME],string[256];
					GetPlayerName(RepairOffer[playerid], giveplayer, sizeof(giveplayer));
					GetPlayerName(playerid, sendername, sizeof(sendername));
					RepairCar[playerid] = GetPlayerVehicleID(playerid);
					RepairVehicle(RepairCar[playerid]);
					format(string, sizeof(string), "{0049FF}[Popravka] {FFFFFF}Vase auto je popravljeno za $%d od strane mehanicara %s.",RepairPrice[playerid],giveplayer);
					SCM(playerid, PLAVA, string);
					format(string, sizeof(string), "{0049FF}[Popravka] {FFFFFF}Popravio si %s-ovo auto za $%d.",sendername,RepairPrice[playerid]);
					SCM(RepairOffer[playerid], PLAVA, string);
					//SafeGivePlayerMoney(giveplayer, RepairPrice[playerid]);
					SafeGivePlayerMoney(playerid, -RepairPrice[playerid]);
					RepairOffer[playerid] = 999;
					RepairPrice[playerid] = 0;
					Return 1;
                }
            }
	        Else Return SCM(playerid, CRVENA, "{00A6FF}divClient: {FFFFFF}Nemas dovoljno novca.");
    }
	Return 1;
}
Reply


Messages In This Thread
error 035: argument type mismatch (argument 1) - by StreetboyBalkan - 17.12.2013, 20:35
Re: error 035: argument type mismatch (argument 1) - by BlackWolf120 - 17.12.2013, 22:38

Forum Jump:


Users browsing this thread: 1 Guest(s)