01.05.2012, 18:32
tб ai mano..
isso deve resolver seu problema..
isso deve resolver seu problema..
pawn Код:
//topo do gm:
new mncorregedor[MAX_PLAYERS];
//OnPlayerCommandtext
if (strcmp(cmd, "/chatc", true) == 0 && IsPlayerAdmin(playerid)) {
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' ')) {
idx++;
}
new offset = idx;
new result[64];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1))) {
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if (!strlen(result)) {
SendClientMessage(playerid, COLOR_GRAD2, "USE: /chatc [texto]");
return 1;
}
new str[128];
new szPlayerName[MAX_PLAYER_NAME];
GetPlayerName(playerid, szPlayerName, MAX_PLAYER_NAME);
if (corregedor(playerid)) {
format(str, 128, "* Corregedor %s: %s", szPlayerName, result);
SendClientMessage(playerid, LARANJA, str);
}
return 1;
}