PHP код:
if(strcmp(cmd, "/me", true) == 0)
{
new mynew[1024];
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' ')) {
idx++;
}
new offset = idx;
new result[128];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1))) {
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result)) {
SendClientMessage(playerid, 0xFFFFFFFF, " /me [action]");
return 1;
}
format(mynew, sizeof(mynew), "* %s %s", GetName(playerid), result);
ProxDetector(30.0, playerid, mynew, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
return 1;
}