24.04.2010, 10:11
Hello,
I've made a function to send /me messages simply to that are in your sight. The problem is it doesen't work. The player who types the /me command receive it, but the other players doesent get it. Here's my code:
Who can help me to fix this?
Greetz,
Sean5874
I've made a function to send /me messages simply to that are in your sight. The problem is it doesen't work. The player who types the /me command receive it, but the other players doesent get it. Here's my code:
Код:
// the /me command if(strcmp("/me", cmd, true) == 0) { new str3[128]; format(str3, 128, "%s %s",pname,cmdtext[3]); SendMeMessage(str3); return 1; }
Код:
// the function public SendMeMessage(const msgstring[]) { new playerid; new Float:myX, Float:myY, Float:myZ; GetPlayerPos(playerid, myX, myY, myZ); for(new i; i<MAX_PLAYERS; i++) { if(IsPlayerInRangeOfPoint(i, 7.0, myX, myY, myZ)) { SendClientMessage(i, 0xEE66EEFF, msgstring); return 1; } } }
Greetz,
Sean5874