SA-MP Forums Archive
rror 035: argument type mismatch (argument 3) - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: rror 035: argument type mismatch (argument 3) (/showthread.php?tid=511468)



rror 035: argument type mismatch (argument 3) - IGeorge - 05.05.2014

It gives me error error 035: argument type mismatch (argument 3). . Why?

else if(IDArme[playerid] == 14)
{
GivePlayerWeapon(playerid, 14, inputtext); // On donne des fleurs
}


Re: rror 035: argument type mismatch (argument 3) - KillerStrike23 - 05.05.2014

dude show the full code or edit GivePlayerWeapon(playerid, weaponid, ammo); whats wrong with ya people check samp wiki


Re: rror 035: argument type mismatch (argument 3) - Konstantinos - 05.05.2014

The 3rd argument of the function GivePlayerWeapon is ammo and it's integer. inputtext is string; hence you get the warning. If inputtext holds the ammo, then use strval function to convert a string to an integer.


Re: rror 035: argument type mismatch (argument 3) - IGeorge - 05.05.2014

No offense but can not do. . Could you give an example. .?


Re: rror 035: argument type mismatch (argument 3) - Konstantinos - 05.05.2014

Only if what I said above is true will work:
pawn Code:
GivePlayerWeapon(playerid, 14, strval(inputtext));



Re: rror 035: argument type mismatch (argument 3) - IGeorge - 05.05.2014

Thank you !