IP Join script
#1

I have made this script with the intention to display the IP of a player when he connects
Код:
public OnPlayerConnect(playerid)
{
	new name[MAX_PLAYER_NAME], string[128];
	new para1, ip[17];
	
	GetPlayerName(para1, name, sizeof(name));
	GetPlayerIp(para1, ip, sizeof(ip));
	
	if(Player[playerid][pAdmin] >= 1 && IsPlayerAdmin(playerid))
	format(string, sizeof(string), "[ADMIN] Player %s has connected with IP: %d", name, ip);
	SendAdminMessage(-1, string);
	return 1;
}
the message is not shown however, why would that be?

Also, my givegun script is acting weird - I have put:
Код:
	if(!( 1 <= ammo <= 999 )) 
		return SCM(playerid, -1, "The gun ammo must be between 1-999!");
But if I put in a value between 1-999 (e.g 500) it says it the ammo must be between 1-999.
I have seen this in the server console: sscanf warning: Format specifier does not match parameter count.
What does this mean?
Reply


Messages In This Thread
IP Join script - by JXF - 31.05.2016, 01:22
Re: IP Join script - by justice96 - 31.05.2016, 01:35
Re: IP Join script - by saffierr - 31.05.2016, 07:20
Re: IP Join script - by Dayrion - 31.05.2016, 08:37
Re: IP Join script - by J0sh... - 31.05.2016, 08:41
Re: IP Join script - by JXF - 31.05.2016, 12:14
Re: IP Join script - by Dayrion - 31.05.2016, 12:25
Re: IP Join script - by JXF - 31.05.2016, 12:37
Re: IP Join script - by F1N4L - 31.05.2016, 12:43
Re: IP Join script - by JXF - 31.05.2016, 13:27

Forum Jump:


Users browsing this thread: 1 Guest(s)