[Ajuda] Procurar nome
#1

Queria fazer um sistema de ir pro a/d sу quem esta com uma tag especifica mais ta dando erro ;-;

Код:
new name[MAX_PLAYER_NAME],
        azt[MAX_PLAYER_NAME]; //<< TODOS QUE TIVER COM A TAG AZT VAI PRO A/D
	for (new i = 0; i < MAX_PLAYERS; i++)
	{
		if(IsPlayerConnected(i))
		{
			if(name[i] == azt[i]); // << linha do erro
			GetPlayerName(i, name, MAX_PLAYER_NAME);
			AAD_Vai[i] = 0;
}
Reply
#2

Comparaзгo de valores normal й usada para inteiros.

Para strings use strcmp.

Recomendo vocк fazer uma verificaзгo com strfind aн.
Reply
#3

pawn Код:
GetPlayerName(playerid, player, sizeof(player));
if(strfind(player,"AZT,true) != -1)
{
..... lalalala
}
Reply
#4

Valeu :d
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)