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

This is the code I have done

Код:
	if(dialogid == 5)
	{
		if(response == 0) return SendClientMessage(playerid, COL_RED, "You have closed the help dialog.");
		switch(listitem)
		{
		    case 0:
			{
			ShowPlayerDialog(playerid, DIALOG_HELP_OTHER, DIALOG_STYLE_MSGBOX, "General", "{F81414}Not finished yet", "Okay", "");
			}
			
			case 1:
			{
			ShowPlayerDialog(playerid, DIALOG_HELP_CAR, DIALOG_STYLE_MSGBOX, "Car", "{F81414}Not finished yet", "Okay", "");
			}

			case 2:
		    {
			ShowPlayerDialog(playerid, DIALOG_HELP_ANIMATION, DIALOG_STYLE_MSGBOX, "Animations", "/drunk", "Okay", "");
			}
		}
	}
This is the error

Код:
error 035: argument type mismatch (argument 2)
The line where the error is coming from

Код:
		if(response == 0) return SendClientMessage(playerid, COL_RED, "You have closed the help dialog.");
Reply
#2

COL_RED must be defined as a number but it's defined as a string.

Change to:
pawn Код:
if(response == 0) return SendClientMessage(playerid, COLOR_RED, "You have closed the help dialog.");
and add:
pawn Код:
#define COLOR_RED 0xFF0000FF
Reply
#3

Thanks it worked. My define was
Код:
#define COL_RED "{F81414}"
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)