20.08.2009, 15:16
OnPlayerText, if text[0] == '(' and !text[1] then fire off your command but return 0 at the end so the ( doesnt show up in chat.
Код:
if(text[0] == '(' && !text[1]) { new pName[MAX_PLAYER_NAME],string[256]; GetPlayerName(playerid,pName,sizeof(pName)); format(string,sizeof(string),"((%s: %s))",pName,params[0]); if(OOCChat == 1) { SendClientMessageToAll(0xD0F3D4AA,string); } else if(OOCChat == 0) return SendClientMessage(playerid,COLOR_DARKRED,"OOC CHAT DISABLED"); return 0; }