16.11.2013, 15:47
I created a simple function for you
Replace
To
pawn Код:
stock SendNearMessage(playerid, color, string[], Float:radius)
{
new Float:Position[3];
GetPlayerPos(playerid,Position[0],Position[1],Position[2]);
for(new i; i <= MAX_PLAYERS; i++)
{
if(!IsPlayerConnected(playerid)) continue;
if(IsPlayerInRangeOfPoint(i,radius, Position[0],Position[1],Position[2]))
return SendClientMessage(i, color, string);
}
return 1;
}
pawn Код:
SendClientMessageToAll(COLOR_PURPLE, RandomMSG[randMSG]);
pawn Код:
SendNearMessage(playerid, COLOR_PURPLE, RandomMSG[randMSG], 15.0);