Problem command /ann
#1

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;
}
Reply


Messages In This Thread
Problem command /ann - by KamilPolska - 31.12.2018, 03:47
Re: Problem command /ann - by GeorgeLimit - 31.12.2018, 05:33
Re: Problem command /ann - by Threshold - 31.12.2018, 06:25

Forum Jump:


Users browsing this thread: 1 Guest(s)