31.10.2009, 21:40
you didnt format your string correctly to display the text.
Try this:
I'd recommend using sscanf and zcmd. Hope that helps. Good Luck.
Try this:
pawn Код:
if(!strcmp(cmdtext,"/d",true,2))
{
if(!strlen(cmdtext[2])) return SendClientMessage(playerid, 0xAFAFAFAA, "USAGE: /d [text]");
new playername[MAX_PLAYER_NAME], string[128];
GetPlayerName(playerid, playername, sizeof(playername));
for(new i = 0; i < MAX_PLAYERS; i++)
{
format(string, sizeof(string), "Police [%s]: %s, over", playername, cmdtext[2])
if(gTeam[playerid] == TEAM_LSPD)
{
SendClientMessage(playerid, COLOR_GOLD, string);
}
}
return 1;
}