Get ID with PlayerInfo
#1

Hi, ( Sorry for my english, i'm FR.. ! )

I have make a system for /nameoff with ID ( ex: Inconnu_18293 )

And i want retrieve the id of "unknow player" ( /nameoff player )

Код:
	else if(strcmp(cmd, "/inconnu", true) == 0)
	{
	    tmp = strtok(cmdtext, idx);
		new param1 = strval(tmp);
		if (!pack_isAdmin(playerid, 8))
			{SendClientMessage(playerid, COLOR_SERVER, noAcces); return 1;}
		if(!strlen(tmp))
			{SendClientMessage(playerid, COLOR_USAGE, "{FF6600}[Action]{99EEFF} /inconnu [ID inconnu]"); return 1;}
		for(i = MIN_PLAYERID; i < MAX_PLAYERS_CURRENT+1; i++)
		{
			if(param1 == idnomoff[i])
			{
 				new playername23[64], string23[150];
		  		GetPlayerName(i, playername23, sizeof(playername23));
		  		format(string23, sizeof(string23), "L'inconnu_%d est %s", param1, playername23);
		  		SendClientMessage(playerid, COLOR_WHITE, string23);
			}
			else
			{
		   		SendClientMessage(playerid, COLOR_WHITE, "Inconnu introuvable");
		   		return 1;
			}
		}
		return 1;
	}
My command returns always "Inconnu introuvable"

I am doing something wrong ..?

ty..
Reply


Messages In This Thread
Get ID with PlayerInfo - by introx - 29.01.2016, 08:47
Re: Get ID with PlayerInfo - by Tamy - 29.01.2016, 09:24
Re: Get ID with PlayerInfo - by introx - 29.01.2016, 09:28
Re: Get ID with PlayerInfo - by Tamy - 29.01.2016, 09:40
Re: Get ID with PlayerInfo - by introx - 29.01.2016, 09:47
Re: Get ID with PlayerInfo - by introx - 29.01.2016, 09:51
Re: Get ID with PlayerInfo - by Tamy - 29.01.2016, 10:50
Re: Get ID with PlayerInfo - by introx - 29.01.2016, 11:52
Re: Get ID with PlayerInfo - by Tamy - 29.01.2016, 12:30

Forum Jump:


Users browsing this thread: 1 Guest(s)