31.12.2018, 03:47
I have a problem. When entering a command, for example: /ann Welco~k~me it gets a crash. Could it be fixed?
Код:
CMD:ann(playerid, params[]) { new text[128], ann_b[][] = {"~f~", "~k~", "~o~"}; if(sscanf(params, "s[128]", text)) { SendClientMessage(playerid, -1, "Usage: /ann [text]"); return 1; } for(new i, find; i < sizeof(ann_b); i++) { if((find = strfind(text, ann_b[i], true), find) != -1) { SendClientMessage(playerid, -1, "Wrong!"); return 1; } } GameTextForAll(text, 10000, 4); return 1; }