09.03.2015, 20:49
With player you have first to format your message:
Also check out format wiki documentation
pawn Код:
new
message[23 + MAX_PLAYER_NAME], // We only need space for "Player " +player name " has used /hello" + end of string indicator
playername[MAX_PLAYER_NAME + 1]
;
GetPlayerName(playerid, playername, sizeof(playername)); //You have to pass playerid to function, in most command processors it's by default passed (ZCMD/YCMD)
format(message, sizeof(message), "Player %s has used /hello", playername);
SendClientMessageToAll(0xBADA55FF, message);