Argument type mismatch - 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: Argument type mismatch (
/showthread.php?tid=650415)
Argument type mismatch -
NoteND - 27.02.2018
Hey!
Basicly check pastebin for what my script looks like, and I get this error on under OnPlayerConnect.
https://pastebin.com/7v7DFkhp
" argument type mismatch (argument 2) "
Re: Argument type mismatch -
Sew_Sumi - 27.02.2018
Because that's not how you use the enum, as it's not an array.
You also need to complete the enum, as it's incomplete.
https://sampforum.blast.hk/showthread.php?tid=318307
Re: Argument type mismatch -
NoteND - 27.02.2018
well I also got this: new pInfo[MAX_PLAYERS][PlayerData];
Re: Argument type mismatch -
Sew_Sumi - 27.02.2018
Then you reference pInfo[playerid][pName].
Don't forgo reading and learning to script.
Re: Argument type mismatch -
NoteND - 27.02.2018
Thanks Sew_Sumi, fixed my problem, this is line at end:
GetPlayerName(playerid, pInfo[playerid][pName], MAX_PLAYER_NAME);