for(new i = 0; i < MAX_PLAYERS; i++){if(IsPlayerConnected(i)){ if(IsPlayerInRangeOfPoint(i,10.0,X, Y, Z)) { format(cString,sizeof(cString),\"%s mondja:%s\",Nev(playerid),text[]); SendClientMessage(i,-1,cString); }}}stock Nev(playerid){new neve[MAX_PLAYER_NAME];GetPlayerName(playerid,neve,sizeof(neve));return neve;}
for(new i = 0; i < MAX_PLAYERS; i++){if(IsPlayerConnected(i)){ if(IsPlayerInRangeOfPoint(i,10.0,X, Y, Z)) { format(cString,sizeof(cString),\"%s mondja:%s\",Nev(playerid),text[]); SendClientMessage(i,-1,cString); }}}stock Nev(playerid){new neve[MAX_PLAYER_NAME];GetPlayerName(playerid,neve,sizeof(neve));return neve;} Valami hasonló megoldást láttam egy RP módban, fogalmam sincs mennyi mûködõ képes.
public OnPlayerText(playerid,text[]){new Float:Pos[3],str[128]; GetPlayerPos(playerid,Pos[0],Pos[1],Pos[2]); for(new i; i < GetMaxPlayers(); i++) { if(!IsPlayerConnected(i) || !IsPlayerInRangeOfPoint(i,10.0,Pos[0],Pos[1],Pos[2])) { continue; } format(str,sizeof(str),\"%s mondja:%s\",Nev(playerid),text); SendClientMessage(i,0xFFFFFFFF,str);}return 0;}stock Nev(playerid){new neve[MAX_PLAYER_NAME]; GetPlayerName(playerid,neve,sizeof(neve)); return neve;}