Little error with one command
#1

Код:
CMD:ekazi(playerid, params[])
{
	new tekst[128], string[128], id;
	new Float:x, Float:y, Float:z;
	if(PlayerInfo[playerid][pAdmin] < 1)return SendClientMessage(playerid, COLOR_WHITE, "Samo admini");
	GetPlayerPos(playerid, x, y, z);
 	if(IsPlayerInRangeOfPoint(playerid, 20.0, x, y, z));
 	{
		format(string, sizeof(string), "(( Admin %s: %s ))", PlayerName(playerid), tekst);
		SendClientMessage(id, -1, string);
	}
	return 1;
}
error:
Код:
C:\Users\toni\Desktop\Gang War Los Santos 0.3e\gamemodes\mod2.pwn(2865) : error 036: empty statement
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply
#2

change

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 20.0, x, y, z));
replace it with

pawn Код:
if(IsPlayerInRangeOfPoint(playerid, 20.0, x, y, z))
Reply
#3

now i made command:
Код:
CMD:e(playerid, params[])
{
	new tekst[128], string[128], id;
	new Float:x, Float:y, Float:z;
	if(PlayerInfo[playerid][pAdmin] < 1)return SendClientMessage(playerid, COLOR_WHITE, "Samo admini");
	else if(sscanf(params, "s[128]", tekst))return SendClientMessage(playerid, COLOR_WHITE, "/e [Tekst]");
	GetPlayerPos(playerid, x, y, z);
 	if(IsPlayerInRangeOfPoint(playerid, 100.0, x, y, z))
 	{
		format(string, sizeof(string), "(( Admin %s: %s ))", PlayerName(playerid), tekst);
		SendClientMessage(id, -1, string);
	}
	return 1;
}
but i want hat this message can see only players in range, how to make this?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)