01.09.2011, 13:28
pawn Код:
public OnPlayerText(playerid, text[])
{
if(text[0] = ';' && text[1] = ' ')
{
new
Float:p[3],
string[128],
player[MAX_PLAYER_NAME];
GetPlayerName(playerid, player, sizeof(player));
GetPlayerPos(playerid, p[0], p[1], p[2]);
strdel(text, 0, 2);
format(string, sizeof(string), "%s: %d %s", player, playerid, text);
for(new i = 0; i < GetMaxPlayers(); i++)
{
if(IsPlayerConnected(i) && IsPlayerInRangeOfPoint(i, 25.0, p[0], p[1], p[2]))
{
SendClientMessage(i, -1, string);
}
}
return false;
}
return true;
}