Error 25, 35, 47.
#1

So I compiled my script and removed most of the errors but I'm stuck with 4 errors.
error 025: function heading differs from prototype [LINE: 8795]
error 035: argument type mismatch (argument 2) [LINE: 14379]
error 047: array sizes do not match, or destination array is too small [LINE: 21666]
error 047: array sizes do not match, or destination array is too small [LINE: 21887]

These are the code(s);
Код:
stock OnPlayerLogin(playerid, password[]) // THIS IS THE ERROR LINE
{
	new 
		sqlQuery[300], 
		password2 = num_hash(password)
	;
	format(sqlQuery, sizeof(sqlQuery), "SELECT * FROM samp_users WHERE `Username`='%s' AND `Password`='%d'", GPN(playerid), password2);
	mysql_query(sqlQuery, THREAD_LOGIN, playerid);
	return 1;
}
Код:
	if(dialogid == 1245)
	{
		if(response)
		{
			strmid(Typed[playerid], inputtext, 0, strlen(inputtext), 255);
			if(!strcmp(Typed[playerid], "None", true))
			{
				ShowPlayerDialog(playerid, 1245, DIALOG_STYLE_PASSWORD,"Try Again, Please Log-In","You didn't type a password!\nType your password below to log-in","Log-in","Quit");
			}
			else
			{
				OnPlayerLogin(playerid, inputtext); // THIS IS THE ERROR LINE
			}
		}
		else
		{
			Kick(playerid);
		}
	}
Код:
	if(MarriageCeremoney[playerid] > 0)
	{
	    new idx;
	    tmp = strtok(text, idx); // THIS IS THE ERROR LINE
	    if ((strcmp("yes", tmp, true, strlen(tmp)) == 0) && (strlen(tmp) == strlen("yes")))
		{
		    if(GotProposedBy[playerid] < 999)
		    {
			    if(IsPlayerConnected(GotProposedBy[playerid]))
				{
					GetPlayerName(playerid, sendername, sizeof(sendername));
					GetPlayerName(GotProposedBy[playerid], giveplayer, sizeof(giveplayer));
				    format(string, sizeof(string), "Priest: %s do you take %s as your lovely Wife? (type 'yes', anything else will reject the Marriage).", giveplayer,sendername);
					SCM(GotProposedBy[playerid], COLOR_WHITE, string);
					MarriageCeremoney[GotProposedBy[playerid]] = 1;
					MarriageCeremoney[playerid] = 0;
					GotProposedBy[playerid] = 999;
				    return 1;
			    }
Код:
	if(Mobile[playerid] != 255)
	{
		new idx;
		tmp = strtok(text, idx); // THIS IS ERROR LINE
		GetPlayerName(playerid, sendername, sizeof(sendername));
		if(UnidentifedCall[playerid] == 1)
		{
		    format(string, sizeof(string), "Stranger Says (cellphone): %s", text);
		}
		else
		{
			format(string, sizeof(string), "%s Says (cellphone): %s", sendername, text);
		}
        ProxDetector(20.0, playerid, string,COLOR_FADE1,COLOR_FADE2,COLOR_FADE3,COLOR_FADE4,COLOR_FADE5);
Any help is amazing, thanks guys. + Rep who helps me.
Reply
#2

sqlQuery[600] ??
Reply
#3

Fixed, thanks.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)